Skip to content

feat: wire SolutionServer into agents.Serve (#290) - #291

Merged
antoinetoussaint-byte merged 2 commits into
issue-287-new-agent-kind-codefly-solution-registry-entry-protofrom
issue-290-solution-wire-solutionserver-into-agents-serve-so-the
Aug 16, 2026
Merged

feat: wire SolutionServer into agents.Serve (#290)#291
antoinetoussaint-byte merged 2 commits into
issue-287-new-agent-kind-codefly-solution-registry-entry-protofrom
issue-290-solution-wire-solutionserver-into-agents-serve-so-the

Conversation

@antoinetoussaint-byte

Copy link
Copy Markdown
Contributor

Closes#290.

Stacked on #288 (the codefly:solution contract from #287) — the base is issue-287-… and GitHub will retarget to main once #288 merges. The last commit here is the #290 change; the earlier commits belong to #287.

Summary

  • A solution plugin had no way to expose its generated gRPC contract through the standard agents.Serve() startup path — PluginRegistration lacked a Solution field and Serve() never registered one, unlike Provider and the other capabilities.
  • Adds Solution solutionv0.SolutionServer to PluginRegistration and registers it during startup, unblocking a solution binary serving its contract (obin-ai/lodestar#17).
  • Extracts the unconditional server registrations into a registerServices helper so the registration path is unit-testable without booting the blocking Serve(); the env-dependent Toolbox/PDP path stays in Serve.

Test plan

  • go test ./agents/ passes.
  • TestRegisterServices_RegistersSolutionWhenSet asserts the Solution service appears in grpc.Server.GetServiceInfo() when set.
  • TestRegisterServices_SkipsSolutionWhenNil asserts it is absent when unset.
  • go vet ./agents/ clean.

🤖 Generated with Claude Code

Add a Solution field to PluginRegistration and register it during agent
startup, so a solution plugin can expose its gRPC contract through the
standard Serve() path alongside Provider and the other capabilities.
Extract the unconditional server registrations into a testable
registerServices helper and cover Solution registration with a test.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The prior test asserted a private registerServices helper via
GetServiceInfo, so it could not catch a regression that stopped Serve
from calling the registration (both tests passed against the helper, not
against Serve). The helper existed only to enable that weaker test.
Register Solution inline in Serve exactly like Provider (dropping the
helper), and replace the unit test with a real spawn test: it builds a
testdata solution agent, starts it through Serve, dials over gRPC, and
asserts a Solution RPC routes to the fixture handler. Removing the
registration in Serve now surfaces as an Unimplemented "unknown service"
error — verified by temporarily deleting the registration. No mocks; the
test drives the actual Serve path.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@antoinetoussaint-byte
antoinetoussaint-byte merged commit 80641fd into issue-287-new-agent-kind-codefly-solution-registry-entry-protoAug 16, 2026
Sign up for freeto 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

@antoinetoussaint-byte