Project

Profile

Help

Story #5731

closed

Syncing creates RepositoryContent records even if no content was actually added

Added by daviddavis over 4 years ago. Updated over 4 years ago.

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

0%

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

Description

Problem

The workflow we have for errata merge:

1. During sync, we create new errata records and associate them to a repo version via RepositoryContent
2. In finalize_new_version we merge errata in the new version
3. Then we remove original errata which may have been just added in step 1

The problem is that the RepositoryContent content in step 1 still gets created and therefore will exist. It's useless and misleading to users. We have to add an extra step in pulp_rpm to delete these records.

Solution

In pulpcore, after finalize_new_version gets called, add a step which deletes any of these RepositoryContent where version_added and version_removed both point to your new version.


Related issues

Is duplicate of Pulp - Issue #5707: base_version can cause content can show as being added and removed in the same versionCLOSED - CURRENTRELEASEgmbnomisActions
Actions #1

Updated by daviddavis over 4 years ago

  • Description updated (diff)
Actions #2

Updated by daviddavis over 4 years ago

  • Subject changed from Syncing creates useless RepositoryContent records to Syncing creates RepositoryContent records even if no content was actually added
  • Description updated (diff)
Actions #3

Updated by daviddavis over 4 years ago

  • Tracker changed from Issue to Story
  • Sprint/Milestone deleted (3.0.0)
  • % Done set to 0
Actions #4

Updated by gmbnomis over 4 years ago

I think #5707 and this issue have the same root cause.

I think we have two conditions to fix:

- RepositoryContent where version_added and version_removed both point to your new version (the one mentioned above)
- RepositoryContent where version_removed and version_added both point to your new version. These need to be merged (e.g. 1-3 and 3- should become 1- )

As another implementation option, we could do the fixup directly when adding/removing content. Then, the add/remove quirks would not be visible to the finalizer.

Note that we also have the general problem that the finalizers currently operate on the wrong sets to begin with... (see #5706)

Actions #5

Updated by daviddavis over 4 years ago

  • Related to Issue #5707: base_version can cause content can show as being added and removed in the same version added
Actions #6

Updated by dalley over 4 years ago

@daviddavis, gmbnomis is this the same issue as the other one, and if so, is it fixed? Can we mark it fixed?

Actions #7

Updated by daviddavis over 4 years ago

Yup, closing this out.

Actions #8

Updated by daviddavis over 4 years ago

  • Status changed from NEW to MODIFIED
Actions #9

Updated by daviddavis over 4 years ago

  • Related to deleted (Issue #5707: base_version can cause content can show as being added and removed in the same version)
Actions #10

Updated by daviddavis over 4 years ago

  • Is duplicate of Issue #5707: base_version can cause content can show as being added and removed in the same version added
Actions #11

Updated by daviddavis over 4 years ago

  • Status changed from MODIFIED to CLOSED - DUPLICATE

Also available in: Atom PDF