Metadata and reverse engineering
Semarchy xDI uses Metadata to design, generate and run the data integration processes.
What is a metadata?
A Metadata in Semarchy xDI is a design-time object used in mappings and processes. Depending on its type, metadata:
-
Defines connection parameters to a datastore or a remote server.
-
Describes the data structure and format of datastores (for example, tables in a relational database).
-
Stores information used in mappings or processes.
A metadata can be used in mappings or processes to represent an inbound or outbound data store and map data according to its data model.
Metadata types
Several types of metadata are available in Semarchy xDI. The main types are:
-
Server with Data structure: Defines the connection parameters to a data store and the format of the data it manages. For example, RDBMS (relational database), File Server, REST API, etc.
-
Data structure: Defines the format of structured data. For example, XML, JSON, Avro, Parquet, etc.
-
Server: Defines the connection parameters to a server.For example, Mail Server, LDAP Server, SSH Server, etc.
-
Security: Defines security parameters (used by other metadata). For example, Kerberos, Proxy, HTTP Security, etc.
Other types of metadata offer specific features:
-
Runtime: Allows creating Runtimes that are available for selection:
-
In the Runtime and Navigator views.
-
In processes (case of the Execute Delivery action).
-
-
Variable: Defines a Variable Set. Variables from a Variable Set can be used in mappings and can optionally be persisted in a database. Refer to Variables for more information.
-
Function: Defines a library of user-defined functions that can be called in mappings.
-
Generic: Allows designers to define a structured element from which data can be retrieved by processes.
-
Object Selector: References elements from other metadata to facilitate the design-time experience.
You can also create Sub-Metadata, a Metadata object created from other Metadata that can be used to inherit properties and organize your projects. For more information, see Work with Sub-metadata.
Shapes of metadata
Depending on the metadata that is added to a mapping, the following types of data stores can be managed:
-
Databases: Semarchy xDI supports numerous relational and NoSQL database technologies.
-
Files: Flat and Hierarchical (E.g. JSON, XML)
-
API: REST and SOAP
-
Applications such as SAP, Salesforce, etc.
Create A Metadata
To create a metadata:
-
Click the button in the Project Explorer's toolbar. Alternatively, right-click the parent project or folder in which you wish to create the new metadata and click New > Metadata.
-
Select the metadata technology and click Next.
-
Confirm the parent folder for your new metadata, enter a Metadata Model name, and then click Next.
-
If the selected type of metadata requires you to select a module, the Module Selection/Creation step opens:
The Type pane contains all the categories of modules that represent all types of technologies provided in the current installation. The list is filtered to only show the relevant categories for the selected technology.
This list contains the following categories:
-
Default: This category only contains one empty module called default. This module is available for any technology and is used as a fallback module at execution when no module is specified for metadata.
-
Generic: This category contains modules that are not linked to any particular technology and can thus be used by any metadata.
-
<Technology name>: This category contains all the modules for a given technology.
Refer to Modules for more information on managing modules in a workspace. -
Select a category in the Type pane. The Module pane is filtered based on the selected category.
-
Select a module in the Module pane. The content of the module is displayed in the Details pane.
-
If needed, add files to the selected module by clicking the button.
-
Click Finish.
-
-
-
If the created metadata is of type Server or Server With Data Structure, a dialog opens to enter the connection parameters such as URL and credentials. Enter those parameters and click:
-
Next to configure and launch the Reverse-Engineering of the new metadata. Refer to Reverse-Engineering for more information.
-
Finish to complete the creation of the metadata without reverse-engineering its model.
-
In the New Metadata wizard, you can only select the metadata types corresponding to components allowed by your license. The types that are not allowed appear disabled. The Show only available option hides the metadata types that are not allowed. |
You can configure external value resolvers to retrieve sensitive information (usernames, passwords) from an external secret store. With this feature, instead of storing sensitive information in the metadata, you store references to secrets stored in an external secret store. For example in HashiCorp Vault, AWS Secrets Manager Azure Key Vault, Google Cloud Secret Manager, etc. |
Define the data model
Reverse-Engineering
Reverse-engineering is the most common way to build the data model of metadata in Semarchy xDI. This mechanism connects to the data point (database server, file system, etc.) to retrieve its data structure (tables, files, etc.).
Reverse-engineering can be run:
-
By the metadata creation wizard. Refer to Create A Metadata for more information.
-
Manually, by clicking Actions > Launch Dataschema Wizard from the contextual menu in the metadata editor.
The following sections explain with examples how to create metadata for the most common types of metadata:
-
Create metadata to access a database.
-
Create metadata to access a file server.
-
Create metadata to define an XML model.
Define a generic model
A Generic Model is used to describe a specific data structure that can be used in mappings and processes.
To create a Generic Model:
-
Click the New Metadata button in the Project Explorer toolbar. The New Model wizard opens.
-
Select the Advanced option to display all types of metadata.
-
In the Choose the type of Metadata tree, select Generic > Element.
-
Click Next.
-
Select the parent folder or project for the new resource.
-
Enter a Name for your new metadata file and click Finish. The metadata editor opens.
-
Select the Element node and enter the Name for this element in the Properties view.
A Generic Model is a hierarchy of elements and attributes. Attribute values can be retrieved for an element using the Semarchy xDI usual Xpath syntax.
To create a new element:
-
Right-click the parent element.
-
Click New > Element.
-
In the Properties view, enter the name of the new element.
To add an attribute to an element:
-
Right-click the parent element.
-
Select New > Attribute.
-
In the Properties view enter the Name and the Value of the attribute.
Update a metadata
Designers can update the properties as well as the data structure (if applicable) of metadata objects. To open the metadata editor, double-click the metadata resource in Project Explorer, or click Open in its contextual menu.
Modify metadata properties
To modify the properties of a metadata:
-
Edit properties from the metadata editor: all properties are shown in finger tabs. The list of available properties depends on the type of metadata.
-
Properties with custom user values are enabled in the interface and can be modified directly.
-
Properties with default or undefined values are disabled. Click the property’s label to enable and then define a value (Leave it empty to define an empty value).
-
-
Alternatively, you can launch the configuration wizard if available: right-click the root node of the metadata in the editor and then select Actions > Launch Server Wizard. The list of available wizards vary depending on the type of metadata.
Modify the data model of metadata
The data model of metadata can be modified:
-
By reverse-engineering: In the metadata editor, right-click the root node and click Actions > Launch DataSchema wizard.
-
Manually: Double-click a node (a table or a column in the case of database metadata) in the metadata editor. All the editable properties for this node are shown in finger tabs that depend on the type of metadata.
Change the module used by metadata
To change the module used by a single metadata:
-
Double-click the metadata from Project Explorer to open its editor.
-
Select the root node in the editor.
-
In the Properties view, modify the Module property.
-
Save your changes.
Metadata module manager
The Metadata Module Manager allows changing the module used by several metadata at once.
This wizard only allows assigning modules to metadata. If you want to prepare modules for technologies that are not used by any metadata yet, use the Module Manager. |
To assign a module used to a set of metadata:
-
Navigate to Utilities > Metadata Module Manager. The Metadata Module Manager opens.
-
In the left panel of the Metadata Module Manager, select a category (for example, PostgreSQL).
The categories are filtered based on the metadata available in the current workspace.
The list of metadata from the current workspace that corresponds to the selected category is displayed in the right panel. The table view also shows the module used by each metadata.
-
Click the button to select the module you want to assign.
If a module already exists for a given category, it is preselected in the Select a Module to apply field.
-
Select the checkbox of each metadata to which you want to apply this module.
-
Click Perform Update.