Skip to content

JS Coderunner Settings

Cached Workers Count

Defines the maximum number of worker threads that can remain cached after completing their tasks. A positive value keeps workers in a ready state, enabling them to quickly handle new tasks with preloaded code, which can significantly reduce execution delays.

Specifying value 0 disables the caching workers feature and after executing such workers will be immediately removed

Configuration Property Path Type Default Value Example
config/coderunner/js/workers/cache/limit Number config/coderunner/js/workers/cache/limit = 10

Concurrent Workers Count

Sets the upper limit on the number of worker threads that can operate at the same time. This controls how many tasks can be processed simultaneously, balancing performance and system resource usage to prevent overloading.

Configuration Property Path Type Default Value Example
config/coderunner/js/workers/concurrent Number 4 config/coderunner/js/workers/concurrent = 10

Predefined Workers Count

Specifies the number of worker threads that will start in an idle state, ready to process tasks immediately. This ensures a minimum number of workers are always available without waiting for initialization, which can reduce latency for new incoming tasks.

Configuration Property Path Type Default Value Example
config/coderunner/js/workers/minIdle Number 4 config/coderunner/js/workers/minIdle = 10

Cached Workers TTL (Time-to-Live )

Sets the time-to-live (TTL) in seconds for idle cached worker threads. After this time, any workers that remain idle without receiving new tasks are terminated, freeing up resources while maintaining efficiency for workloads that fluctuate over time.

Configuration Property Path Type Default Value Example
config/coderunner/js/workers/cachedIdleTTL Number config/coderunner/js/workers/cachedIdleTTL = 180