Project

Profile

Help

Story #5757

closed

As a user, I can expect that an empty repository version will always be created first on repo creation.

Added by iballou almost 3 years ago. Updated over 2 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:
No
Tags:
Katello
Sprint:
Sprint 62
Quarter:

Description

Katello relies on being able to create a repository and a publication before any content has been added to the repository. Since pulpcore no longer creates a repository version when no changes are being made, users are unable to create an 'empty' repository version. As a result, a publication can't be created either. In order to keep the behaviour of repository version creation consistent, it would be best if pulpcore simply created an empty repository version when a repository is created.

Actions #1

Updated by daviddavis almost 3 years ago

  • Sprint/Milestone set to 3.0.0
Actions #2

Updated by dkliban@redhat.com almost 3 years ago

  • Description updated (diff)

Each plugin is responsible for handling the requests to create a Repository resource. Pulpcore should provide a post_save() hook for the Repository master model. This hook should create a RepositoryVersion for the newly created Repository.

https://docs.djangoproject.com/en/2.2/ref/signals/#post-save

Actions #3

Updated by daviddavis almost 3 years ago

  • Groomed changed from No to Yes
  • Sprint set to Sprint 62
Actions #4

Updated by dkliban@redhat.com almost 3 years ago

We could probably accomplish this without overriding the post_save signal. We could simply override the save method to call super() and then create a RepositoryVersion.

We should also consider starting the version numbering with 0. A newly created repository has last_version set to 0 by default. After the repository version 0 is created, the repository would not need to be updated. If the empty repository version is number 1, then the Repository.last_version field needs to be updated.

Actions #5

Updated by daviddavis almost 3 years ago

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

Updated by daviddavis almost 3 years ago

  • Status changed from ASSIGNED to POST

Added by daviddavis almost 3 years ago

Revision 99b5b08b

Fix tests for new initial repo version change

ref #5757 https://pulp.plan.io/issues/5757

Added by daviddavis almost 3 years ago

Revision 4068a8fd

Create an initial repo version when repos get created

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

Required PR: https://github.com/pulp/pulp_file/pull/322

Actions #7

Updated by daviddavis almost 3 years ago

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

Updated by daviddavis almost 3 years ago

  • Status changed from MODIFIED to POST

Added by daviddavis almost 3 years ago

Revision 7d9c9668

Fix tests for new initial repo version change

ref #5757 https://pulp.plan.io/issues/5757

Required PR: https://github.com/pulp/pulpcore/pull/399

Added by daviddavis almost 3 years ago

Revision 562cdf65

Fix tests for new initial repo version change

ref #5757 https://pulp.plan.io/issues/5757

Required PR: https://github.com/pulp/pulpcore/pull/400

(cherry picked from commit 7d9c9668b1e999c2478c2c9ba2e0ff201d591041)

Added by daviddavis almost 3 years ago

Revision 0dcf0147

Create an initial repo version when repos get created

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

Required PR: https://github.com/pulp/pulp_file/pull/323

(cherry picked from commit 4068a8fd9f10c20836ecfbf3eaa7175c918c875a)

Added by daviddavis almost 3 years ago

Revision 83205629

Fix test for initial repo version

ref #5757

Added by daviddavis almost 3 years ago

Revision 83205629

Fix test for initial repo version

ref #5757

Added by daviddavis almost 3 years ago

Revision 2f91b292

Fix tests for initial repo version

ref #5757

Actions #9

Updated by daviddavis almost 3 years ago

  • Status changed from POST to MODIFIED
Actions #10

Updated by ipanova@redhat.com almost 3 years ago

  • Status changed from MODIFIED to POST

Added by daviddavis almost 3 years ago

Revision c910d5cd

Fix test for initial repo version

closes #5757

(cherry picked from commit 83205629a223fcbc4980bb3beb2f679df95a2f1d)

Added by daviddavis almost 3 years ago

Revision c910d5cd

Fix test for initial repo version

closes #5757

(cherry picked from commit 83205629a223fcbc4980bb3beb2f679df95a2f1d)

Actions #11

Updated by ipanova@redhat.com almost 3 years ago

  • Status changed from POST to MODIFIED

Added by daviddavis almost 3 years ago

Revision babb693c

Updating tests for initial repo version change

ref #5757

Added by daviddavis almost 3 years ago

Revision a9950883

Fix tests for initial repo version

ref #5757

(cherry picked from commit 2f91b292dd8b5d40a7baf428a1cfab09d92d0e07)

Actions #12

Updated by bmbouter almost 3 years ago

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

Updated by ggainey over 2 years ago

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

Also available in: Atom PDF