As a plugin writer, I can iterate over repository versions in a memory efficient manner
Plugins need to iterate over the content in a repository version to create a publication. Pulp
should offer a batching iterator over content in order to limit the memory footprint and to allow
efficient use of content batches in DB operations.
We could make
batch_qs() available to plugin writers. But this generator is hard to use correctly because of the ordering requirement (even in pulpcore it has not been used correctly).
Instead, add a generator to
RepositoryVersion, which does "the right thing" by default and is customizable by plugin writers if necessary.
Added by gmbnomis almost 4 years ago
Add a batching content iterator
Plugins need to iterate over the content in a repository version to create a publication.
RepositoryVersion.content_batch_qs() generates content batches to
efficiently iterate over all content.