Skip to content

v3.13.0

Choose a tag to compare

@github-actions github-actions released this 25 Jul 19:48
· 143 commits to main since this release
6851c3c

Resource/credential leasing ships in this release as a beta feature. The interfaces below are
stable enough for evaluation and feedback, but the capability is deliberately v1-scoped —
multi-holder admission (maxHolders > 1), budget counting, and phase-scoped leases are designed-for
but deferred, and details may evolve based on real-world usage. Deployments that declare no
resources: see zero behavior change.

Added

  • Resource leasing (beta). Work items can now declare exclusive or advisory access to shared resources
    (a staging slot, a test database, a deploy credential, a fleet-wide deployment mutex) via a new
    resources: dimension on trait definitions, enforced as a gate inside advance_item at WORK
    entry (start and resume) — no new MCP tool, no explicit acquire/release verb. exclusive
    resources take a TTL-bounded lease (default 3600s, max 86400s); contention rejects with a
    transient resource_unavailable error (MCP) or 409 + Retry-After (REST), disclosing the
    contended keys only, never the current holder. advisory resources are audit-only. Lease
    acquisition retries up to 5 times (40ms delay) on SQLITE_BUSY/SQLITE_LOCKED contention before
    falling through to a transient DB-error response, so a losing writer in a genuine cross-connection
    race gets a clean re-evaluation instead of a spurious failure.
  • credentialRefs audit field (beta). advance_item transitions accept an optional credentialRefs
    array of opaque credential/resource labels (never secret values), persisted to
    role_transitions.consumed_credentials and surfaced read-only via RoleTransitionDto.consumedCredentials.
    Once an item declares resources:, the field becomes a closed set validated against the
    declared/registered keys, and declared keys are auto-recorded on work entry.
  • Resource-lease read/recovery surfaces. get_context(itemId=...) item mode gains a
    resourceLeases block (mirroring claimDetail). New REST routes GET /api/v1/resources/leases
    (list active leases; holder actor identity ADMIN-only) and
    DELETE /api/v1/resources/leases/{key} (ADMIN-only force-release — the operator recovery path for
    a crashed holder, without waiting out the TTL or disabling enforcement server-wide).
  • Enforcement matrix and kill switch. Both MCP and REST enforce the resource-lease gate by
    default; REST additionally accepts an ADMIN-only overrideResourceLeases request flag (403 for
    non-admin callers who set it, WARN-logged when used). New RESOURCE_LEASES_ENFORCED env var
    (default true) is a deployment-wide kill switch, read per advance call rather than once at
    startup. CORS_EXPOSE_HEADERS now defaults to include Retry-After.
  • Lease-interval history (beta, audit log). New append-only resource_lease_history table records one
    row per lease hold interval — answering "who held resource R at time T" after a lease has already
    been released, stolen, or force-released. Every acquire/refresh/release/steal/force-release write
    is mirrored into history in the same transaction as the live-row write; ResourceLeaseRepository
    gains findHoldersAt / findRecentIntervals, and forceReleaseByKey gains an optional actorId
    parameter recorded on the closed interval. New REST route
    GET /api/v1/resources/leases/history?key=&at=&limit= (holder/closer actor identity ADMIN-only,
    at optional ISO-8601 instant, 400 on an unparseable value, limit default 100 max 500). No
    pruning/retention in v1 — append-only, cardinality tracks lease events.

Changed

  • Every exit from the work phase — primary transitions, cascades, and complete_tree — now releases
    the item's resource leases automatically; TTL expiry remains the crash backstop.
  • Bumped plugin version to 3.5.2 — skills and hooks distinguish transient lease contention from
    note-gate blocks (schema-workflow, dependency-manager, status-progression, the dispatched-agent
    context, both orchestrator output styles), /manage-schemas recognizes and preserves the
    resources: config section, and /configure-server documents the RESOURCE_LEASES_ENFORCED
    kill switch.
  • Documented the one item = one concurrent actor modelling assumption (from beta field
    feedback): item-keyed exclusivity arbitrates between items, not between actors sharing one item —
    cut items at actor granularity; claim_item is the opt-in enforcement. Stated in the
    workflow-guide guarantees section and fleet capacity planning.

Fixed

  • Lease-interval history could report two simultaneous holders for one key (beta field report): a
    re-take of a previously-held key after an intervening expired holder left that holder's interval
    open, and a late release then stamped it closed at "now". Stale holder intervals now close on
    every acquire path, and history closes are clamped to the interval's own expiry with a truthful
    expired reason. Live-lease exclusivity was never affected — audit-view accuracy only.