Aksara [v0.7.0] — Durable Authorized Operations #29
nagarjuna-tella
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Aksara v0.7 makes authorized backend operations durable.
v0.6 established the rule that AI agents and tools must execute inside the same authentication, tenancy, permission, policy, transaction, and audit boundaries as the rest of the application.
v0.7 extends that model across time and failure.
An operation can now outlive the HTTP request, process, or worker that started it while preserving authoritative state, scoped retry identity, current authorization, fenceable ownership, approval and cancellation intent, and recoverable execution history.
Durable Operations
Aksara now provides a first-class durable execution model built around two concepts:
Operations are stored in PostgreSQL and survive:
The current PostgreSQL Operation row remains authoritative. Attempts and transition records explain execution history without becoming a separate source of truth.
Safe retries and scoped idempotency
Durable submissions can use scoped idempotency.
The identity includes the relevant application, tenant, initiating principal, action/version, client key, and normalized semantic input.
This means:
A lost response is therefore no longer a reason to blindly repeat a mutation.
Clients can reread authoritative Operation state or safely resubmit the same idempotency identity.
Database-time leases and fencing
Each physical claim creates a new Attempt with:
Lease decisions use PostgreSQL time rather than worker clocks.
If Worker A owns fence
N, its lease expires, and Worker B later acquires fenceN+1, Worker A can no longer:The ownership check happens before application SQL inside the protected transaction.
This prevents a stale worker from waking up after replacement and corrupting application state.
Atomic PostgreSQL execution
For supported
postgres_atomicactions, Aksara provides a strong same-database guarantee.The following share one guarded PostgreSQL transaction:
They commit together or roll back together.
This means Aksara does not produce durable state where a supported application mutation committed but the Operation still claims it did not succeed, or vice versa.
The guarantee applies only to supported writes through the owning Aksara
Databaseand guarded execution context.Independent database connections, separate databases, subprocess/thread mutations, direct connection-pool escapes, and external network effects are outside that atomic boundary.
Authorization across time
Durable execution does not freeze authorization at admission time.
Aksara stores non-secret principal provenance, not reusable credentials or permanent authority.
Before supported delayed effects, the framework resolves the current
Principaland checks current:PolicyEnginedecisionsApplication-specific object, permission, field, and model validation continue to belong to the registered action authorization boundary.
If a user loses permission while an Operation is waiting, the old admission decision does not grant permanent access.
Durable approvals
Approval decisions can now survive worker and process loss.
A durable decision is bound to the exact:
Approval records intent.
It does not replace authorization.
If the requester loses permission after approval, execution still fails current authorization.
Durable cancellation
Cancellation is now durable intent.
It can prevent future work when it wins the race against execution, including while an Operation is waiting, ready, delayed, or running.
Cancellation does not:
Completion and cancellation compete through the authoritative Operation row.
Background task integration
Existing Aksara background tasks remain supported.
Tasks can optionally schedule durable Operations, but task state does not become execution authority.
For linked work:
Existing unlinked v0.6 task APIs, IDs, queues, scheduling, and CLI behavior remain compatible.
External effects
Aksara explicitly distinguishes external-effect behavior.
Supported effect classes include semantics for:
Before an external mutation, Aksara can persist durable intent and a stable operation-scoped effect identity.
On recovery:
external_outcome_unknownAksara does not claim exactly-once execution for arbitrary external systems.
PostgreSQL and an external provider do not share one atomic transaction.
Operational history and outbox
Durable Operations include bounded transition evidence and transactional outbox intent.
This supports:
The current Operation row remains authoritative.
Aksara does not turn this into event sourcing or claim that application-owned history is a tamper-resistant compliance ledger.
Retention
Durable state is intentionally bounded.
The framework supports retention and pruning for:
Active work is protected, and idempotency identities remain available for their promised deduplication window.
Compatibility
Durable Operations are additive and opt-in.
Existing applications do not need to:
Existing v0.6 behavior remains in force for:
Principalremains Aksara's runtime authority type.MCP
Existing synchronous Streamable HTTP MCP remains supported.
Protocol-level durable MCP Tasks are not included in v0.7.
The current official MCP Python SDK does not yet implement the
io.modelcontextprotocol/tasksextension, and Aksara does not introduce a competing private wire protocol.Durable Operations are therefore available independently of protocol-level MCP Tasks.
Infrastructure
PostgreSQL remains the only mandatory durable authority.
v0.7 does not add mandatory dependencies on:
What remains experimental or deferred
v0.7 does not stabilize:
DurableStepalso remains an evolving workflow-step cache and does not inherit the new Operation/Attempt guarantees.Validation
The final v0.7.0 release passed:
Doctor completed with no warnings, failures, or blockers.
Ruff and mypy ratchets passed.
Bandit, dependency audit, Gitleaks, Twine, strict documentation, package validation, and CycloneDX SBOM validation also passed.
Upgrade notes
After installing v0.7.0:
aksara migrateusing the migration role.check_durable_operations()for each deployed application/tenant profile.Release artifacts
aksara_framework-0.7.0-py3-none-any.whlSHA-256:
b5ceaafb547bdf095011a2ab10138c5e596a012143dd25ae7b482ff164f7816eaksara_framework-0.7.0.tar.gzSHA-256:
b52895d0b5f4443be6801f43d265d6520544ea1a3012edd1b7dac8d1379e34beAksara v0.7 moves the framework from safe execution inside a single invocation to durable execution across failure and time:
This discussion was created from the release Aksara [v0.7.0] — Durable Authorized Operations.
All reactions