Project

Profile

Help

Task #2407

closed

Convert celery task repository.delete to Pulp 3

Added by ttereshc about 8 years ago. Updated almost 5 years ago.

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

100%

Estimated time:
Platform Release:
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
Sprint:
Sprint 11
Quarter:

Description

Task name in Pulp 2: `pulp.server.tasks.repository.delete`.
Task implementation in Pulp 2: https://github.com/pulp/pulp/blob/3.0-dev/server/pulp/server/controllers/repository.py#L480


Related issues

Related to Pulp - Task #2380: Create a redmine task for each 2.y celery task to be converted to 3.0CLOSED - CURRENTRELEASEttereshc

Actions
Actions #1

Updated by ttereshc about 8 years ago

  • Related to Task #2380: Create a redmine task for each 2.y celery task to be converted to 3.0 added
Actions #2

Updated by ttereshc about 8 years ago

  • Tags Pulp 3 added
Actions #3

Updated by bmbouter about 8 years ago

Does a repo delete still need to be run by the tasking system or could it be a CRUD operation in the view layer only?

If I'm reading this right, I believe the only thing this task has to do are these 2 lines[0].

  • For example the model layer will cascade delete all importers and publishers when a repo is deleted because of this[1].
  • The exception handling is now handled centrally so this task doesn't need to deal with that
  • The consumer actions are no longer in Pulp3

The only area that may continue to be needed could be the group membership stuff, but adding that could be the responsibility of the work to implement to group stuff correctly.

[0]: https://github.com/pulp/pulp/blob/c3e4e6514748ad24df27f64303ba3f226dc3f396/server/pulp/server/controllers/repository.py#L518-L519
[1]: https://github.com/pulp/pulp/blob/8c23b326cdb7739c420fdff8538a66e73147e0fb/app/pulp/app/models/repository.py#L112

Actions #4

Updated by mhrivnak about 8 years ago

bmbouter wrote:

Does a repo delete still need to be run by the tasking system or could it be a CRUD operation in the view layer only?

Great question, and one that's been on my mind also. I think there are two reasons why pulp 2 has similar CRUD operations in tasks.

1) to update consumers. It really just needs to queue tasks to update the consumers, but that itself can take some time.

2) to ensure that a repo does not get deleted (or modified, importer/publisher included) while some other task is operating on it, such as a sync.

Reason 1 won't apply in pulp 3. But much of reason 2 still applies. I would like to do some CRUD operations not as tasks, and have sync/publish/etc tasks be prepared to deal with that (by using some combination of a transaction, and just loading what it needs once up-front and never again). But that brings its own set of edge cases, and it seems easier and safer to stick with the current model of doing most repo UD with the safety of a resource lock.

Actions #5

Updated by mhrivnak about 8 years ago

  • Sprint Candidate changed from No to Yes
Actions #6

Updated by bmbouter about 8 years ago

  • Groomed changed from No to Yes

Yes let's keep it as a task

Actions #7

Updated by mhrivnak about 8 years ago

  • Sprint/Milestone set to 29
Actions #8

Updated by jortel@redhat.com about 8 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to jortel@redhat.com
Actions #9

Updated by jortel@redhat.com about 8 years ago

  • Status changed from ASSIGNED to NEW
  • Assignee deleted (jortel@redhat.com)
Actions #10

Updated by ipanova@redhat.com almost 8 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to ipanova@redhat.com
Actions #11

Updated by ipanova@redhat.com almost 8 years ago

  • Status changed from ASSIGNED to POST
Actions #12

Updated by ipanova@redhat.com almost 8 years ago

What is the status with repo sync/publish result collections, are we going to create those in the future or we have some other plans?
https://github.com/pulp/pulp/blob/3.0-dev/server/pulp/server/controllers/repository.py#L527-L528

Actions #13

Updated by mhrivnak almost 8 years ago

I think we are deliberately omitting that from the MVP so we can think about better ways to store similar history.

Added by ipanova@redhat.com almost 8 years ago

Revision 50ce6ba7 | View on GitHub

Convert celery task repository.delete

closes #2407 https://pulp.plan.io/issues/2407

Added by ipanova@redhat.com almost 8 years ago

Revision 50ce6ba7 | View on GitHub

Convert celery task repository.delete

closes #2407 https://pulp.plan.io/issues/2407

Actions #14

Updated by ipanova@redhat.com almost 8 years ago

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

Updated by bmbouter over 6 years ago

  • Sprint set to Sprint 11
Actions #16

Updated by bmbouter over 6 years ago

  • Sprint/Milestone deleted (29)
Actions #17

Updated by daviddavis over 5 years ago

  • Sprint/Milestone set to 3.0.0
Actions #18

Updated by bmbouter over 5 years ago

  • Tags deleted (Pulp 3)
Actions #19

Updated by bmbouter almost 5 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF