Repository commands

There are Repository commands to:

Import configurations into the Repository

To import configurations into the Repository, use the following command:

importAIConfiguration [-id id] [-o option] [ImportDirectory], where:

id:

Identifier of the configuration to be imported or sequenced/updated. Mostly used to sequence a configuration that already exists in the Repository.

The id must match the folder name that stores the configuration files: ImportDirectory/aiConfiguration/<aiConfigurationIdentifier>. If the id and folder name do not match, the import stops and an error message is displayed.

if the id is not specified, all the configurations files under the ImportDirectory/aiConfiguration folder are imported.

option:

Possible values:

- config: it imports only the AI Enabler configuration. It imports a set ctx.mvt + mvt.mvt.

- table: it imports only the configuration of the internal tables values. It imports one or several mvt.mvt files.

If the option is not specified, it imports the configurations from the AI Enabler and the internal tables values.

ImportDirectory:

The AI Enabler configuration files must be stored in the ImportDirectory under the folder aiConfiguration/<aiConfigurationIdentifier>

The configuration files of the internal tables are stored in the ImportDirectory under the folder aiConfiguration/<aiConfigurationIdentifier>/tables

If the ImportDirectory is not specified, the default import directory is used under the structure shown above.

Sequenced AI Enabler configurations

The import command also allows importing a sequenced AI Enablerconfiguration. The suffixes of the configuration files correspond to the id of the sequence.

Note   The first configuration is considered base and the files names have no suffix

Some conditions must be met to import a sequenced configuration:

  • That there is no configuration with same identifier in the repository. Otherwise an error is displayed.
  • That configuration numbers are in the right order (base, then 1, 2, etc.)and apply for both mvt and ctx files.

Export configurations from the Repository

To export configurations from the Repository, use the following command:

exportAIConfiguration [-id id] [-o option] [ExportDirectory], where:

id

Identifier of the configuration to be exported. Only the specified configuration is exported.

If the id is not specified, all the configurations files from the Repository are exported.

option

Possible values:

- config: it exports only the AI Enabler configuration. If the configuration is sequenced, all the configuration updates are exported as pairs of ctx.mvt + mvt.mvt files.

- table: it exports only the configuration of the internal tables values. Since the configuration is not sequenced, only the last version is exported.

If no option is specified, the whole set of configuration —from both the AI Enabler and the internal tables values— is exported

List configurations from the Repository

To list configurations from the Repository, use the following command:

listAIConfiguration [-id id] [-o option], where:

id

Identifier of the configuration to be listed. Only the specified configuration is listed.

If the id is not specified, all the configurations files from the Repository are listed.

option

Possible values:

- config: it lists only the AI Enabler configuration. If the configuration is sequenced, all the configuration updates are listed.

- table: it lists only the configuration of the internal tables values.

If no option is specified, the whole set of configuration —from both the AI Enabler and the internal tables values— is listed.

Clean configurations from the Repository

To clean configurations from the Repository, use the following command:

cleanAIConfiguration [-id id] [-o option] [-from from], where:

id

Identifier of the configuration to be deleted. Only the specified configuration is deleted.

If the id is not specified, all the configurations files from the Repository are deleted.

option

Possible values:

- config: it deletes only the AI Enabler configuration.

- table: it deletes only the configuration of the internal tables values.

If no option is specified, the whole set of configuration —from both the AI Enabler and the internal tables values— is deleted.

from

Specifies the index from where to start cleaning the configuration sequence.

To be used only for the AI Enabler configuration.

If it is not specified, all the AI Enabler configuration updates are removed.

Example

The following example describes the use of the Repository commands.

The table below displays three AI Enabler configurations and their corresponding internal table values:

AI Enabler configuration Internal table value
aiconfig1 COA.mvt, CURRENCY.mvt, RATE.mvt
aiconfig2 COA.mvt
aiconfig3 COA.mvt, CURRENCY.mvt

The import folder must have the structure described in the picture below:

Import folder structure

If some updates are needed, the exported configuration folder wil have an specific structure. For example, if the configuration config1 has two updates, config2 has 1 update and config3 has no update; the exported configuration folder will have the structure described in the picture below:

Export folder structure

To clean only the last update of the first configuration, run the following command: cleanAIConfiguration –id aiconfig1 –o config –from 2

Related Links