Exporter Configuration

The exporter is an application used to export all projects from a given local folder into a remote repository. It can also be used to export the user profiles model.

1. Exporter strategy

The Exporter application supports one strategy :

  • Connected export: the Exporter application establishes a connection to the targeted repository and export projects (chosen by the user).

    • Credentials might be required if the server has been configured to use identification, authentication or user profiles, see Server Configuration job documentation.

See also Projects — Export job documentation.

2. Exporter parameters

exporter.bat file uses -vmargs as a standard eclipse parameter. Eclipse parameters that are used by exporter.bat override the value defined in capella.ini file. So if you want to change a system property existing in capella.ini (-vmargs -Xmx3000m for example) do not forget to do the same change in exporter.bat.

The exporter needs credentials to connect to the CDO server if the server has been started with authentication or user profile. Credentials can be provided using either -repositoryCredentials or -repositoryLogin and -repositoryPassword parameters. Here is a list of arguments that can be set to the Exporter (in exporter.bat or in a launch config):

Arguments Description

-repositoryCredentials

Login and password can be provided using a credentials file. It is the recommended way for confidentiality reason. If the credentials file does not contain any password, the password will be searched in the eclipse secure storage. See how to set the password in the secure storage

This parameter must not be used with -repositoryLogin or -repositoryPassword parameters else the exporter will fail.

To use this property file

  • Add the following program argument: -repositoryCredentials <path_to_credentials_file>

  • Fill the specified file using the following format (only one line allowed):

aLogin:aPassword

-repositoryLogin

The exporter needs a login to connect to the CDO server if the server has been started with authentication or user profile.

-repositoryLogin must not be used with -repositoryCredentials else the application will fail.

-repositoryPassword

This parameter is used to provide a password to the exporter accordingly to the login.

If -repositoryPassword is not used, the password will be searched in the eclipse secure storage. See how to set the password in the secure storage -repositoryPassword must not be used with -repositoryCredentials else the application will fail.

Some special characters like double-quote might not be properly handled when passed in argument of the exporter. The recommended way to provide credentials is through the repositoryCredentials file or the secure storage.

-hostname

Define the team server hostname (default: localhost).

-port

Define the team server port (default: 2036).

-connectionType

The connection kind can be set to tcp or ssl (keep it in low-case) (default: tcp)

-repoName

Define the team server repository name (default: repoCapella).

-sourceToExport

Define the path of folder containing projects to export.

This folder can be :

  • a folder that contains one or more projects to export,

  • a zip containing one or more Sirius project that is aird file,

  • a folder that contains one or more zip files.

-logFolder

Define the folder where to save logs (default: -outputFolder).

-overrideExistingProject

If the remote repository already contains a project to export with the same name, this argument allows removing this existing project (default: false).

-mergeDifferenceOnExistingProjects

If -overrideExistingProject is set to true (default: false), this argument allows selecting one of the two following override strategies:

  • Replace: Delete remote resources content and replace by local content (commit history is lost) (default)

  • Merge: Use Diff/Merge to compare local and existing resources and commit only the differences.

-overrideExistingImage

If the remote repository already contains an image with the same name, this argument allows ignoring and overriding it.

-closeServerOnFailure

Ask to close the server on project export failure (default: false). If the server hosts several repositories, it is better to use the parameter -stopRepositoryOnFailure.

-stopRepositoryOnFailure

Ask to close the repository on project export failure (default: false).

It is currently not possible to restart a single repository, if defined in cdo-server.xml. To restart the stopped repository, stop and restart the server.

-addTimestampToResultFile

Add a time stamp to result files name (.zip, logs, commit history) (default: true).

-httpLogin

Exporter application will trigger an Http request. This argument allows giving a login to identify with on the Jetty server.

-httpPassword

Exporter application will trigger an Http request. This argument allows giving a password to authenticate with on the Jetty server.

-httpPort

Exporter application will trigger an Http request. This argument allows giving a port to communicate with on the Jetty server.

-httpsConnection

Exporter application will trigger an Http request. This boolean argument specifies if the connection should be Https or Http.

-help

Print help message.

If the server has been started with user profile, the Exporter needs to have write access to the whole repository (including the user profiles model). See Resource permission pattern examples section.

If this recommendation is not followed, the Exporter might not be able to override existing projects on remote, for example. This may lead to a failed export.

The exporter uses the default configuration of Capella and does not need its own configuration area. For this to work properly, the exporter needs to have read/write permission to the configuration area of Capella, otherwise it can end up with some errors about access being denied. A common situation where the exporter can be found in this situation is when the Scheduler is launched as a Windows service. In this case, the user account executing the service is not necessarily configured to have the read/write permission to Capella’s configuration area. If somehow you cannot give the read/write permission to the exporter, a workaround is to provide it a dedicated configuration area by adding the following arguments at the end of exporter.bat file: -Dosgi.configuration.area="path/to/exporter/configuration/area" and if necessary, update the existing argument -data exporter-workspace to point to a location with read/write permission.

2.1. How to set the password in secure storage

The exporter does not use the same credentials as the user. It is stored in a different entry in the Eclipse 'Secure Storage'. Storing and clearing the credentials requires a dedicated application that can be executed as an Eclipse Application or using a Jenkins job.

3. Examples

example1: export project
exporter.bat -nosplash -data exporter-workspace
-closeServerOnFailure true
-connectionType ssl
-sourceToExport C:\Users\me\Documents\runtime-T4C