René's URL Explorer Experiment


Title: feat(server): TenantRegistry → serve() adapter — as_platform() or callable platform arg · Issue #645 · adcontextprotocol/adcp-client-python · GitHub

Open Graph Title: feat(server): TenantRegistry → serve() adapter — as_platform() or callable platform arg · Issue #645 · adcontextprotocol/adcp-client-python

X Title: feat(server): TenantRegistry → serve() adapter — as_platform() or callable platform arg · Issue #645 · adcontextprotocol/adcp-client-python

Description: Problem TenantRegistry (5.0, #619) gives adopters a great health-tracked, lazy-factory tenant registry. But there's no way to feed it to serve() without writing a per-request adapter: serve(platform: DecisioningPlatform, ...) — takes a s...

Open Graph Description: Problem TenantRegistry (5.0, #619) gives adopters a great health-tracked, lazy-factory tenant registry. But there's no way to feed it to serve() without writing a per-request adapter: serve(platfor...

X Description: Problem TenantRegistry (5.0, #619) gives adopters a great health-tracked, lazy-factory tenant registry. But there's no way to feed it to serve() without writing a per-request adapter: serve(pla...

Opengraph URL: https://github.com/adcontextprotocol/adcp-client-python/issues/645

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"feat(server): TenantRegistry → serve() adapter — as_platform() or callable platform arg","articleBody":"## Problem\n\n`TenantRegistry` (5.0, #619) gives adopters a great health-tracked, lazy-factory tenant registry. But there's no way to feed it to `serve()` without writing a per-request adapter:\n\n- `serve(platform: DecisioningPlatform, ...)` — takes a single platform object\n- `TenantRegistry.resolve(host) -> TenantResolution` — returns a typed resolution with `.platform`, `.health`, `.tenant_id`\n\nThe bridge is missing. Adopters who want to compose the two have three options today:\n\n1. **Write a `DecisioningPlatform` subclass** that holds a registry reference and overrides every method to delegate via `registry.resolve(current_host()).platform` — duplicating what `LazyPlatformRouter` already does, plus the health-gating logic.\n2. **Skip the registry**, keep using `LazyPlatformRouter` — loses the health-state observability that's the registry's headline feature.\n3. **Don't adopt 5.0's TenantRegistry**, stay on `LazyPlatformRouter` indefinitely — works but punts the parity goal.\n\nWe hit this in [bokelley/salesagent](https://github.com/bokelley/salesagent) (Sprint 3 of our 5.0 migration) and chose option 2. The deferral note in our migration tracker:\n\n> SDK 5.0 ships TenantRegistry but `serve()` takes a `DecisioningPlatform` not a callable, and `TenantRegistry.resolve(host)` returns a `TenantResolution`, not a platform-conformant object. Adopting would require writing a `DecisioningPlatform` wrapper that delegates `registry.resolve(host).platform` per-request — duplicating `LazyPlatformRouter`'s purpose. Net cost > benefit until SDK ships a `TenantRegistry.as_platform()` adapter or `serve()` accepts a callable.\n\n## JS reference\n\nThe JS `@adcp/sdk` pattern composes naturally because `serve()` takes a resolver callback:\n\n```ts\nserve(ctx => registry.resolveByHost(ctx.host).server, { port })\n```\n\nPython's `serve()` doesn't have an equivalent callback shape, so the same composition needs an explicit adapter on the registry side.\n\n## Proposed shapes (in increasing order of API surface)\n\n**A) `TenantRegistry.as_platform()` — returns a DecisioningPlatform that resolves per-call.**\n\n```python\nregistry = TenantRegistry(validator=None)\nfor tenant in load_tenants():\n    await registry.register_lazy(tenant.id, agent_url=..., factory=...)\n\n# Returns a DecisioningPlatform that dispatches each method via\n# registry.resolve(current_host).platform.\u003cmethod>(...). 503s when\n# resolution returns None or health in {\"pending\", \"disabled\"}.\nserve(registry.as_platform(), port=os.environ[\"PORT\"])\n```\n\nCloses the gap with one new public method. The platform proxy holds a registry reference and forwards each `DecisioningPlatform` method through the resolver. Health gating happens inside the proxy — 503 on `pending` / `disabled`, serve on `healthy` / `unverified`.\n\n**B) `serve(platform_resolver=Callable[[RequestContext], DecisioningPlatform], ...)`** — accept a callable as an alternative to a static platform.\n\n```python\ndef resolve(ctx):\n    resolution = registry.resolve_by_host(ctx.host)\n    if resolution is None or resolution.health in (\"pending\", \"disabled\"):\n        raise HTTPException(503)\n    return resolution.platform\n\nserve(platform_resolver=resolve, port=...)\n```\n\nMore flexible but more public-API surface. Matches JS more closely.\n\n**C) Both** — `as_platform()` as the easy default + `platform_resolver=` as the escape hatch for adopters with custom health logic.\n\nI'd prefer (A) for our use case: less surface, the health-gating is the headline benefit of TenantRegistry and bundling it into the adapter avoids per-adopter divergence. (B) would address the same case but requires every adopter to reimplement the gating logic.\n\n## Why this blocks adoption (not just an ergonomic gap)\n\nWithout an adapter, the only way to surface TenantRegistry's health states (pending / healthy / unverified / disabled) is to write the gating proxy ourselves — and that proxy IS the integration point with `serve()`. So it's not \"TenantRegistry is hard to compose with serve\" — it's \"TenantRegistry doesn't actually integrate with serve until adopters write the missing piece.\"\n\nThree adopters into the migration this will surface as the same question every time. Filing now to make the fix happen at the SDK layer where the registry already lives.\n\n## Files\n\n- Our deferral analysis: [bokelley/salesagent core/SDK_FEEDBACK.md](https://github.com/bokelley/salesagent/blob/main/core/SDK_FEEDBACK.md) (Sprint 3 entry).\n- Closed parity issue: #619.\n","author":{"url":"https://github.com/bokelley","@type":"Person","name":"bokelley"},"datePublished":"2026-05-11T06:15:28Z","url":"https://github.com/adcontextprotocol/adcp-client-python/issues/645"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:8c6ff3ab-76ba-d840-eb5b-3e01b2c69a05
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idBA58:172B92:2114472:2C0FAB5:6B0184AC
html-safe-noncebb62bb4d7ad183d559e7423c434d52174387f8d8e7cfd07b6937dbb414d68cf2
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCQTU4OjE3MkI5MjoyMTE0NDcyOjJDMEZBQjU6NkIwMTg0QUMiLCJ2aXNpdG9yX2lkIjoiNzEzMTY0ODY0MTA4ODk4MDE0MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac6daa349bf0720e211653ab97afc871eb65c59184fb7444b89085cbaf480e4168
hovercard-subject-tagissue:4418488759
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/adcontextprotocol/adcp-client-python/645/issue_layout
twitter:imagehttps://opengraph.githubassets.com/5dc052f6eb05e22565d45c288e1765739abe071495e15d3bfc42b17688368a74/adcontextprotocol/adcp-client-python/issues/645
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/5dc052f6eb05e22565d45c288e1765739abe071495e15d3bfc42b17688368a74/adcontextprotocol/adcp-client-python/issues/645
og:image:altProblem TenantRegistry (5.0, #619) gives adopters a great health-tracked, lazy-factory tenant registry. But there's no way to feed it to serve() without writing a per-request adapter: serve(platfor...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamebokelley
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/adcontextprotocol/adcp-client-python git https://github.com/adcontextprotocol/adcp-client-python.git
octolytics-dimension-user_id221690821
octolytics-dimension-user_loginadcontextprotocol
octolytics-dimension-repository_id1090305973
octolytics-dimension-repository_nwoadcontextprotocol/adcp-client-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1090305973
octolytics-dimension-repository_network_root_nwoadcontextprotocol/adcp-client-python
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/adcontextprotocol/adcp-client-python/issues/645#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fadcontextprotocol%2Fadcp-client-python%2Fissues%2F645
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fadcontextprotocol%2Fadcp-client-python%2Fissues%2F645
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=adcontextprotocol%2Fadcp-client-python
Reloadhttps://github.com/adcontextprotocol/adcp-client-python/issues/645
Reloadhttps://github.com/adcontextprotocol/adcp-client-python/issues/645
Reloadhttps://github.com/adcontextprotocol/adcp-client-python/issues/645
adcontextprotocolhttps://github.com/adcontextprotocol
adcp-client-pythonhttps://github.com/adcontextprotocol/adcp-client-python
Codehttps://github.com/adcontextprotocol/adcp-client-python
Issues44 (44)https://github.com/adcontextprotocol/adcp-client-python/issues
Pull requests13 (13)https://github.com/adcontextprotocol/adcp-client-python/pulls
Actionshttps://github.com/adcontextprotocol/adcp-client-python/actions
Projectshttps://github.com/adcontextprotocol/adcp-client-python/projects
Security and qualityhttps://github.com/adcontextprotocol/adcp-client-python/security
Insightshttps://github.com/adcontextprotocol/adcp-client-python/insights
https://github.com/adcontextprotocol/adcp-client-python
New issuehttps://github.com/login?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/645
New issuehttps://github.com/login?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/645
#649https://github.com/adcontextprotocol/adcp-client-python/pull/649
feat(server): TenantRegistry → serve() adapter — as_platform() or callable platform arghttps://github.com/adcontextprotocol/adcp-client-python/issues/645#top
#649https://github.com/adcontextprotocol/adcp-client-python/pull/649
claude-triagedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaged%22
https://github.com/bokelley
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#issue-4418488759
#619https://github.com/adcontextprotocol/adcp-client-python/issues/619
bokelley/salesagenthttps://github.com/bokelley/salesagent
bokelley/salesagent core/SDK_FEEDBACK.mdhttps://github.com/bokelley/salesagent/blob/main/core/SDK_FEEDBACK.md
feat(server): TenantRegistry parity with JS createTenantRegistry #619https://github.com/adcontextprotocol/adcp-client-python/issues/619
bokelleyhttps://github.com/bokelley
claude-triagingTriage routine is actively working on this issue (1-3 min)https://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaging%22
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#event-25368133305
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#event-25369069833
feat(server): TenantRegistry.as_platform() adapter for serve() integr…https://github.com/adcontextprotocol/adcp-client-python/commit/ffaa890dbdf60f988216cf1ca2596251bf541c37
https://docs.github.com/articles/closing-issues-via-commit-messages
ffaa890https://github.com/adcontextprotocol/adcp-client-python/commit/ffaa890dbdf60f988216cf1ca2596251bf541c37
https://github.com/bokelley
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#issuecomment-4418206125
#649https://github.com/adcontextprotocol/adcp-client-python/pull/649
https://claude.ai/code/session_01DboS2SpnZYd9zC87Mk3juThttps://claude.ai/code/session_01DboS2SpnZYd9zC87Mk3juT
Claude Codehttps://claude.ai/code
bokelleyhttps://github.com/bokelley
claude-triagedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaged%22
claude-triagingTriage routine is actively working on this issue (1-3 min)https://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaging%22
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#event-25369194689
bokelleyhttps://github.com/bokelley
completedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
#649https://github.com/adcontextprotocol/adcp-client-python/pull/649
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#event-25369993130
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/645#event-25369993174
feat(server): TenantRegistry.as_platform() adapter for serve() integr…https://github.com/adcontextprotocol/adcp-client-python/commit/0e396ca778ea0a4def1f44d315b0d69b6cc00443
https://docs.github.com/articles/closing-issues-via-commit-messages
0e396cahttps://github.com/adcontextprotocol/adcp-client-python/commit/0e396ca778ea0a4def1f44d315b0d69b6cc00443
Sign up for freehttps://github.com/signup?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/645
Sign in to commenthttps://github.com/login?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/645
claude-triagedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaged%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.