Skip to content
Stand with Ukraine flag

VC Executor Configuration

WEB_APPLICATION_ENABLE · Default false

If you enabled process metrics you should also enable ‘web-environment’.

WEB_APPLICATION_TYPE · Default none

If you enabled process metrics you should set ‘web-application-type’ to ‘servlet’ value.

HTTP_BIND_ADDRESS · Default 0.0.0.0

Server bind address (has no effect if web-environment is disabled).

HTTP_BIND_PORT · Default 8086

Server bind port (has no effect if web-environment is disabled).

ZOOKEEPER_ENABLED · Default true

Enable/disable ZooKeeper discovery service.

ZOOKEEPER_URL · Default localhost:2181

ZooKeeper connect string

ZOOKEEPER_RETRY_INTERVAL_MS · Default 3000

ZooKeeper retry interval in milliseconds

ZOOKEEPER_CONNECTION_TIMEOUT_MS · Default 3000

ZooKeeper connection timeout in milliseconds

ZOOKEEPER_SESSION_TIMEOUT_MS · Default 3000

ZooKeeper session timeout in milliseconds

ZOOKEEPER_NODES_DIR · Default /thingsboard

Name of the directory in ZooKeeper ‘filesystem’

ZOOKEEPER_RECALCULATE_DELAY_MS · Default 0

The recalculate_delay property is recommended in a microservices architecture setup for rule-engine services. This property provides a pause to ensure that when a rule-engine service is restarted, other nodes don’t immediately attempt to recalculate their partitions. The delay is recommended because the initialization of rule chain actors is time-consuming. Avoiding unnecessary recalculations during a restart can enhance system performance and stability.

TB_QUEUE_TYPE · Default kafka

kafka (Apache Kafka)

TB_QUEUE_PREFIX

Global queue prefix. If specified, prefix is added before default topic name: ‘prefix.default_topic_name’. Prefix is applied to all topics (and consumer groups for kafka).

TB_QUEUE_IN_MEMORY_STATS_PRINT_INTERVAL_MS · Default 60000

For debug lvl

TB_KAFKA_SERVERS · Default localhost:9092

Kafka Bootstrap Servers

TB_KAFKA_SSL_ENABLED · Default false

Enable/Disable SSL Kafka communication

TB_KAFKA_SSL_TRUSTSTORE_LOCATION

The location of the trust store file

TB_KAFKA_SSL_TRUSTSTORE_PASSWORD

The password of trust store file if specified

TB_KAFKA_SSL_KEYSTORE_LOCATION

The location of the key store file. This is optional for the client and can be used for two-way authentication for the client

TB_KAFKA_SSL_KEYSTORE_PASSWORD

The store password for the key store file. This is optional for the client and only needed if ‘ssl.keystore.location’ is configured. Key store password is not supported for PEM format

TB_KAFKA_SSL_KEY_PASSWORD

The password of the private key in the key store file or the PEM key specified in ‘keystore.key’

TB_KAFKA_ACKS · Default all

The number of acknowledgments the producer requires the leader to have received before considering a request complete. This controls the durability of records that are sent. The following settings are allowed:0,1 and all

TB_KAFKA_RETRIES · Default 1

Number of retries. Resend any record whose send fails with a potentially transient error

TB_KAFKA_COMPRESSION_TYPE · Default none

none or gzip

TB_KAFKA_BATCH_SIZE · Default 16384

Default batch size. This setting gives the upper bound of the batch size to be sent

TB_KAFKA_LINGER_MS · Default 1

This variable creates a small amount of artificial delay—that is, rather than immediately sending out a record

TB_KAFKA_MAX_REQUEST_SIZE · Default 1048576

The maximum size of a request in bytes. This setting will limit the number of record batches the producer will send in a single request to avoid sending huge requests

TB_KAFKA_MAX_IN_FLIGHT_REQUESTS_PER_CONNECTION · Default 5

The maximum number of unacknowledged requests the client will send on a single connection before blocking

TB_BUFFER_MEMORY · Default 33554432

The total bytes of memory the producer can use to buffer records waiting to be sent to the server

TB_QUEUE_KAFKA_REPLICATION_FACTOR · Default 1

The multiple copies of data over the multiple brokers of Kafka

TB_QUEUE_KAFKA_MAX_POLL_INTERVAL_MS · Default 300000

The maximum delay between invocations of poll() when using consumer group management. This places an upper bound on the amount of time that the consumer can be idle before fetching more records

TB_QUEUE_KAFKA_MAX_POLL_RECORDS · Default 8192

The maximum number of records returned in a single call to poll()

TB_QUEUE_KAFKA_MAX_PARTITION_FETCH_BYTES · Default 16777216

The maximum amount of data per-partition the server will return. Records are fetched in batches by the consumer

TB_QUEUE_KAFKA_FETCH_MAX_BYTES · Default 134217728

The maximum amount of data the server will return. Records are fetched in batches by the consumer

TB_QUEUE_KAFKA_REQUEST_TIMEOUT_MS · Default 30000

(30 seconds)

TB_QUEUE_KAFKA_SESSION_TIMEOUT_MS · Default 10000

(10 seconds)

TB_QUEUE_KAFKA_AUTO_OFFSET_RESET · Default earliest

earliest, latest or none

TB_QUEUE_KAFKA_USE_CONFLUENT_CLOUD · Default false

Enable/Disable using of Confluent Cloud

TB_QUEUE_KAFKA_CONFLUENT_SSL_ALGORITHM · Default https

The endpoint identification algorithm used by clients to validate server hostname. The default value is https

TB_QUEUE_KAFKA_CONFLUENT_SASL_MECHANISM · Default PLAIN

The mechanism used to authenticate Schema Registry requests. SASL/PLAIN should only be used with TLS/SSL as a transport layer to ensure that clear passwords are not transmitted on the wire without encryption

TB_QUEUE_KAFKA_CONFLUENT_SASL_JAAS_CONFIG · Default org.apache.kafka.common.security.plain.PlainLoginModule required username=“CLUSTER_API_KEY” password=“CLUSTER_API_SECRET”;

Using JAAS Configuration for specifying multiple SASL mechanisms on a broker

TB_QUEUE_KAFKA_CONFLUENT_SECURITY_PROTOCOL · Default SASL_SSL

Protocol used to communicate with brokers. Valid values are: PLAINTEXT, SSL, SASL_PLAINTEXT, SASL_SSL

TB_QUEUE_KAFKA_OTA_MAX_POLL_RECORDS · Default 10

Example of specific consumer properties value per topic

TB_QUEUE_KAFKA_VC_MAX_POLL_INTERVAL_MS · Default 600000

Example of specific consumer properties value per topic for VC

TB_QUEUE_KAFKA_CONSUMER_PROPERTIES_PER_TOPIC_INLINE

tb_rule_engine.sq: - key: max.poll.records value: ”${TB_QUEUE_KAFKA_SQ_MAX_POLL_RECORDS:1024}” If you override any default Kafka topic name using environment variables, you must also specify the related consumer properties for the new topic in consumer-properties-per-topic-inline. Otherwise, the topic will not inherit its expected configuration (e.g., max.poll.records, timeouts, etc). Format: “topic1:key1=value1,key2=value2;topic2:key=value” Example: “tb_core_modified.notifications:max.poll.records=10;tb_edge_modified:max.poll.records=10,enable.auto.commit=true”

TB_QUEUE_KAFKA_OTHER_PROPERTIES

In this section you can specify custom parameters (semicolon separated) for Kafka consumer/producer/admin

TB_QUEUE_KAFKA_CORE_TOPIC_PROPERTIES · Default retention.ms:604800000;segment.bytes:52428800;retention.bytes:1048576000;partitions:1;min.insync.replicas:1

Kafka properties for Core topics

TB_QUEUE_KAFKA_NOTIFICATIONS_TOPIC_PROPERTIES · Default retention.ms:604800000;segment.bytes:52428800;retention.bytes:1048576000;partitions:1;min.insync.replicas:1

Kafka properties for Notifications topics

TB_QUEUE_KAFKA_VC_TOPIC_PROPERTIES · Default retention.ms:604800000;segment.bytes:52428800;retention.bytes:1048576000;partitions:1;min.insync.replicas:1

Kafka properties for Core topics

TB_QUEUE_KAFKA_HOUSEKEEPER_TOPIC_PROPERTIES · Default retention.ms:604800000;segment.bytes:52428800;retention.bytes:1048576000;partitions:10;min.insync.replicas:1

Kafka properties for Housekeeper tasks topic

TB_QUEUE_KAFKA_CONSUMER_STATS_ENABLED · Default true

Prints lag between consumer group offset and last messages offset in Kafka topics

TB_QUEUE_KAFKA_CONSUMER_STATS_MIN_PRINT_INTERVAL_MS · Default 60000

Statistics printing interval for Kafka’s consumer-groups stats

TB_QUEUE_KAFKA_CONSUMER_STATS_RESPONSE_TIMEOUT_MS · Default 1000

Time to wait for the stats-loading requests to Kafka to finis

TB_QUEUE_KAFKA_TOPICS_CACHE_TTL_MS · Default 300000

Topics cache TTL in milliseconds. 5 minutes by default

TB_QUEUE_PARTITIONS_HASH_FUNCTION_NAME · Default murmur3_128

murmur3_32, murmur3_128 or sha256

TB_QUEUE_CORE_TOPIC · Default tb_core

Default topic name

TB_QUEUE_CORE_NOTIFICATIONS_TOPIC · Default tb_core.notifications

For high-priority notifications that require minimum latency and processing time

TB_QUEUE_CORE_POLL_INTERVAL_MS · Default 25

Interval in milliseconds to poll messages by Core microservices

TB_QUEUE_CORE_PARTITIONS · Default 10

Amount of partitions used by Core microservices

TB_QUEUE_CORE_PACK_PROCESSING_TIMEOUT_MS · Default 2000

Timeout for processing a message pack by Core microservices

TB_QUEUE_CORE_OTA_TOPIC · Default tb_ota_package

Default topic name for OTA updates

TB_QUEUE_CORE_OTA_PACK_INTERVAL_MS · Default 60000

The interval of processing the OTA updates for devices. Used to avoid any harm to the network due to many parallel OTA updates

TB_QUEUE_CORE_OTA_PACK_SIZE · Default 100

The size of OTA updates notifications fetched from the queue. The queue stores pairs of firmware and device ids

TB_QUEUE_US_TOPIC · Default tb_usage_stats

Stats topic name

TB_QUEUE_CORE_STATS_ENABLED · Default true

Enable/disable statistics for Core microservices

TB_QUEUE_CORE_STATS_PRINT_INTERVAL_MS · Default 60000

Statistics printing interval for Core microservices

TB_HOUSEKEEPER_TOPIC · Default tb_housekeeper

Topic name for Housekeeper tasks

TB_QUEUE_VC_TOPIC · Default tb_version_control

Default topic name

TB_QUEUE_VC_PARTITIONS · Default 10

Number of partitions to associate with this queue. Used for scaling the number of messages that can be processed in parallel

TB_QUEUE_VC_INTERVAL_MS · Default 25

Interval in milliseconds between polling of the messages if no new messages arrive

TB_QUEUE_VC_PACK_PROCESSING_TIMEOUT_MS · Default 180000

Timeout before retrying all failed and timed-out messages from the processing pack

TB_QUEUE_VC_MSG_CHUNK_SIZE · Default 250000

Limit for single queue message size

TB_VC_POOL_SIZE · Default 6

Pool size for handling export tasks

TB_VC_GIT_POOL_SIZE · Default 3

Pool size for handling the git IO operations

TB_VC_GIT_REPOSITORIES_FOLDER · Default ${java.io.tmpdir}/repositories

Default storing repository path

USAGE_STATS_REPORT_ENABLED · Default true

Enable/Disable the collection of statistics about API usage. Collected on a system and tenant level by default

USAGE_STATS_REPORT_PER_CUSTOMER_ENABLED · Default false

Enable/Disable collection of statistics about API usage on a customer level

USAGE_STATS_REPORT_INTERVAL · Default 60

Interval of reporting the statistics. By default, the summarized statistics are sent every 10 seconds

USAGE_STATS_REPORT_URGENT_INTERVAL · Default 10

Reporting interval for urgent keys (e.g. SMS, Email) that require quicker usage state updates

USAGE_STATS_REPORT_PACK_SIZE · Default 1024

Amount of statistic messages in pack

METRICS_ENABLED · Default false

Enable/disable actuator metrics.

METRICS_TIMER_PERCENTILES · Default 0.5

Metrics percentiles returned by actuator for timer metrics. List of double values (divided by ,).

METRICS_ENDPOINTS_EXPOSE · Default info

Expose metrics endpoint (use value ‘prometheus’ to enable prometheus metrics).

TB_SERVICE_TYPE · Default tb-vc-executor

service type

TB_SERVICE_ID

Unique id for this service (autogenerated if empty)

TB_NOTIFICATION_RULES_DEDUPLICATION_DURATIONS · Default RATE_LIMITS:14400000;

Semicolon-separated deduplication durations (in millis) for trigger types. Format: ‘NotificationRuleTriggerType1:123;NotificationRuleTriggerType2:456’