Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Pull request overview
Updates the vMCP scaling guide to document a session-affinity option intended to help route stateful client sessions consistently when horizontally scaling.
Changes:
- Replaces the prior generic note about session affinity with a new section describing a
VirtualMCPServer.spec.sessionAffinityfield and an example YAML snippet.
| The `VirtualMCPServer` CRD includes a `sessionAffinity` field that controls how | ||
| the Kubernetes Service routes repeated client connections. By default, it uses | ||
| `ClientIP` affinity, which routes connections from the same client IP to the | ||
| same pod. You can configure this using the `sessionAffinity` field: | ||
|
|
||
| ```yaml | ||
| spec: | ||
| sessionAffinity: ClientIP # default | ||
| ``` |
There was a problem hiding this comment.
The docs state that the VirtualMCPServer CRD has a spec.sessionAffinity field with default ClientIP, but I can’t find sessionAffinity anywhere in the CRD reference (docs/toolhive/reference/crd-spec.md) or in the repo’s Go/YAML sources. This makes the configuration example misleading. Please either (a) update the operator/CRD and reference docs to actually support this field, or (b) reword this section to describe how to set spec.sessionAffinity on the generated Kubernetes Service (if that’s the intended approach) and clarify the actual default behavior.
Description
Document new session affinity option in relation to scalability.
Type of change
Related issues/PRs
stacklok/toolhive#3986
Screenshots
Submitter checklist
Content and formatting
Reviewer checklist
Content