Skip to content

docs(client): add architecture document#5938

Open
eriknordmark wants to merge 1 commit into
lf-edge:masterfrom
eriknordmark:client-architecture-doc
Open

docs(client): add architecture document#5938
eriknordmark wants to merge 1 commit into
lf-edge:masterfrom
eriknordmark:client-architecture-doc

Conversation

@eriknordmark
Copy link
Copy Markdown
Contributor

@eriknordmark eriknordmark commented May 11, 2026

Description

I've read this architecture document and asked claude to fix and add a few things. Ready for broader review and merge.


Adds pkg/pillar/docs/client.md describing the zedclient onboarding
microservice. The document covers:

  • responsibilities and how zedclient differs from the rest of pillar
    (one-shot binary, not part of zedbox long-running group);
  • the controller endpoints used (/certs, /register, /uuid) and the
    device-side LED-state mapping per HTTP status code;
  • pubsub inputs (ConfigItemValueMap, DeviceNetworkStatus,
    CachedResolvedIPs, the synchronous EvalStatus gate) and outputs
    (OnboardingStatus, MetricsMap);
  • persistent artefacts written under /persist/ (status/uuid,
    status/hardwaremodel, checkpoint/controllercerts);
  • the single retry-loop control flow, including the 5-second
    already-onboarded fast path and the SenderStatusCertMiss re-fetch
    trigger;
  • debugging — pubsub commands, log grep patterns, and how to force
    each path during development.

The document is structured to mirror the existing nim.md,
nodeagent.md and baseosmgr.md so the pillar docs remain consistent
across microservices and can serve both as developer-onboarding
material and as a basis for functional test coverage.

Dependencies

The doc describes the post-refactor cmd/client; it should land after
the following PRs in this order:

How to test and validate this PR

Docs-only change. Read pkg/pillar/docs/client.md; verify it matches
the behaviour in pkg/pillar/cmd/client/{client.go,parseuuid.go} and
the boot-time invocation in pkg/pillar/scripts/device-steps.sh.

Changelog notes

No user-facing changes.

PR Backports

  • 16.0-stable: No, docs-only change for master.
  • 14.5-stable: No, docs-only change for master.
  • 13.4-stable: No, docs-only change for master.

Checklist

  • I've provided a proper description
  • I've added the proper documentation
  • I've tested my PR on amd64 device — N/A, docs-only
  • I've tested my PR on arm64 device — N/A, docs-only
  • I've written the test verification instructions
  • I've set the proper labels to this PR

@eriknordmark eriknordmark force-pushed the client-architecture-doc branch from 44f5eb0 to 6b211a3 Compare May 15, 2026 20:58
Documents the zedclient onboarding microservice: responsibilities and
its place in pillar (one-shot binary, distinct from the long-running
zedbox group), the controller endpoints used (/certs, /register,
/uuid) and the LED-state mapping per HTTP status, pubsub inputs
(ConfigItemValueMap, DeviceNetworkStatus, CachedResolvedIPs, and the
synchronous EvalStatus gate) and outputs (OnboardingStatus,
MetricsMap), persistent artefacts under /persist/, the single
retry-loop control flow including the SenderStatusCertMiss re-fetch
trigger, a dedicated section on the 5-second already-onboarded fast
path (pre-conditions, silent behaviour, and how to disable it), and
a debugging section with the pubsub paths, log grep patterns, a
connectivity smoke check, and how each control-flow branch is
exercised in development.

Structure mirrors nim.md, nodeagent.md, and baseosmgr.md so the
pillar docs stay consistent across microservices.

Signed-off-by: eriknordmark <erik@zededa.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@eriknordmark eriknordmark force-pushed the client-architecture-doc branch from 6b211a3 to 67232e4 Compare May 19, 2026 14:00
@eriknordmark eriknordmark marked this pull request as ready for review May 19, 2026 14:06
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