Project

Profile

Help

Story #4172

Remove duplicate tags from repository during sync

Added by amacdona@redhat.com almost 2 years ago. Updated 9 months ago.

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

100%

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

Description

The docker plugin has repository version uniqueness constraints for Tags. For example the Tag with name "latest" points to a Manifest List. Another Tag with name "latest" (pointing to another Manifest List) cannot be added to the repository version while the first "latest" tag remains. Note: This repository version could have a "latest" that points to a manifest instead of a manifest list.

At this point, we don't think this uniqueness constraint can exist in the db, so we need to enforce the constraint at sync time (and later during add/remove.

During sync, before the new tags are added to the repository version, corresponding tags that are already in the repository version should be removed.

Heres an example:
RepositoryVersion1 contains a tag, "latest" which points to ManifestList1. A sync retrieves a new Tag "latest" that points to ManifestList2. Before "latest"-> ManifestList2 is added to the repository version, "latest"->ManifestList1 must be removed.

For implementation, this probably should be a new Stage, which could be the last item in the pipeline. (Add/remove stages are added outside of the plugin-defined pipeline.)


Related issues

Blocked by Pulp - Story #3934: As a plugin writer, I can have a stage that removes duplicatesCLOSED - CURRENTRELEASE

<a title="Actions" class="icon-only icon-actions js-contextmenu" href="#">Actions</a>
Copied to Container Support - Test #4299: Remove duplicate tags from repository during syncNEW<a title="Actions" class="icon-only icon-actions js-contextmenu" href="#">Actions</a>

Associated revisions

Revision 7f79cd73 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Remove non-unique tag names during sync

When syncing, if a tag name references a different manifest/manifest list it must be removed from the repo. To do this simply, it was more convinient to split the Tag model into ManifestTag and ManifestListTag.

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

Revision f871b7d5 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Distribute tags according to requested media type

Return the artifacts associated with a tag with type failover. Try manifest list first, then manifest schema 2. If both fail, log the warning and return a 404. This provides a convinient location for an on-the-fly schema converter.

These changes are necessary to use the split-tag models for distribution, so they will be merged as a part of #4172.

https://pulp.plan.io/issues/4172 re #4172

Revision 7f79cd73 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Remove non-unique tag names during sync

When syncing, if a tag name references a different manifest/manifest list it must be removed from the repo. To do this simply, it was more convinient to split the Tag model into ManifestTag and ManifestListTag.

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

Revision f871b7d5 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Distribute tags according to requested media type

Return the artifacts associated with a tag with type failover. Try manifest list first, then manifest schema 2. If both fail, log the warning and return a 404. This provides a convinient location for an on-the-fly schema converter.

These changes are necessary to use the split-tag models for distribution, so they will be merged as a part of #4172.

https://pulp.plan.io/issues/4172 re #4172

Revision 7f79cd73 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Remove non-unique tag names during sync

When syncing, if a tag name references a different manifest/manifest list it must be removed from the repo. To do this simply, it was more convinient to split the Tag model into ManifestTag and ManifestListTag.

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

Revision f871b7d5 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Distribute tags according to requested media type

Return the artifacts associated with a tag with type failover. Try manifest list first, then manifest schema 2. If both fail, log the warning and return a 404. This provides a convinient location for an on-the-fly schema converter.

These changes are necessary to use the split-tag models for distribution, so they will be merged as a part of #4172.

https://pulp.plan.io/issues/4172 re #4172

Revision 7f79cd73 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Remove non-unique tag names during sync

When syncing, if a tag name references a different manifest/manifest list it must be removed from the repo. To do this simply, it was more convinient to split the Tag model into ManifestTag and ManifestListTag.

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

Revision f871b7d5 View on GitHub
Added by amacdona@redhat.com almost 2 years ago

Distribute tags according to requested media type

Return the artifacts associated with a tag with type failover. Try manifest list first, then manifest schema 2. If both fail, log the warning and return a 404. This provides a convinient location for an on-the-fly schema converter.

These changes are necessary to use the split-tag models for distribution, so they will be merged as a part of #4172.

https://pulp.plan.io/issues/4172 re #4172

History

#1 Updated by ipanova@redhat.com almost 2 years ago

  • Groomed changed from No to Yes
  • Sprint Candidate changed from No to Yes

#2 Updated by amacdona@redhat.com almost 2 years ago

  • Related to Story #3934: As a plugin writer, I can have a stage that removes duplicates added

#3 Updated by amacdona@redhat.com almost 2 years ago

  • Related to deleted (Story #3934: As a plugin writer, I can have a stage that removes duplicates)

#4 Updated by amacdona@redhat.com almost 2 years ago

  • Blocked by Story #3934: As a plugin writer, I can have a stage that removes duplicates added

#5 Updated by amacdona@redhat.com almost 2 years ago

  • Sprint set to Sprint 46

#6 Updated by amacdona@redhat.com almost 2 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to amacdona@redhat.com

#7 Updated by amacdona@redhat.com almost 2 years ago

  • Status changed from ASSIGNED to MODIFIED
  • % Done changed from 0 to 100

#9 Updated by bherring almost 2 years ago

  • Copied to Test #4299: Remove duplicate tags from repository during sync added

#10 Updated by bmbouter over 1 year ago

  • Tags deleted (Pulp 3)

#11 Updated by ipanova@redhat.com 11 months ago

  • Project changed from Docker Support to Container Support

#12 Updated by bmbouter 11 months ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

#13 Updated by ipanova@redhat.com 9 months ago

  • Sprint/Milestone set to 1.0.0

Please register to edit this issue

Also available in: Atom PDF