Durability

org.llm4s.agent.graph.Durability
enum Durability

When a run's checkpoints and events become durable. In every mode a durable event is delivered only after the commit that numbered it, so no subscriber sees a sequence number that a crash could later reuse. In every mode a run claims its thread with a synchronous commit before it runs anything, and makes everything durable before it returns - so a returned RunResult.Suspended has been persisted and can be resumed by another process.

Attributes

Source
GraphRuntime.scala
Graph
Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Type members

Enum entries

case Async extends Durability

Commits are queued and written in order on a background writer while the run continues. After a crash, the work since the last durable checkpoint is redone by recover. The run waits for the queue before returning, and fails if any queued commit failed - or with GraphError.CommitTimedOut if one stays in the store for twice the claim's ttl with none returning.

Commits are queued and written in order on a background writer while the run continues. After a crash, the work since the last durable checkpoint is redone by recover. The run waits for the queue before returning, and fails if any queued commit failed - or with GraphError.CommitTimedOut if one stays in the store for twice the claim's ttl with none returning.

Attributes

Source
GraphRuntime.scala
case OnExit extends Durability

After the claim, nothing is written until the run ends; then the last checkpoint, its pending writes and every buffered event are committed at once. A crash loses the run's progress. An exit commit that stays in the store for twice the claim's ttl ends the run GraphError.CommitTimedOut.

After the claim, nothing is written until the run ends; then the last checkpoint, its pending writes and every buffered event are committed at once. A crash loses the run's progress. An exit commit that stays in the store for twice the claim's ttl ends the run GraphError.CommitTimedOut.

Attributes

Source
GraphRuntime.scala
case Sync extends Durability

Each task result and superstep is committed before the run moves on.

Each task result and superstep is committed before the run moves on.

Attributes

Source
GraphRuntime.scala