Skip to main content
This page documents all worker configuration options. For conceptual information, see Workers.

Daemon-level settings

You configure worker pool settings in the [general] section of malbox.toml:
[general]
max_workers = 4
min_workers = 1
idle_timeout_ms = 60000
FieldTypeDefaultDescription
max_workersinteger4Maximum number of concurrent workers. The pool auto-scales up to this limit when all active workers are busy.
min_workersinteger1Baseline workers that are always running. These never idle-exit.
idle_timeout_msinteger60000How long a demand worker (beyond min_workers) waits without work before exiting. In milliseconds.
Baseline workers (min_workers) have no idle timeout and run until the daemon shuts down. The daemon spawns demand workers when all active workers are busy, and they exit automatically after idle_timeout_ms of inactivity.

Worker configuration

Control individual worker behavior through WorkerConfig:
[[workers]]
name = "default"
execution_mode = "Single"
batch_processing = false
max_batch_size = 1
batch_timeout_ms = 500
idle_timeout_ms = 500
max_concurrent_tasks = 1
priority = 5

[workers.resource_limits]
memory_mb = 4096
cpu_cores = 2

[workers.plugin_restrictions]
allow = ["string-extractor", "yara-scanner"]
deny = []

Fields

FieldTypeRequiredDefaultDescription
namestringYes-Unique name for this worker configuration.
compatible_tasksstring[]Noall typesTask types this worker can handle. Omit or set to null to accept all task types.
execution_modestringYes-"Single" (one task at a time) or "Batch" (batch processing).
batch_processingboolYes-Whether this worker supports batch processing.
max_batch_sizeintegerNo1Maximum tasks in a single batch.
batch_timeout_msintegerNo500Maximum time to wait for batch collection (milliseconds).
idle_timeout_msintegerNo500Maximum idle time before the worker exits (milliseconds).
max_concurrent_tasksintegerNo1Maximum concurrent tasks this worker can handle.
priorityintegerNo5Worker priority for task assignment (higher = preferred). Range: 0-255.
compatible_platformsstring[]NoallMachine platforms this worker can handle ("windows", "linux").

[workers.resource_limits]

Optional resource constraints for the worker.
FieldTypeDefaultDescription
memory_mbintegerunlimitedMemory limit in megabytes.
cpu_coresintegerunlimitedCPU core limit.
disk_mbintegerunlimitedDisk space limit in megabytes.
network_kbpsintegerunlimitedNetwork bandwidth limit in KB/s.

[workers.plugin_restrictions]

Control which plugins a worker is allowed to execute.
FieldTypeDefaultDescription
allowstring[][] (all allowed)Plugins this worker is allowed to use. Empty means all plugins are allowed.
denystring[][]Plugins this worker must not use. Takes precedence over allow.