Skip to content

Commit e8fe6db

Browse files
bokelleyclaude
andcommitted
docs(migration): §3.1 — single-adapter adopters skip PlatformRouter
PlatformRouter is the right primitive for heterogeneous platforms behind one process. Single-adapter adopters (salesagent today — GAM-only deployments, with Kevel/Broadstreet/Triton/Xandr being unused scaffolding) skip the router entirely: instantiate one GAMPlatform, pass to serve(), let multi-tenancy ride on Account.metadata['tenant_id']. For that shape the migration is "delete the registry, instantiate one GAMPlatform," not "translate registry into router." Adding a "Who needs this" callout at the top of §3.1 so single-adapter adopters don't waste time on the router pattern they don't need. Also fixes a verbatim duplicate paragraph at the end of §3.1. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 588b3a1 commit e8fe6db

1 file changed

Lines changed: 15 additions & 5 deletions

File tree

examples/multi_platform_seller/MIGRATION_FROM_ADAPTER_REGISTRY.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,21 @@ an aspirational re-skin of the existing surface.
202202

203203
### 3.1 `ADAPTER_REGISTRY``PlatformRouter`
204204

205+
**Who needs this.** `PlatformRouter` is the right primitive when
206+
you have **heterogeneous platforms behind one process**
207+
different tenants routed to different `DecisioningPlatform`
208+
implementations (GAM for tenant A, Kevel for tenant B, etc.).
209+
**Single-adapter adopters skip the router**: instantiate one
210+
`GAMPlatform` (or `KevelPlatform`, or whichever), pass it directly
211+
to `serve(...)`, and let multi-tenancy ride on
212+
`Account.metadata['tenant_id']` per-request. Salesagent's actual
213+
deployments are GAM-only today (Kevel/Broadstreet/Triton/Xandr
214+
adapters exist but have no client traffic); for that shape the
215+
migration is "delete the registry, instantiate one `GAMPlatform`,"
216+
not "translate registry into router." Keep reading §3.1 if you
217+
genuinely run more than one upstream behind the same process; jump
218+
to §3.2 if you don't.
219+
205220
**Before**`salesagent/src/adapters/__init__.py:17`:
206221

207222
```python
@@ -258,11 +273,6 @@ request. Connection pools, OAuth token caches, and any platform-level
258273
state amortise across the platform's lifetime — the per-request
259274
instantiation overhead in the registry pattern goes away.
260275

261-
Platforms are constructed once, at process start, and reused for every
262-
request. Connection pools, OAuth token caches, and any platform-level
263-
state amortise across the platform's lifetime — the per-request
264-
instantiation overhead in the registry pattern goes away.
265-
266276
### 3.2 `AdServerAdapter` ABC → `DecisioningPlatform` + `SalesPlatform`
267277

268278
**Before**`salesagent/src/adapters/base.py:174` and the Kevel

0 commit comments

Comments
 (0)