You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit aad4119
Browse filesBrowse the repository at this point in the historyBrowse files
fix(v2): bound workspace source body reservations per caller and 404 the source routes on the mcp host (#10607)
* fix(v2): bound workspace source body reservations per caller and 404 the source routes on the mcp host
A workspace source apply or plan reserves room for its body before the use case authorizes it,
from a lane budget every caller shares, so a few slow-trickled bodies from one API key held
every tenant's room (429s until the socket timed out). Each caller (the user behind the
credential, or a workspace key's workspace) now holds at most a cap's worth of bodies per lane,
and a body not read by a deadline that grows with its declared size is answered 408 and frees
its room.
The proxy matcher leaves these routes out so Next never buffers their bodies, which also skipped
the proxy's 404 for the dedicated MCP host. defineV2JsonRoute now answers that host 404 before
admitting the caller or reserving room.
* fix(v2): fail fast on an unholdable source body caller and declare mcp dispatch body length
A source body is held for the workspace a key belongs to or the person behind the credential;
a principal with neither now throws instead of sharing one holder per principal kind. The MCP
in-process dispatch declares its body's length, so a source plan or apply sent over MCP reserves
what it holds rather than a full cap. The read deadline timer is cleared only in finally, and the
source route docs name the per-caller 429 and the 408.
* fix(v2): declare the actorless gap in the source body holder
0 commit comments