Project

Profile

Help

Story #4901

closed

Repository Version creation api should provide an easy way to clear out all units when adding new units

Added by jsherril@redhat.com almost 5 years ago. Updated almost 4 years ago.

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

100%

Estimated time:
Platform Release:
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
Katello
Sprint:
Sprint 54
Quarter:

Description

When creating a new repository version, its very easy to add units or remove units, but if I want to specify some list of units I want the repository version to have, i must first clear out all the existing units which is very cumbersome.

Solution

Allow users to specify ['*'] for remove_content_units. This will let users remove all content units from a repo version. They can also specify add_content_units which will add back units to the empty repo version.

Note that we'll need to change the current logic to add units after removing units. We want to document these behaviors clearly in the docs too.


Related issues

Related to Pulp - Test #4956: As a user, I can clear all units from a new repository versionCLOSED - COMPLETEkersomActions
Actions #1

Updated by jsherril@redhat.com almost 5 years ago

  • Tags Katello-P2 added
Actions #2

Updated by dkliban@redhat.com almost 5 years ago

What about letting the user submit ['*'] for remove_content_units?

Actions #3

Updated by bmbouter almost 5 years ago

@dkliban I was thinking the same thing! wow.

Actions #4

Updated by daviddavis almost 5 years ago

What if I submit a list of add_content_units (e.g. A, B, C) along with ['*'] for remove_content_units? Then my repo version has just A, B, C?

Actions #5

Updated by dkliban@redhat.com almost 5 years ago

Yes. However, I don't think that will happen always now. If A, B, C were in the previous version, they will not be present in the new version because we add first and then remove.

https://github.com/pulp/pulpcore/blob/master/pulpcore/app/tasks/repository.py#L72

Actions #6

Updated by daviddavis almost 5 years ago

  • Description updated (diff)
Actions #7

Updated by dkliban@redhat.com almost 5 years ago

  • Groomed changed from No to Yes
  • Sprint Candidate changed from No to Yes
  • Sprint set to Sprint 54
Actions #8

Updated by daviddavis almost 5 years ago

  • Tracker changed from Issue to Story
  • % Done set to 0
Actions #9

Updated by daviddavis almost 5 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to daviddavis
Actions #10

Updated by daviddavis almost 5 years ago

  • Related to Test #4956: As a user, I can clear all units from a new repository version added
Actions #11

Updated by daviddavis almost 5 years ago

Actions #12

Updated by daviddavis almost 5 years ago

Actions #13

Updated by daviddavis almost 5 years ago

Actions #14

Updated by daviddavis almost 5 years ago

  • Status changed from ASSIGNED to POST

Added by daviddavis almost 5 years ago

Revision 5c5bbfa4 | View on GitHub

Allow users to remove all content units from repo versions

fixes #4901 https://pulp.plan.io/issues/4901

Actions #15

Updated by daviddavis almost 5 years ago

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

Updated by bmbouter over 4 years ago

  • Sprint/Milestone set to 3.0.0
Actions #17

Updated by bmbouter over 4 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE
Actions #18

Updated by ggainey almost 4 years ago

  • Tags Katello added
  • Tags deleted (Katello-P2)

Also available in: Atom PDF