Skip to main content

Configure simulator connectors

Simulator connectors are Windows-based services that enable communication between simulation tools and Cognite Data Fusion (CDF). The connectors act as translators between your simulator's specific commands and CDF, facilitating bidirectional data flow while operating as a client making outbound https-connections only.

Before you start

Infrastructure setup

  • A Windows virtual or physical machine with storage space for model files.

  • Simulation software installed with valid licenses.

  • Windows administrator access for service configuration.

Authentication setup

  • Registered service application in your Identity Provider (IdP).

  • Client secret for authentication.

  • Properly configured access groups in your IdP.

  • Dedicated data set in CDF for storing simulator data.

  • Appropriate CDF group access capabilities.

Network configuration

  • Firewall allowing outbound traffic to https://{cluster}.cognitedata.com.

  • TLS certificate validation settings.

  • Proxy configuration (if applicable).

Configuration settings

To configure a simulator connector, you must edit the configuration file. The file is in YAML format, and you'll find configuration file examples listed under the config folder in the directory where the connector is installed.

tip

Don't base your configuration on the config.example.ymlfile. Instead, use config.minimal.yml as your base and copy the parts you need from config.example.yml.

Step 1: Configure the file setup

  1. Download simulator connectors from Data management > Integrate > Extractors and connectors.

  2. Create config.yml in the connector's installation directory. Start with config.minimal.yml as a baseline.

  3. Configure authentication values using your IdP credentials.

Step 2: Set up a local service account

  1. Create a dedicated Windows service/user account on the connector machine.

  2. Set read and write access for the service account to the connector installation folder.

Step 3: Start the Windows service

  1. Configure the Windows service to use the local dedicated account.

  2. Start the Windows service.

  3. Monitor startup using Windows Event Viewer.

  4. Verify the connector registration under Integrations in the Simulators tool in the CDF user interface or by listing simulator integrations through the Cognite API.

Step 4: Run the connector

  • When the connector starts, it reads the configuration file, authenticates with CDF, registers itself as a simulator integration, and start processing models and routines

  • When you've configured the connector, it registers itself and the associated simulator in CDF, and you can create models and routines.

note

For on-premises connectors, customers are responsible for maintaining connector uptime. Connectors are designed to operate as always-on services to ensure consistent compute availability for users.

Using values from environment variables

In the configuration file, values wrapped in ${} are replaced with environment variables with that name. For example, ${COGNITE_PROJECT} will be replaced with the value of the environment variable called COGNITE_PROJECT.

The configuration file also contains the global parameter version, which holds the version of the configuration schema used in the configuration file. This document describes version 1 of the configuration schema.

Configuration sections

Connector

This section contains information on how the current connector appears in Simulators.

ParameterDescriptionRequired
connector.data-set-idEnter the data set ID to read the model files and simulator routines from. Result inputs and outputs will be written to this data set.Yes
connector.name-prefixEnter the connector name that is registered on the API.No
connector.add-machine-name-suffixWhen set to true (default), the connector name is composed of the prefix name-prefix@vm-host-name followed by the machine name.No
connector.simulation-run-toleranceThe connector will time out simulation runs that are older than this value (in seconds).No
connector.fetch-runs-intervalThe connector will fetch simulation runs from CDF at this interval (in seconds).No
connector.status-intervalThe connector will update its heartbeat in CDF at this interval (in seconds).No
connector.scheduler-update-intervalThe connector will check if scheduled simulations should be triggered at this interval (in seconds)No

Logger

Log entries are either Fatal, Error, Warning, Information, Debug, Verbose, in order of decreasing importance. Each level covers the ones of higher importance.

ParameterDescription
consoleConfiguration for logging to the console.
console.levelSet the minimum level of log events to write to the console. Set this parameter to enable console logging.
console.stderr-levelLog events at this level or above are redirected to standard error.
fileConfiguration for logging to a rotating log file.
file.levelSet the minimum level of log events to write to file.
file.pathEnter the path to the files to be logged. For instance, if this is set to logs/log.txt, logs on the form logs/log[date].txt will be created, depending on rolling-interval.
file.retention-limitSet the maximum number of log files that are kept in the log folder.
file.rolling-intervalEnter a rolling interval for log files as day or hour. The default value is day.
remoteConfiguration for logging to CDF.
remote.enabledInsert boolean of whether to push logs to CDF or not. The default value is true.
remote.levelSet the minimum level of log events to push to CDF. Valid values are Error, Warning, Information and Debug.

Cognite

This is the configuration of the connection to CDF.

ParameterDescription
hostInsert the CDF service URL. The default value is https://api.cognitedata.com.
projectEnter the CDF project. This is a required parameter.
idp-authenticationThe configuration for authenticating to CDF.
idp-authentication.authorityThe authority used with tenant to authenticate to Azure tenants. Use token-url if you're connecting using a non-azure IdP. The default value is https://login.microsoftonline.com.
idp-authentication.tenantEnter the Azure tenant used with authority.
idp-authentication.token-urlInsert the URL used to obtain service tokens, used for non-azure IdPs.
idp-authentication.client-idEnter the service principal client ID.
idp-authentication.secretEnter the service principal client secret.
idp-authentication.resourceInsert an optional resource parameter to pass along with token requests.
idp-authentication.scopesEnter a list of scopes to pass along with the request. This will typically need to contain [host]/.default.
idp-authentication.audienceInsert an optional audience parameter to pass along with token requests.
idp-authentication.min-ttlSet the requested minimum time-to-live in seconds for the token.
idp-authentication.certificateConfiguration for authenticating using a client certificate.
idp-authentication.certificate.authority-urlInsert the certificate authority URL.
idp-authentication.certificate.pathEnter the path to the .pem or .pfx certificate to be used for authentication.
idp-authentication.certificate.passwordEnter the certificate password.
max-data-points-upload-queue-sizeSet the maximum number of cached data points before they are uploaded to CDF. The default value is 1000000.
cdf-retriesSet the number of automatic retries on requests to CDF.
cdf-retries.timeoutSet a timeout in milliseconds for each try. The default value is 80000.
cdf-retries.max-retriesSet the maximum number of retries. A value less than 0 retries forever.
cdf-retries.max-delaySet the maximum delay between each try in milliseconds. The base delay is calculated according to 125 * 2 ^ retry milliseconds. If this is less than 0, there's no upper limit. The default value is 5000.
cdf-chunkingThe configuration for chunking on requests to CDF. Note that increasing these may cause requests to fail, due to limits in the API. Read the API documentation before making these higher than their current value.
cdf-chunking.time-seriesSet the maximum number of time series per get/create time series request.
cdf-chunking.data-point-time-seriesSet the maximum number of time series per data point create request.
cdf-chunking.data-pointsSet the maximum number of data points per data point create request.
cdf-throttlingSet how requests to CDF should be throttled.
cdf-throttling.time-seriesSet the maximum number of parallel requests per time series operation. The default value is 20.
cdf-throttling.data-pointsSet the maximum number of parallel requests per datapoints operation. The default value is 10.
sdk-loggingThe configuration for logging of requests from the SDK.
sdk-logging.disableSet this to true to disable logging of requests from the SDK. This is by default enabled.
sdk-logging.levelSet the log level to log messages from the SDK. The default value is debug.
sdk-logging.formatSet the log message format. The default value is CDF ({Message}): {HttpMethod} {Url} - {Elapsed} ms
nan-replacementReplacement for NaN values when writing to CDF. The default value is none, meaning these values are removed.
extraction-pipeline.external-idThe configuration for associating this connector with an extraction pipeline. This is used for monitoring and remote configuration.
certificatesThe configuration for special handling of SSL certificates. This should not be considered as a permanent solution to certificate problems.
certificates.accept-allAccept all remote SSL certificates even if verification fails. Note: This introduces a risk of man-in-the-middle attacks.
certificates.allow-listList of certificate thumbprints to automatically accept. This is a smaller risk than accepting all certificates.

State store

This section includes the configuration parameters for storing state in a local database.

ParameterDescription
locationEnter the path to the database file containing the state store.
databaseSelect which type of database to use. Only LiteDb is currently supported. The default value is None.

Maintain connectors

  • Connectors might require significant disk space for caching model files stored in CDF
  • Connectors don't have auto-update features, so regular manual updates are necessary to get bug fixes and new features
  • The underlying simulation software may also require periodic updates
  • When troubleshooting problems, check the connector logs in the installation directory and Windows Event Logs