Description

Master Projects can be used to maintain referential integrity for a Domain (e.g., a User Domain) ACROSS applications and databases. They should be used when multiple databases or applications share a common Domain or set of Domains. 


A Master Project is a Project with limited functionality whose Project Versions can be inherited by other Project Versions within your Organization. When a Project inherits Domains from a Master Project, it contains the information generated by the common Domains but not necessarily the same Parent/Child/Sibling Relationships. 


Important: Master Projects should be used sparingly.


In This Article


Rules for Master Projects

  • A Master Project can only contain Master Domains containing Master Attributes.
  • A Project whose Project Versions inherit from a Master Project Version is called a Child Project.
  • A Master Project's Domain inheritance cannot be modified once referenced by even one Child Project. 
  • Attributes within a Master Domain can be added, modified, and deleted. 
  • Generators within a Master Attribute can be added, modified, and deleted. 
  • Changes made to a Master Project Versions' Master Domains, Master Attributes, and Master Generators are immediately refactored to any Child Project Versions.
  • A Master Project cannot inherit from another Master Project. 


Project Dashboard Icons

The following icons will appear in the Project Dashboard when Master Projects are used: 


Icon
Description
Master Project - This icon will be displayed within the Project Dashboard for any Master Project, Master Project Version, and Master Domain. You will also see this icon for any Master Attribute within the Domain Dashboard.
Project - This icon will be displayed within the Project Dashboard for any Project that is not a Master Project.


Master Projects Example

An organization uses 3 common Domains (Customer, Address, Account) to generate data for two separate databases. Each database needs the data generated by these Domains. A Master Project can be set up with common Domains, and then each Project Version can inherit the common Domains from that Master Project.


Step 1 - Create the Master Project 

  • Click on the New Project button within the Project Dashboard.



  • Enter a Name for the Project.
  • Click on the checkbox to enable the Master Project option. It will have a checkmark when enabled.
  • Click the Save button.



Step 2 - Add Master Domains to the Master Project

Master Domains can be added to a Master Project using any of the available methods within the GenRocket web platform for importing your data model or adding Domains to a Project Version of a given Project.  


Important: The quantity and complexity of Domains imported into a Master Project should be minimal and the complexity of parent/child/sibling relationships simple. Master Projects are not meant to be full-blown, complex projects; they are meant to contain one or more Domains that are shared amongst two or more Child Projects within their respective Project Versions.


To learn about the different methods for adding Domains and importing your data model, click here



For this example, three Master Domains have been added using Scratchpad: Customer, Address, and Account.


Note: Once Master Domains have been added, you can add Attributes, assign a different Generator, Link Generators, or change Generator Parameters. 


Step 3 - Verify and Configure Parent/Child/Sibling Relationships

If you have imported your data model, you will need to review Parent/Child/Sibling Relationships. This can be done within the Domain Referencing Wizard. For more information on how to use the Domain Referencing Wizard, click here



If you have created the Domains, as done in this example, then you will need to set the Parent/Child/Sibling Relationships up within the Domain Dashboard. To learn how to set up Parent/Child/Sibling Relationships, click here



Step 4 - Open Master Project Management for a Project Version

Once the Master Project has been set up and configured appropriately, any Project Version that is not a Master Project Version can become a Child Project Version that inherits from it.


For this example, we will need to perform Step 4 and Step 5 twice. We have created 2 Projects, each containing a default Project Version, which will inherit from the Master Project created in Step 1. 


  • Select the Project within the Project Dashboard.



  • Click on the Master Project Management icon for the appropriate Project Version of a given Project.



  • The Master Project Management dialog window will appear as shown below:


Step 5 - Select a Master Project and Master Project Version

Important: Once this step has been completed, you cannot add more Master Domains or change the relationship between Master Domains within the Master Project. You can still manage existing Master Domains and their Master Attributes / Master Generators.


Note: For this example, these steps will need to be completed twice, once for each default Project Version of the following two Projects: ChildProject1 and ChildProject2.


  • Click on the Add Master Project button.



  • Select a Master Project and a Master Project Version.

  • Click the Save button.



  • Click Yes to confirm.



  •  Click Close once finished.


Completed Story

Each Child Project will have the Master Domains, Master Attributes, Master Generators, and Parent/Child/Sibling Relationships defined within the selected Master Project and Master Project Version.

Note: Master Domains, Master Attributes, and their Generators cannot be modified within the Child Project, but they can be modified within the Master Project. Changes are immediately refactored to each Child Project.



Making changes to Domain Attributes within a Master Project Version

Changes made to a Master Project Versions' Master Domains and Master Attributes are immediately refactored to any Child Project.


Adding Attributes to a Master Domain

  • Select the Master Project and Master Project Version.
  • Select the Master Domain within the Domains Pane.



  • Click on the Add Attribute button.



  • Enter a Name for the Attribute and click the Save button.



  • The added Attribute will appear as shown below:



  • The added Attribute will also appear in each Child Project.


Removing Attributes from a Master Domain

  • Select the Master Project and Master Project Version.
  • Select the Master Domain within the Domains Pane.



  • Click on the Delete (Trash Can) icon to remove a Master Attribute from a Master Domain.



  • Click Yes to confirm.



  • Refactoring will occur automatically, and the Attribute will also be removed from all Child Projects.


How to make changes to Master Generators within a Master Project Version

For Master Generators, you can add, re-assign, and remove Master Generators. For these changes to be refactored to child projects, you must complete the following steps:


  • Make any needed changes to the currently assigned Master Generator or replace it, then click the Save Generator button.

  • Click on the Sync Generators button to sync the Master Generator for a Master Attribute with each Child Project that inherits from it.


    Note: If you do not click this button, the changes will not be synced with the Master Generator within each Child Project.