Expand description
AgentMux-object read/update/meta primitives used by the object service
handler, plus the per-agent zoom mirror. update_object_meta and
schedule_agent_zoom_mirror are re-exported crate-wide.
Functions§
- find_
tab_ 🔒for_ layout - Phase E.4 (Option A) — reverse lookup: given a
LayoutState.oid, find theTab.oidthat owns it (i.e., the tab whoselayoutstatefield matches). ReturnsNonewhen the layout is unowned (legacy or partially-migrated row) or the mstore read fails — caller treats either as “skip the reducer dispatch and fall through to the wcore write.” Linear scan over all tabs; acceptable here because the layout-update path is low-frequency relative to drag-resize and the reducer mutex itself is held for sub-millisecond intervals. - get_
object_ 🔒by_ oref - Resolve an “otype:oid” string to the corresponding wave object JSON.
- schedule_
agent_ 🔒zoom_ mirror - Mirror an agent block’s
term:zoominto the per-agentui:zoomcontent blob immediately (no debounce) so the zoom survives pane close even if the user closes the pane right after zooming.zoom = Some(z)upserts;zoom = None(term:zoom reset to null / 1.0) deletes the row so a default agent stores nothing. Writes are off-thread so the WebSocket handler stays non-blocking; SQLite serializes concurrent writes via the store mutex. See SPEC_AGENT_ZOOM_PERSISTENCE §4.3. - update_
object 🔒 - Update a wave object by replacing it wholesale in the store.
The incoming value must have
otypeandoidfields. Matches Go’s ObjectService.UpdateObject behavior. Returns (otype, oid, updated_value_with_new_version) on success. - update_
object_ 🔒meta - Update object meta by oref string. Merges meta into existing object.