Project

Profile

Help

Story #6376

closed

As a user, I can track Publications/Distributions and not remigrate them on every run

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

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

100%

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

Description

Motivation

Currently, Publications/Distributions are recreated on every run. It means that on every run, even if there were no changes all the metadata (for some plugins) needs to be regenerated and Publication and Distribution needs to be created.

Proposal

Track If there were any changes in pulp2 distributors. Check if there were any changes to repositories. Based on that information decide whether to recreate the Publications and Distributions or not

Track If there were any changes in pulp2 distributors

Similar to importers, this commit removed some initial attempts to track the distrubutors, see the deletion in mark_removed_resources and pre_migrate_*.

It's very important to delete all irrelevant Distributions, otherwise it's possible to have an overlapping base_paths which will fail migration.

  • Pulp2Distributor model for pre-migration needs a new field not_in_plan
  • Update not_in_plan accordingly in the mark_removed_resources step
  • Remove Publications and Distributions from Pulp 3 if their Pulp 2 counterpart is marked as not_in_plan
  • When pre-migrating a distributor, determine if there were any changes and mark it by setting is_migrated to False
  • When pre-migrating a distributor, if there are changes affected a publication or a distribution, remove a Publication or A Distribution associated with it.
Check if there were any changes to repositories
  • If a repository had any changes to the content, distributors for such repository needs to be marked as is_migrated=False and corresponding Publication/Distribution should be removed from Pulp 3.
Based on that information decide whether to recreate Publications and Distributions or not
  • At the migration step, create a Publication and/or a Distribution for each Pulp2Distributor has is_migrated=False
Actions #1

Updated by ttereshc over 4 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to ttereshc
  • Sprint set to Sprint 73
Actions #2

Updated by dalley over 4 years ago

  • Description updated (diff)
  • Groomed changed from No to Yes

Added by ttereshc over 4 years ago

Revision 5562f70f | View on GitHub

Track distributors, recreate Publications/Distributions only if needed

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

Added by ttereshc over 4 years ago

Revision 5562f70f | View on GitHub

Track distributors, recreate Publications/Distributions only if needed

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

Added by ttereshc over 4 years ago

Revision 5562f70f | View on GitHub

Track distributors, recreate Publications/Distributions only if needed

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

Actions #3

Updated by ttereshc over 4 years ago

  • Status changed from ASSIGNED to POST
Actions #4

Updated by rchan over 4 years ago

  • Sprint changed from Sprint 73 to Sprint 74
Actions #5

Updated by ttereshc over 4 years ago

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

Updated by ttereshc over 4 years ago

  • Sprint/Milestone set to 0.2.0
Actions #7

Updated by ttereshc over 4 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF