The Model Element Repository integration provides you with the possibility to refer to any external source for applications, services, data and business objects and process definitions.
This chapter guides you through the following two registry type examples:
Stardust provides registry type extension points, e.g. for the Stardust Registry. Registry connections for a registry integration can be created for Stardust Process Models. You can connect to an arbitrary number of Stardust registries.
You have the option to implement your own repository connection extension points. Please refer to the chapter Implementing a Repository Connection Extension Point for detailed information.
You import model elements by reference. The following model elements are available:
Note that these elements are only referred in the referencing model and by any way they do not get copied to the model. For more information, please refer to the section Using Elements Imported by Reference.
To provide stability of model references against changing file locations, absolute as well as relative path is supported. The following syntax is used for relative path:
To create a file connection:
Note if the Import by Reference checkbox is selected then the usage of elements from the imported models is done by reference in the referencing model. If not selected, elements are copied by value. For more information, please refer to the section, Copying By Reference or By Value of the chapter Copying and Pasting Modeled Elements.
Figure: Create a File Connection
To refresh the file connection:
Figure: Refresh File Connection
If elements are changed in the provider model, the refresh operation reflects the change in consumer model.
You can also add a new external model reference using the Add External Model Reference option. This is just another way to add references under the External Model References node. For more information, please refer to the section Managing References to Other Models. Note that if the external model reference already exists then Add External Model References context menu is not available.
Figure: File Connection - Add External Model References
To delete the file connection:
Figure: Delete Element
The confirmation dialog box is displayed. If you click OK the file connection to provider model gets deleted.
Figure: Delete Element - Confirmation Dialog
To use the search functionality on a file connection:
Figure: Search on a File Connection
This will invoke the Search dialog. Enter a search string and select Search. Note that no wildcards are supported here.
Figure: Enter a Search Text.
All elements containing the search text in their name are displayed in the Search Result tree.
Figure: The Search Result List.
The Properties menu displays the same dialog box in which you can edit and view the file connection properties.
In case a connection pointing to a referenced model has been removed or renamed, a validation error occurs, indicating that the connection to the referenced model could not be established.
Whenever a new file connection is created, a validation check is performed to detect whether the new model references would create circular reference between the set of models in the same workspace. A Circular Dependency Detected warning is displayed.
Dangling references may result, in case, file to be referenced is not found. Inconsistency error is displayed at the time of the deployment.
Only after establishing the file connection with referenced model and selecting Imported by Reference check box the elements can be referenced. These elements cannot be used as local elements. Although they behave as local elements. So if any changes are performed in the referenced model, the file connection should be refreshed.
To use an element imported by reference in the referencing model, perform the drag-and-drop operation.
Figure: Drag Referenced Element
Each element of the referenced model has the following semantics in the referencing model:
For details on dragging and dropping elements from the Outline View, please refer to the Outline View chapter.
Note that in case a referenced model element is not accessible due to rename or deletion, a validation error, indicating that the model element is not present in the referenced model is displayed in the Problems view.
Also note that reference cannot be established to a model element of a referenced model if any reference to a model element of another version of the referenced model has already been created. In this case, you cannot drag and drop model element of a referenced model and the warning is displayed in the Problems view.
Dangling references may result in case referenced model elements are not displayed. Inconsistency error is displayed at the time of the deployment.
You can view the references to other models using External Model References node. An External Model References is a library which keeps track of the referenced models. For each provider model used from the current model, it contains a sub-node with the name of the referenced model. Note that a file connection must exist prior to manage references action.
Figure: External Model References
If the reference is not added from File Connection menu context then you can add a new external model reference using this option. Right-click on External Model References node and select Add External Model Reference from the context menu. However note that references also get added when you drag and drop any referenced element into the consumer model. In that case, you do not need to explicitly add the reference using this option.
Figure: Add External Model References
List of available file connections are displayed. Select file connection as the source to add new external model reference.
Figure: File Connection
If the reference already exists in the model then the "Reference Exists" message is displayed and Add External Model Reference operation is canceled. Else the reference of the provider model gets added under the External Model Reference node.
Figure: Reference Exists
You can perform following operations on each external reference node:
Deletes all usages of the provider model from the consumer model.
Figure: Delete External Model Reference
If you select the Delete option, the following warning is displayed.
Figure: Delete External Model Reference - Warning
Select this option to rename the external model reference.
Figure: Rename External Model Reference
Displays a list of all usages of model elements from the provider model in the Search Results view.
Figure: References
To view the properties, select Properties from the context menu.
Figure: Properties
Following properties of the selected external model reference get displayed.
Figure: Properties of External Model Reference
Note that in case a referenced model is not accessible due to deletion from file system or moved to another location or renamed, a validation error, indicating that the model is not present is displayed in the Problems view.
Dangling references may result, in case referenced models are not found. An error of inconsistent model version is displayed at the time of the deployment.