Project

Profile

Help

Story #8250

closed

As a user, all advisory conflicts are resolved automagically

Added by ttereshc almost 4 years ago. Updated over 3 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Sprint/Milestone:
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
Groomed:
No
Sprint Candidate:
No
Tags:
Katello
Sprint:
Sprint 93
Quarter:

Description

Motivation

There are situations when Pulp raises an AdvisoryConflict exception and fails a sync or copy task.
In such cases, manual resolution is needed.
It's neither easy, nor straightforward in some cases for user to resolve it.

Situation 1
Updated date and version are the same but pkglists differ (and one is not a subset or superset of the other).
E.g. It's likely a mistake in one of the pkglists.

Manual resolution:

  • look at both and decide which one to keep
  • if the "bad" one is in Pulp, remove it from Pulp (remove from every repo version and run orphan cleanup)
  • if the "bad" one is in a remote source, contact remote source and ask them to fix it

Situation 2
Updated dates are different but pkglists have no intersection at all.
E.g. It's either and attempt to combine content from incompatible repos (RHEL6-main and RHEL7 debuginfo), or someone created a completely different advisory with already used id.

Manual resolution:

  • look at both and decide what's wrong
  • maybe pick one if it works for user's case (pick one = either remove from Pulp or do not add a remote one)
  • maybe change what is added to a repo if it was a mistake (e.g. to combine RHEL6-main and RHEL7-debuginfo)

Proposed solution

Since Pulp cannot safely resolve conflicts in the situations described earlier, any automatic resolution would be at user's own risk.

Introduce a global configuration ALLOW_UNSAFE_ADVISORY_CONFLICT_RESOLUTION, which defaults to False.
When it is set to True:

  • for Situation 1, Pulp will produce a new advisory content unit with merged pkglists
  • for Situation 2, Pulp will pick a newer one

This is not on a roadmap, please leave a comment if you need this feature and what is your situation/use case.

Actions #1

Updated by ttereshc almost 4 years ago

  • Description updated (diff)
Actions #2

Updated by ttereshc almost 4 years ago

  • Description updated (diff)
Actions #3

Updated by jsherril@redhat.com almost 4 years ago

  • Tags Katello added
Actions #4

Updated by adam.winberg@smhi.se almost 4 years ago

I just encountered 'Situation 2', trying to copy erratas from RHEL8 repos to my frozen repos. For some reason a couple of old erratas had been updated from Red Hat with a new version, but copying them to my frozen repos failed since the pkglist in my frozen repos was empty for this advisory. The frozen repos are migrated from pulp2 which may be why the pkglist was empty.

So when using a pulp3 environment fed by 2to3-migration, it makes sense to me to assume that the newer advisory is the correct one since the error is most likely caused by bad metadata in the migrated repo.

Actions #5

Updated by dalley almost 4 years ago

  • Sprint set to Sprint 90
Actions #6

Updated by rchan almost 4 years ago

  • Sprint changed from Sprint 90 to Sprint 91
Actions #7

Updated by rchan over 3 years ago

  • Sprint changed from Sprint 91 to Sprint 92
Actions #8

Updated by pulpbot over 3 years ago

  • Status changed from NEW to POST
Actions #9

Updated by ggainey over 3 years ago

  • Assignee set to ggainey
Actions #10

Updated by rchan over 3 years ago

  • Sprint changed from Sprint 92 to Sprint 93

Added by ggainey over 3 years ago

Revision 651ee795 | View on GitHub

Added ALLOW_AUTOMATIC_UNSAFE_ADVISORY_CONFLICT_RESOLUTION.

Default is False.

closes #8250

Actions #11

Updated by ggainey over 3 years ago

  • Status changed from POST to MODIFIED
  • % Done changed from 0 to 100
Actions #12

Updated by dalley over 3 years ago

  • Sprint/Milestone set to 3.10.0
Actions #13

Updated by dalley over 3 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF