Configuration reference

Worker and client settings

Configuration keys for workers and clients, and how they are resolved from files, environment variables and arguments.

Distro Current 2 min read Updated

Note

Kiwi Distro is currently in private preview. Interfaces and behaviour described here can change before general availability. Contact Kiwify Labs for access.

Resolution order#

Settings are flat keys, resolved from lowest to highest precedence:

  1. appsettings.json
  2. Environment variables prefixed with KIWI_ (for example KIWI_MIDDLEWARE_URL)
  3. Command-line arguments (--key value)
  4. Options passed in code

Worker settings#

Key Required Default Notes
middleware_url yes For example https://localhost:8443
auth_secret yes The worker-profile secret
worker_id no random GUID Lower-case letters, digits, :, _ and -; it cannot be all or any
worker_name no Display name
execution_mode no eager eager, lazy or connected
middleware_ca_url no Plain-HTTP CA endpoint, for example http://localhost:8080/ca/cert. Pins that CA
ignore_ssl no false Development only
wakeup_probe_service_port no auto (from 55222) Local TCP port the middleware pings in lazy mode
long_poll_wait no 25 Eager mode: seconds to hold an idle poll (seconds or a time period). The middleware clamps it to its own limit
version no 1.0.0 Worker or script version label
heartbeat_delay no 3S
tags no Free-form {key: value} used for tag-filtered routing

service_id is informational; the real service id comes from the access token.

Client settings#

Key Required Notes
middleware_url yes Base URL of the middleware, for example https://mw:8443
client_id, client_secret yes OAuth client credentials
middleware_ca_url no Plain-HTTP CA endpoint; pins the middleware's certificate chain
ignore_ssl no Development only
request_timeout no Seconds or a time period such as 30S or 2M. Default 30 seconds

Time periods#

Wherever a duration is accepted you can write a number of seconds or a time period such as 30S, 5M, 1H, 7D.

Middleware settings of note#

Key Default Meaning
kiwi:min-threads 200 Minimum thread-pool threads
kiwi:task-queues:worker-wakeup-parallelism 100 Concurrent worker wake-ups
kiwi:task-queues:result-awaiter-parallelism 100 Concurrent result awaiters
kiwi:worker:long-poll-timeout Upper bound for worker long-polls

See Capacity planning before changing these.