Getting Started with ThingWorx > Installing and Upgrading ThingWorx > Installation Appendices > platform-settings.json Configuration Details
  
platform-settings.json Configuration Details
The platform-settings.json file is available for administrators to adjust settings for fine-tuning and is available in the software download.
* 
The sample below contains all options. Only one persistence provider is required.
{
"PlatformSettingsConfig": {
"BasicSettings": {
"BackupStorage": "/ThingworxBackupStorage",
"DatabaseLogRetentionPolicy": 7,
"EnableBackup": true,
"EnableHA": false,
"EnableSystemLogging": false,
"EnableSSO": false,
"FileRepositoryRoot": "/ThingworxStorage",
"HTTPRequestHeaderMaxLength": 2000,
"HTTPRequestParameterMaxLength": 2000,
"InternalAesCryptographicKeyLength": 128,
"Storage": "/ThingworxStorage"
},
"AdministratorUserSettings": {
"InitialPassword": "changeme"
},
"ContentTypeSettings": {
"supportedMediaEntityContentTypes" : ["image/svg+xml","image/png","image/gif","image/bmp","image/jpeg","application/pdf","image/vnd.microsoft.icon"]
},
"ExtensionPackageImportPolicy": {
"importEnabled": false,
"allowJarResources": false,
"allowJavascriptResources": false,
"allowCSSResources": false,
"allowJSONResources": false,
"allowWebAppResources": false,
"allowEntities": false,
"allowExtensibleEntities": false
},
"HASettings": {
"CoordinatorConnectionTimeout": 15000,
"CoordinatorHosts": "127.0.0.1:2181",
"CoordinatorMaxRetries": 3,
"CoordinatorRetryTimeout": 1000,
"CoordinatorSessionTimeout": 90000,
"CoordinatorZNode": "/HALeadershipCoordinator",
"LoadBalancerBase64EncodedCredentials": "QWRtaW5pc3RyYXRvcjphZG1pbg=="
},
"LicensingConnectionSettings": {
"username": "<username>",
"password": "<password>",
"timeout":"60"
}
},
"PersistenceProviderPackageConfigs": {
"NeoPersistenceProviderPackage": {
"StreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumQueueSize": 250000,
"maximumWaitTime": 10000,
"scanRate": 5,
"sizeThreshold": 1000
},
"ValueStreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumQueueSize": 500000,
"maximumWaitTime": 10000,
"scanRate": 5,
"sizeThreshold": 1000
},
"PersistentPropertyProcessorSettings": {
"maximumBlockSize": 2500,
"maximumWaitTime": 1000,
"maximumQueueSize": 100000,
"numberOfProcessingThreads": 20,
"scanRate": 25,
"sizeThreshold": 1000
}
},
"H2PersistenceProviderPackage": {
"ConnectionInformation": {
"acquireIncrement": 5,
"acquireRetryAttempts": 30,
"acquireRetryDelay": 1000,
"checkoutTimeout": 2000,
"idleConnectionTestPeriod": 6,
"initialPoolSize": 10,
"maxConnectionAge": 0,
"maxIdleTime": 0,
"maxIdleTimeExcessConnections": 36000,
"maxPoolSize": 100,
"maxStatements": 0,
"maxStatementsPerConnection": 50,
"minPoolSize": 10,
"numHelperThreads": 6,
"password": "password",
"tableLockTimeout": 10000,
"testConnectionOnCheckout": false,
"unreturnedConnectionTimeout": 0,
"username": "twadmin"
},
"StreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumQueueSize": 250000,
"maximumWaitTime": 10000,
"numberOfProcessingThreads": 5,
"scanRate": 5,
"sizeThreshold": 1000
},
"ValueStreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumWaitTime": 10000,
"maximumQueueSize": 500000,
"numberOfProcessingThreads": 5,
"scanRate": 5,
"sizeThreshold": 1000
},
"PersistentPropertyProcessorSettings": {
"maximumBlockSize": 2500,
"maximumWaitTime": 1000,
"maximumQueueSize": 100000,
"numberOfProcessingThreads": 20,
"scanRate": 25,
"sizeThreshold": 1000
}
},
"PostgresPersistenceProviderPackage": {
"ConnectionInformation": {
"acquireIncrement": 5,
"acquireRetryAttempts": 3,
"acquireRetryDelay": 10000,
"checkoutTimeout": 1000000,
"driverClass": "org.postgresql.Driver",
"fetchSize": 5000,
"idleConnectionTestPeriod": 60,
"initialPoolSize": 5,
"jdbcUrl": "jdbc:postgresql://localhost:5432/thingworx",
"maxConnectionAge": 0,
"maxIdleTime": 0,
"maxIdleTimeExcessConnections": 300,
"maxPoolSize": 100,
"maxStatements": 100,
"minPoolSize": 5,
"numHelperThreads": 8,
"password": "password",
"testConnectionOnCheckout": false,
"unreturnedConnectionTimeout": 0,
"username": "twadmin"
},
"StreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumQueueSize": 250000,
"maximumWaitTime": 10000,
"numberOfProcessingThreads": 5,
"scanRate": 5,
"sizeThreshold": 1000
},
"ValueStreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumQueueSize": 500000,
"maximumWaitTime": 10000,
"numberOfProcessingThreads": 5,
"scanRate": 5,
"sizeThreshold": 1000
},
"PersistentPropertyProcessorSettings": {
"maximumBlockSize": 2500,
"maximumWaitTime": 1000,
"maximumQueueSize": 100000,
"numberOfProcessingThreads": 20,
"scanRate": 25,
"sizeThreshold": 1000
}
},
"MssqlPersistenceProviderPackage": {
"ConnectionInformation": {
"acquireIncrement": 5,
"acquireRetryAttempts": 3,
"acquireRetryDelay": 10000,
"checkoutTimeout": 1000000,
"driverClass": "com.microsoft.sqlserver.jdbc.SQLServerDriver",
"fetchSize": 5000,
"idleConnectionTestPeriod": 60,
"initialPoolSize": 5,
"jdbcUrl": "jdbc:sqlserver://localhost:1433;databaseName=thingworx;applicationName=Thingworx;",
"maxConnectionAge": 0,
"maxIdleTime": 0,
"maxIdleTimeExcessConnections": 300,
"maxPoolSize": 100,
"maxStatements": 100,
"minPoolSize": 5,
"numHelperThreads": 8,
"password": "Password@123",
"testConnectionOnCheckout": false,
"unreturnedConnectionTimeout": 0,
"username": "msadmin"
},
"StreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumQueueSize": 250000,
"maximumWaitTime": 10000,
"numberOfProcessingThreads": 5,
"scanRate": 5,
"sizeThreshold": 1000
},
"ValueStreamProcessorSettings": {
"maximumBlockSize": 2500,
"maximumWaitTime": 10000,
"maximumQueueSize": 500000,
"numberOfProcessingThreads": 5,
"scanRate": 5,
"sizeThreshold": 1000
},
"PersistentPropertyProcessorSettings": {
"maximumBlockSize": 2500,
"maximumWaitTime": 1000,
"maximumQueueSize": 100000,
"numberOfProcessingThreads": 20,
"scanRate": 25,
"sizeThreshold": 1000
}
}
}
}
platform-settings.json Options
Basic Settings
Setting
Default
Description
BackupStorage
/ThingworxBackupStorage
The directory name where all backups are written to.
DatabaseLogRetentionPolicy
7
The number of days that database logs are retained.
EnableBackup
true
Determines whether backups are retained.
EnableHA
false
Determines whether ThingWorx can be configured for a highly available landscape.
EnableSystemLogging
false
Determines whether system logging is enabled.
* 
Do not turn this on unless instructed by ThingWorx Support.
EnableSSO
false
Set to true to enable SSO for ThingWorx Platform. When SSO is enabled, all authentication is redirected to the central authorization server that is configured in the sso-settings.json file. Edge websocket authentication is not affected.
FileRepositoryRoot
/ThingworxStorage
The directory where the root file repository is created. The default location is sufficient for standalone deployments. For ThingWorx HA deployments, the repository should be located on a shared file system where all ThingWorx servers have access.
HTTPRequestHeaderMaxLength
2000
The maximum allowable length for HTTP Request Headers values.
HTTPRequestParameterMaxLength
2000
The maximum allowable length for HTTP Request Parameter values.
InternalAesCryptographicKeyLength
128
Key length used when generating a symmetric AES key. Supported values are 128, 192, and 256.
* 
Encryption and decryption will fail if the key length is higher than 128 and the Java policies are not configured to use that key size.
Storage
/ThingworxStorage
The directory where all storage directories are created/located (excluding Backup Storage).
Extension Package Import Policy
Extension import is disabled by default for all users. Use the following settings to configure extension import functionality. Reference Importing Extensions for more information.
Setting
Description
Default
Examples
importEnabled
The top level control that represents the ability to import (=true) or not import (=false) extensions.
false
"importEnabled": false - Extensions cannot be imported, even if other ExtensionPackageImportPolicy settings are set to true.
"importEnabled": true - Passes the extension import to the next set of allow<Content>Resources settings (see rows below).
* 
If the allow<Content>Resources settings are false, then an empty extension (no entities, extensible entities, or resources) can be imported. Since this is likely not a useful configuration, if importEnabled is set to true, at least one other allow<Content>Resources setting should also be set to true.
allowJarResources
Allows extensions with Jar Resources to be imported.
false
"allowJarResources": true - allows extensions that declare jar files in their manifest as jar resources to be imported.
"allowJarResources": false -will not allow extensions that declare jar files in their manifest as jar resources to be imported.
allowJavascriptResources
Allows extensions with JavaScript Resources to be imported.
false
"allowJavascriptResources": true -allows extensions that declare JavaScript UI file resources of JS type in their manifest as JavaScript resources to be imported.
"allowJavascriptResources": false - will not allow extensions that declare JavaScript UI file resources of JS type in their manifest as JavaScript resources to be imported.
allowCSSResources
Allows extensions with CSS Resources to be imported.
false
"allowCSSResources": true -allows extensions that contain CSS UI file resources to be imported.
"allowCSSResources": false -will not allow extensions that contain CSS UI file resources to be imported.
allowJSONResources
Allows extensions with JSON Resources (for example, localization files) to be imported.
false
"allowJSONResources": true - allows extensions that contain JSON UI file resources to be imported.
"allowJSONResources": false - will not allow extensions that contain JSON UI file resources to be imported.
allowWebAppResources
Allows extensions with Web Resources to be imported.
false
"allowWebAppResources": true - allows extensions that contain WebApp UI file resources to be imported.
"allowWebAppResources": false - will not allow extensions that contain WebApp UI file resources to be imported.
allowEntities
Allows extensions with non-extensible entities to be imported. Examples of non-extensible entities include:
Application Key
Authenticator
Dashboard
Data Analysis Definition
Data Shape
GenericContentEntity and derived child classes like State Definition, Style Definition, Style Theme
Group
Localization Table
Log
Mashup
Media Entity
Menu
ModeledServiceProviderEntity and child classes like Notification Content
Network
Notification Definition
Organization
Persistence Provider
PersistenceProviderPackage and derived child classes
Project
Thing Shape
Thing Template
User
Vocabulary and derived child classes like DataTagVocabulary, ModelTagVocabulary
false
"allowEntities": true - allows extensions that declare non-extensible entities in their manifest to be imported.
"allowEntities": false - will not allow extensions that declare non-extensible entities in their manifest to be imported.
allowExtensibleEntities
Allows extensions with non-extensible entities to be imported. Examples of extensible entities include:
DirectoryService and derived child classes
ExtensionPackage
Resource and derived child classes that contain custom functions/services used as resources similar to OOTB Resources such as InfoTableFunctions, EntityServices, and EncryptionServices.
* 
The OOTB Subsystems that are not part of extensions are not affected.
ScriptFunctionLibrary and derived child classes.
Subsystem and derived child classes.
* 
The OOTB Subsystems that are not part of extensions are not affected.
Thing Package
Widget
false
"allowExtensibleEntities": true - allows extensions that declare extensible entities in their manifest to be imported.
"allowExtensibleEntities": false - will not allow extensions that declare extensible entities in their manifest to be imported.
HA Settings
Settings specific to a PostgreSQL HA landscape configuration. All settings are ignored if the EnableHA setting above is set to false. CoordinatorHosts and LoadBalancerBase64EncodedCredentials must be modified to suit your environment.
Setting
Default
Description
CoordinatorConnectionTimeout
15000
How long to wait (in milliseconds) for a connection to be established with Apache ZooKeeper service used to coordinate ThingWorx leadership.
CoordinatorHosts
127.0.0.1:2181
A comma-delimited list of the Apache ZooKeeper servers used to coordinate ThingWorx leader election. String pattern is IP:port. (e.g. "127.0.0.1:2181, 127.0.0.2:2181").
CoordinatorMaxRetries
3
The maximum allowable number of retries that will be made to establish a connection with the Apache ZooKeeper service used to coordinate ThingWorx leadership.
CoordinatorRetryTimeout
1000
How long to wait (in milliseconds) for each retry attempt.
CoordinatorSessionTimeout
90000
How long ThingWorx waits (in milliseconds) without receiving a "heartbeat" from the Apache ZooKeeper service used to coordinate ThingWorx leadership.
CoordinatorZNode
/HALeadershipCoordinator
When one Apache ZooKeeper service is shared by multiple ThingWorx HA deployments, this setting must provide a unique value for each ThingWorx HA deployment. This setting’s value can be arbitrary but must follow the format /<anyTextHere>. For example, ThingWorx instances TWX1 and TWX2 are in HA system A, and ThingWorx instances TWX3 and TWX4 are in HA system B. CoordinatorZNode is set to /HAsystemA for TWX1 and TWX2, and it is set to /HAsystemB for TWX3 and TWX4.
LoadBalancerBase64EncodedCredentials
QWRtaW5pc3RyYXRvcjphZG1pbg==
The Base64-encoded credentials for the HA Load Balancer, in the format of <user>:<unique password>
* 
Do not use a ThingWorx user.
* 
You can use any utility that Base64 encodes the matching <user>:<unique password> string used in your load balancer setup.
Administrator User Settings
Setting
Default
Description
InitialPassword
n/a
The initial Administrator password that is required to log into ThingWorx for the first time. The minimum length can be configured in the User Management Subsystem (minimum 10 characters, default is 14 characters). See Passwords (click here if you are viewing the PDF) for more information.
Content Type Settings
Setting
Default
Description
supportedMediaEntityContentTypes
"image/svg+xml","image/png","image/gif","image/bmp","image/jpeg","application/pdf","image/vnd.microsoft.icon"
Comma-delimited list of valid MIME content types that can be dynamically linked to Media entities. Additional types can be added.
Licensing Connection Settings
Setting
Default
Description
username
n/a
PTC Support site username
password
n/a
PTC Support site password
timeout (in seconds)
60
After the timeout period, the following error is logged in the Application Log:
License Server could not process request
NeoPersistenceProviderPackage
Contains Neo4j-specific Persistence Provider settings. If Neo4j is not the Persistence Provider, this entire section should be ignored.
Setting
Default
Description
StreamProcessorSettings
maximumBlockSize
2500
The maximum number of stream writes to process in one block.
maximumQueueSize
250000
The maximum number of stream entries to queue (will be rejected after that).
maximumWaitTime
10000
The maximum wait time (in milliseconds) before flushing stream buffer.
scanRate
5
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing stream buffer.
ValueStreamProcessorSettings
maximumBlockSize
2500
The maximum number of stream writes to process in one block.
maximumQueueSize
500000
The maximum number of stream entries to queue (will be rejected after that).
maximumWaitTime
10000
The maximum wait time (in milliseconds) before flushing the stream buffer.
scanRate
5
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing stream buffer.
PersistentPropertyProcessorSettings
maximumBlockSize
2500
The maximum number of property writes to process in one block.
maximumWaitTime
1000
The maximum wait time (in milliseconds) before flushing the property buffer.
maximumQueueSize
100000
The maximum number of property entries to queue (will be rejected after that).
numberOfProcessingThreads
20
The number of threads to use when processing properties.
scanRate
25
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing the property buffer.
H2PersistenceProviderPackage
Setting
Default
Description
Connection Information
acquireIncrement
5
Determines how many connections at a time the ThingWorx will try to acquire when the pool is exhausted.
acquireRetryAttempts
30
Defines how many times ThingWorx will try to acquire a new connection from the database before giving up.
acquireRetryDelay
1000
The time (in milliseconds) ThingWorx will wait between acquire attempts.
checkoutTimeout
1000000
The number of milliseconds a client calling getConnection() will wait for a connection to be checked-in or acquired when the pool is exhausted.
idleConnectionTestPeriod
6
Time period (in seconds) where connections will be tested so that idle connections won’t be closed from outside processes such as firewalls, etc. If this is a number greater than 0, ThingWorx will test all idle, pooled but unchecked-out connections, every x number of seconds.
* 
If you are experiencing “No connection to model provider” errors, review this setting. Compare to firewall defaults. Lowering the default will alleviate disconnection issues.
initialPoolSize
10
Initial number of database connections created and maintained within a pool upon startup. Should be between minPoolSize and maxPoolSize.
maxConnectionAge
0
Seconds, effectively a time to live. A connection older than maxConnectionAge will be destroyed and purged from the pool.
maxIdleTime
0
Seconds a connection can remain pooled but unused before being discarded. Zero means idle connections never expire.
maxIdleTimeExcessConnections
36000
The number of seconds that connections in excess of minPoolSize are permitted to remain in idle in the pool before being culled. Intended for applications that wish to aggressively minimize the number of open connections, shrinking the pool back towards minPoolSize if, following a spike, the load level diminishes and connections acquired are no longer needed. If maxIdleTime is set, maxIdleTimeExcessConnections should be smaller to have any effect. Setting this to zero means no enforcement and excess connections are not idled out.
maxPoolSize
100
Maximum number of connections a pool will maintain at any given time.
maxStatements
0
The size of the ThingWorx global PreparedStatement cache.
maxStatementsPerConnection
50
The size of the ThingWorx global PreparedStatement cache for each connection.
minPoolSize
5
Minimum number of connections a pool will maintain at any given time.
numHelperThreads
6
The number of helper threads to spawn. Slow JDBC operations are generally performed by helper threads that don't hold contended locks. Spreading these operations over multiple threads can significantly improve performance by allowing multiple operations to be performed simultaneously.
password
n/a
Database password.
username
twadmin
Database username.
tableLockTimeout
10000
The number of milliseconds a client will wait for a database table to be unlocked.
testConnectionOnCheckout
false
If true, an operation will be performed at every connection checkout to verify that the connection is valid.
unreturnedConnectionTimeout
0
The number of seconds to wait for a response from an unresponsive connection before discarding it. If set, if an application checks out but then fails to check-in a connection within the specified period of time, the pool will discard the connection. This permits applications with occasional connection leaks to survive, rather than eventually exhausting the connection pool. Zero means no timeout, and applications are expected to close their own connections.
StreamProcessorSettings
maximumBlockSize
2500
The maximum number of stream writes to process in one block.
maximumQueueSize
250000
The maximum number of stream entries to queue (will be rejected after that).
maximumWaitTime
10000
The maximum wait time (in milliseconds) before flushing stream buffer.
numberOfProcessingThreads
5
The number of threads to use when processing properties.
scanRate
5
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing stream buffer.
ValueStreamProcessorSettings
maximumBlockSize
2500
The maximum number of stream writes to process in one block.
maximumQueueSize
250000
The maximum number of stream entries to queue (will be rejected after that).
maximumWaitTime
10000
The maximum wait time (in milliseconds) before flushing the stream buffer.
numberOfProcessingThreads
5
The number of threads to use when processing properties.
scanRate
5
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing stream buffer.
PersistentPropertyProcessorSettings
maximumBlockSize
2500
The maximum number of property writes to process in one block.
maximumWaitTime
1000
The maximum wait time (in milliseconds) before flushing the property buffer.
maximumQueueSize
100000
The maximum number of property entries to queue (will be rejected after that).
numberOfProcessingThreads
20
The number of threads to use when processing properties.
scanRate
25
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing the property buffer.
PostgresPersistenceProviderPackage
Setting
Default
Description
ConnectionInformation
acquireIncrement
5
Determines how many connections at a time the platform will try to acquire when the pool is exhausted.
acquireRetryAttempts
3
Defines how many times ThingWorx will try to acquire a new connection from the database before giving up.
acquireRetryDelay
10000
The time (in milliseconds) ThingWorx will wait between acquire attempts.
checkoutTimeout
10000000
The number of milliseconds a client calling getConnection()will wait for a connection to be checked-in or acquired when the pool is exhausted.
driverClass
org.postgresql.Driver
The fully-qualified class name of the JDBC driverClass that is expected to provide Connections.
fetchSize
5000
The count of rows to be fetched in batches instead of caching all rows on the client side.
idleConnectionTestPeriod
60
If this is a number greater than 0, ThingWorx will test all idle, pooled but unchecked-out connections, every x number of seconds.
initialPoolSize
5
Initial number of database connections created and maintained within a pool upon startup. Should be between minPoolSize and maxPoolSize.
jdbcUrl
jdbc:postgresql://localhost:5432/thingworx
The jdbc url used to connect to PostgreSQL.
* 
If the default schema name is changed (from public), you must add <databasename>?currentSchema=<name of schema>. For example, if the schema name is mySchema, it would be: jdbc:postgresql://<DBServer>:<DBPort>/<databasename>?currentSchema=mySchema
* 
If you are configuring an HA solution, this should reflect the server IP that the pgPool process is running on. Change the port to the port that pgPool is serving.
maxConnectionAge
0
Seconds, effectively a time to live. A Connection older than maxConnectionAge will be destroyed and purged from the pool.
maxIdleTime
0
Seconds a connection can remain pooled but unused before being discarded. Zero means idle connections never expire.
maxIdleTimeExcessConnections
300
The number of seconds that connections in excess of minPoolSize are permitted to remain in idle in the pool before being culled. Intended for applications that wish to aggressively minimize the number of open connections, shrinking the pool back towards minPoolSize if, following a spike, the load level diminishes and connections acquired are no longer needed. If maxIdleTime is set, maxIdleTimeExcessConnections should be smaller to have any effect. Setting this to zero means no enforcement and excess connections are not idled out.
maxPoolSize
100
Maximum number of connections a pool will maintain at any given time.
maxStatements
100
The size of ThingWorx’s global PreparedStatement cache.
minPoolSize
5
Minimum number of Connections a pool will maintain at any given time.
numHelperThreads
8
The number of helper threads to spawn. Slow JDBC operations are generally performed by helper threads that don't hold contended locks. Spreading these operations over multiple threads can significantly improve performance by allowing multiple operations to be performed simultaneously.
password
<unique password>
The password used to log into the database.
testConnectionOnCheckout
false
If true, an operation will be performed at every connection checkout to verify that the connection is valid.
unreturnedConnectionTimeout
0
The number of seconds to wait for a response from an unresponsive connection before discarding it. If set, if an application checks out but then fails to check-in a connection within the specified period of time, the pool will discard the connection. This permits applications with occasional connection leaks to survive, rather than eventually exhausting the Connection pool. Zero means no timeout, and applications are expected to close their own connections.
username
twadmin
The user that has the privilege to modify tables. This is the user created on the database for the ThingWorx server.
* 
To change the PostgreSQL password: Change this user's password, and also change the unencrypted password setting in the platform-settings.json file or the encrypted value in the /ThingworxStorage/keystore.jks keystore.
Stream Processor Settings
maximumBlockSize
2500
The maximum number of stream writes to process in one block.
maximumQueueSize
250000
The maximum number of stream entries to queue (will be rejected after that).
maximumWaitTime
10000
Number of milliseconds the system waits before flushing the stream buffer.
numberOfProcessingThreads
5
The number of processing threads (cannot change for Neo4j).
scanRate
5
The buffer status is checked at the specified rate value in milliseconds.
sizeThreshold
1000
Maximum number of items to accumulate before flushing the stream buffer.
Value Stream Processor Settings
maximumBlockSize
2500
Maximum number of value stream writes to process in one block.
maximumQueueSize
500000
Maximum number of value stream entries to queue (will be rejected after that).
maximumWaitTime
10000
Number of milliseconds the system waits before flushing the value stream buffer.
numberofProcessingThreads
5
The number of processing threads (cannot change for Neo4j).
scanRate
5
The rate (in milliseconds) before flushing the stream buffer.
sizeThreshold
1000
Maximum number of items to accumulate before flushing the value stream buffer.
PersistentPropertyProcessorSettings
maximumBlockSize
2500
The maximum number of property writes to process in one block.
maximumWaitTime
1000
The maximum wait time (in milliseconds) before flushing the property buffer.
maximumQueueSize
100000
The maximum number of property entries to queue (will be rejected after that).
numberOfProcessingThreads
20
The number of threads to use when processing properties.
scanRate
25
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing the property buffer.
MssqlPersistenceProviderPackage
Setting
Default
Description
ConnectionInformation
acquireIncrement
5
Determines how many connections at a time ThingWorx will try to acquire when the pool is exhausted.
acquireRetryAttempts
3
Defines how many times ThingWorx will try to acquire a new connection from the database before giving up.
acquireRetryDelay
10000
The time (in milliseconds) ThingWorx will wait between acquire attempts.
checkoutTimeout
1000000
The number of milliseconds a client calling getConnection() will wait for a connection to be checked-in or acquired when the pool is exhausted.
driverClass
com.microsoft.sqlserver.jdbc.SQLServerDriver
The fully-qualified class name of the JDBC driverClass that is expected to provide connections.
fetchSize
5000
The count of rows to be fetched in batches instead of caching all rows on the client side.
idleConnectionTestPeriod
60
Time period (in seconds) where connections will be tested so that idle connections won’t be closed from outside processes such as firewalls, etc. If this is a number greater than 0, ThingWorx will test all idle, pooled but unchecked-out connections, every x number of seconds.
* 
If you are experiencing “No connection to model provider” errors, review this setting. Compare to firewall defaults. Lowering the default will alleviate disconnection issues.
initialPoolSize
5
Initial number of database connections created and maintained within a pool upon startup. Should be between minPoolSize and maxPoolSize.
jdbcUrl
jdbc:sqlserver://localhost:1433;databaseName=thingworx;applicationName=Thingworx;
The jdbc url used to connect to MSSQL.
maxConnectionAge
0
Seconds, effectively a time to live. A connection older than maxConnectionAge will be destroyed and purged from the pool.
maxIdleTime
0
Seconds a connection can remain pooled but unused before being discarded. Zero means idle connections never expire.
maxIdleTimeExcessConnections
300
The number of seconds that connections in excess of minPoolSize are permitted to remain in idle in the pool before being culled. Intended for applications that wish to aggressively minimize the number of open connections, shrinking the pool back towards minPoolSize if, following a spike, the load level diminishes and Connections acquired are no longer needed. If maxIdleTime is set, maxIdleTimeExcessConnections should be smaller to have any effect. Setting this to zero means no enforcement and excess connections are not idled out.
maxPoolSize
100
Maximum number of Connections a pool will maintain at any given time.
maxStatements
100
The size of the ThingWorx global PreparedStatement cache.
minPoolSize
5
Minimum number of Connections a pool will maintain at any given time.
numHelperThreads
8
The number of helper threads to spawn. Slow JDBC operations are generally performed by helper threads that don't hold contended locks. Spreading these operations over multiple threads can significantly improve performance by allowing multiple operations to be performed simultaneously.
password
<unique password>
The password to log into the database.
testConnectionOnCheckout
false
If true, an operation will be performed at every connection checkout to verify that the connection is valid.
unreturnedConnectionTimeout
0
The number of seconds to wait for a response from an unresponsive connection before discarding it. If set, if an application checks out but then fails to check-in a connection within the specified period of time, the pool will discard the connection. This permits applications with occasional connection leaks to survive, rather than eventually exhausting the Connection pool. Zero means no timeout, and applications are expected to close their own connections.
username
msadmin
This is the userid that owns the TWSCHEMA schema and is used for authentication to MSSQL in the JDBC connection string.
Stream Processor Settings
maximumBlockSize
2500
The maximum number of stream writes to process in one block.
maximumQueueSize
250000
The maximum number of stream entries to queue (will be rejected after that).
maximumWaitTime
10000
Number of milliseconds the system waits before flushing the stream buffer.
numberOfProcessingThreads
5
The number of processing threads (cannot change for Neo4j).
scanRate
5
The buffer status is checked at the specified rate value in milliseconds.
sizeThreshold
1000
Maximum number of items to accumulate before flushing the stream buffer.
Value Stream Processor Settings
maximumBlockSize
2500
Maximum number of value stream writes to process in one block.
maximumWaitTime
10000
Number of milliseconds the system waits before flushing the value stream buffer.
maximumQueueSize
500000
Maximum number of value stream entries to queue (will be rejected after that).
numberofProcessingThreads
5
The number of processing threads (cannot change for Neo4j).
scanRate
5
The rate (in milliseconds) before flushing the stream buffer.
sizeThreshold
1000
Maximum number of items to accumulate before flushing the value stream buffer.
PersistentPropertyProcessorSettings
maximumBlockSize
2500
The maximum number of property writes to process in one block.
maximumWaitTime
1000
The maximum wait time (in milliseconds) before flushing the property buffer.
maximumQueueSize
100000
The maximum number of property entries to queue (will be rejected after that).
numberOfProcessingThreads
20
The number of threads to use when processing properties.
scanRate
25
The rate (in milliseconds) at which to check the buffer status.
sizeThreshold
1000
The maximum number of items to accumulate before flushing the property buffer.
ThingWorx Flow Settings
To add the RabbitMQ Password to the ThingWorx Keystore, do the following:
1. In the platform-settings.json file, update the ThingWorx Flow settings > QueuePassword setting value as follows:
"QueuePassword": "encrypt.queue.password"
This password signals the ThingWorx platform to look for the encrypted queue password in the keystore when it is encountered.
2. To create a keystore with the queue password encrypted inside, run the following command and in the second argument, enter your queue server password as follows:
java com.thingworx.security.keystore.ThingworxKeyStore encrypt.queue.password
<queue_server password>
* 
By default, the password is stored in /ThingworxPlatform and the keystore is stored in /ThingworxStorage.
If you need to configure the custom folder locations, run the following command:
java com.thingworx.security.keystore.ThingworxKeyStore encrypt.queue.password
<queue_server password> <Password location> <Keystore location>