Skip to content

model: line_uuid + downstream_line_uuid on SingBoxNode (design-15) - #7

Merged
lr00rl merged 5 commits into
mainfrom
feat/design-15-line-uuid
Jul 22, 2026
Merged

model: line_uuid + downstream_line_uuid on SingBoxNode (design-15)#7
lr00rl merged 5 commits into
mainfrom
feat/design-15-line-uuid

Conversation

@lr00rl

@lr00rl lr00rl commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Summary

  • SingBoxNode.LineUUID — control-plane line identity (design-15 D1), sourced from the sidecar lattice.singbox-metadata.v2
  • SingBoxNode.DownstreamLineUUID — declared chain edge target (design-15 §6)

Both omitempty: old agents/servers interoperate unchanged; JSON-only contract (no proto mirror for SingBox types).

Verification

  • gofmt clean, go vet ./... clean, go test ./... ok

Consumers (server/agent) pin this branch as a Go pseudo-version until merge. Refs LatticeNet/lattice#2.

lr00rl added 3 commits July 14, 2026 22:14
Spec §9.3 binds a host-risk approval to the exact code and inputs that produced
its plan: plugin id, version, artifact digest, service, method, request hash, and
the full target set. The server had somewhere for only two of those — Plugin and a
singular NodeID — so the rest had to be smuggled into the free-form Plan string and
recovered by hashing it.

Give them real columns. Each is compared to live state at execute time and each is
what the operator's review is accountable for, so each should be a typed field, not
a value parsed back out of a blob. ApprovalView carries them too, so a reviewer sees
what will actually run — which plugin version, which artifact, which nodes.

Every field is omitempty and additive: an approval that is not a plugin operation
(nft, dns, agent update) serializes exactly as before, and NodeID stays the first
target so the per-node approval machinery is unchanged.

Tests: model build + proto contract test green.
Design-15 D1/D4/D6: the agent reads the sing-box sidecar metadata
(lattice.singbox-metadata.v2) and reports the control-plane line identity
plus declared chain edge per inbound. Both fields are omitempty so older
agents and servers interoperate unchanged.
@lr00rl
lr00rl marked this pull request as ready for review July 22, 2026 12:37
@lr00rl
lr00rl merged commit 4a318f2 into main Jul 22, 2026
1 check passed
@lr00rl
lr00rl deleted the feat/design-15-line-uuid branch July 22, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant