Repository navigation
Reach a tenant's clusters from the control plane - #482
Merged
Merged
Conversation
The topology resolved in #480 had no caller: baseUrl and sidesFor were written and tested but nothing used them. This is the layer that does. A side that fails does not fail the call. An operator asking what a tenant holds needs to know which cluster is unwell, and the healthy side's answer is still worth having - so each side comes back with either a body or its reason, in a stable order however slow either was. The cause is surfaced next to the message, since that is where the reason a connection failed actually lives. The caller's Authorization and Actor-ROLE travel with the request: the cluster should see who is asking, not who is relaying. GET /control/tenants/{tenant}/datastore/tables proves it end to end. Nothing mutates yet. Part of #370 Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
This was referenced Aug 6, 2026
The topology examples and test fixtures used kc and talk, which name real products. Nothing depends on the values, so they become alpha and beta. Unrelated: the kc.graph.* config prefix stays as it is. That one is load-bearing and renaming it would break every existing deployment's config.
Contributor
Author
|
Optimistic |
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.
Summary
#480 resolved a tenant's clusters into a
Topologyand then stopped:baseUrl(tenant, side)andsidesFor(tenant, fanout)were written and tested with nothing calling them. This is the layer that calls them.ClusterClientreaches the clusters of one tenant and returns one entry per side. A failing side does not fail the call. An operator asking what a tenant holds needs to know which cluster is unwell, and the healthy side's answer is still worth having — so each side comes back with either a body or its reason, in a stable order however slow either was. The cause is surfaced next to the message, because that is where the reason a connection failed actually lives.The caller's
AuthorizationandActor-ROLEtravel with the request: the cluster should see who is asking, not who is relaying.Nothing mutates yet. Per the roadmap in #370, destructive execution lands after authorization.
Changes
ClusterClientandSideResponseunderserver/control/clusteractionbase.control.request-timeout(default 10s) — how long one cluster may take before its side is reported as failedGET /control/tenants/{tenant}/datastore/tables?fanout=true, merging each side's table listingHow to Test
There is no stub-server dependency in this repo and this PR does not add one: the unit tests substitute an exchange function for the clusters, so nothing binds a port. Covered there: per-side ordering, fanout on and off, a failing side not hiding a healthy one, a non-2xx side reporting its status, the timeout, and header forwarding.
ControlDatastoreE2ETestpoints the topology at a closed port, which is the interesting case over http — an unreachable cluster must be reported as that side failing with a 200 overall, not as the request failing.Notes
A
CONTROLinstance refuses/graph/v2,/graph/v3and/queue/v1on itself, so it cannot be its own data plane. That rules out the tempting shortcut of pointing a test'sactive-urlat its own port.AI Assistance