Project

Profile

Help

Story #3173

Updated by dkliban@redhat.com about 2 years ago

The syncing with an importer portion of the plugin writer's guide needs to A user should be updated. The guide needs able to explain that it's the author's responsibility make POST request to

- define
/api/v3/repositories/<id>/versions/ in order to create a UserFacingTask that creates a new RepositoryVersion of a repository by syncing with a specific importer.
-
version. The user should be able to provide 3 optional arguments: importer, add_content_units, and remove_content_units. This task should implement the first option while #3234 will implement the last two.

A
task should be spawned to create a new repository version. The repository version starts with the content from previous version, if any, and add it then uses the importer to import units, and then adds units from add_content_units, then removes content from remove_content_units.

The ViewSet for
the task's created list in a single transaction
-
RepositoryVersion model needs to be extended to handle POST requests.

The detail 'sync' view for
the Importer viewset needs to be removed.

The sync
task in pulp/pulpcore/pulpcore/app/tasks/importer.py needs to be removed.

A repository_version task
should add / remove content using the Importer be added to drive pulp/pulpcore/pulpcore/app/tasks/repository.py

The new task should implement
the download API
- the
algorithm described above. The task should set the repository version's to complete field to true after all content manipulation is done
- define a detail route
lock on the Importer ViewSet for 'sync' that accepts a 'repository' POST body parameter
-
importer, the route should perform validation new repository version, and then dispatch the the sync associated repository itself. The task with reservations for the should produce a new repository and version even if the importer. content has not changed.

Back