Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion braintrust/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ route these paths:
| --- | --- |
| `braintrust-api` (default) | All requests not matched by an explicit ingest or background route |
| `braintrust-api-ingest` | `POST /logs3`, `POST /otel/v1/traces`, `POST /attachment`, `POST /attachment/status` |
| `braintrust-api-background` | `POST /v1/eval`, `POST /v1/eval/*`, `POST /function/eval`, `POST /function/sandbox`, `POST /function/use`, `POST /function/invoke-async-batch`, `POST /function/insert-functions`, `POST /automation/logs/trigger`; all methods for `/v1/proxy/chat/completions`, `/v1/proxy/responses` |
| `braintrust-api-background` | `POST /v1/eval`, `POST /v1/eval/*`, `POST /function/eval`, `POST /function/sandbox`, `POST /function/use`, `POST /function/invoke-async-batch`, `POST /function/insert-functions`, `POST /automation/logs/trigger`, `POST /automation/trigger`; all methods for `/v1/proxy/chat/completions`, `/v1/proxy/responses` |

By default, Brainstore's internal `BRAINSTORE_AI_PROXY_URL` targets the
background Service while isolation is enabled. For an existing deployment,
Expand Down
3 changes: 3 additions & 0 deletions braintrust/files/contracts/api-workload-isolation-routes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ pools:
- path: /automation/logs/trigger
pathType: exact
method: POST
- path: /automation/trigger
pathType: exact
method: POST
- path: /v1/proxy/chat/completions
pathType: exact
- path: /v1/proxy/responses
Expand Down
19 changes: 14 additions & 5 deletions braintrust/tests/virtualservice_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -292,18 +292,27 @@ tests:
path: spec.http[5].match[0].method.exact
value: POST
- equal:
path: spec.http[13].match[0].uri.exact
path: spec.http[12].match[0].uri.exact
value: /automation/trigger
- equal:
path: spec.http[12].route[0].destination.host
value: custom-background
- equal:
path: spec.http[12].match[0].method.exact
value: POST
- equal:
path: spec.http[14].match[0].uri.exact
value: /v1/proxy/responses
- equal:
path: spec.http[13].route[0].destination.host
path: spec.http[14].route[0].destination.host
value: custom-background
- isNull:
path: spec.http[13].match[0].method
path: spec.http[14].match[0].method
- equal:
path: spec.http[14].match[0].uri.prefix
path: spec.http[15].match[0].uri.prefix
value: /
- equal:
path: spec.http[14].route[0].destination.host
path: spec.http[15].route[0].destination.host
value: braintrust-api

- it: should reject workload-isolation routes without the API pools
Expand Down
Loading