Repository navigation
feat: Connect face beside gRPC, and core bindings - #108
Merged
Merged
Conversation
…rest endpoint found" The generic Python builder reports a failed load in the response's state and returns a nil error. Load checked only the error, went on to look for a REST endpoint in a service it had not loaded, and replaced the real cause (a refused interface binding, a missing service file, no identity) with "no rest endpoint found". It now stops on an ERROR state and hands that response back. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
core v0.19.6 refuses a service's `- interface:` dependency when no unit in
scope implements it ("no provider in scope satisfies it"), so Load fails for a
Python service that declares codefly.dev/authority@0.1.0. On the branch head an
unimplemented interface stays unbound (72084f3f), the host hands the agent its
composition's binding through ServiceIdentity.interface_bindings (4ab16f55),
a module contract binding may be optional (a3bf508a), and the Python proto
facade keeps map_entry (54a028aa).
A pseudo-version of an unmerged core branch: the pin moves to a core release
before this branch is proposed.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A module's one face is Connect-family: Connect and gRPC-Web for a browser behind an L7 hop, gRPC for services. go-grpc serves it; a Python service could serve gRPC only, so a browser could not reach it through the edge. `connect-endpoint: true` (with grpc-server) now: - makes sync write code/src/rpc/connect_gen.py, byte for byte from templates/connect/connect_gen.py. The face reads the methods it serves from the descriptors the service's bindings register, transcodes Connect (unary and server streams, proto and JSON) and gRPC-Web onto the service's own grpc.aio server, and relays gRPC (HTTP/2 prior knowledge) to it on the same port, so every interceptor runs on every protocol and no second copy of the API exists. Bodies are bounded before they are read; reads are timed. - makes the runtime find the `api: connect` endpoint and hand the process its port as CODEFLY_CONNECT_PORT (docker port mapped too); - renders the connect container and Service ports (8081, appProtocol http: Connect is HTTP/1.1 there). Refused without grpc-server: the face serves that server's API, none of its own. Tests: testdata/connect (12 cases against a real grpc.aio server, run by TestConnectFaceServesEveryProtocol through uv), settings, sync, deployment. Version 0.0.121. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The builder loaded the spec through the generic Python Load, which decodes it into the generic half of the settings only. grpc-server and connect-endpoint were therefore false on every loaded (not just created) service: `codefly sync service` generated no gRPC server stubs and wrote no Connect face, and Deploy rendered neither the gRPC nor the Connect port. The runtime already loaded the full settings, which is why a local run still served gRPC. Load now calls the generic LoadService with this agent's Settings. TestBuilderLoadReadsTheAgentsSettings fails without it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds connect-endpoint: Connect (unary and server streams, binary and JSON) and gRPC-Web, transcoded onto the service's own gRPC server on one port, with every interceptor applied. Fixes loaded services ignoring grpc-server and connect-endpoint. Version 0.0.121.
This is part of moving the platform from saas permissions to the host authority interface: one interface, implemented by saas accounts and by the local authority. Core #835 (merged) is the base. Land in dependency order: core → cli → agents → authority → saas → modules → solution runtime → core-solutions → platform-obin.
Merge with a merge commit, never a squash. Other repos pin this branch's commits by SHA.
Every call goes through a Codefly-generated client on one Connect face behind the authority hop.
🤖 Generated with Claude Code