Add sync optimization support to pulp_file#7553
Open
Conversation
e2cff15 to
e2fb9cf
Compare
dralley
commented
Apr 4, 2026
| The ``repository`` field has to be provided. | ||
| """ | ||
| serializer = RepositorySyncURLSerializer( | ||
| serializer = FileRepositorySyncURLSerializer( |
Contributor
Author
There was a problem hiding this comment.
This is a little bit unfortunate.
The issue is that since PulpFile did not previously provide any extensions to RepositorySyncURLSerializer, RepositorySyncURLSerializer was literally baked into the API. So now the addition of a new field changes the actual type.
Which in turn means that the API bindings will break by merely adding it as an optional parameter.
If this is considered a breaking change, then I would likely need to strip this PR of everything but the task change, and maybe add a temporary setting in settings.py to allow some control over it, and then return the serializer / viewset changes later in 3.115
NOTE: we cannot actually enable this for a while due to zero downtime upgrade restrictions and possible breaking changes. Whe the manifest hasn't changed relative to the previous sync, we skip the sync, so long as the sync modes are compatible and such. This requires storing a bit of hidden metadata on the repository object.
Add serializer and viewset support for the feature, which couldn't be added earlier as it would have broken bindings and zero-downtime upgrades.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Whe the manifest hasn't changed relative to the previous sync, we skip the sync, so long as the sync modes are compatible and such.
This requires storing a bit of hidden metadata on the repository object.
📜 Checklist
See: Pull Request Walkthrough