gchandler: who is calling gc is what the server kept of the start #70
Loading…
Reference in a new issue
No description provided.
Delete branch "gc-identity-from-start"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The handler sets the eleven identity variables from what the server kept of the session's start, not from the request.
session.IdentityEnvis the list (it replaces the handler's own).Where each comes from (the registry's marks of the session, written by
operate.setMarksfrom the start config's environment):GC_SESSION_ID,GC_RUNTIME_EPOCH,GC_INSTANCE_TOKEN: marks gc keeps current. At the pinned revision gc writes them only instampAdoptedRuntime(the adoption barrier,SetMeta), when it adopts a running session that has none; they arrive asset-metaand the handler reads them at each call, so they are not stale.GC_AGENT,GC_ALIAS,GC_SESSION_NAME,GC_TEMPLATE,GC_SESSION_ORIGIN,GC_CONTINUATION_EPOCH,GC_PROVIDER,GC_STARTUP_PROMPT_DELIVERED: fixed by the start. gc does not write them after it (noSetMetafor them in the source); a new start clears the marks and records its own.Not taken from anywhere:
GC_HOOK_DEADLINE(a call's own, in gc's list of session-scoped variables),BEADS_ACTOR,BEADS_HOLDER_TOKENandCLAUDE_CODE_SESSION_ID(also in that list; the stand-in sends onlyGC_*, so bd's actor attribution through the stand-in is not this change's to settle).A session started before this release has no record (a marker mark says one was made); for it the request's identity is taken as before, until it starts again. A record the server cannot read fails the call.
Tests: the record wins over a request that claims another identity and the request adds nothing the record lacks; the fallback for a session with no record; a read error; the registry's record, with the epoch moving as gc stamps it; the start records it.