Project

Profile

Help

Story #3360

Updated by daviddavis almost 6 years ago

***Motivation*** 

 As a user I want to be able to revert a repository at repository version Y to repository version X from before. 

 As a user I want to treat different lifecycle environments as separate repositories. When the 'dev' repository is ready to be promoted to the 'testing' repository, I want to create a new repository version of 'testing' that is exactly the same as a specific repository version of 'dev'.  

 Currently this can be achieved by: 

 1. Determine which units need to be added to the latest repository version Y and which need to be removed to achieve the same content set as repository version X. 
 2. Create a new repository version Z by using information from step 1. 

 Step 1 requires the user to create some tooling for calculating the diffs. The user then also has to make sure that nothing happens to the repository in between when the diff was computed and when the new repository version is created.  

 ***Solution*** 

 A user should be able to create a repository version by specifying an href for another repository version. This would remove the responsibility of finding deltas between repository versions from the user. 

 The /api/v3/repositories/<id>/versions/ API should accept a 'base_version' parameter. The base_version can point 'mirror_repository_version'. When specified, the new repository version is created to any repo version. The base_version param be exactly like the repository version specified. This parameter can not be used in conjunction combination with    'add_content_units' and 'remove_content_units' which modify the content from base_version. 'remove_content_units'.

Back