Configuration Sections
Advanced Usage
Configuration of CSE parameters is done through a configuration file. This file contains all configurable and customizable settings for the CSE. It is optional, and settings in this file overwrite the CSE's default values.
It follows the Windows INI file format with sections, keywords and values. A configuration file may include comments, prefixed with the characters "#"" or ";"" .
Also, some settings can be applied via the command line when starting the CSE. These command line arguments overwrite the settings in the configuration file.
Changes should only be done to a copy of the default configuration file.
A default configuration file is provided with the file acme.ini.default. Don't make changes to this file, but rather copy it to a new file named acme.ini, which is the default configuration file name. You can use another filename, but must then specify it with the --config command line argument when running the (see Running the CSE).
It is sufficient to only add the settings to the configuration file that need to be different from the default settings. All other settings are read from the default config file acme.ini.default.
If the specified or the default acme.ini could not be found then an interactive procedure is started to generate a file with basic configuration settings. You can add further configurations if necessary by copying sections and settings from acme.ini.default.
In addition to assigning individual values for configurations settings you can use
settings interpolation which allows you to
referece settings from the same or from other sections. The syntax to denote a value from a section is ${section:option}.
A built-in configuration setting that points to the base-directory of the CSE installation can be
referenced by the interpolation ${basic.config:baseDirectory}.
Example:
[cse]
resourcesPath=${basic.config:baseDirectory}/initThe following tables provide detailed descriptions of all the possible CSE configuration settings.
[cse] - General CSE Settings
[cse.security] - General Security Settings
[cse.operation] - CSE Operations Settings
[server.http] - HTTP Server Settings
[server.http.security] - HTTP Security Settings
[server.http.cors] - HTTP CORS (Cross-Origin Resource Sharing) Settings
[client.mqtt] - MQTT Client Settings
[client.mqtt.security] - MQTT Security Settings
[database] - Database Settings
[logging] - Logging Settings
[cse.registration] - Settings for Self-Registrations
[cse.registrar] - Settings for Remote CSE Access
[cse.announcements] - Settings for Resource Announcements
[cse.statistics] - Statistic Settings
[cse.resource.acp] - Resource defaults: Access Control Policies
[cse.resource.cnt] - Resource Defaults: Container
[cse.resource.req] - Resource Defaults: Request
[cse.resource.sub] - Resource Defaults: Subscription
[cse.resource.ts] - Resource Defaults: TimeSeries
[cse.resource.tsb] - Resource Defaults: TimeSyncBeacon
[cse.console] - Console Settings
[cse.scripting] - Scripting Settings
[cse.webui] - Web UI Settings
[server.http.mappings] - ID Mappings
| Keyword | Description | Configuration Name |
|---|---|---|
| type | The CSE type. Allowed values: IN, MN, ASN. Default: IN |
cse.type |
| serviceProviderID | The CSE's service provider ID. Default: acme |
cse.spid |
| cseID | The CSE ID. Can be overwritten in imported CSE definition. A CSE-ID must start with a /. Default: id-in |
cse.csi |
| resourceID | The CSE's resource ID. This should be the cseid without the leading "/". Can be overwritten in imported CSE definition. Default: id-in |
cse.ri |
| resourceName | The CSE's resource name or CSE-Name. Can be overwritten in imported CSE definition. Default: cse-in |
cse.rn |
| resourcesPath | Directory of default resources to import. See also command line argument –import-directory. Default: ./init |
cse.resourcesPath |
| maxExpirationDelta | Default and maximum expirationTime allowed for resources in seconds. Default: 6060243655 = 157680000 seconds = 5 years |
cse.maxExpirationDelta |
| enableResourceExpiration | Enable resource expiration. If disabled resources will not be expired when the "expirationTimestamp" is reached. Default: true |
cse.enableResourceExpiration |
| requestExpirationDelta | Expiration time for requests sent by the CSE in seconds Default: 10.0 seconds |
cse.requestExpirationDelta |
| originator | Admin originator for the CSE. Default: CAdmin |
cse.originator |
| enableRemoteCSE | Enable remote CSE registration and checking. See also command line arguments –remote-cse and –no-remote-cse. Default: true |
cse.enableRemoteCSE |
| sortDiscoveredResources | Enable alphabetical sorting of discovery results. Default: true |
cse.sortDiscoveredResources |
| checkExpirationsInterval | Interval to check for expired resources. 0 means "no checking". Default: 60 seconds |
cse.checkExpirationsInterval |
| flexBlockingPreference | Indicate the preference for flexBlocking response types. Allowed values: "blocking", "nonblocking". Default: blocking |
cse.flexBlockingPreference |
| supportedReleaseVersions | A comma-separated list of supported release versions. This list can contain a single or multiple values. Default: 2a,3,4 |
cse.supportedReleaseVersions |
| releaseVersion | The release version indicator for requests. Allowed values: 2a, 3, 4. Default: 3 |
cse.releaseVersion |
| defaultSerialization | Indicate the serialization format if none was given in a request and cannot be determined otherwise. Allowed values: json, cbor. Default: json |
cse.defaultSerialization |
| asyncSubscriptionNotifications | Enable or disable asynchronous notification for normal runtime subscription notifications. Default: true |
cse.asyncSubscriptionNotifications |
| Keyword | Description | Configuration Name |
|---|---|---|
| enableACPChecks | Enable access control checks. Default: true |
cse.security.enableACPChecks |
| fullAccessAdmin | Always grant the admin originator full access (bypass access checks). Default: True |
cse.security.fullAccessAdmin |
| Keyword | Description | Configuration Name |
|---|---|---|
| jobBalanceTarget | Thread Pool Management: Target balance between paused and running jobs (n paused for 1 running threads). Default: 3.0 |
cse.operation.jobBalanceTarget |
| jobBalanceLatency | Thread Pool Management: Number of get / create requests for a new thread before performing a balance check. A latency of 0 disables the thread pool balancing. Default: 1000 |
cse.operation.jobBalanceLatency |
| jobBalanceReduceFactor | Thread Pool Management: The Factor to reduce the paused jobs (number of paused / balanceReduceFactor) in a balance check. Example: a factor of 2.0 reduces the number of paused threads by half in a single balance check. Default: 2.0 |
cse.operation.jobBalanceReduceFactor |
| Keyword | Description | Configuration Name |
|---|---|---|
| port | Port to listen to. Default: 8080 |
http.port |
| listenIF | Interface to listen to. Use 0.0.0.0 for "all" interfaces. Default:127.0.0.1 |
http.listenIF |
| address | Own address. Should be a local/public reachable address. Default: http://127.0.0.1:8080 |
http.address |
| root | CSE Server root. Never provide a trailing /. Default: empty string |
http.root |
| enableRemoteConfiguration | Enable an endpoint for get and set certain configuration values via a REST interface. ATTENTION: Enabling this feature exposes configuration values, IDs and passwords, and is a security risk. Default: false |
http.enableRemoteConfiguration |
| enableStructureEndpoint | Enable an endpoint for getting a structured overview about a CSE's resource tree and deployment infrastructure (remote CSE's). ATTENTION: Enabling this feature exposes various potentially sensitive information. See also the [cse.console].hideResources setting to hide resources from the tree. Default: false |
http.enableStructureEndpoint |
| enableResetEndpoint | Enable an endpoint for resetting the CSE (remove all resources and import the init directory again) ATTENTION: Enabling this feature may lead to a total loss of data. Default: false |
http.enableResetEndpoint |
| enableUpperTesterEndpoint | Enable an endpoint for supporting Upper Tester commands to the CSE. This is to support certain testing and certification systems. See oneM2M's TS-0019 for further details. ATTENTION: Enabling this feature may lead to a total loss of data. Default: false |
http.enableUpperTesterEndpoint |
| allowPatchForDelete | Allow the http PATCH method to be used as a replacement for the DELETE method. This is useful for constraint devices that only support http/1.0, which doesn't specify the DELETE method. Default: False |
http.allowPatchForDelete |
| timeout | Timeout when sending http requests and waiting for responses. Default: 10.0 seconds |
http.timeout |
| Keyword | Description | Configuration Name |
|---|---|---|
| useTLS | Enable TLS for communications. This can be overridden by the command line arguments --http and --https. See oneM2M TS-0003 Clause 8.2.1 "Overview on Security Association Establishment Frameworks". Default: False |
http.security.useTLS |
| tlsVersion | TLS version to be used in connections. Allowed versions: TLS1.1, TLS1.2, auto . Use "auto" to allow client-server certificate version negotiation. Default: auto |
http.security.tlsVersion |
| verifyCertificate | Verify certificates in requests. Set to False when using self-signed certificates. Default: False |
http.security.verifyCertificate |
| caCertificateFile | Path and filename of the certificate file. Default: None |
http.security.caCertificateFile |
| caPrivateKeyFile | Path and filename of the private key file. Default: None |
http.security.caPrivateKeyFile |
| Keyword | Description | Configuration Name |
|---|---|---|
| enable | Enable CORS support for the HTTP binding. Default: false |
http.cors.enable |
| resources | A comma separated list of allowed resource paths. The list elements could be regular expressions. Default: "/*" , ie. all resources under the HTTP server's root |
http.cors.resources |
| Keyword | Description | Configuration Name |
|---|---|---|
| enable | Enable the MQTT binding. Default: False |
mqtt.enable |
| address | he hostname of the MQTT broker. Default; 127.0.0.1 |
mqtt.address |
| port | Set the port for the MQTT broker. Default: 1883, or 8883 for TLS |
mqtt.port |
| listenIF | Interface to listen to. Use 0.0.0.0 for "all" interfaces. Default:127.0.0.1 |
mqtt.listenIF |
| keepalive | Value for the MQTT connection's keep-alive parameter in seconds. Default: 60 seconds |
mqtt.keepalive |
| topicPrefix | Optional prefix for topics. Default: empty string |
mqtt.topicPrefix |
| timeout | Timeout when sending MQTT requests and waiting for responses. Default: 10.0 seconds |
mqtt.timeout |
| Keyword | Description | Configuration Name |
|---|---|---|
| username | The username for MQTT broker authentication if required by the broker. Default: None |
mqtt.security.username |
| password | The password for MQTT broker authentication. Default: None |
mqtt.security.password |
| useTLS | Enable TLS for communications with the MQTT broker. Default: False |
mqtt.security.useTLS |
| verifyCertificate | Verify certificates in requests. Set to False when using self-signed certificates.. Default: False |
mqtt.security.verifyCertificate |
| caCertificateFile | Path and filename of the certificate file. Default: None |
mqtt.security.caCertificateFile |
| allowedCredentialIDs | List of credential-IDs that can be used to register an AE via MQTT. If this list is empty then all credential IDs are allowed. This is a comma-separated list. Wildcards (* and ?) are supported. Default: empty list |
mqtt.security.allowedCredentialIDs |
| Keyword | Description | Configuration Name |
|---|---|---|
| path | Directory for the database files. Default: ./data |
db.path |
| inMemory | Operate the database in in-memory mode. Attention: No data is stored persistently. See also command line argument --db-storage. Default: false |
db.inMemory |
| cacheSize | Cache size in bytes, or 0 to disable caching. Default: 0 |
db.cacheSize |
| resetOnStartup | Reset the databases at startup. See also command line argument --db-reset. Default: false |
db.resetOnStartup |
| Keyword | Description | Configuration Name |
|---|---|---|
| enableFileLogging | Enable logging to file. Default: false |
logging.enableFileLogging |
| enableScreenLogging | Enable logging to the screen. Default: true |
logging.enableScreenLogging |
| path | Pathname for log files. Default: ./logs |
logging.path |
| level | Loglevel. Allowed values: debug, info, warning, error, off. See also command line argument –log-level. Default: debug |
logging.level |
| count | Number of files for log rotation. Default: 10 |
logging.count |
| size | Size per log file. Default: 100.000 bytes |
logging.size |
| stackTraceOnError | Print a stack trace when logging an 'error' level message. Default: True |
logging.stackTraceOnError |
| enableBindingsLogging | Enable logging of low-level HTTP & MQTT client events. Default: False |
logging.enableBindingsLogging |
| queueSize | Number of log entries that can be added to the asynchronous queue before blocking. A queue size of 0 means disabling the queue. Default: F5000 entries |
logging.queueSize |
| Keyword | Description | Configuration Name |
|---|---|---|
| allowedAEOriginators | List of AE originators that can register. This is a comma-separated list of originators. Wildcards (* and ?) are supported. Default: C*, S* |
cse.registration.allowedAEOriginators |
| allowedCSROriginators | List of CSR originators that can register. This is a comma-separated list of originators. Wildcards (* and ?) are supported. Note: No leading "/" Default: empty list |
cse.registration.allowedCSROriginators |
| checkLiveliness | Check the liveliness if the registrations to the registrar CSE and also from the registree CSEs. Default: True |
cse.registration.checkLiveliness |
| Keyword | Description | Configuration Name |
|---|---|---|
| address | URL of the Registrar CSE. Default: no default |
cse.registrar.address |
| root | Registrar CSE root path. Never provide a trailing /. Default: empty string |
cse.registrar.root |
| cseID | CSE-ID of the Registrar CSE. A CSE-ID must start with a /. Default: no default |
cse.registrar.csi |
| resourceName | The Registrar CSE's resource name. Default: no default |
cse.registrar.rn |
| serialization | Specify the serialization type that must be used for the registration to the registrar CSE. Allowed values: json, cbor Default: json |
cse.registrar.serialization |
| checkInterval | Wait n seconds between tries to to connect to the registrar CSE and to check validity of Registrar CSE connections in seconds. Default: 30 |
cse.registrar.checkInterval |
| excludeCSRAttributes | List of resources that are excluded when creating a registrar CSR. Default: empty list |
cse.registrar.excludeCSRAttributes |
| Keyword | Description | Configuration Name |
|---|---|---|
| checkInterval | Wait n seconds between tries to announce resources to registered remote CSE. Default: 10 |
cse.announcements.checkInterval |
| allowAnnouncementsToHostingCSE | Allow resource announcements to the own hosting CSE. Default: True |
cse.announcements.allowAnnouncementsToHostingCSE |
| Keyword | Description | Configuration Name |
|---|---|---|
| enable | Enable or disable collecting CSE statistics. Default: True |
cse.statistics.enable |
| writeInterval | Interval for saving statistics data to disk in seconds. Default: 60 |
cse.statistics.writeInterval |
| Keyword | Description | Configuration Name |
|---|---|---|
| permission | Default permission when creating an ACP resource. Default: 63 |
cse.acp.pv.acop |
| selfPermission | Default selfPermission when creating an ACP resource. Default: 51 |
cse.acp.pvs.acop |
| Keyword | Description | Configuration Name |
|---|---|---|
| enableLimits | Enable/disable the default limits. Default: False |
cse.cnt.enableLimits |
| mni | Default for maxNrOfInstances. Default: 10 |
cse.cnt.mni |
| mbs | Default for maxByteSize. Default: 10.000 bytes |
cse.cnt.mbs |
| Keyword | Description | Configuration Name |
|---|---|---|
| minimumExpirationTime | A <request> resource's minimum expiration time in seconds. Must be >0. Default: 60 |
cse.req.minet |
| maximumExpirationTime | A <request> resource's maximum expiration time in seconds. Must be >0. Default: 180 |
cse.req.maxet |
| Keyword | Description | Configuration Name |
|---|---|---|
| batchNotifyDuration | Default for the batchNotify/duration in seconds. Must be >0. Default: 60 seconds |
cse.sub.dur |
| Keyword | Description | Configuration Name |
|---|---|---|
| enableLimits | Enable/disable the default limits. Default: False |
cse.ts.enableLimits |
| mni | Default for maxNrOfInstances. Default: 10 |
cse.ts.mni |
| mbs | Default for maxByteSize. Default: 10.000 bytes |
cse.ts.mbs |
| mdn | Default for missingDataMaxNr. Default: 10 |
cse.ts.mdn |
| Keyword | Description | Configuration Name |
|---|---|---|
| bcni | Default timeSyncBeacon interval. This is the duration between to beacon notifications sent by the CSE to an AE or CSE.T he format must be an ISO8601 duration. Default: PT1H = 1 hour |
cse.tsb.bcni |
| bcnt | Default timeSyncBeacon threshold. When this time threshold is passed then a beacon notifications is sent to an AE or CSE. Default: 10.0 seconds |
cse.ts.bcnt |
| Keyword | Description | Configuration Name |
|---|---|---|
| refreshInterval | Interval for continuously refreshing information displays. Must be > 0.0 Default: 2.0 seconds |
cse.console.refreshInterval |
| hideResources | Hide certain resources from display in the console. This is a list of resource identifiers. Wildcards are allowed. Default: Empty list |
cse.console.hideResources |
| treeMode | Set the mode how resources and their content are presented in the console's and structure endpoint's tree view. Allowed values: normal, compact, content, contentOnly Default: normal |
cse.console.treeMode |
| treeIncludeVirtualResources | Show virtual resources in the console's and structure endpoint's tree view.. Default: False |
cse.console.treeIncludeVirtualResources |
| confirmQuit | Quitting the console needs to be confirmed. This may not work under Windows, so it is switched off by default. Default: False |
cse.console.confirmQuit |
| theme | Set the color theme for the console. Allowed values are "dark" and "light". Default: dark |
cse.console.theme |
| Keyword | Description | Configuration Name |
|---|---|---|
| scriptDirectories | Add one or multiple directory paths to look for scripts, in addition to the ones in the "init" directory. Must be a comma-separated list. Default: not set |
cse.scripting.scriptDirectories |
| verbose | Enable debug output during script execution, such as the current executed line. Default: False |
cse.scripting.verbose |
| fileMonitoringInterval | Set the interval to check for new files in the script (init) directory. 0 means disable monitoring. Must be >= 0.0. Default: 2.0 seconds |
cse.scripting.fileMonitoringInterval |
| Keyword | Description | Configuration Name |
|---|---|---|
| enable | Enable the web UI. Default: true |
cse.webui.enable |
| root | Root path of the web UI. Default: /webui |
cse.webui.root |
This section defines mappings for URI paths to IDs in the CSE. Mappings can be used to provide a more convenient way to access the CSE's resources via http. Each setting in the configuration file specifies a mapping, where the key specifies a new path and the value specified the mapping to a request (including optional arguments).
The http server redirects a request to a path element that matches one of specified keys to the respective request mapping (using the http status code 307).
Please note, that the "root" path in server.http prefixes both the new path and the respecting mapping. Also note, that the request still needs to have the necessary headers set in the request.
The following snippet only presents some example for ID mappings.
[server.http.mappings]
/access/v1/devices=/cse-mn?ty=14&fu=1&fo=2&rcn=8
/access/v1/apps=/id-mn?ty=2&fu=1&fo=2&rcn=8
/access/v1/devices/battery=/id-mn?ty=14&mgd=1006&fu=1&fo=2&rcn=8Configuration values can be referenced by their respective configuration name and used when importing resources.
The following configuration names are supported in addition to those defined in the sections below. They are set by the CSE at runtime.
| Configuration name | Description |
|---|---|
| configfile | Path and name of the configuration file. |
| packageDirectory | Path to the acme package directory. |