org.llm4s.agent.service.WorkerSettings
See theWorkerSettings companion object
@Experimental
How an AgentWorker runs (Stage 5 W2, design 4.56), loaded from llm4s.agent.worker by WorkerConfigLoader:
concurrency: the most runs the worker has at once (default 4).pollInterval: how long the worker waits before it asks the queue again once it found nothing to take (default 1 second), and how long it passes over an entry it deferred to a live run on the thread.unrunnableAfter: how long an entry may wait for a worker whose graph version can restore its thread before a worker that cannot closes itFailed(Unrunnable)(default 1 hour): long enough for a rolling upgrade's old workers to finish their runs. Judged by the store's clock, from the entry's submission or its latest attempt.drainGrace: on shutdown, how long running runs have to reach a suspension or their end before the worker cancels them (default 30 seconds).exitTimeout: how long a cancelled run then has to exit before the worker gives up on it (default 10 seconds). A run that has not exited keeps its claim and lease, which expire after their ttl once the process exits.sweepEvery: how often the worker runs the store-wide retention sweep (Checkpointer.sweep) and reclaims closed entries past their ticket lifetime (RunQueue.reclaim), one instance of the fleet at a time;Noneturns the sweep off (default 5 minutes).sweep: what the sweep prunes and reclaims (SweepPolicy; defaultSweepPolicy.keepAll, which prunes nothing, so the sweep only reclaims expired queue entries).label: names the worker in its lease holder and its logs, such as a host or pod name; a random suffix keeps two workers with one label apart.
Every duration must be positive, concurrency at least 1 and a label not blank: apply and the with* setters throw IllegalArgumentException otherwise, and WorkerSettings.of returns a ValidationError.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any
Members list
In this article