Skip to content

feat(vesseld): daemon binary v0.1.0#62

Merged
lIang70 merged 4 commits into
mainfrom
feat/vesseld-v0.1.0
May 7, 2026
Merged

feat(vesseld): daemon binary v0.1.0#62
lIang70 merged 4 commits into
mainfrom
feat/vesseld-v0.1.0

Conversation

@lIang70

@lIang70 lIang70 commented May 7, 2026

Copy link
Copy Markdown
Collaborator

Summary

Second slice of vessel v0.1.0 — the vesseld control plane that hosts vessels in a long-running daemon. Module is cmd/vesseld/ (own go.mod, ~58 files, ~7.8k LOC).

Pinned dependencies (no replace directives):

Module Version
sdk v0.2.7
sdkx v0.2.5
vessel v0.1.0-rc.1 (PR #61)

Scope

  • apispec/v1alpha1 — YAML schema for Daemon / LLMProfile / HistoryStore / Vessel / Agent
  • loader / resolver / catalog / fleet / api / cli / runtime
  • Built-in graph-llm engine emits full engine.run.> lifecycle envelopes
  • HTTP API: /healthz, /readyz, /metrics (Prometheus), /v1/{plan,vessels,runs}, SSE log stream
  • auth.token via TCP, Unix-socket file-mode auth
  • Fleet: in-memory paginated ListRuns, Snapshot() for metrics, daemon-wide concurrency gate, per-LLMProfile rate limiters

Release strategy

cmd/vesseld is a daemon binary, not a library — it does NOT participate in the Go-module auto-tag flow. Releases ship as GitHub Release artifacts via .github/workflows/release-vesseld.yml, triggered on vesseld/v* tag push:

  • Cross-builds: linux/{amd64,arm64}, darwin/{amd64,arm64}, windows/amd64
  • Each binary tarballed (zip on Windows) with a SHA-256 sidecar
  • Auto-generated release notes from PRs since the last vesseld/* tag
  • SemVer pre-release suffixes (e.g. v0.1.0-rc.1) auto-marked --prerelease

CI

  • New test-vesseld matrix job (Go 1.25 + 1.26, -race)
  • lint / post-merge build extended to vesseld
  • auto-tag.yml intentionally excludes cmd/vesseld

Test plan

  • go vet ./... in cmd/vesseld/
  • go test -race -count=1 ./... in cmd/vesseld/
  • GOWORK=off go build ./... in cmd/vesseld/
  • gofmt -l cmd/vesseld empty
  • CI green

Out of scope

  • PR-3 test(vesseld): e2e black-box suite — chained on this PR
  • PR-4 chore: examples + Makefile

Notes

  • [skip-tag:sdk] because no sdk files touched.
  • After merge: git tag vesseld/v0.1.0-rc.1 && git push origin vesseld/v0.1.0-rc.1 triggers the release workflow.

lIang70 added a commit that referenced this pull request May 7, 2026
Two flakes caught by Go 1.26 -race CI on PR #62:

- cmd/vesseld/api: TestAPI_Metrics_TextExposition raced the run
  registry's terminal-state goroutine. /call returns when the
  Handle's Wait resolves, but CompletedAt is set by a separate
  goroutine watching h.Done(). Poll /metrics for the completed
  counter rather than asserting on a single shot.

- vessel: TestProbe_RestartOnFailure tried to catch the transient
  PhaseFailed window with 5ms polling, which the race-detector
  scheduler can skip past. Switch to checking the persistent
  c.restartAttempts counter (resets only after stableWindow=30s)
  combined with PhaseRunning — the restart counter is the durable
  artefact of the failure→recovery cycle.

Co-authored-by: Cursor <cursoragent@cursor.com>
lIang70 and others added 3 commits May 7, 2026 15:41
The vesseld control plane: declarative YAML config (apispec
v1alpha1), engine/probe/tool/LLM-provider catalog, multi-vessel
fleet, HTTP API over Unix socket + optional TCP+bearer-token,
SSE log stream, Prometheus /metrics, paged /v1/runs, and a
mock-OpenAI-friendly graph-llm engine that emits full
engine.run.> lifecycle envelopes.

Module pins:
  - sdk      v0.2.7
  - sdkx     v0.2.5
  - vessel   v0.1.0-rc.1   (PR #61)

Conventions follow the rest of the repo: no replace directives,
go.sum committed, GOWORK=off-friendly. CI gains a test-vesseld
job and the auto-tag workflow now patch-bumps cmd/vesseld
once a seed tag exists.

The e2e black-box suite + the multi-vessel example land in
follow-up PRs.

[skip-tag:sdk]

Co-authored-by: Cursor <cursoragent@cursor.com>
Two flakes caught by Go 1.26 -race CI on PR #62:

- cmd/vesseld/api: TestAPI_Metrics_TextExposition raced the run
  registry's terminal-state goroutine. /call returns when the
  Handle's Wait resolves, but CompletedAt is set by a separate
  goroutine watching h.Done(). Poll /metrics for the completed
  counter rather than asserting on a single shot.

- vessel: TestProbe_RestartOnFailure tried to catch the transient
  PhaseFailed window with 5ms polling, which the race-detector
  scheduler can skip past. Switch to checking the persistent
  c.restartAttempts counter (resets only after stableWindow=30s)
  combined with PhaseRunning — the restart counter is the durable
  artefact of the failure→recovery cycle.

Co-authored-by: Cursor <cursoragent@cursor.com>
Bumps vessel to v0.1.0-rc.2 and migrates Fleet's two <-h.Done()
watcher goroutines to the new synchronous OnTerminate hook
(vessel#63):

  - runRegistry.track: removes its private goroutine; the
    OnTerminate hook updates CompletedAt / Status / Messages /
    Err inside the captain's dispatch goroutine, BEFORE Done is
    closed. Fixes the /call→/metrics race that PR-2's first CI
    pass papered over with poll-until-ready.
  - Fleet.Submit: gate-release watcher likewise replaced with
    an OnTerminate hook. One fewer goroutine per Submit.
  - noopCtx helper deleted — the registry no longer calls
    Handle.Wait, so it doesn't need a synthetic never-cancelling
    context.

Reverts the test-side polling hack in TestAPI_Metrics_TextExposition
because the OnTerminate ordering contract now guarantees the
counter is populated by the time /call returns.

Co-authored-by: Cursor <cursoragent@cursor.com>
@lIang70
lIang70 force-pushed the feat/vesseld-v0.1.0 branch from 3d02886 to 7f06811 Compare May 7, 2026 07:43
Co-authored-by: Cursor <cursoragent@cursor.com>
@lIang70
lIang70 merged commit 31b0cae into main May 7, 2026
13 checks passed
@lIang70
lIang70 deleted the feat/vesseld-v0.1.0 branch May 7, 2026 07:49
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