Project

Profile

Help

Issue #7291

closed

Advisory merge incorrectly reuses UpdateCollections

Added by ggainey over 3 years ago. Updated over 3 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Sprint 79
Quarter:

Description

When combining content to make a new repository-version, there is a specific edge-case that results in an advisory that exists in both places to be merged into a single new advisory. In this case, current pulp_rpm code "reuses" the UpdateCollections from the previous advisory in such a way that they 'belong to' both the previous and the newly-merged/created advisory.

This is a different usage-pattern than that used for any other sub-object of an advisory. It also prevents us from linking an UpdateCollection directly (and only) to its 'owning' advisory, which is desirable for a number of reasons (see #5740 and #7195 for examples)

We need to:

  • teach merge_advisories() to make a deep copy of the 'previous_advisory' collections and their packages
  • point the new copies at the new advisory
  • build a data-migration to find and fix existing instances of an UpdateCollection being linked to multiple advisories
Actions #1

Updated by ttereshc over 3 years ago

  • Description updated (diff)
  • Triaged changed from No to Yes
  • Sprint set to Sprint 78
Actions #2

Updated by pulpbot over 3 years ago

  • Status changed from ASSIGNED to POST
Actions #3

Updated by rchan over 3 years ago

  • Sprint changed from Sprint 78 to Sprint 79

Added by ggainey over 3 years ago

Revision 192a9035 | View on GitHub

Teach merge_advisory() to use its own copies of relevant UpdateCollections.

Added migration to clean up and data that is already in this broken state.

fixes #7291 [nocoverage]

Actions #4

Updated by ggainey over 3 years ago

  • Status changed from POST to MODIFIED
Actions #5

Updated by ttereshc over 3 years ago

  • Sprint/Milestone set to 3.6.0
Actions #6

Updated by pulpbot over 3 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF