Add support for pass-through publications. #3654
Conversation
|
Hello @jortel! Thanks for submitting the PR.
|
Codecov Report
@@ Coverage Diff @@
## master #3654 +/- ##
=========================================
- Coverage 56% 55.8% -0.21%
=========================================
Files 61 61
Lines 2680 2695 +15
=========================================
+ Hits 1501 1504 +3
- Misses 1179 1191 +12
Continue to review full report at Codecov.
|
|
I was thinking that pass_through was going to only be available to plugin writers. I have two concerns about this option be managed by users. First, I wonder if users (as opposed to plugin writers) can understand the intricacies of pass-through vs not. How will they know whether they need to create a pass-through publication vs not? Also, what if I have plugin and I don't want to allow my content to be published via pass-through publications? Edit: To give an example, in pulp_rpm we generate PublishedMetadata and probably don't want users to create publications via |
|
I think to kind of address the concerns in my previous comment, we could remove the |
|
This PR is exactly as I imagined it, including the create that only allows It's also not needed for the immediate use case. With pulp_ansible the plugin writer is making the Publication via plugin-code so the core API call isn't used there. |
|
I will remove the publication POST endpoint and supporting changes. |
|
LGTM |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This also looks good to me. Thank you so much @jortel this unblocks a plugin writer w/ pulp_ansible!
https://pulp.plan.io/issues/4020
Adds support for pass-through publications.
Publishers would still use the
Publicationcontext and may (optionally) set pass-through=True. In combination with this, the publisher can (optionally) addPublishedMetaand possiblyPublishedArtifactsto customize how the publication is composed.I still need to run EXMPLAIN to see what django has translated the content-artifact query to be sure it's efficient and using the indexes.
I'm not sure where/how to update the docs. I'm inclined to capture pass-through in planned more comprehensive docs rewrite stores.