A task identifier is not a durable result archive
An A2A client submits a synthetic artifact inspection and polls its task identifier later. The server restarts, or the task store discards an older entry, and the client receives task-not-found. A client that interprets every missing task as permission to submit the operation again can duplicate work. Retention and identity are therefore part of the interoperability contract, even when the example server uses an in-memory store.
ADK Python 2.16.0, released on December 3, 2026, changes the default A2A task store used by to_a2a and the A2A-enabled FastAPI application. The release notes describe bounded retention and creator scoping. This guide examines the operational consequences of those defaults. It does not claim that an in-memory task store has become persistent or that configuring an Agent Card automatically authenticates requests.
The original experiment should run against the pinned installed package with synthetic tasks and a controllable clock. It checks storage behavior without contacting a model. The relevant implementation is an internal class, so the probe is a version-specific regression experiment rather than a recommended public extension API. Application configuration should use the documented store injection options.
Understand three independent boundaries
The first boundary is process lifetime. In-memory state disappears when the owning process exits. The second is retention: the new default expires terminal tasks after an hour and caps the store at ten thousand tasks. The third is caller scope: authenticated tasks are associated with their creator, while unauthenticated callers share an anonymous scope. Each boundary can independently prevent a later lookup.
The source implementation uses least-recently-saved ordering for capacity eviction and updates terminal expiry when saving a terminal task. A read is not the same as a save. These details matter for a precise probe, but callers should not depend on undocumented internal behavior as a long-term API contract. Test the pinned version and treat an upgrade as a reason to repeat the retention checks.
None of these boundaries replaces authentication. The application must establish the caller context through a trusted integration. A user name accepted directly from an arbitrary request body is not a verified identity. Similarly, an Agent Card describing security requirements is descriptive metadata; the server must enforce the corresponding request authentication and authorization.
Construct a small capacity experiment
Use a store capacity of two in a version-specific local probe. Save synthetic tasks A and B, read A, then save C. If eviction follows save order, reading A does not refresh its position and A is removed. In a second run, save A again before saving C; now B becomes the older entry. The experiment distinguishes read recency from update recency without allocating ten thousand objects.
Use distinct task identifiers and explicit states. A completed task and an active task may face different expiry behavior, while the capacity bound can still affect stored tasks. Record the exact operations and observed lookups rather than merely printing the store's internal length. The client-visible behavior is whether the expected task can be retrieved.
Do not use this smaller capacity as an undocumented production configuration recommendation. It is a probe of the versioned internal class. The public application route is to supply an explicit task store when the default's retention or sharing semantics do not fit. A custom store must be reviewed for its own persistence, isolation and lifecycle behavior.
Test expiry without waiting an hour
A fake monotonic clock can make expiry tests deterministic. Save a completed task at virtual time zero, advance to just before the retention boundary and verify it remains available. Advance to the boundary and verify the documented experiment's result. Repeat with a nonterminal task to distinguish age-based terminal expiry from capacity eviction.
# Author: Sandeep Belgavi. Clock fixture, not a replacement task store.
class Clock:
def __init__(self):
self.value = 0.0
def __call__(self):
return self.value
def advance(self, seconds):
if seconds < 0:
raise ValueError("monotonic clock cannot move backward")
self.value += seconds
clock = Clock()
clock.advance(3599)
assert clock() < 3600
clock.advance(1)
assert clock() == 3600The fixture avoids fragile sleeps and makes the boundary visible in test output. The actual probe must inject the clock only through the inspected version's constructor and record that it uses a private implementation detail. Do not copy the vendor's implementation into an original example and remove its license. The experiment should call the installed package and keep any quoted source attribution intact.
Verify creator isolation explicitly
Create two authenticated synthetic caller contexts. Save a task as caller A and attempt to read, update and delete it as caller B. Check the resulting store through caller A afterward. A read returning not-found is only one part of the isolation contract; unauthorized mutation attempts must not change the owner's task.
Also test anonymous contexts separately. Shared anonymous scope is not per-browser isolation. Two unauthenticated callers may share the same effective scope, so an application requiring caller separation must establish authentication. Avoid describing an anonymous task identifier as a secret capability unless the application has explicitly designed, protected and tested it as one.
Task identifiers should remain collision-resistant and generated through the application or protocol's supported path. Caller scoping does not justify predictable identifiers, and unpredictable identifiers do not replace authorization. Keep the concepts separate in documentation so clients understand both what they may ask for and why the server allows the lookup.
Make missing-task behavior safe for clients
A missing task can mean expiry, eviction, restart, wrong caller scope or an unknown identifier. The client may not be able to distinguish them from the protocol response alone. Store a separate operation identifier and durable result reference when the operation's consequences require reconciliation. A task store is a transport-facing view, while the operation ledger records whether work actually occurred.
Before resubmitting an inspection with side effects, query the authoritative operation record using an idempotency key. If no authoritative result is available, return an unresolved state rather than silently creating a new operation. For a read-only inspection, a fresh request may be acceptable, but the client should still know it is a new execution with potentially different inputs or results.
Long-polling and delayed clients need a retention agreement. If clients are expected to reconnect after several hours, a one-hour terminal retention default is insufficient. Persist results in a supported store or expose a durable result endpoint with its own policy. Document how long task status remains queryable and what clients should do after that interval.
Migration from the previous default
Inventory applications relying on the implicit in-memory store. Identify cross-user task lookups, long-delayed polling and multiple server replicas. These uses may already be fragile under process-local state even before the new bounds. Make the store choice explicit and test the exact deployment topology rather than assuming a single-process demonstration represents a replicated service.
Run a compatibility test with representative client behavior against both pinned versions. Include a completed task, an active task, a different authenticated caller and a process restart. Record which differences are intentional consequences of the new default. Do not loosen authentication merely to preserve a formerly permissive lookup; redesign the authorized sharing requirement explicitly.
If supplying a database-backed store, follow its lifecycle requirements, including disposal of owned resources. Persistence introduces schema migration, connection management and authorization responsibilities. Replacing an in-memory default is an architectural decision, not a single configuration value that guarantees durability and isolation automatically.
Evidence to retain before release
The local probe passed with google-adk 2.16.0 and a2a-sdk 1.4.0: another caller could not read or delete the owner's task, a read did not prevent capacity eviction, a terminal task expired at the virtual boundary, and an active task remained while capacity was available. The saved result records these assertions and package versions. Include the private-API limitation in the README. This establishes behavior of the pinned package and fixture, not an entire A2A deployment.
The useful change in 2.16.0 is a more constrained default with concrete migration consequences. Applications still need to decide their retention, identity and durable operation contracts. When those choices are explicit, task-not-found becomes a handled state with a recovery path instead of an invitation to guess whether the agent's work happened.