OpenTelemetry Configuration for Logging
The following OpenTelemetry configuration settings are available in the BasicSettings section of the platform-settings.json file.
Setting
Type
Default Value
Description
EnableOpenTelemetryForLogging
BOOLEAN
false
Set the value to true to enable the OpenTelemetry Collector.
When the ThingWorx Platform server starts, the OpenTelemetry Collector establishes a connection with the ThingWorx Platform server.
DisableFileLogging
BOOLEAN
false
When you set this value to true:
Logs are not written to the /ThingworxStorage/logs folder.
Logs do not get displayed on the Composer > Monitoring page.
You will see the following message on the Composer > Monitoring page:
Logging is disabled. Please refer to ThingWorx Platform configuration file to enable it.
This setting only stops ThingWorx internal logs. Logs configured through logback.xml, such as external logs continue to work.
Console logs and HTTP.out logs are not affected and continue to work.
If DisableFileLogging is set to true and EnableOpenTelemetryForLogging is set to false:
You see the following message on the Composer > Monitoring page:
Logging is disabled. Please refer to platform configuration file to enable it.
Log retrieval strategy will be set to DefaultLogRetrievalStrategy.
If DisableFileLogging is set to false and EnableOpenTelemetryForLogging is set to true, logs are available in ThingWorx log files on the platform and the third party software integrated with OpenTelemetry.
OpenTelemetry SDK Configuration
The following OpenTelemetry configuration settings are available in the OpenTelemetrySettings section of the platform-settings.json file.
Setting
Default Value
Description
BatchLogProcessorMaxQueueSize
2048
The maximum number of log records that can be queued before processing and export. Larger values increase throughput but require more memory.
BatchLogProcessorScheduledDelay
10 milliseconds
The number of milliseconds the processor waits before exporting a new batch of logs, even if the batch is not full.
BatchLogProcessorMaxExportBatchSize
512
The maximum number of log entries sent in a single export batch. This setting helps to control payload size and network utilization.
BatchLogProcessorExportTimeout
1000 milliseconds
The number of milliseconds the system waits for a log export request to complete before timing out.
OtlpGRPCLogExporterEndpoint
The OTLP gRPC endpoint URL where ThingWorx Platform exports logs (for example, http://localhost:4317). Required for remote log ingestion through the OpenTelemetry Collector or any OTLP gRPC-compatible backend.
OtlpGRPCEnableSSL
false
Allows you to enable or disable SSL/TLS for OTLP gRPC log export.
true
-uses secure transmission
false-uses plaintext
OtlpGRPCTrustStorePath
N/A
The path to the truststore file that contains trusted certificates for validating the OpenTelemetry Collector or target backend during SSL communication.
OtlpGRPCTrustStorePassword
N/A
Password for accessing the truststore configured in OtlpGRPCTrustStorePath.
OtlpGRPCKeyStorePath
N/A
The path to the keystore file that contains the client certificate and private key for mutual TLS (mTLS).
OtlpGRPCKeyStorePassword
N/A
Password for accessing the keystore configured in OtlpGRPCKeyStorePath.
RetryOtlpGRPCLogExporterMaxAttempts
5
The maximum number of retry attempts when log export fails due to transient errors.
RetryOtlpGRPCLogExporterBackOffMultiplier
1.5
The multiplier used to calculate exponential backoff. After each failed attempt of data export, the wait time keeps on increasing by this factor.
RetryOtlpGRPCLogExporterInitialBackOff
1 second
The amount of time in seconds before the first retry attempt.
RetryOtlpGRPCLogExporterMaxBackOff
5 seconds
The number of seconds between retry attempts during exponential backoff.
OtlpGRPCMetricExporterEndpoint
N/A
The OTLP gRPC endpoint URL where ThingWorx Platform exports metrics (for example, http://localhost:4317). This URL is required for metrics ingestion through the OpenTelemetry Collector or any OTLP gRPC-compatible backend.
EnableOpenTelemetryInternalMetrics
true
Enables sending metrics to the observability platform through the OpenTelemetry Collector.
Related Topics
Was this helpful?