- 如何修改配置参数?
- 配置参数
- HTTP server parameters
- MQTT listeners parameters
- Kafka parameters
- General service parameters
- Actor system parameters
- Platform integrations parameters
- Database time series parameters
- SQL configuration parameters
- Redis lettuce configuration parameters
- Redis jedis configuration parameters
- SQL DAO configuration parameters
- General Spring parameters
- Security parameters
- MQTT parameters
- Cache parameters
- Redis configuration parameters
- Statistics parameters
- Historical data statistics parameters
- Metrics management parameters
- Spring CORS configuration
- Spring doc common parameters
- Swagger common parameters
- Application info parameters
- Analysis parameters
本指南帮助您熟悉TBMQ PE 的配置文件和参数。 我们强烈建议使用环境变量配置TBMQ。 这样在新平台版本发布时,您无需合并配置文件。
可用配置参数及对应环境变量列表见此处。
如何修改配置参数?
Docker-Based部署
若TBMQ部署在Docker Compose环境中,可编辑脚本并为对应容器添加环境变量。更多详情请参阅 Docker文档。
K8S-Based部署
若TBMQ部署在K8S环境中,可编辑脚本并为对应deployments/stateful sets添加环境变量。更多详情请参阅 K8S文档。
配置参数
配置文件采用YAML格式。所有配置参数均有对应的环境变量名和默认值。修改配置参数时,只需修改其默认值。例如:
1
2
server:
address: "${HTTP_BIND_ADDRESS:0.0.0.0}"
本例中,‘HTTP_BIND_ADDRESS’ 为环境变量名,‘0.0.0.0’ 为默认值。
以下示例用于添加值为 ‘8084’ 的环境变量 ‘HTTP_BIND_PORT’:
1
2
...
export HTTP_BIND_PORT=8084
参数按系统组件分组。列表包含名称(thingsboard-mqtt-broker.yml 中的路径)、环境变量、默认值和说明。
HTTP server parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| server.shutdown | SERVER_SHUTDOWN | graceful | 关闭类型(优雅关闭或立即关闭) |
| server.address | HTTP_BIND_ADDRESS | 0.0.0.0 | HTTP服务器绑定地址(如果禁用web环境则不生效) |
| server.port | HTTP_BIND_PORT | 8083 | HTTP服务器绑定端口(如果禁用web环境则不生效) |
| server.forward_headers_strategy | HTTP_FORWARD_HEADERS_STRATEGY | framework | 服务器标头转发策略。在使用反向代理时对SWAGGER UI是必需的 |
| server.http2.enabled | HTTP2_ENABLED | true | 启用/禁用HTTP/2支持 |
| server.log_controller_error_stack_trace | HTTP_LOG_CONTROLLER_ERROR_STACK_TRACE | false | 当REST API抛出异常时记录带有堆栈跟踪的错误 |
| server.http.max_payload_size | HTTP_MAX_PAYLOAD_SIZE_LIMIT_CONFIGURATION | /api/image*/**=52428800;/api/resource/**=52428800;/api/**=16777216 | 分号分隔的urlPattern=maxPayloadSize对列表,定义指定URL模式的最大HTTP请求大小(字节为单位)。首次匹配后,所有其他将被跳过 |
| server.ssl.enabled | SSL_ENABLED | false | 启用/禁用SSL支持 |
| server.ssl.credentials.type | SSL_CREDENTIALS_TYPE | PEM | 服务器凭证类型(PEM-PEM证书文件;KEYSTORE-Java密钥库) |
| server.ssl.credentials.pem.cert_file | SSL_PEM_CERT | server.pem | 服务器证书文件路径(包含服务器证书或证书链,可能包括服务器私钥) |
| server.ssl.credentials.pem.key_file | SSL_PEM_KEY | server_key.pem | 服务器证书私钥文件路径。默认情况下为可选项。如果服务器证书文件中不存在私钥,则为必需项 |
| server.ssl.credentials.pem.key_password | SSL_PEM_KEY_PASSWORD | server_key_password | 服务器证书私钥密码(可选) |
| server.ssl.credentials.keystore.type | SSL_KEY_STORE_TYPE | PKCS12 | 密钥库的类型(JKS或PKCS12) |
| server.ssl.credentials.keystore.store_file | SSL_KEY_STORE | classpath:keystore/keystore.p12 | 保存SSL证书的密钥库的路径 |
| server.ssl.credentials.keystore.store_password | SSL_KEY_STORE_PASSWORD | thingsboard_mqtt_broker | 用于访问密钥库的密码 |
| server.ssl.credentials.keystore.key_alias | SSL_KEY_ALIAS | tomcat | 密钥别名 |
| server.ssl.credentials.keystore.key_password | SSL_KEY_PASSWORD | thingsboard_mqtt_broker | 用于访问密钥的密码 |
MQTT listeners parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| listener.proxy_enabled | MQTT_PROXY_PROTOCOL_ENABLED | false | 作为所有侦听器的全局设置启用代理协议支持。默认禁用。如果启用,支持v1和v2两种版本。 用于在日志中获取客户端的真实IP地址,用于会话详细信息和未授权客户端功能 |
| listener.leak_detector_level | NETTY_LEAK_DETECTOR_LVL | DISABLED | Netty泄漏检测器级别:DISABLED、SIMPLE、ADVANCED、PARANOID。它为所有侦听器全局设置 |
| listener.write_buffer_high_water_mark | NETTY_WRITE_BUFFER_HIGH_WATER_MARK | 64 | Netty认为通道不可写的阈值(KB为单位)。达到限制时,TBMQ停止向订阅者传递数据,直到通道再次可写。 在这种情况下,非持久客户端会丢失数据 |
| listener.write_buffer_low_water_mark | NETTY_WRITE_BUFFER_LOW_WATER_MARK | 32 | Netty认为通道再次可写的阈值(KB为单位)。达到限制时,TBMQ开始向订阅者传递数据 |
| listener.so_receive_buffer | NETTY_SO_RECEIVE_BUFFER | 0 | Netty的套接字接收缓冲区大小(KB为单位)。如果达到缓冲区限制,TCP将触发背压并通知发送方降速。 如果设置为0(默认值),将使用系统的默认缓冲区大小 |
| listener.tcp.enabled | LISTENER_TCP_ENABLED | true | 启用/禁用MQTT TCP端口侦听器 |
| listener.tcp.bind_address | LISTENER_TCP_BIND_ADDRESS | 0.0.0.0 | MQTT TCP侦听器绑定地址 |
| listener.tcp.bind_port | LISTENER_TCP_BIND_PORT | 1883 | MQTT TCP侦听器绑定端口 |
| listener.tcp.proxy_enabled | MQTT_TCP_PROXY_PROTOCOL_ENABLED | 为MQTT TCP侦听器启用代理协议支持。默认未设置——在这种情况下,它继承全局MQTT_PROXY_PROTOCOL_ENABLED值。 如果显式设置,支持v1和v2两种版本,并优先于全局设置。 用于在日志中获取客户端的真实IP地址,用于会话详细信息和未授权客户端功能 | |
| listener.tcp.netty.boss_group_thread_count | TCP_NETTY_BOSS_GROUP_THREADS | 1 | Netty boss组线程计数 |
| listener.tcp.netty.worker_group_thread_count | TCP_NETTY_WORKER_GROUP_THREADS | 12 | Netty worker组线程计数 |
| listener.tcp.netty.max_payload_size | TCP_NETTY_MAX_PAYLOAD_SIZE | 65536 | Max payload size in bytes |
| listener.tcp.netty.so_keep_alive | TCP_NETTY_SO_KEEPALIVE | true | Enable/disable keep-alive mechanism to periodically probe the other end of a connection |
| listener.tcp.netty.shutdown_quiet_period | TCP_NETTY_SHUTDOWN_QUIET_PERIOD | 0 | Period in seconds in graceful shutdown during which no new tasks are submitted |
| listener.tcp.netty.shutdown_timeout | TCP_NETTY_SHUTDOWN_TIMEOUT | 5 | The max time in seconds to wait until the executor is stopped |
| listener.ssl.enabled | LISTENER_SSL_ENABLED | false | Enable/disable MQTT SSL port listener |
| listener.ssl.bind_address | LISTENER_SSL_BIND_ADDRESS | 0.0.0.0 | MQTT SSL listener bind address |
| listener.ssl.bind_port | LISTENER_SSL_BIND_PORT | 8883 | MQTT SSL listener bind port |
| listener.ssl.proxy_enabled | MQTT_SSL_PROXY_PROTOCOL_ENABLED | Enable proxy protocol support for the MQTT TLS listener. Unset by default – in this case it inherits the global MQTT_PROXY_PROTOCOL_ENABLED value. If explicitly set, supports both v1 and v2 and takes precedence over the global setting. Useful to get the real IP address of the client in the logs, for session details info and unauthorized clients feature | |
| listener.ssl.config.protocol | LISTENER_SSL_PROTOCOL | TLSv1.2 | SSL protocol: see this link |
| listener.ssl.config.enabled_cipher_suites | LISTENER_SSL_ENABLED_CIPHER_SUITES | Sets the cipher suites enabled for use on mqtts listener. The value is a comma-separated list of cipher suits (e.g. TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256). Defaults to empty list meaning all supported cipher suites of the used provider are taken | |
| listener.ssl.config.credentials.type | LISTENER_SSL_CREDENTIALS_TYPE | PEM | 服务器凭证类型(PEM-PEM证书文件;KEYSTORE-Java密钥库) |
| listener.ssl.config.credentials.pem.cert_file | LISTENER_SSL_PEM_CERT | mqttserver.pem | 服务器证书文件路径(包含服务器证书或证书链,可能包括服务器私钥) |
| listener.ssl.config.credentials.pem.key_file | LISTENER_SSL_PEM_KEY | mqttserver_key.pem | 服务器证书私钥文件路径。默认情况下为可选项。如果服务器证书文件中不存在私钥,则为必需项 |
| listener.ssl.config.credentials.pem.key_password | LISTENER_SSL_PEM_KEY_PASSWORD | server_key_password | 服务器证书私钥密码(可选) |
| listener.ssl.config.credentials.keystore.type | LISTENER_SSL_KEY_STORE_TYPE | JKS | 密钥库的类型(JKS或PKCS12) |
| listener.ssl.config.credentials.keystore.store_file | LISTENER_SSL_KEY_STORE | mqttserver.jks | 保存SSL证书的密钥库的路径 |
| listener.ssl.config.credentials.keystore.store_password | LISTENER_SSL_KEY_STORE_PASSWORD | server_ks_password | 用于访问密钥库的密码 |
| listener.ssl.config.credentials.keystore.key_alias | LISTENER_SSL_KEY_ALIAS | Optional alias of the private key. If not set, the platform will load the first private key from the keystore | |
| listener.ssl.config.credentials.keystore.key_password | LISTENER_SSL_KEY_PASSWORD | server_key_password | Optional password to access the private key. If not set, the platform will attempt to load the private keys that are not protected with the password |
| listener.ssl.netty.boss_group_thread_count | SSL_NETTY_BOSS_GROUP_THREADS | 1 | Netty boss组线程计数 |
| listener.ssl.netty.worker_group_thread_count | SSL_NETTY_WORKER_GROUP_THREADS | 12 | Netty worker组线程计数 |
| listener.ssl.netty.max_payload_size | SSL_NETTY_MAX_PAYLOAD_SIZE | 65536 | Max payload size in bytes |
| listener.ssl.netty.so_keep_alive | SSL_NETTY_SO_KEEPALIVE | true | Enable/disable keep-alive mechanism to periodically probe the other end of a connection |
| listener.ssl.netty.shutdown_quiet_period | SSL_NETTY_SHUTDOWN_QUIET_PERIOD | 0 | Period in seconds in graceful shutdown during which no new tasks are submitted |
| listener.ssl.netty.shutdown_timeout | SSL_NETTY_SHUTDOWN_TIMEOUT | 5 | The max time in seconds to wait until the executor is stopped |
| listener.ws.enabled | LISTENER_WS_ENABLED | true | Enable/disable MQTT WS port listener |
| listener.ws.bind_address | LISTENER_WS_BIND_ADDRESS | 0.0.0.0 | MQTT WS listener bind address |
| listener.ws.bind_port | LISTENER_WS_BIND_PORT | 8084 | MQTT WS listener bind port |
| listener.ws.proxy_enabled | MQTT_WS_PROXY_PROTOCOL_ENABLED | Enable proxy protocol support for the MQTT WS listener. Unset by default – in this case it inherits the global MQTT_PROXY_PROTOCOL_ENABLED value. If explicitly set, supports both v1 and v2 and takes precedence over the global setting. Useful to get the real IP address of the client in the logs, for session details info and unauthorized clients feature | |
| listener.ws.netty.sub_protocols | WS_NETTY_SUB_PROTOCOLS | mqttv3.1,mqtt | Comma-separated list of subprotocols that the WebSocket can negotiate. The subprotocol setting `mqtt` represents MQTT 3.1.1 and MQTT 5 |
| listener.ws.netty.boss_group_thread_count | WS_NETTY_BOSS_GROUP_THREADS | 1 | Netty boss组线程计数 |
| listener.ws.netty.worker_group_thread_count | WS_NETTY_WORKER_GROUP_THREADS | 12 | Netty worker组线程计数 |
| listener.ws.netty.max_payload_size | WS_NETTY_MAX_PAYLOAD_SIZE | 65536 | Max payload size in bytes |
| listener.ws.netty.so_keep_alive | WS_NETTY_SO_KEEPALIVE | true | Enable/disable keep-alive mechanism to periodically probe the other end of a connection |
| listener.ws.netty.shutdown_quiet_period | WS_NETTY_SHUTDOWN_QUIET_PERIOD | 0 | Period in seconds in graceful shutdown during which no new tasks are submitted |
| listener.ws.netty.shutdown_timeout | WS_NETTY_SHUTDOWN_TIMEOUT | 5 | The max time in seconds to wait until the executor is stopped |
| listener.wss.enabled | LISTENER_WSS_ENABLED | false | Enable/disable MQTT WSS port listener |
| listener.wss.bind_address | LISTENER_WSS_BIND_ADDRESS | 0.0.0.0 | MQTT WSS listener bind address |
| listener.wss.bind_port | LISTENER_WSS_BIND_PORT | 8085 | MQTT WSS listener bind port |
| listener.wss.proxy_enabled | MQTT_WSS_PROXY_PROTOCOL_ENABLED | Enable proxy protocol support for the MQTT WSS listener. Unset by default – in this case it inherits the global MQTT_PROXY_PROTOCOL_ENABLED value. If explicitly set, supports both v1 and v2 and takes precedence over the global setting. Useful to get the real IP address of the client in the logs, for session details info and unauthorized clients feature | |
| listener.wss.config.protocol | LISTENER_WSS_PROTOCOL | TLSv1.2 | SSL protocol: see this link |
| listener.wss.config.enabled_cipher_suites | LISTENER_WSS_ENABLED_CIPHER_SUITES | Sets the cipher suites enabled for use on wss listener. The value is a comma-separated list of cipher suits (e.g. TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256). Defaults to empty list meaning all supported cipher suites of the used provider are taken | |
| listener.wss.config.credentials.type | LISTENER_WSS_CREDENTIALS_TYPE | PEM | 服务器凭证类型(PEM-PEM证书文件;KEYSTORE-Java密钥库) |
| listener.wss.config.credentials.pem.cert_file | LISTENER_WSS_PEM_CERT | ws_mqtt_server.pem | 服务器证书文件路径(包含服务器证书或证书链,可能包括服务器私钥) |
| listener.wss.config.credentials.pem.key_file | LISTENER_WSS_PEM_KEY | ws_mqtt_server_key.pem | 服务器证书私钥文件路径。默认情况下为可选项。如果服务器证书文件中不存在私钥,则为必需项 |
| listener.wss.config.credentials.pem.key_password | LISTENER_WSS_PEM_KEY_PASSWORD | ws_server_key_password | 服务器证书私钥密码(可选) |
| listener.wss.config.credentials.keystore.type | LISTENER_WSS_KEY_STORE_TYPE | JKS | 密钥库的类型(JKS或PKCS12) |
| listener.wss.config.credentials.keystore.store_file | LISTENER_WSS_KEY_STORE | ws_mqtt_server.jks | 保存SSL证书的密钥库的路径 |
| listener.wss.config.credentials.keystore.store_password | LISTENER_WSS_KEY_STORE_PASSWORD | ws_server_ks_password | 用于访问密钥库的密码 |
| listener.wss.config.credentials.keystore.key_alias | LISTENER_WSS_KEY_ALIAS | Optional alias of the private key. If not set, the platform will load the first private key from the keystore | |
| listener.wss.config.credentials.keystore.key_password | LISTENER_WSS_KEY_PASSWORD | ws_server_key_password | Optional password to access the private key. If not set, the platform will attempt to load the private keys that are not protected with the password |
| listener.wss.netty.sub_protocols | WSS_NETTY_SUB_PROTOCOLS | mqttv3.1,mqtt | Comma-separated list of subprotocols that the WebSocket can negotiate. The subprotocol setting `mqtt` represents MQTT 3.1.1 and MQTT 5 |
| listener.wss.netty.boss_group_thread_count | WSS_NETTY_BOSS_GROUP_THREADS | 1 | Netty boss组线程计数 |
| listener.wss.netty.worker_group_thread_count | WSS_NETTY_WORKER_GROUP_THREADS | 12 | Netty worker组线程计数 |
| listener.wss.netty.max_payload_size | WSS_NETTY_MAX_PAYLOAD_SIZE | 65536 | Max payload size in bytes |
| listener.wss.netty.so_keep_alive | WSS_NETTY_SO_KEEPALIVE | true | Enable/disable keep-alive mechanism to periodically probe the other end of a connection |
| listener.wss.netty.shutdown_quiet_period | WSS_NETTY_SHUTDOWN_QUIET_PERIOD | 0 | Period in seconds in graceful shutdown during which no new tasks are submitted |
| listener.wss.netty.shutdown_timeout | WSS_NETTY_SHUTDOWN_TIMEOUT | 5 | The max time in seconds to wait until the executor is stopped |
Kafka parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| queue.msg-all.consumers-count | TB_MSG_ALL_CONSUMERS_COUNT | 4 | Number of parallel consumers for 'tbmq.msg.all' topic. Should not be more than the number of partitions in topic |
| queue.msg-all.threads-count | TB_MSG_ALL_THREADS_COUNT | 4 | Number of threads in the pool to process consumers tasks. Should not be less than number of consumers |
| queue.msg-all.poll-interval | TB_MSG_ALL_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.msg.all' topic |
| queue.msg-all.pack-processing-timeout | TB_MSG_ALL_PACK_PROCESSING_TIMEOUT | 20000 | Timeout in milliseconds for processing the pack of messages from 'tbmq.msg.all' topic |
| queue.msg-all.ack-strategy.type | TB_MSG_ALL_ACK_STRATEGY_TYPE | SKIP_ALL | Processing strategy for 'tbmq.msg.all' topic. Can be: SKIP_ALL, RETRY_ALL |
| queue.msg-all.ack-strategy.retries | TB_MSG_ALL_ACK_STRATEGY_RETRIES | 1 | Number of retries, 0 is unlimited. Use for RETRY_ALL processing strategy |
| queue.msg-all.msg-parallel-processing | TB_MSG_ALL_PARALLEL_PROCESSING | false | Enable/disable processing of consumed messages in parallel (grouped by publishing client id to preserve order). Helpful when the same client publishes lots of messages in a short amount of time. It is recommended to count the impact of this parameter before setting it on production |
| queue.application-persisted-msg.poll-interval | TB_APP_PERSISTED_MSG_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from Application topics |
| queue.application-persisted-msg.pack-processing-timeout | TB_APP_PERSISTED_MSG_PACK_PROCESSING_TIMEOUT | 20000 | Timeout in milliseconds for processing the pack of messages |
| queue.application-persisted-msg.ack-strategy.type | TB_APP_PERSISTED_MSG_ACK_STRATEGY_TYPE | RETRY_ALL | Processing strategy for Application topics. Can be: SKIP_ALL, RETRY_ALL |
| queue.application-persisted-msg.ack-strategy.retries | TB_APP_PERSISTED_MSG_ACK_STRATEGY_RETRIES | 3 | Number of retries, 0 is unlimited. Use for RETRY_ALL processing strategy |
| queue.application-persisted-msg.client-id-validation | TB_APP_PERSISTED_MSG_CLIENT_ID_VALIDATION | true | Enable/disable check that application client id contains only alphanumeric chars for Kafka topic creation |
| queue.application-persisted-msg.shared-topic-validation | TB_APP_PERSISTED_MSG_SHARED_TOPIC_VALIDATION | true | Enable/disable check that application shared subscription topic filter contains only alphanumeric chars or '+' or '#' for Kafka topic creation |
| queue.device-persisted-msg.consumers-count | TB_DEVICE_PERSISTED_MSG_CONSUMERS_COUNT | 3 | Number of parallel consumers for 'tbmq.msg.persisted' topic. Should not be more than the number of partitions in topic |
| queue.device-persisted-msg.threads-count | TB_DEVICE_PERSISTED_MSG_THREADS_COUNT | 3 | Number of threads in the pool to process consumers tasks |
| queue.device-persisted-msg.poll-interval | TB_DEVICE_PERSISTED_MSG_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.msg.persisted' topic |
| queue.device-persisted-msg.pack-processing-timeout | TB_DEVICE_PERSISTED_MSG_PACK_PROCESSING_TIMEOUT | 20000 | Timeout in milliseconds for processing the pack of messages from 'tbmq.msg.persisted' topic |
| queue.device-persisted-msg.ack-strategy.type | TB_DEVICE_PERSISTED_MSG_ACK_STRATEGY_TYPE | RETRY_ALL | Queue processing strategy. Can be: SKIP_ALL, RETRY_ALL |
| queue.device-persisted-msg.ack-strategy.retries | TB_DEVICE_PERSISTED_MSG_ACK_STRATEGY_RETRIES | 3 | Number of retries, 0 is unlimited. Use for RETRY_ALL processing strategy |
| queue.device-persisted-msg.ack-strategy.pause-between-retries | TB_DEVICE_PERSISTED_MSG_ACK_STRATEGY_PAUSE_BETWEEN_RETRIES | 1 | Time in seconds to wait in consumer thread before retries |
| queue.retained-msg.poll-interval | TB_RETAINED_MSG_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.msg.retained' topic |
| queue.retained-msg.acknowledge-wait-timeout-ms | TB_RETAINED_MSG_ACK_WAIT_TIMEOUT_MS | 500 | Interval in milliseconds to wait for system messages to be delivered to 'tbmq.msg.retained' topic |
| queue.client-session.poll-interval | TB_CLIENT_SESSION_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.client.session' topic |
| queue.client-session.acknowledge-wait-timeout-ms | TB_CLIENT_SESSION_ACK_WAIT_TIMEOUT_MS | 500 | Interval in milliseconds to wait for system messages to be delivered to 'tbmq.client.session' topic |
| queue.client-subscriptions.poll-interval | TB_CLIENT_SUBSCRIPTIONS_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.client.subscriptions' topic |
| queue.client-subscriptions.acknowledge-wait-timeout-ms | TB_CLIENT_SUBSCRIPTIONS_ACK_WAIT_TIMEOUT_MS | 500 | Interval in milliseconds to wait for system messages to be delivered to 'tbmq.client.subscriptions' topic |
| queue.client-session-event.consumers-count | TB_CLIENT_SESSION_EVENT_CONSUMERS_COUNT | 2 | Number of parallel consumers for `tbmq.client.session.event.request` topic |
| queue.client-session-event.max-pending-requests | TB_CLIENT_SESSION_EVENT_MAX_PENDING_REQUESTS | 10000 | Number of pending client session events |
| queue.client-session-event.poll-interval | TB_CLIENT_SESSION_EVENT_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.client.session.event.request' topic |
| queue.client-session-event.batch-wait-timeout-ms | TB_CLIENT_SESSION_EVENT_BATCH_WAIT_MS | 2000 | Max interval in milliseconds to process 'tbmq.client.session.event.request' messages after consuming them |
| queue.client-session-event-response.response-sender-threads | TB_CLIENT_SESSION_EVENT_RESPONSE_SENDER_THREADS | 8 | Number of threads for sending event responses to session event requests |
| queue.client-session-event-response.poll-interval | TB_CLIENT_SESSION_EVENT_RESPONSE_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.client.session.event.response' topics |
| queue.client-session-event-response.max-request-timeout | TB_CLIENT_SESSION_EVENT_RESPONSE_MAX_REQUEST_TIMEOUT | 100000 | Max time in milliseconds for client session events before they are expired |
| queue.client-session-event-response.cleanup-interval | TB_CLIENT_SESSION_EVENT_RESPONSE_CLEANUP_INTERVAL | 100 | Period in milliseconds to clean-up stale client session events |
| queue.disconnect-client-command.poll-interval | TB_DISCONNECT_CLIENT_COMMAND_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.client.disconnect' topics |
| queue.persisted-downlink-msg.consumers-count | TB_PERSISTED_DOWNLINK_MSG_CONSUMERS_COUNT | 2 | Number of parallel consumers for `tbmq.msg.downlink.persisted` topics |
| queue.persisted-downlink-msg.threads-count | TB_PERSISTED_DOWNLINK_MSG_THREADS_COUNT | 2 | Number of threads in the pool to process consumers tasks |
| queue.persisted-downlink-msg.poll-interval | TB_PERSISTED_DOWNLINK_MSG_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.msg.downlink.persisted' topics |
| queue.basic-downlink-msg.consumers-count | TB_BASIC_DOWNLINK_MSG_CONSUMERS_COUNT | 2 | Number of parallel consumers for `tbmq.msg.downlink.basic` topics |
| queue.basic-downlink-msg.threads-count | TB_BASIC_DOWNLINK_MSG_THREADS_COUNT | 2 | Number of threads in the pool to process consumers tasks |
| queue.basic-downlink-msg.poll-interval | TB_BASIC_DOWNLINK_MSG_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.msg.downlink.basic' topics |
| queue.application-removed-event.poll-interval | TB_APPLICATION_REMOVED_EVENT_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.sys.app.removed' topic |
| queue.application-removed-event.processing.cron | TB_APPLICATION_REMOVED_EVENT_PROCESSING_CRON | 0 0 3 * * * | Cron expression to when execute the consuming and processing of messages |
| queue.application-removed-event.processing.zone | TB_APPLICATION_REMOVED_EVENT_PROCESSING_ZONE | UTC | Timezone for the processing cron-job |
| queue.historical-data-total.poll-interval | TB_HISTORICAL_DATA_TOTAL_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.sys.historical.data' topic |
| queue.integration-uplink.poll-interval | TB_IE_UPLINK_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.ie.uplink' topic |
| queue.integration-uplink-notifications.poll-interval | TB_IE_UPLINK_NOTIFICATIONS_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.ie.uplink.notifications' topics |
| queue.internode-notifications.poll-interval | TB_NODE_NOTIFICATION_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.sys.internode.notifications' topics |
| queue.blocked-client.poll-interval | TB_BLOCKED_CLIENT_POLL_INTERVAL | 100 | Interval in milliseconds to poll messages from 'tbmq.client.blocked' topic |
| queue.blocked-client.acknowledge-wait-timeout-ms | TB_BLOCKED_CLIENT_ACK_WAIT_TIMEOUT_MS | 500 | Interval in milliseconds to wait for system messages to be delivered to 'tbmq.client.blocked' topic |
| queue.kafka.bootstrap.servers | TB_KAFKA_SERVERS | localhost:9092 | List of kafka bootstrap servers used to establish connection |
| queue.kafka.enable-topic-deletion | TB_KAFKA_ENABLE_TOPIC_DELETION | true | Controls whether TBMQ is allowed to delete Kafka topics that were created for Application MQTT Clients or Application Shared subscriptions. When set to 'true', TBMQ may automatically remove topics during cleanup (for example, when an Application client or shared subscription is deleted). When set to 'false', TBMQ will skip topic deletions and simply stop using them. This helps prevent accidental data loss in production environments |
| queue.kafka.default.consumer.partition-assignment-strategy | TB_KAFKA_DEFAULT_CONSUMER_PARTITION_ASSIGNMENT_STRATEGY | org.apache.kafka.clients.consumer.StickyAssignor | A list of class names or class types, ordered by preference, of supported partition assignment strategies that the client will use to distribute partition ownership amongst consumer instances when group management is used |
| queue.kafka.default.consumer.session-timeout-ms | TB_KAFKA_DEFAULT_CONSUMER_SESSION_TIMEOUT_MS | 10000 | The timeout in milliseconds used to detect client failures when using Kafka's group management facility |
| queue.kafka.default.consumer.max-poll-interval-ms | TB_KAFKA_DEFAULT_CONSUMER_MAX_POLL_INTERVAL_MS | 300000 | The maximum delay in milliseconds between invocations of poll() when using consumer group management |
| queue.kafka.default.consumer.max-poll-records | TB_KAFKA_DEFAULT_CONSUMER_MAX_POLL_RECORDS | 2000 | The maximum number of records returned in a single call to poll() |
| queue.kafka.default.consumer.max-partition-fetch-bytes | TB_KAFKA_DEFAULT_CONSUMER_MAX_PARTITION_FETCH_BYTES | 16777216 | The maximum amount of data in bytes per-partition the server will return |
| queue.kafka.default.consumer.fetch-max-bytes | TB_KAFKA_DEFAULT_CONSUMER_FETCH_MAX_BYTES | 134217728 | The maximum amount of data in bytes the server should return for a fetch request |
| queue.kafka.default.consumer.heartbeat-interval-ms | TB_KAFKA_DEFAULT_CONSUMER_HEARTBEAT_INTERVAL_MS | 3000 | The expected time between heartbeats to the consumer coordinator when using Kafka’s group management facilities. Heartbeats are used to ensure that the consumer’s session stays active and to facilitate rebalancing when new consumers join or leave the group. The value must be set lower than TB_KAFKA_DEFAULT_CONSUMER_SESSION_TIMEOUT_MS, but typically should be set no higher than 1/3 of that value. It can be adjusted even lower to control the expected time for normal rebalances. Value in milliseconds. Default is 3 sec |
| queue.kafka.default.producer.acks | TB_KAFKA_DEFAULT_PRODUCER_ACKS | 1 | The number of acknowledgments the producer requires the leader to have received before considering a request complete |
| queue.kafka.default.producer.retries | TB_KAFKA_DEFAULT_PRODUCER_RETRIES | 1 | Setting a value greater than zero will cause the client to resend any record whose send fails with a potentially transient error |
| queue.kafka.default.producer.batch-size | TB_KAFKA_DEFAULT_PRODUCER_BATCH_SIZE | 16384 | The producer will attempt to batch records together into fewer requests whenever multiple records are being sent to the same partition. Size in bytes |
| queue.kafka.default.producer.linger-ms | TB_KAFKA_DEFAULT_PRODUCER_LINGER_MS | 5 | The producer groups together any records that arrive in between request transmissions into a single batched request, set in milliseconds |
| queue.kafka.default.producer.buffer-memory | TB_KAFKA_DEFAULT_PRODUCER_BUFFER_MEMORY | 33554432 | The total bytes of memory the producer can use to buffer records waiting to be sent to the server |
| queue.kafka.default.producer.compression-type | TB_KAFKA_DEFAULT_COMPRESSION_TYPE | none | The compression type for all data generated by the producer. Valid values are `none`, `gzip`, `snappy`, `lz4`, or `zstd` |
| queue.kafka.admin.config | TB_KAFKA_ADMIN_CONFIG | retries:1 | List of configs separated by semicolon used for admin kafka client creation |
| queue.kafka.admin.command-timeout | TB_KAFKA_ADMIN_COMMAND_TIMEOUT_SEC | 30 | Kafka Admin client command timeout (in seconds). Applies to operations like describeCluster, listTopics, etc |
| queue.kafka.consumer-stats.enabled | TB_KAFKA_CONSUMER_STATS_ENABLED | true | Prints lag if enabled between consumer group offset and last messages offset in Kafka topics |
| queue.kafka.consumer-stats.print-interval-ms | TB_KAFKA_CONSUMER_STATS_PRINT_INTERVAL_MS | 60000 | Statistics printing interval in milliseconds for Kafka's consumer-groups stats |
| queue.kafka.consumer-stats.kafka-response-timeout-ms | TB_KAFKA_CONSUMER_STATS_RESPONSE_TIMEOUT_MS | 1000 | Time to wait in milliseconds for the stats-loading requests to Kafka to finish |
| queue.kafka.consumer-stats.consumer-config | TB_KAFKA_CONSUMER_STATS_CONSUMER_CONFIG | List of configs separated by semicolon used for kafka stats consumer | |
| queue.kafka.home-page.consumer-config | TB_KAFKA_HOME_PAGE_CONSUMER_CONFIG | List of configs separated by semicolon used for kafka admin client for home page | |
| queue.kafka.home-page.kafka-response-timeout-ms | TB_KAFKA_HOME_PAGE_RESPONSE_TIMEOUT_MS | 1000 | Time to wait in milliseconds for the home page requests to Kafka to finish |
| queue.kafka.msg-all.topic | TB_KAFKA_MSG_ALL_TOPIC | tbmq.msg.all | Topic for persisting incoming PUBLISH messages |
| queue.kafka.msg-all.topic-properties | TB_KAFKA_MSG_ALL_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:2147483648;partitions:16;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.all` topic |
| queue.kafka.msg-all.additional-consumer-config | TB_KAFKA_MSG_ALL_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.all` topic | |
| queue.kafka.msg-all.additional-producer-config | TB_KAFKA_MSG_ALL_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.msg.all` topic | |
| queue.kafka.application-persisted-msg.topic-properties | TB_KAFKA_APP_PERSISTED_MSG_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.app` topics |
| queue.kafka.application-persisted-msg.additional-consumer-config | TB_KAFKA_APP_PERSISTED_MSG_ADDITIONAL_CONSUMER_CONFIG | max.poll.records:200 | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.app` topics |
| queue.kafka.application-persisted-msg.additional-producer-config | TB_KAFKA_APP_PERSISTED_MSG_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.msg.app` topics | |
| queue.kafka.application-persisted-msg.shared-topic.topic-properties | TB_KAFKA_APP_PERSISTED_MSG_SHARED_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;replication.factor:1 | Kafka topic properties separated by semicolon for application shared subscription topics |
| queue.kafka.application-persisted-msg.shared-topic.additional-consumer-config | TB_KAFKA_APP_PERSISTED_MSG_SHARED_ADDITIONAL_CONSUMER_CONFIG | max.poll.records:500 | Additional Kafka consumer configs separated by semicolon for application shared subscription topics |
| queue.kafka.application-persisted-msg.shared-topic.additional-producer-config | TB_KAFKA_APP_PERSISTED_MSG_SHARED_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for application shared subscription topics | |
| queue.kafka.device-persisted-msg.topic | TB_KAFKA_DEVICE_PERSISTED_MSG_TOPIC | tbmq.msg.persisted | Topic for persisting messages related to Device clients before saving them in Database |
| queue.kafka.device-persisted-msg.topic-properties | TB_KAFKA_DEVICE_PERSISTED_MSG_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:12;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.persisted` topic |
| queue.kafka.device-persisted-msg.additional-consumer-config | TB_KAFKA_DEVICE_PERSISTED_MSG_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.persisted` topic | |
| queue.kafka.device-persisted-msg.additional-producer-config | TB_KAFKA_DEVICE_PERSISTED_MSG_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.msg.persisted` topic | |
| queue.kafka.retained-msg.topic | TB_KAFKA_RETAINED_MSG_TOPIC | tbmq.msg.retained | Topic for retained messages |
| queue.kafka.retained-msg.topic-properties | TB_KAFKA_RETAINED_MSG_TOPIC_PROPERTIES | segment.bytes:26214400;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.retained` topic |
| queue.kafka.retained-msg.additional-consumer-config | TB_KAFKA_RETAINED_MSG_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.retained` topic | |
| queue.kafka.retained-msg.additional-producer-config | TB_KAFKA_RETAINED_MSG_ADDITIONAL_PRODUCER_CONFIG | retries:3 | Additional Kafka producer configs separated by semicolon for `tbmq.msg.retained` topic |
| queue.kafka.client-session.topic | TB_KAFKA_CLIENT_SESSION_TOPIC | tbmq.client.session | Topic for persisting client sessions |
| queue.kafka.client-session.topic-properties | TB_KAFKA_CLIENT_SESSION_TOPIC_PROPERTIES | segment.bytes:26214400;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.client.session` topic |
| queue.kafka.client-session.additional-consumer-config | TB_KAFKA_CLIENT_SESSION_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.client.session` topic | |
| queue.kafka.client-session.additional-producer-config | TB_KAFKA_CLIENT_SESSION_ADDITIONAL_PRODUCER_CONFIG | retries:3 | Additional Kafka producer configs separated by semicolon for `tbmq.client.session` topic |
| queue.kafka.client-subscriptions.topic | TB_KAFKA_CLIENT_SUBSCRIPTIONS_TOPIC | tbmq.client.subscriptions | Topic for persisting client subscriptions |
| queue.kafka.client-subscriptions.topic-properties | TB_KAFKA_CLIENT_SUBSCRIPTIONS_TOPIC_PROPERTIES | segment.bytes:26214400;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.client.subscriptions` topic |
| queue.kafka.client-subscriptions.additional-consumer-config | TB_KAFKA_CLIENT_SUBSCRIPTIONS_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.client.subscriptions` topic | |
| queue.kafka.client-subscriptions.additional-producer-config | TB_KAFKA_CLIENT_SUBSCRIPTIONS_ADDITIONAL_PRODUCER_CONFIG | retries:3 | Additional Kafka producer configs separated by semicolon for `tbmq.client.subscriptions` topic |
| queue.kafka.client-session-event.topic | TB_KAFKA_CLIENT_SESSION_EVENT_TOPIC | tbmq.client.session.event.request | Topic for sending client session event requests |
| queue.kafka.client-session-event.topic-properties | TB_KAFKA_CLIENT_SESSION_EVENT_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:24;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.client.session.event.request` topic |
| queue.kafka.client-session-event.additional-consumer-config | TB_KAFKA_CLIENT_SESSION_EVENT_ADDITIONAL_CONSUMER_CONFIG | max.poll.records:1000 | Additional Kafka consumer configs separated by semicolon for ``tbmq.client.session.event.request`` topic |
| queue.kafka.client-session-event.additional-producer-config | TB_KAFKA_CLIENT_SESSION_EVENT_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for ``tbmq.client.session.event.request`` topic | |
| queue.kafka.client-session-event-response.topic-prefix | TB_KAFKA_CLIENT_SESSION_EVENT_RESPONSE_TOPIC_PREFIX | tbmq.client.session.event.response | Prefix for topics for sending client session event responses to Broker nodes |
| queue.kafka.client-session-event-response.topic-properties | TB_KAFKA_CLIENT_SESSION_EVENT_RESPONSE_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.client.session.event.response` topics |
| queue.kafka.client-session-event-response.additional-consumer-config | TB_KAFKA_CLIENT_SESSION_EVENT_RESPONSE_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.client.session.event.response` topics | |
| queue.kafka.client-session-event-response.additional-producer-config | TB_KAFKA_CLIENT_SESSION_EVENT_RESPONSE_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.client.session.event.response` topics | |
| queue.kafka.disconnect-client-command.topic-prefix | TB_KAFKA_DISCONNECT_CLIENT_COMMAND_TOPIC_PREFIX | tbmq.client.disconnect | Prefix for topics for sending disconnect client commands to Broker nodes |
| queue.kafka.disconnect-client-command.topic-properties | TB_KAFKA_DISCONNECT_CLIENT_COMMAND_RESPONSE_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.client.disconnect` topics |
| queue.kafka.disconnect-client-command.additional-consumer-config | TB_KAFKA_DISCONNECT_CLIENT_COMMAND_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.client.disconnect` topics | |
| queue.kafka.disconnect-client-command.additional-producer-config | TB_KAFKA_DISCONNECT_CLIENT_COMMAND_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.client.disconnect` topics | |
| queue.kafka.basic-downlink-msg.topic-prefix | TB_KAFKA_BASIC_DOWNLINK_MSG_TOPIC_PREFIX | tbmq.msg.downlink.basic | Prefix for topics for non-persistent Device messages that should be transferred to other Broker nodes |
| queue.kafka.basic-downlink-msg.topic-properties | TB_KAFKA_BASIC_DOWNLINK_MSG_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:12;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.downlink.basic` topics |
| queue.kafka.basic-downlink-msg.additional-consumer-config | TB_KAFKA_BASIC_DOWNLINK_MSG_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.downlink.basic` topics | |
| queue.kafka.basic-downlink-msg.additional-producer-config | TB_KAFKA_BASIC_DOWNLINK_MSG_ADDITIONAL_PRODUCER_CONFIG | batch.size:32768 | Additional Kafka producer configs separated by semicolon for `tbmq.msg.downlink.basic` topics |
| queue.kafka.persisted-downlink-msg.topic-prefix | TB_KAFKA_PERSISTED_DOWNLINK_MSG_TOPIC_PREFIX | tbmq.msg.downlink.persisted | Prefix for topics for persistent Device messages that should be transferred to other Broker nodes |
| queue.kafka.persisted-downlink-msg.topic-properties | TB_KAFKA_PERSISTED_DOWNLINK_MSG_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:12;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.downlink.persisted` topics |
| queue.kafka.persisted-downlink-msg.additional-consumer-config | TB_KAFKA_PERSISTED_DOWNLINK_MSG_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.downlink.persisted` topics | |
| queue.kafka.persisted-downlink-msg.additional-producer-config | TB_KAFKA_PERSISTED_DOWNLINK_MSG_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.msg.downlink.persisted` topics | |
| queue.kafka.application-removed-event.topic | TB_KAFKA_APPLICATION_REMOVED_EVENT_TOPIC | tbmq.sys.app.removed | Topic for sending events to remove application topics when application clients are changed to be device clients |
| queue.kafka.application-removed-event.topic-properties | TB_KAFKA_APPLICATION_REMOVED_EVENT_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.sys.app.removed` topic |
| queue.kafka.application-removed-event.additional-consumer-config | TB_KAFKA_APPLICATION_REMOVED_EVENT_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.sys.app.removed` topic | |
| queue.kafka.application-removed-event.additional-producer-config | TB_KAFKA_APPLICATION_REMOVED_EVENT_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.sys.app.removed` topic | |
| queue.kafka.historical-data-total.topic | TB_KAFKA_HISTORICAL_DATA_TOTAL_TOPIC | tbmq.sys.historical.data | Topic for sending historical data stats to be summed from each broker |
| queue.kafka.historical-data-total.topic-properties | TB_KAFKA_HISTORICAL_DATA_TOTAL_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.sys.historical.data` topic |
| queue.kafka.historical-data-total.additional-consumer-config | TB_KAFKA_HISTORICAL_DATA_TOTAL_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.sys.historical.data` topic | |
| queue.kafka.historical-data-total.additional-producer-config | TB_KAFKA_HISTORICAL_DATA_TOTAL_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.sys.historical.data` topic | |
| queue.kafka.integration-downlink.topic-prefix | TB_KAFKA_IE_DOWNLINK_TOPIC_PREFIX | tbmq.ie.downlink | Prefix for topics for sending integration configurations and validation requests from tbmq to integration executors |
| queue.kafka.integration-downlink.http.topic-properties | TB_KAFKA_IE_DOWNLINK_HTTP_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:6;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.ie.downlink.http` topic |
| queue.kafka.integration-downlink.http.additional-consumer-config | TB_KAFKA_IE_DOWNLINK_HTTP_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.ie.downlink.http` topic | |
| queue.kafka.integration-downlink.http.additional-producer-config | TB_KAFKA_IE_DOWNLINK_HTTP_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.ie.downlink.http` topic | |
| queue.kafka.integration-downlink.kafka.topic-properties | TB_KAFKA_IE_DOWNLINK_KAFKA_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:6;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.ie.downlink.kafka` topic |
| queue.kafka.integration-downlink.kafka.additional-consumer-config | TB_KAFKA_IE_DOWNLINK_KAFKA_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.ie.downlink.kafka` topic | |
| queue.kafka.integration-downlink.kafka.additional-producer-config | TB_KAFKA_IE_DOWNLINK_KAFKA_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.ie.downlink.kafka` topic | |
| queue.kafka.integration-downlink.mqtt.topic-properties | TB_KAFKA_IE_DOWNLINK_MQTT_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:6;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.ie.downlink.mqtt` topic |
| queue.kafka.integration-downlink.mqtt.additional-consumer-config | TB_KAFKA_IE_DOWNLINK_MQTT_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.ie.downlink.mqtt` topic | |
| queue.kafka.integration-downlink.mqtt.additional-producer-config | TB_KAFKA_IE_DOWNLINK_MQTT_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.ie.downlink.mqtt` topic | |
| queue.kafka.integration-uplink.topic | TB_KAFKA_IE_UPLINK_TOPIC | tbmq.ie.uplink | Topic for sending messages/events from integration executors to tbmq |
| queue.kafka.integration-uplink.topic-properties | TB_KAFKA_IE_UPLINK_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:6;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.ie.uplink` topic |
| queue.kafka.integration-uplink.additional-consumer-config | TB_KAFKA_IE_UPLINK_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.ie.uplink` topic | |
| queue.kafka.integration-uplink.additional-producer-config | TB_KAFKA_IE_UPLINK_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.ie.uplink` topic | |
| queue.kafka.integration-uplink-notifications.topic-prefix | TB_KAFKA_IE_UPLINK_NOTIF_TOPIC_PREFIX | tbmq.ie.uplink.notifications | Prefix for topics for sending notifications or replies from integration executors to specific tbmq node |
| queue.kafka.integration-uplink-notifications.topic-properties | TB_KAFKA_IE_UPLINK_NOTIF_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.ie.uplink.notifications` topics |
| queue.kafka.integration-uplink-notifications.additional-consumer-config | TB_KAFKA_IE_UPLINK_NOTIF_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.ie.uplink.notifications` topic | |
| queue.kafka.integration-uplink-notifications.additional-producer-config | TB_KAFKA_IE_UPLINK_NOTIF_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.ie.uplink.notifications` topic | |
| queue.kafka.integration-msg.topic-properties | TB_KAFKA_IE_MSG_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.msg.ie` topics |
| queue.kafka.integration-msg.additional-consumer-config | TB_KAFKA_IE_MSG_ADDITIONAL_CONSUMER_CONFIG | max.poll.records:50 | Additional Kafka consumer configs separated by semicolon for `tbmq.msg.ie` topics |
| queue.kafka.integration-msg.additional-producer-config | TB_KAFKA_IE_MSG_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.msg.ie` topics | |
| queue.kafka.internode-notifications.topic-prefix | TB_KAFKA_INTERNODE_NOTIFICATIONS_TOPIC_PREFIX | tbmq.sys.internode.notifications | Prefix for topics for sending system notifications to Broker nodes |
| queue.kafka.internode-notifications.topic-properties | TB_KAFKA_INTERNODE_NOTIFICATIONS_TOPIC_PROPERTIES | retention.ms:604800000;segment.bytes:26214400;retention.bytes:1048576000;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.sys.internode.notifications` topics |
| queue.kafka.internode-notifications.additional-consumer-config | TB_KAFKA_INTERNODE_NOTIFICATIONS_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.sys.internode.notifications` topics | |
| queue.kafka.internode-notifications.additional-producer-config | TB_KAFKA_INTERNODE_NOTIFICATIONS_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.sys.internode.notifications` topics | |
| queue.kafka.blocked-client.topic | TB_KAFKA_BLOCKED_CLIENT_TOPIC | tbmq.client.blocked | Topic for blocked clients |
| queue.kafka.blocked-client.topic-properties | TB_KAFKA_BLOCKED_CLIENT_TOPIC_PROPERTIES | segment.bytes:26214400;partitions:1;replication.factor:1 | Kafka topic properties separated by semicolon for `tbmq.client.blocked` topic |
| queue.kafka.blocked-client.additional-consumer-config | TB_KAFKA_BLOCKED_CLIENT_ADDITIONAL_CONSUMER_CONFIG | Additional Kafka consumer configs separated by semicolon for `tbmq.client.blocked` topic | |
| queue.kafka.blocked-client.additional-producer-config | TB_KAFKA_BLOCKED_CLIENT_ADDITIONAL_PRODUCER_CONFIG | Additional Kafka producer configs separated by semicolon for `tbmq.client.blocked` topic | |
| queue.kafka.kafka-prefix | TB_KAFKA_PREFIX | The common prefix for all Kafka topics, producers, consumer groups, and consumers. Defaults to empty string meaning no prefix is added |
General service parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| service.type | TB_SERVICE_TYPE | tbmq | Microservice type. Allowed value: tbmq |
| service.id | TB_SERVICE_ID | Unique id for this service (autogenerated if empty) |
Actor system parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| actors.system.throughput | ACTORS_SYSTEM_THROUGHPUT | 5 | Number of messages the actor system will process per actor before switching to processing of messages for next actor |
| actors.system.scheduler-pool-size | ACTORS_SYSTEM_SCHEDULER_POOL_SIZE | 1 | Thread pool size for actor system scheduler |
| actors.system.max-actor-init-attempts | ACTORS_SYSTEM_MAX_ACTOR_INIT_ATTEMPTS | 10 | Maximum number of attempts to init the actor before disabling the actor |
| actors.system.processing-metrics.enabled | ACTORS_SYSTEM_PROCESSING_METRICS_ENABLED | false | Enable/disable actors processing metrics |
| actors.system.disconnect-wait-timeout-ms | ACTORS_SYSTEM_DISCONNECT_WAIT_TIMEOUT_MS | 2000 | Actors disconnect timeout in milliseconds |
| actors.persisted-device.dispatcher-pool-size | ACTORS_SYSTEM_PERSISTED_DEVICE_DISPATCHER_POOL_SIZE | 8 | Number of threads processing the Device actor's messages |
| actors.persisted-device.wait-before-actor-stop-minutes | ACTORS_SYSTEM_PERSISTED_DEVICE_WAIT_BEFORE_ACTOR_STOP_MINUTES | 5 | Minutes to wait before deleting Device actor after disconnect |
| actors.client.dispatcher-pool-size | ACTORS_SYSTEM_CLIENT_DISPATCHER_POOL_SIZE | 8 | Number of threads processing the MQTT client actors messages |
| actors.client.wait-before-generated-actor-stop-seconds | ACTORS_SYSTEM_CLIENT_WAIT_BEFORE_GENERATED_ACTOR_STOP_SECONDS | 10 | Time in seconds to wait until the actor is stopped for clients that did not specify client id |
| actors.client.wait-before-named-actor-stop-seconds | ACTORS_SYSTEM_CLIENT_WAIT_BEFORE_NAMED_ACTOR_STOP_SECONDS | 60 | Time in seconds to wait until the actor is stopped for clients that specified client id |
| actors.rule.mail_thread_pool_size | ACTORS_RULE_MAIL_THREAD_POOL_SIZE | 4 | Thread pool size for mail sender executor service |
| actors.rule.mail_password_reset_thread_pool_size | ACTORS_RULE_MAIL_PASSWORD_RESET_THREAD_POOL_SIZE | 4 | Thread pool size for password reset emails executor service |
Platform integrations parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| integrations.init.connection-check-api-request-timeout-sec | INTEGRATIONS_INIT_CONNECTION_CHECK_API_REQUEST_TIMEOUT_SEC | 20 | Connection check timeout for API request in seconds |
| integrations.cleanup.period | INTEGRATIONS_CLEANUP_PERIOD_SEC | 10800 | The parameter to specify the period of execution cleanup task for disconnected integrations. Value set in seconds. Default value corresponds to three hours |
| integrations.cleanup.ttl | INTEGRATIONS_CLEANUP_TTL_SEC | 604800 | Administration TTL (in seconds) for cleaning up disconnected integrations. The cleanup removes integration topics that persist messages. The current value is set to one week. A value of 0 or negative disables this TTL |
Database time series parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| database.ts_max_intervals | DATABASE_TS_MAX_INTERVALS | 700 | Max number of DB queries generated by single API call to fetch time series records |
SQL configuration parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| sql.batch_sort | SQL_BATCH_SORT | true | Specify whether to sort entities before batch update. Should be enabled for cluster mode to avoid deadlocks |
| sql.ts_key_value_partitioning | SQL_TS_KV_PARTITIONING | DAYS | Specify partitioning size for timestamp key-value storage. Example: DAYS, MONTHS, YEARS, INDEFINITE |
| sql.remove_null_chars | SQL_REMOVE_NULL_CHARS | true | Specify whether to remove null characters from strValue before insert |
| sql.ts.batch_size | SQL_TS_BATCH_SIZE | 1000 | Batch size for persisting time series inserts |
| sql.ts.batch_max_delay | SQL_TS_BATCH_MAX_DELAY_MS | 100 | Max timeout for time series entries queue polling. Value set in milliseconds |
| sql.ts.batch_threads | SQL_TS_BATCH_THREADS | 3 | Number of threads that execute batch insert/update statements for time series data. Batch thread count have to be a prime number like 3 or 5 to gain perfect hash distribution |
| sql.ts_latest.batch_size | SQL_TS_LATEST_BATCH_SIZE | 1000 | Batch size for persisting latest time series inserts |
| sql.ts_latest.batch_max_delay | SQL_TS_LATEST_BATCH_MAX_DELAY_MS | 50 | Max timeout for latest time series entries queue polling. Value set in milliseconds |
| sql.ts_latest.batch_threads | SQL_TS_LATEST_BATCH_THREADS | 3 | Number of threads that execute batch insert/update statements for latest time series data. Batch thread count have to be a prime number like 3 or 5 to gain perfect hash distribution |
| sql.unauthorized-client.insert.batch_size | SQL_UNAUTHORIZED_CLIENT_INSERT_BATCH_SIZE | 1000 | Batch size for persisting unauthorized client inserts |
| sql.unauthorized-client.insert.batch_max_delay | SQL_UNAUTHORIZED_CLIENT_INSERT_BATCH_MAX_DELAY_MS | 50 | Max timeout for unauthorized client insert entries queue polling. Value set in milliseconds |
| sql.unauthorized-client.insert.batch_threads | SQL_UNAUTHORIZED_CLIENT_INSERT_BATCH_THREADS | 3 | Number of threads that execute batch insert/update statements for unauthorized client data. Batch thread count have to be a prime number like 3 or 5 to gain perfect hash distribution |
| sql.unauthorized-client.delete.batch_size | SQL_UNAUTHORIZED_CLIENT_DELETE_BATCH_SIZE | 1000 | Batch size for processing unauthorized client deletes |
| sql.unauthorized-client.delete.batch_max_delay | SQL_UNAUTHORIZED_CLIENT_DELETE_BATCH_MAX_DELAY_MS | 50 | Max timeout for unauthorized client delete entries queue polling. Value set in milliseconds |
| sql.unauthorized-client.delete.batch_threads | SQL_UNAUTHORIZED_CLIENT_DELETE_BATCH_THREADS | 3 | Number of threads that execute batch delete statements for unauthorized client data. Batch thread count have to be a prime number like 3 or 5 to gain perfect hash distribution |
| sql.events.batch_size | SQL_EVENTS_BATCH_SIZE | 10000 | Batch size for persisting events updates |
| sql.events.batch_max_delay | SQL_EVENTS_BATCH_MAX_DELAY_MS | 100 | Max timeout for events entries queue polling. The value set in milliseconds |
| sql.events.batch_threads | SQL_EVENTS_BATCH_THREADS | 3 | Batch size for processing events insert/update. Batch thread count has to be a prime number like 3 or 5 to gain perfect hash distribution |
| sql.events.partition_size | SQL_EVENTS_REGULAR_PARTITION_SIZE_HOURS | 168 | Number of hours to partition the events. The current value corresponds to one week |
| sql.events.max-symbols | SQL_EVENTS_MAX_SYMBOLS | 4096 | Maximum number of symbols per event. The event content will be truncated if needed |
| sql.ttl.ts.enabled | SQL_TTL_TS_ENABLED | true | The parameter to specify whether to use TTL (Time To Live) for time series records |
| sql.ttl.ts.execution_interval_ms | SQL_TTL_TS_EXECUTION_INTERVAL_MS | 86400000 | The parameter to specify the period of execution TTL task for time series records. Value set in milliseconds. Default value corresponds to one day |
| sql.ttl.ts.ts_key_value_ttl | SQL_TTL_TS_KEY_VALUE_TTL | 604800 | The parameter to specify system TTL(Time To Live) value for time series records. Value set in seconds. 0 - records are never expired. Default value corresponds to seven days |
| sql.ttl.unauthorized_client.enabled | SQL_TTL_UNAUTHORIZED_CLIENT_ENABLED | true | The parameter to specify whether to use TTL (Time To Live) for unauthorized clients |
| sql.ttl.unauthorized_client.execution_interval_ms | SQL_TTL_UNAUTHORIZED_CLIENT_EXECUTION_INTERVAL_MS | 86400000 | The parameter to specify the period of execution TTL task for unauthorized clients. Value set in milliseconds. Default value corresponds to one day |
| sql.ttl.unauthorized_client.ttl | SQL_TTL_UNAUTHORIZED_CLIENT_TTL | 259200 | The parameter to specify system TTL(Time To Live) value for unauthorized clients. Value set in seconds. 0 - records are never expired. Default value corresponds to three days |
| sql.ttl.events.enabled | SQL_TTL_EVENTS_ENABLED | true | Enable/disable TTL (Time To Live) for event records |
| sql.ttl.events.execution_interval_ms | SQL_TTL_EVENTS_EXECUTION_INTERVAL_MS | 3600000 | Number of milliseconds (max random initial delay and fixed period). Defaults to 1 hour |
| sql.ttl.events.events_ttl | SQL_TTL_EVENTS_TTL_SEC | 1209600 | Number of seconds for TTL. TTL is set to 14 days by default. The accuracy of the cleanup depends on the sql.events.partition_size parameter |
Redis lettuce configuration parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| lettuce.auto-flush | REDIS_LETTUCE_CMDS_AUTO_FLUSH_ENABLED | true | Enable/disable auto-flush. If disabled, commands are buffered and flushed based on cmd count or time interval |
| lettuce.buffered-cmd-count | REDIS_LETTUCE_BUFFERED_CMDS_COUNT | 5 | Number of buffered commands before flush is triggered. Used when auto-flush is disabled |
| lettuce.flush-interval-ms | REDIS_LETTUCE_FLUSH_INTERVAL_MS | 5 | Maximum time in milliseconds to buffer commands before flushing, regardless of cmd count |
| lettuce.config.command-timeout | REDIS_LETTUCE_COMMAND_TIMEOUT_SEC | 30 | Maximum time (in seconds) to wait for a lettuce command to complete. This affects health checks and any command execution (e.g. GET, SET, PING). Reduce this to fail fast if Redis is unresponsive |
| lettuce.config.shutdown-quiet-period | REDIS_LETTUCE_SHUTDOWN_QUIET_PERIOD_SEC | 1 | The shutdown quiet period for lettuce client set in seconds |
| lettuce.config.shutdown-timeout | REDIS_LETTUCE_SHUTDOWN_TIMEOUT_SEC | 10 | The shutdown timeout for lettuce client set in seconds |
| lettuce.config.cluster.topology-refresh.enabled | REDIS_LETTUCE_CLUSTER_TOPOLOGY_REFRESH_ENABLED | false | Enables or disables periodic cluster topology updates. Useful for Redis Cluster setup to handle topology changes, such as node failover, restarts, or IP address changes |
| lettuce.config.cluster.topology-refresh.period | REDIS_LETTUCE_CLUSTER_TOPOLOGY_REFRESH_PERIOD_SEC | 60 | Specifies the interval (in seconds) for periodic cluster topology updates |
Redis jedis configuration parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| jedis.cluster.topology-refresh.enabled | REDIS_JEDIS_CLUSTER_TOPOLOGY_REFRESH_ENABLED | false | Enables or disables periodic cluster topology updates. Useful for Redis cluster setup to handle topology changes, such as node failover, restarts, or IP address changes |
| jedis.cluster.topology-refresh.period | REDIS_JEDIS_CLUSTER_TOPOLOGY_REFRESH_PERIOD_SEC | 60 | Specifies the interval (in seconds) for periodic cluster topology updates |
SQL DAO configuration parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| spring.data.jpa.repositories.enabled | SPRING_DATA_JPA_REPOSITORIES_ENABLED | true | Enable/Disable the Spring Data JPA repositories support |
| spring.jpa.open-in-view | SPRING_JPA_OPEN_IN_VIEW | false | Enable/disable OSIV |
| spring.jpa.hibernate.ddl-auto | SPRING_JPA_HIBERNATE_DDL_AUTO | none | You can set a Hibernate feature that controls the DDL behavior in a more fine-grained way. The standard Hibernate property values are none, validate, update, create-drop. Spring Boot chooses a default value for you based on whether it thinks your database is embedded (default create-drop) or not (default none) |
| spring.datasource.driverClassName | SPRING_DRIVER_CLASS_NAME | org.postgresql.Driver | Database driver for Spring JPA |
| spring.datasource.url | SPRING_DATASOURCE_URL | jdbc:postgresql://localhost:5432/thingsboard_mqtt_broker | Database connection URL |
| spring.datasource.username | SPRING_DATASOURCE_USERNAME | postgres | Database username |
| spring.datasource.password | SPRING_DATASOURCE_PASSWORD | postgres | Database user password |
| spring.datasource.hikari.maximumPoolSize | SPRING_DATASOURCE_MAXIMUM_POOL_SIZE | 16 | This property allows the number of connections in the pool to increase as demand increases. At the same time, the property ensures that the pool doesn't grow to the point of exhausting a system's resources, which ultimately affects an application's performance and availability |
| spring.datasource.hikari.maxLifetime | SPRING_DATASOURCE_MAX_LIFETIME | 600000 | This property controls the max lifetime in milliseconds of a connection. Only when it is closed will it then be removed. Default is 10 minutes |
| spring.datasource.hikari.connectionTimeout | SPRING_DATASOURCE_CONNECTION_TIMEOUT_MS | 30000 | Maximum time (in milliseconds) HikariCP will wait to acquire a connection from the pool. If exceeded, an exception is thrown. Default is 30 seconds |
General Spring parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| spring.lifecycle.timeout-per-shutdown-phase | SPRING_LIFECYCLE_TIMEOUT_PER_SHUTDOWN_PHASE | 1m | The server will wait for active requests to finish their work up to a specified amount of time before graceful shutdown |
| spring.jpa.properties.hibernate.jdbc.lob.non_contextual_creation | SPRING_JPA_HIBERNATE_JDBC_LOB_NON_CONTEXTUAL_CREATION | true | Setting this property to true disables contextual LOB creation and forces the use of Hibernate's own LOB implementation. Fixes Postgres JPA Error |
| spring.jpa.properties.hibernate.order_by.default_null_ordering | SPRING_JPA_HIBERNATE_ORDER_BY_DEFAULT_NULL_ORDERING | last | Default ordering for null values |
| spring.data.redis.repositories.enabled | SPRING_DATA_REDIS_REPOSITORIES_ENABLED | false | Disables redis repositories scanning |
| spring.freemarker.checkTemplateLocation | SPRING_FREEMARKER_CHECK_TEMPLATE_LOCATION | false | Spring freemarker configuration to check that the templates location exists |
| spring.mvc.async.request-timeout | SPRING_MVC_ASYNC_REQUEST_TIMEOUT | 30000 | The default timeout for asynchronous requests in milliseconds |
| spring.mvc.pathmatch.matching-strategy | SPRING_MVC_PATH_MATCH_MATCHING_STRATEGY | ANT_PATH_MATCHER | For endpoints matching in Swagger |
| spring.servlet.multipart.max-file-size | SPRING_SERVLET_MULTIPART_MAX_FILE_SIZE | 50MB | Total file size cannot exceed 50MB when configuring file uploads |
| spring.servlet.multipart.max-request-size | SPRING_SERVLET_MULTIPART_MAX_REQUEST_SIZE | 50MB | Total request size for a multipart/form-data cannot exceed 50MB |
Security parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| security.mqtt.auth_strategy | SECURITY_MQTT_AUTH_STRATEGY | BOTH | DEPRECATED: BOTH or SINGLE - the former means the first attempt of client authentication will be by 'basic' provider and then by 'ssl' provider if 'basic' is not successful; the latter means only one attempt is done according to the listener communication chosen (see listener.tcp/listener.ssl) |
| security.mqtt.basic.enabled | SECURITY_MQTT_BASIC_ENABLED | false | DEPRECATED: If enabled the server will try to authenticate client with clientId and/or username and/or password |
| security.mqtt.ssl.enabled | SECURITY_MQTT_SSL_ENABLED | false | DEPRECATED: If enabled the server will try to authenticate client with client certificate chain |
| security.mqtt.ssl.skip_validity_check_for_client_cert | SECURITY_MQTT_SSL_SKIP_VALIDITY_CHECK_FOR_CLIENT_CERT | false | DEPRECATED: Skip certificate validity check for client certificates |
| security.jwt.tokenExpirationTime | JWT_TOKEN_EXPIRATION_TIME | 9000 | User JWT Token expiration time in seconds (2.5 hours) |
| security.jwt.refreshTokenExpTime | JWT_REFRESH_TOKEN_EXPIRATION_TIME | 604800 | User JWT Refresh Token expiration time in seconds (1 week) |
| security.jwt.tokenIssuer | JWT_TOKEN_ISSUER | thingsboard.io | User JWT Token issuer |
| security.jwt.tokenSigningKey | JWT_TOKEN_SIGNING_KEY | Qk1xUnloZ0VQTlF1VlNJQXZ4cWhiNWt1cVd1ZzQ5cWpENUhMSHlaYmZIM0JrZ2pPTVlhQ3N1Z0ZMUnd0SDBieg== | User JWT Token sign key |
| security.basic.enabled | SECURITY_BASIC_ENABLED | false | Enable/Disable basic security options |
| security.user_token_access_enabled | SECURITY_USER_TOKEN_ACCESS_ENABLED | true | Enable/disable access to other Administrators JWT token by System Administrator |
| security.user_login_case_sensitive | SECURITY_USER_LOGIN_CASE_SENSITIVE | true | Enable/disable case-sensitive username login |
| security.oauth2.loginProcessingUrl | SECURITY_OAUTH2_LOGIN_PROCESSING_URL | /login/oauth2/code/ | Redirect URL where access code from external user management system will be processed |
| security.oauth2.githubMapper.emailUrl | SECURITY_OAUTH2_GITHUB_MAPPER_EMAIL_URL_KEY | https://api.github.com/user/emails | The email addresses that will be mapped from the URL |
MQTT parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| mqtt.connect.threads | MQTT_CONNECT_THREADS | 4 | Number of threads for clients connection thread pool |
| mqtt.msg-subscriptions-parallel-processing | MQTT_MSG_SUBSCRIPTIONS_PARALLEL_PROCESSING | false | Enable/disable processing of found subscriptions in parallel for published messages. Helpful when the"PUBLISH" message should be delivered to lots of subscribers. It is recommended to count the impact of this parameter before setting it on production |
| mqtt.pre-connect-queue.max-size | MQTT_PRE_CONNECT_QUEUE_MAX_SIZE | 10000 | Max number of messages that can be stored in queue before client gets connected and start processing them |
| mqtt.max-in-flight-msgs | MQTT_MAX_IN_FLIGHT_MSGS | 1000 | Max number of PUBLISH messages not yet responded |
| mqtt.flow-control.enabled | MQTT_FLOW_CONTROL_ENABLED | true | Enable/disable flow control MQTT 5 feature for server. If disabled, the server will not control the number of messages sent to subscribers by"Receive Maximum". This feature works for MQTT 3.x clients as well when enabled. "Receive Maximum" for MQTT 3.x clients can be set using `MQTT_FLOW_CONTROL_MQTT_3X_RECEIVE_MAX` parameter |
| mqtt.flow-control.timeout | MQTT_FLOW_CONTROL_TIMEOUT | 1000 | Timeout to wait in case there is nothing to process regarding the flow control feature. The separate thread is responsible for sending delayed messages to subscribers. If no clients are affected by flow control restrictions, there is no need to continuously try to find and send such messages |
| mqtt.flow-control.ttl | MQTT_FLOW_CONTROL_TTL | 600 | Time in seconds to store delayed messages for subscribers. Delayed messages are those that can not be sent immediately due to flow control restrictions. Default is 10 minutes |
| mqtt.flow-control.delayed-queue-max-size | MQTT_FLOW_CONTROL_DELAYED_QUEUE_MAX_SIZE | 1000 | Max allowed queue length for delayed messages - publishing messages from broker to client when in-flight window is full |
| mqtt.flow-control.mqtt3x-receive-max | MQTT_FLOW_CONTROL_MQTT_3X_RECEIVE_MAX | 65535 | Receive maximum value for MQTT 3.x clients |
| mqtt.retransmission.enabled | MQTT_RETRANSMISSION_ENABLED | false | Enable/disable MQTT msg retransmission |
| mqtt.retransmission.scheduler-pool-size | MQTT_RETRANSMISSION_SCHEDULER_POOL_SIZE | 0 | Retransmission scheduler pool size (0 means the number of processors available to the JVM multiplied by 2 will be used) |
| mqtt.retransmission.initial-delay | MQTT_RETRANSMISSION_INITIAL_DELAY | 10 | Initial delay for the msg retransmission in seconds |
| mqtt.retransmission.period | MQTT_RETRANSMISSION_PERIOD | 5 | Increment period for the subsequent retransmissions of the msg in seconds (retransmission interval is increased by period for each run) |
| mqtt.keep-alive.monitoring-delay-ms | MQTT_KEEP_ALIVE_MONITORING_DELAY_MS | 1000 | Time in milliseconds between subsequent checks for the non-active clients |
| mqtt.keep-alive.max-keep-alive | MQTT_KEEP_ALIVE_MAX_KEEP_ALIVE_SEC | 600 | Max value in seconds allowed by the server for keep-alive that can be used by clients. Defaults to 10 minutes, used for MQTT v5 clients |
| mqtt.topic.max-segments-count | MQTT_TOPIC_MAX_SEGMENTS_COUNT | 0 | Maximum number of segments in topics. If it's too large, processing of topics with too much segments can lead to errors. 0 means limitation is disabled |
| mqtt.topic.alias-max | MQTT_TOPIC_ALIAS_MAX | 10 | Max count of topic aliases per connection. 0 indicates that the Broker does not accept any Topic Aliases for all connections meaning the 'Topic Alias' feature is disabled |
| mqtt.topic.min-length-for-alias-replacement | MQTT_TOPIC_MIN_LENGTH_FOR_ALIAS_REPLACEMENT | 50 | Minimal required topic name length that Broker publishes to client that can be replaced with topic alias (e.g. if topic has more than 50 chars - it can be replaced with alias) |
| mqtt.shared-subscriptions.processing-type | MQTT_SHARED_SUBSCRIPTIONS_PROCESSING_TYPE | ROUND_ROBIN | Processing strategy type - how messages are split between clients in shared subscription. Supported types: ROUND_ROBIN |
| mqtt.subscription-trie.wait-for-clear-lock-ms | MQTT_SUB_TRIE_WAIT_FOR_CLEAR_LOCK_MS | 100 | Maximum pause in milliseconds for clearing subscription storage from empty nodes. If wait is unsuccessful the subscribing clients will be resumed, but the clear will fail |
| mqtt.subscription-trie.clear-nodes-cron | MQTT_SUB_TRIE_CLEAR_NODES_CRON | 0 0 0 * * * | Cron job to schedule clearing of empty subscription nodes. Defaults to 'every day at midnight' |
| mqtt.subscription-trie.clear-nodes-zone | MQTT_SUB_TRIE_CLEAR_NODES_ZONE | UTC | Timezone for the subscription clearing cron-job |
| mqtt.retain-msg-trie.wait-for-clear-lock-ms | MQTT_RETAIN_MSG_TRIE_WAIT_FOR_CLEAR_LOCK_MS | 100 | Maximum pause in milliseconds for clearing retain msg storage from empty nodes. If wait is unsuccessful retain messages processing will be resumed, but the clear will fail |
| mqtt.retain-msg-trie.clear-nodes-cron | MQTT_RETAIN_MSG_TRIE_CLEAR_NODES_CRON | 0 0 0 * * * | Cron job to schedule clearing of empty retain msg nodes. Defaults to 'every day at midnight' |
| mqtt.retain-msg-trie.clear-nodes-zone | MQTT_RETAIN_MSG_TRIE_CLEAR_NODES_ZONE | UTC | Timezone for retain msg clearing cron-job |
| mqtt.retain-msg.expiry-processing-period-ms | MQTT_RETAIN_MSG_EXPIRY_PROCESSING_PERIOD_MS | 60000 | Period in milliseconds to clear retained messages by expiry feature of MQTT |
| mqtt.client-session-expiry.cron | MQTT_CLIENT_SESSION_EXPIRY_CRON | 0 0 * ? * * | Cron job to schedule clearing of expired and not active client sessions. Defaults to 'every hour', e.g. at 20:00:00 UTC |
| mqtt.client-session-expiry.zone | MQTT_CLIENT_SESSION_EXPIRY_ZONE | UTC | Timezone for the client sessions clearing cron-job |
| mqtt.client-session-expiry.max-expiry-interval | MQTT_CLIENT_SESSION_EXPIRY_MAX_EXPIRY_INTERVAL | 604800 | Max expiry interval allowed of inactive sessions in seconds. The current value corresponds to one week |
| mqtt.client-session-expiry.ttl | MQTT_CLIENT_SESSION_EXPIRY_TTL | 604800 | Administration TTL in seconds for clearing sessions that do not expire by session expiry interval (e.g. MQTTv3 cleanSession=false or MQTTv5 cleanStart=false && sessionExpiryInterval == 0). The current value corresponds to one week. 0 or negative value means this TTL is disabled |
| mqtt.version-3-1.max-client-id-length | MQTT_3_1_MAX_CLIENT_ID_LENGTH | 1024 | Max ClientId length for 3.1 version of protocol |
| mqtt.write-and-flush | MQTT_MSG_WRITE_AND_FLUSH | true | If enabled, each message is published to non-persistent subscribers with flush. When disabled, the messages are buffered in the channel and are flushed once in a while |
| mqtt.buffered-msg-count | MQTT_BUFFERED_MSG_COUNT | 5 | Number of messages buffered in the channel before the flush is made. Used when `MQTT_MSG_WRITE_AND_FLUSH` = false |
| mqtt.buffered-delivery.session-cache-max-size | MQTT_BUFFERED_CACHE_MAX_SIZE | 10000 | When either `MQTT_MSG_WRITE_AND_FLUSH` or `MQTT_PERSISTENT_MSG_WRITE_AND_FLUSH` is set to false, the broker buffers outgoing messages in the outbound channel to improve throughput. The respective buffer sizes are controlled by `MQTT_BUFFERED_MSG_COUNT` (for non-persistent clients) and `MQTT_PERSISTENT_BUFFERED_MSG_COUNT` (for persistent clients). Defines the maximum number of session entries that can be stored in the flush state cache. When the cache exceeds this size, the least recently used sessions are evicted and their pending message buffers are flushed automatically |
| mqtt.buffered-delivery.session-cache-expiration-ms | MQTT_BUFFERED_CACHE_EXPIRY_MS | 300000 | Time in milliseconds after which an inactive session entry in the flush cache expires. A session is considered inactive if it receives no new messages during this period. Upon expiration, the session is evicted from the cache and its buffer is flushed. Default is 5 minutes |
| mqtt.buffered-delivery.scheduler-execution-interval-ms | MQTT_BUFFERED_SCHEDULER_INTERVAL_MS | 100 | Interval in milliseconds at which the scheduler checks all sessions in the cache for potential flushing. A smaller value results in more frequent flush checks |
| mqtt.buffered-delivery.idle-session-flush-timeout-ms | MQTT_BUFFERED_IDLE_FLUSH_MS | 200 | Maximum duration in milliseconds that a session can remain idle (i.e., without being flushed) before its message buffer is automatically flushed to the client. In essence, a flush occurs either when the buffer limit is reached or when this timeout elapses |
| mqtt.persistent-session.device.persisted-messages.limit | MQTT_PERSISTENT_SESSION_DEVICE_PERSISTED_MESSAGES_LIMIT | 10000 | Maximum number of PUBLISH messages stored for each persisted DEVICE client |
| mqtt.persistent-session.device.persisted-messages.ttl | MQTT_PERSISTENT_SESSION_DEVICE_PERSISTED_MESSAGES_TTL | 604800 | TTL of persisted DEVICE messages in seconds. The current value corresponds to one week |
| mqtt.persistent-session.device.persisted-messages.write-and-flush | MQTT_PERSISTENT_MSG_WRITE_AND_FLUSH | true | If enabled, each message is published to persistent DEVICE client subscribers with flush. When disabled, the messages are buffered in the channel and are flushed once in a while |
| mqtt.persistent-session.device.persisted-messages.buffered-msg-count | MQTT_PERSISTENT_BUFFERED_MSG_COUNT | 5 | Number of messages buffered in the channel before the flush is made. Used when `MQTT_PERSISTENT_MSG_WRITE_AND_FLUSH` = false |
| mqtt.persistent-session.app.persisted-messages.write-and-flush | MQTT_APP_MSG_WRITE_AND_FLUSH | false | If enabled, each message is published to persistent APPLICATION client subscribers with flush. When disabled, the messages are buffered in the channel and are flushed once in a while |
| mqtt.persistent-session.app.persisted-messages.buffered-msg-count | MQTT_APP_BUFFERED_MSG_COUNT | 10 | Number of messages buffered in the channel before the flush is made. Used when `MQTT_APP_MSG_WRITE_AND_FLUSH` = false |
| mqtt.rate-limits.threads-count | MQTT_RATE_LIMITS_THREADS_COUNT | 1 | The number of parallel threads dedicated to processing total rate limit checks for incoming messages |
| mqtt.rate-limits.batch-size | MQTT_RATE_LIMITS_BATCH_SIZE | 50 | The number of messages to process in each batch when checking total rate limits for incoming messages |
| mqtt.rate-limits.period-ms | MQTT_RATE_LIMITS_PERIOD_MS | 50 | The period, in milliseconds, to wait before processing a batch of messages for total rate limits for incoming messages |
| mqtt.rate-limits.incoming-publish.enabled | MQTT_INCOMING_RATE_LIMITS_ENABLED | false | Enable/disable publish rate limits per client for incoming messages to the broker from publishers |
| mqtt.rate-limits.incoming-publish.client-config | MQTT_INCOMING_RATE_LIMITS_CLIENT_CONFIG | 10:1,300:60 | Limit the maximum count of publish messages per publisher for specified time intervals in seconds. Comma separated list of limit:seconds pairs. Example: 10 messages per second or 300 messages per minute |
| mqtt.rate-limits.outgoing-publish.enabled | MQTT_OUTGOING_RATE_LIMITS_ENABLED | false | Enable/disable publish rate limits per client for outgoing messages from the broker to subscribers. Used only for non-persistent subscribers with QoS = 0 ("AT_MOST_ONCE") |
| mqtt.rate-limits.outgoing-publish.client-config | MQTT_OUTGOING_RATE_LIMITS_CLIENT_CONFIG | 10:1,300:60 | Limit the maximum count of publish messages per subscriber for specified time intervals in seconds. Comma separated list of limit:seconds pairs. Example: 10 messages per second or 300 messages per minute |
| mqtt.rate-limits.device-persisted-messages.enabled | MQTT_DEVICE_PERSISTED_MSGS_RATE_LIMITS_ENABLED | false | Enable/disable Device clients persisted messages rate limits for the broker (per whole cluster) |
| mqtt.rate-limits.device-persisted-messages.config | MQTT_DEVICE_PERSISTED_MSGS_RATE_LIMITS_CONFIG | 100:1,1000:60 | Limit the maximum count of Device clients persisted messages for specified time intervals in seconds. Comma separated list of limit:seconds pairs. Example: 100 messages per second or 1000 messages per minute |
| mqtt.application-clients-limit | MQTT_APPLICATION_CLIENTS_LIMIT | 0 | Limit the total number of Application persistent clients and external system integrations. A setting of 0 means the limitation is disabled |
| mqtt.handler.all_msg_callback_threads | MQTT_HANDLER_ALL_MSG_CALLBACK_THREADS | 2 | Number of threads in thread pool for processing all publish messages callbacks after sending them to Kafka |
| mqtt.handler.device_msg_callback_threads | MQTT_HANDLER_DEVICE_MSG_CALLBACK_THREADS | 2 | Number of threads in thread pool for processing device persisted publish messages callbacks after sending them to Kafka |
| mqtt.handler.app_msg_callback_threads | MQTT_HANDLER_APP_MSG_CALLBACK_THREADS | 2 | Number of threads in thread pool for processing application persisted publish messages callbacks after sending them to Kafka |
| mqtt.handler.downlink_msg_callback_threads | MQTT_HANDLER_DOWNLINK_MSG_CALLBACK_THREADS | 2 | Number of threads in thread pool for processing downlink messages callbacks after sending them to Kafka |
| mqtt.response-info | MQTT_RESPONSE_INFO | Response info value for MQTT 5 request-response feature to be returned to clients that request it. If not set the broker will not reply with response info to mqtt 5 clients that connect with"request response info" = 1. Set it to topic to be used for request-response feature, e.g. "example/" | |
| mqtt.blocked-client.cleanup.period | BLOCKED_CLIENT_CLEANUP_PERIOD_MINUTES | 5 | The parameter to specify the period of execution cleanup task for expired blocked clients. Value set in minutes. Default value corresponds to five minutes |
| mqtt.blocked-client.cleanup.ttl | BLOCKED_CLIENT_CLEANUP_TTL_MINUTES | 10080 | Time to Live for expired blocked clients. After this time, the expired blocked client is removed completely. Value set in minutes. Default value corresponds to one week |
Cache parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| cache.stats.enabled | CACHE_STATS_ENABLED | true | Enable/disable cache stats logging |
| cache.stats.intervalSec | CACHE_STATS_INTERVAL_SEC | 60 | Cache stats logging interval in seconds |
| cache.cache-prefix | CACHE_PREFIX | The common prefix for all cache keys. Defaults to empty string meaning no prefix is added | |
| cache.specs.mqttClientCredentials.timeToLiveInMinutes | CACHE_SPECS_MQTT_CLIENT_CREDENTIALS_TTL | 1440 | Cache TTL in minutes. Defaults to 1 day |
| cache.specs.basicCredentialsPassword.timeToLiveInMinutes | CACHE_SPECS_BASIC_CREDENTIALS_PASSWORD_TTL | 1 | Cache TTL in minutes. It is recommended to set this TTL as a small value to not store them for a long time (e.g., 1-5 minutes) |
| cache.specs.sslRegexBasedCredentials.timeToLiveInMinutes | CACHE_SPECS_SSL_REGEX_BASED_CREDENTIALS_TTL | 1440 | Cache TTL in minutes. Defaults to 1 day |
| cache.specs.clientSessionCredentials.timeToLiveInMinutes | CACHE_SPECS_CLIENT_SESSION_CREDENTIALS_TTL | 0 | Cache TTL in minutes. Defaults to 0 meaning the cache is eternal |
| cache.specs.clientMqttVersion.timeToLiveInMinutes | CACHE_SPECS_CLIENT_MQTT_VERSION_TTL | 0 | Cache TTL in minutes. Defaults to 0 meaning the cache is eternal |
| cache.image.etag.timeToLiveInMinutes | CACHE_IMAGE_ETAG_TTL | 10080 | Image ETags cache TTL in minutes. Defaults to 7 days |
| cache.image.etag.maxSize | CACHE_IMAGE_ETAG_MAX_SIZE | 10000 | Max size of entries in the cache. 0 means the cache is disabled |
| cache.image.systemImagesBrowserTtlInMinutes | CACHE_IMAGE_SYSTEM_BROWSER_TTL | 0 | Browser cache TTL for system images in minutes. 0 means the cache is disabled |
Redis configuration parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| redis.connection.type | REDIS_CONNECTION_TYPE | standalone | Connection type: standalone or cluster or sentinel |
| redis.standalone.host | REDIS_HOST | localhost | Redis connection host |
| redis.standalone.port | REDIS_PORT | 6379 | Redis connection port |
| redis.standalone.useDefaultClientConfig | REDIS_USE_DEFAULT_CLIENT_CONFIG | true | Use the default Redis configuration file |
| redis.standalone.clientName | REDIS_CLIENT_NAME | standalone | This value may be used only if you did not use the default ClientConfig, to specify client name |
| redis.standalone.connectTimeout | REDIS_CLIENT_CONNECT_TIMEOUT | 30000 | This value may be used only if you did not use the default ClientConfig, to specify connection timeout |
| redis.standalone.readTimeout | REDIS_CLIENT_READ_TIMEOUT | 60000 | This value may be used only if you did not use the default ClientConfig, to specify read timeout |
| redis.standalone.usePoolConfig | REDIS_CLIENT_USE_POOL_CONFIG | false | This value may be used only if you did not use the default ClientConfig, to use pool config section |
| redis.cluster.nodes | REDIS_NODES | Comma-separated list of"host:port" pairs to bootstrap from | |
| redis.cluster.maxRedirects | REDIS_MAX_REDIRECTS | 12 | Maximum number of redirects to follow when executing commands across the cluster |
| redis.cluster.useDefaultPoolConfig | REDIS_CLUSTER_USE_DEFAULT_POOL_CONFIG | true | If set false will be used pool config build from values of the pool config section |
| redis.sentinel.master | REDIS_MASTER | Name of master node | |
| redis.sentinel.sentinels | REDIS_SENTINELS | Comma-separated list of"host:port" pairs of sentinels | |
| redis.sentinel.password | REDIS_SENTINEL_PASSWORD | Password to authenticate with sentinel | |
| redis.sentinel.useDefaultPoolConfig | REDIS_SENTINEL_USE_DEFAULT_POOL_CONFIG | true | If set false will be used pool config build from values of the pool config section |
| redis.db | REDIS_DB | 0 | DB index |
| redis.password | REDIS_PASSWORD | DB password | |
| redis.pool_config.maxTotal | REDIS_POOL_CONFIG_MAX_TOTAL | 128 | Maximum number of connections that can be allocated by the connection pool |
| redis.pool_config.maxIdle | REDIS_POOL_CONFIG_MAX_IDLE | 128 | Maximum number of idle connections that can be maintained in the pool without being closed |
| redis.pool_config.minIdle | REDIS_POOL_CONFIG_MIN_IDLE | 16 | Minimum number of idle connections that can be maintained in the pool without being closed |
| redis.pool_config.testOnBorrow | REDIS_POOL_CONFIG_TEST_ON_BORROW | true | Enable/Disable PING command sent when a connection is borrowed |
| redis.pool_config.testOnReturn | REDIS_POOL_CONFIG_TEST_ON_RETURN | true | The property is used to specify whether to test the connection before returning it to the connection pool |
| redis.pool_config.testWhileIdle | REDIS_POOL_CONFIG_TEST_WHILE_IDLE | true | Indicates whether to use the ping command to monitor the connection validity during idle resource monitoring. Invalid connections will be destroyed |
| redis.pool_config.minEvictableMs | REDIS_POOL_CONFIG_MIN_EVICTABLE_MS | 60000 | Minimum time the connection should be idle before it can be evicted from the connection pool. The value is set in milliseconds |
| redis.pool_config.evictionRunsMs | REDIS_POOL_CONFIG_EVICTION_RUNS_MS | 30000 | Specifies the time interval in milliseconds between two consecutive eviction runs |
| redis.pool_config.maxWaitMills | REDIS_POOL_CONFIG_MAX_WAIT_MS | 60000 | Maximum time in milliseconds where a client is willing to wait for a connection from the pool when all connections are exhausted |
| redis.pool_config.numberTestsPerEvictionRun | REDIS_POOL_CONFIG_NUMBER_TESTS_PER_EVICTION_RUN | 3 | Specifies the number of connections to test for eviction during each eviction run |
| redis.pool_config.blockWhenExhausted | REDIS_POOL_CONFIG_BLOCK_WHEN_EXHAUSTED | true | Determines the behavior when a thread requests a connection from the pool, but there are no available connections, and the pool cannot create more due to the maxTotal configuration |
Statistics parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| stats.enabled | STATS_ENABLED | true | Enable/disable stats printing to the logs |
| stats.print-interval-ms | STATS_PRINT_INTERVAL_MS | 60000 | Period in milliseconds to print stats. Default value corresponds to 1 minute |
| stats.timer.percentiles | STATS_TIMER_PERCENTILES | 0.5 | Metrics percentiles returned by actuator for timer metrics. List of comma-separated (,) double values |
| stats.application-processor.enabled | APPLICATION_PROCESSOR_STATS_ENABLED | true | Enable/disable specific Application clients stats |
| stats.system-info.persist-frequency | STATS_SYSTEM_INFO_PERSIST_FREQUENCY_SEC | 60 | Persist frequency of system info (CPU, memory usage, etc.) in seconds |
Historical data statistics parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| historical-data-report.enabled | HISTORICAL_DATA_REPORT_ENABLED | true | Enable/disable historical data stats reporting and persistence to the time series |
| historical-data-report.interval | HISTORICAL_DATA_REPORT_INTERVAL | 1 | Period in minutes (1-60) to collect stats for each broker. Used in cron expression |
| historical-data-report.zone | HISTORICAL_DATA_REPORT_ZONE | UTC | Timezone for the historical data stats processing |
Metrics management parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| management.health.diskspace.enabled | HEALTH_DISKSPACE_ENABLED | false | Enable/disable disk space health check |
| management.endpoint.health.show-details | HEALTH_SHOW_DETAILS | never | Controls whether health endpoint shows full component details (e.g., Redis, DB, TBMQ). Options: - 'never': always hide details (default if security is enabled). - 'when-authorized': show details only to authenticated users. - 'always': always include full health details in the response |
| management.endpoints.web.exposure.include | METRICS_ENDPOINTS_EXPOSE | health,info,prometheus | Specify which Actuator endpoints should be exposed via HTTP. Use 'health,info' to expose only basic health and information endpoints. For exposing Prometheus metrics, update this to include 'prometheus' in the list (e.g., 'health,info,prometheus') |
Spring CORS configuration
| 参数 | 环境变量 | 默认值 | 描述 |
| spring.mvc.cors.mappings."[/api/**]".allowed-origin-patterns | MVC_CORS_API_ALLOWED_ORIGIN_PATTERNS | * | Comma-separated list of origins to allow. '*' allows all origins. When not set, CORS support is disabled |
| spring.mvc.cors.mappings."[/api/**]".allowed-methods | MVC_CORS_API_ALLOWED_METHODS | * | Comma-separated list of methods to allow. '*' allows all methods |
| spring.mvc.cors.mappings."[/api/**]".allowed-headers | MVC_CORS_API_ALLOWED_HEADERS | * | Comma-separated list of headers to allow in a request. '*' allows all headers |
| spring.mvc.cors.mappings."[/api/**]".max-age | MVC_CORS_API_MAX_AGE | 1800 | How long, in seconds, the response from a pre-flight request can be cached by clients |
| spring.mvc.cors.mappings."[/api/**]".allow-credentials | MVC_CORS_API_ALLOW_CREDENTIALS | true | Set whether credentials are supported. When not set, credentials are not supported |
| license.secret | TBMQ_LICENSE_SECRET | License secret obtained from ThingsBoard License Portal (https://license.thingsboard.io) | |
| license.instance_data_file | TBMQ_LICENSE_INSTANCE_DATA_FILE | tbmq-instance-license.data | Instance data is auto-generated and is used to identify a particular TBMQ Instance. Instance data is periodically updated and stored into the specified file which can be set to absolute or relative path. Please make sure that TBMQ process has access to the instance data file, in case you use absolute path |
Spring doc common parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| springdoc.api-docs.enabled | SWAGGER_ENABLED | true | If false swagger API docs will be unavailable |
| springdoc.default-produces-media-type | SWAGGER_DEFAULT_PRODUCES_MEDIA_TYPE | application/json | Swagger default produces media-type |
Swagger common parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| swagger.api_path | SWAGGER_API_PATH | /api/** | General swagger match pattern of swagger UI links |
| swagger.security_path_regex | SWAGGER_SECURITY_PATH_REGEX | /api/.* | General swagger match pattern path of swagger UI links |
| swagger.non_security_path_regex | SWAGGER_NON_SECURITY_PATH_REGEX | /api/noauth.* | Non-security API path match pattern of swagger UI links |
| swagger.title | SWAGGER_TITLE | TBMQ REST API | The title on the API doc UI page |
| swagger.description | SWAGGER_DESCRIPTION | TBMQ Professional Edition REST API documentation | The description on the API doc UI page |
| swagger.contact.name | SWAGGER_CONTACT_NAME | TBMQ team | The contact name on the API doc UI page |
| swagger.contact.url | SWAGGER_CONTACT_URL | https://thingsboard.io/products/mqtt-broker/ | The contact URL on the API doc UI page |
| swagger.contact.email | SWAGGER_CONTACT_EMAIL | info@thingsboard.io | The contact email on the API doc UI page |
| swagger.license.title | SWAGGER_LICENSE_TITLE | Apache License Version 2.0 | The license title on the API doc UI page |
| swagger.license.url | SWAGGER_LICENSE_URL | https://github.com/thingsboard/tbmq/blob/main/LICENSE | Link to the license body on the API doc UI page |
| swagger.version | SWAGGER_VERSION | The version of the API doc to display. Default to the package version | |
| swagger.group_name | SWAGGER_GROUP_NAME | TBMQ | The group name (definition) on the API doc UI page |
Application info parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| app.version | "@project.version@" | Application version |
Analysis parameters
| 参数 | 环境变量 | 默认值 | 描述 |
| analysis.log.enabled | ANALYSIS_LOG_ENABLED | true | Enable/disable the analysis logging |
| analysis.log.all-clients | ANALYSIS_LOG_ALL_CLIENTS | false | If true – log events for ALL clients (ignores analyzed-client-ids) |
| analysis.log.analyzed-client-ids | ANALYSIS_LOG_CLIENT_IDS | List of Client Ids separated with comas. Additional events for those clients will be logged. Example env var: ANALYSIS_LOG_CLIENT_IDS=client1,client2 |