Deploy a model edition using VS Code
This page explains how to deploy a model edition in an existing data location using the Semarchy extension for VS Code.
Set up the deployment configuration
To deploy a model, you need to configure the extension to connect to an existing xDM instance. Follow the steps below to set up the Semarchy extension in VS Code:
-
In the Extensions view, locate the Semarchy extension and click the
Settings icon. -
In the contextual menu, select Extension Settings.
-
Select the Workspace tab.
-
Set the following properties for the Semarchy extension at the workspace level:
-
semarchy.xdm.url: URL of the xDM instance. -
semarchy.xdm.port: port of the xDM instance. -
semarchy.xdm.apiKey: API key for authenticating to the instance, defined in the xDM instance. -
semarchy.xdm.authInfo: user-password credentials for authentication to the instance, formatted asusername:password.Choose either user-password authentication or API key authentication. Ensure that the user or API key has a role with the Application Management platform privilege. -
semarchy.xdm.datasourceName: name of the datasource, as configured in the Configuration interface. -
semarchy.xdm.datalocationName: name of the data location where the model will be deployed.
-
The properties configured in the extension settings are saved in a file named settings.json, which is automatically created in your workspace. You can manually adjust these properties in this file.
|
Deploy a model
To deploy a model, you can use any of the following options:
-
Semarchy extension toolbar
-
From the Activity Bar, access the
Semarchy view. -
Click the Build and Deploy button.
-
or
-
Command Palette
-
Open the Command Palette.
-
Type and select Semarchy: Build and Deploy Data Management Model.
-
or
-
-
Open the Terminal view.
-
Use the following command to build and deploy a specific model:
-
semarchy dm data-location deploy
[--workspace <workspace_directory>]
--instance-url <xdm_instance_url>
--instance-port <xdm_instance_port>
--data-location <data_location_name>
--api-key <api_key>
--username <username>
--password <password>
Replace <workspace_directory> with the full path to the model’s root folder.
|
Regardless of the method chosen, the Output panel shows the model validation results and any potential errors.