G §683: a start composes the modules whose kept want and entry it holds before its other inputs are read

The node's own record comes from the node-engine's statement of itself, taken in memory with no bus.

Builds: design 47 G A-117, A-120, §683, A-95
Claude-Session: https://claude.ai/code/session_01NcbgfGKaxw984XyAPfLm4h
This commit is contained in:
2026-11-12 01:12:06 +01:00
parent 054ca5a6b3
commit c6df8fa20f
4 changed files with 127 additions and 2 deletions
+17
View File
@@ -183,6 +183,10 @@ func (q *Session) SayFacts(ctx context.Context, r Report) bool {
bus := q.bus
q.mu.Unlock()
if bus == nil {
// With no link open the facts are still taken in memory, so the node's own record is known to what composes before the
// bus is read (design 47 G A-120); nothing is written.
r.Node = q.Membership.Node
q.noteApply(r)
return false
}
r.Node = q.Membership.Node
@@ -196,6 +200,19 @@ func (q *Session) SayFacts(ctx context.Context, r Report) bool {
return true
}
// OwnRecord is the record of this node the node-engine states of itself (tunnel key, sealing key, capabilities), from the facts it
// last took, held in memory (design 47 G A-120); false before any.
func (q *Session) OwnRecord() (nodeengine.NodeRecord, bool) {
q.init()
s := &q.haves
s.mu.Lock()
defer s.mu.Unlock()
if s.node == nil || s.node.Record == nil {
return nodeengine.NodeRecord{}, false
}
return *s.node.Record, true
}
// FactsAsked is the mesh asking this node to say its facts again: run on the link open now.
func (q *Session) FactsAsked(ctx context.Context) {
q.init()