Project

General

Profile

InterServerSync » History » Revision 14

Revision 13 (Chris Duryee, 10/28/2015 02:02 PM) → Revision 14/34 (Chris Duryee, 10/28/2015 02:16 PM)

h1. InterServerSync 

 h3. What is ISS? 

 Inter-Server Sync is a feature designed to help users in two scenarios: 

  * users who have a connected Foreman/Katello instance and disconnected Foreman/Katello, who want to propogate data from the connected side of their network to the disconnected side. 
  * users who have a "main" Foreman/Katello and want to propogate some data (but not all data) to other instances. One example is for users who have "blessed" content views that are validated by the IT department, and want to propogate those down elsewhere. 

 More info is available at https://fedorahosted.org/spacewalk/wiki/InterSpacewalkServerSync. 

 h3. Goals 

 Roughly, phase 1 is the minimal "get it working" phase where we have a demoable end-to-end scenario that works via hammer. After that, we will collect feedback and move on to phase 2 which moves some of the grunt work done by hammer to the server, and adds web UI support. Phase 3 enhances the "connected" scenario, and Phase 4 will be for support of additional content types and new types of foreman/katello data. 

 All code, test, doc and installer changes should be merged by the end of each phase in order to keep PR size down. 

 h4. Phase 1 "get it working" goals 

  * allow exporting and importing of products and Library content views 
  * export/import can occur via hammer and web UI, but some filesystem-level access is needed for accessing yum repo exports (scp, http, etc) 
  * only yum is supported 
  * incremental dumps are supported 

 Note: phase 1 replaces katello-disconnected script, and solves the same problem that Spacewalk solves with Inter-Spacewalk Sync in a minimal fashion (notably, without a web UI which comes in phase 2 or the disk space usage optimization which comes in phase 3). 

 h4. Phase 2 "web UI and optimization" goals 

  * API clean up to allow for bulk export/import with only a few server calls - this is needed for web UI support since we can't rely on hammer 
  * support for import/export of products and library CV via web UI 
  * allow export and import without filesystem access to machine (hammer or web ui can provide download of export and upload of import) 

 h4. Phase 3 "do it with less disk space" goals 

  * stream export/import data from one Foreman/katello to another without needing to write a full export to disk 
  * streaming must be able to be initiated from either the source or destination foreman/katello 

 h4. Phase 4+ "rinse and repeat" goals 

  * allow exporting and importing of other data (environments, non-library content views, etc) 
  * support for ostree, docker, puppet content 


 h3. Phase 1 Design 

 There are two areas that need to be updated for phase 1. We need to allow for exporting and importing of yum repo data (including incremental updates), and we need to allow for exporting and importing of product and library CV data. The former is largely provided by Pulp, and the latter is provided by hammer-cli-csv. 

 We will need to add the Pulp export distributor on newly created yum repos. Additionally, existing repos will need to have the export distributor added in via migration (this work is currently in progress). 

 Phase 1 allows for hammer-cli-csv doing a lot of "grunt" work in loading the CSV data. This will need to be done server-side in later phases. 

 h4. Hammer design 

 (need to fill in) 

 h4. API modifications 

 (need to fill in) 

 h4. User Stories 

  * as a katello user, I would like to be able to export and import a yum repository via disk with a hammer command. This includes both "full" and "incremental" export. The demoable output would be exporting from one Katello instance and importing to another, then confirming the published files are the same. Note: this story is the one that replaces http://www.katello.org/docs/user_guide/disconnected/index.html with new functionality, and will require a docs update. 

  * as a katello user, I would like to be able to export and import library content views to CSV via hammer. 

  * as a katello user, I would like to be able to export and import product information to a CSV file via hammer, including repository information. The demoable output would be exporting a product from Katello A that has had its repos already exported, then importing the product to Katell B after the repo import occurs. Katellos A and B should have the same products. 


 h3. Phase 2 Design 

 The main user-facing output of Phase 2 is the ability to do import/export from the web UI. An additional important feature is that data processing does not occur on the hammer client anymore. This greatly improves resiliency of the import/export process. 


 h4. API modifications 

 (need to fill in) 

 h4. Web UI design/mockup 

 (need to fill in) 



 h3. Phase 3 Design 

 This phase is further optimization, focusing on the "connected" scenario where the two foreman/katello instances can talk to each other. Previous phases treated the connected scenario as being solved by the disconnected scenario, which meant that all data was written to disk and optionally transferred via scp or http. 


 h3. Phase 4 Design 

 Phase 4 adds additional content types and data to ISS. Detailed design will be added here after phase 2 or phase 3 is complete.