Libraries v5.0.0
    Preparing search index...

    Shared durable transition engine. Adapters supply locking/storage, not policy. Lease fencing protects scheduler state only, never a handler's external effects.

    Hierarchy (View Summary)

    Index
    storage: JobStorage
    • Fence a running owner immediately; physical cancellation is cooperative.

      Parameters

      • namespace: string
      • id: string

      Returns Promise<boolean>

    • Purge terminal data only; deduplication ends when the retained run is removed.

      Parameters

      • namespace: string
      • limit: number = 100

      Returns Promise<number>

    • Publish output and terminal event atomically, rejecting stale owners.

      Parameters

      • namespace: string
      • id: string
      • token: string
      • output: JsonValue

      Returns Promise<void>

    • Atomically materialize due occurrences and advance locked schedule cursors.

      Parameters

      • namespace: string
      • scheduleLimit: number = 10
      • replayLimit: number = 100

      Returns Promise<number>

    • Read a bounded page of committed events, scoped through the owning run.

      Parameters

      • namespace: string
      • id: string
      • after: number
      • limit: number = 100

      Returns Promise<JobEvent[]>

    • Persist a failure or shutdown interruption and its retry decision.

      Parameters

      • namespace: string
      • id: string
      • token: string
      • error: JobError
      • retryable: boolean = true
      • interrupted: boolean = false

      Returns Promise<void>

    • Read a detached internal record. Applications should use JobScheduler.getRun.

      Parameters

      • namespace: string
      • id: string

      Returns Promise<RunRecord | undefined>

    • Renew an unexpired lease; a late heartbeat cannot resurrect ownership.

      Parameters

      • namespace: string
      • id: string
      • token: string
      • leaseMs: number

      Returns Promise<void>

    • Pausing stops new occurrences, not already accepted runs.

      Parameters

      • namespace: string
      • id: string
      • paused: boolean = true

      Returns Promise<boolean>

    • Tombstone a trigger while preserving identity/revision history.

      Parameters

      • namespace: string
      • id: string

      Returns Promise<boolean>

    • Commit ordered progress within the ownership transaction.

      Parameters

      • namespace: string
      • id: string
      • token: string
      • progress: JsonValue

      Returns Promise<void>