@adhdev/daemon-core 0.9.82-rc.343 → 0.9.82-rc.345

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -323,12 +323,28 @@ export declare class DaemonCommandRouter {
323
323
  * controlbar commands do not — so the controlbar buttons appear to do nothing.
324
324
  *
325
325
  * Mirror the existing node-level remote-forward pattern (fast_forward_mesh_node etc.):
326
- * scan the cached inline-mesh nodes for the one whose active session matches the
327
- * targetSessionId, and return its daemonId when that daemonId is a remote daemon (i.e.
328
- * not this coordinator's own statusInstanceId). Returns undefined for a locally-hosted
329
- * session (no forward — execute locally as before) or when ownership can't be resolved.
326
+ * scan the candidate mesh nodes for the one hosting the targetSessionId, and return its
327
+ * daemonId when that daemonId is a remote daemon (i.e. not this coordinator's own
328
+ * statusInstanceId). Returns undefined for a locally-hosted session (no forward — execute
329
+ * locally as before) or when ownership can't be resolved.
330
+ *
331
+ * The candidate set spans BOTH the cached inline-mesh nodes and the live aggregate
332
+ * mesh-status snapshots. The inline cache reliably carries only each node's single primary
333
+ * session (cachedStatus.activeSession), so a worker hosting more than one session exposes its
334
+ * non-primary sessions only on the aggregate snapshot nodes (status.activeSessions /
335
+ * activeSessionDetails, built from live session records). collectMeshNodeHostedSessionIds does
336
+ * the wider plural-shape scan so a controlbar/modal command targeting a non-primary remote
337
+ * session still resolves its owner — the singular readCachedInlineMeshActiveSessions semantics
338
+ * other consumers depend on stay untouched.
330
339
  */
331
340
  resolveRemoteMeshSessionOwnerDaemonId(sessionId: string): string | undefined;
341
+ /**
342
+ * Candidate nodes for remote-session owner resolution: the cached inline-mesh nodes (which
343
+ * carry each node's primary session) plus the nodes from every cached aggregate mesh-status
344
+ * snapshot (which carry each node's full live session list). getCachedInlineMeshNodes()
345
+ * returns a fresh array, so appending the aggregate nodes never mutates cached state.
346
+ */
347
+ private collectMeshSessionOwnerCandidateNodes;
332
348
  getCachedInlineMesh(meshId: string, inlineMesh?: unknown): any | undefined;
333
349
  private warmInlineMeshCache;
334
350
  private getMeshForCommand;