Runtime thread pool configuration

The implementation of the Asset Gateway and Enterprise Gateway runtime component includes a configurable pool of worker threads. These threads are operating system threads that run in the context of the runtime process. These worker threads perform various tasks, including the support of the:

  • Execution of trigger actions
  • Reading of device variables
  • Communications with external processes, including the Workbench and the Transaction Server.

The original implementation of the pool of worker threads will be referred to as Thread Pool V2.0.

Thread Pool V2.0 is the default configuration for Asset Gateways and Enterprise Gateways. Its features can be configured based on your system and application's design and resource usage.
For some high resource usage applications, the Thread Pool V2.0 implementation and configurable features provide an improvement in the system behavior required for the application's design and resource usage.

Runtime thread pool options

Configuration of the thread pool is an advanced topic. In most cases, you will be directed to this information and the configuration options based on interaction with your support representative.

Thread pool properties, System Variables and default values

Some of the properties are present in the properties files. Other properties are not present in the provided properties files, but have a default value in the code.

Many of the properties and their current values for a node can be seen using the Workbench -> Administration -> System Variables tab.

The default values listed in the following sections are the default values for most Asset Gateway and Enterprise Gateway products. Some products with limited system resources have different default values for some properties. If there is a question, the values can be seen for the node using the Workbench -> Administration -> System Variables tab.

Thread Pool V2.0

The properties available for the configurable features of the Thread Pool V2.0 implementation, and the associated System Variables are:

  1. Minimum thread count:
    1. This concept is removed. The pool.threads.min property is not used.
  2. Maximum thread count:
    1. The Thread Pool V1.0 property pool.threads.max is not used, pool.v2.threads.max is used instead.
    2. The number of worker threads started during the runtime's initialization.
      1. If the number of current, in use, worker threads reaches this maximum value, a new worker thread will not be created.
      2. Instead, the new work item is queued, waiting for a current worker thread to complete its work item and be available to process queued work items.
    3. The defaults are:
      1. Asset Gateway: pool.v2.threads.max=120.
      2. Enterprise Gateway: pool.v2.threads.max=500.
    4. The System Variable is: pool.v2.threads.max.
  3. Worker thread limiter count. In the Thread Pool V2.0 implementation, this is a thread count instead of a percentage of the maximum thread count:
    1. The Thread Pool V1.0 property pool.limiter.count is not used, pool.v2.limiter.count is used instead.
    2. When the worker thread limit count is reached, the system will create a queue and put all new work items for that particular task work type into that queue.
    3. The defaults are:
      1. Asset Gateways: pool.v2.limiter.count=40.
      2. Enterprise Gateways: pool.v2.limiter.count=150.
    4. The System Variable is: pool.v2.limiter.count.
  4. Thread stack size:
    1. The stack size, in bytes, for each worker thread.
    2. The default is: pool.threads.stack=65536.
    3. The System Variable is: pool.queue.threads.stack.

Properties file management

For information on properties file management, including overwritten of files during a product installation or a product update, see Properties file management.


Related topics

System Variables

Diagnostics

Properties file management

Troubleshooting node resource utilization problems