Skip to content

feat(helm): warn when routing through the legacy llm proxy - #134

Open
devin-ai-integration[bot] wants to merge 2 commits into
mainfrom
abhi/sdk-916-warn-legacy-proxy
Open

devin-ai-integration[bot] wants to merge 2 commits into
mainfrom
abhi/sdk-916-warn-legacy-proxy

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Summary

SDK-916: warn self-hosted customers ahead of removing the legacy TS proxy. api-ts runs the legacy proxy whenever GATEWAY_URL is unset in its environment.

  • New braintrust/templates/NOTES.txt prints a deprecation warning (linking to the Gateway setup docs) when any rendered API pool would lack a Gateway URL. It uses the same merged per-pool API config as the Deployment template, so a GATEWAY_URL set via extraEnvVars (literal or valueFrom) counts as configured, and an explicit empty value overrides the ConfigMap one. aiGateway.enabled alone does not affect it.
  • Gateway lookups (.Values.aiGateway.X) in the API configmap and gateway templates now go through (.Values.aiGateway | default dict), so helm upgrade --reuse-values from a chart without the aiGateway map renders (and warns) instead of failing on a nil map.

Non-breaking; intended for a 7.x minor. No Chart.yaml bump (set at release).

Input matrix

Configuration GATEWAY_URL in API pods NOTES warning
useGateway=true (enabled true or false) set from ConfigMap silent
useGateway=false, Gateway deployed (enabled=true) unset warns
useGateway missing/null unset warns
aiGateway map missing (--reuse-values from older chart) unset warns, renders OK
aiGateway missing; shared literal GATEWAY_URL in extraEnvVars set in all pools silent
useGateway=false; shared GATEWAY_URL via valueFrom.secretKeyRef set (value not checkable at render) silent
useGateway=false; only ingest/background pools set GATEWAY_URL unset in default pool warns
useGateway=false; a pool overrides the shared URL with "" empty in that pool warns
useGateway=true; shared explicit empty GATEWAY_URL empty (overrides ConfigMap) warns

Image tags and cloud providers don't affect this logic; all clouds render via ./test.sh.

braintrust/tests/notes_test.yaml covers each row. ./test.sh: 684 helm-unittest tests pass, template rendering for all clouds and lint pass. Not tested against a live cluster.

Link to Devin session: https://braintrust.devinenterprise.com/sessions/7ef375d6fbb44534a435a16019f47db8
Open in Devin Desktop: https://braintrust.devinenterprise.com/desktop/session/7ef375d6fbb44534a435a16019f47db8?variant=devin

> 🤖 **This text was AI-generated.**

Show a deprecation note when the API does not get a Gateway URL from
`aiGateway.useGateway`. Link to the Gateway setup guide and keep upgrades
working when reused values do not contain an `aiGateway` map.

Refs: SDK-916
Co-authored-by: Abhijeet Prasad <abhijeet@braintrustdata.com>
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@devin-ai-integration

Copy link
Copy Markdown
Author

I'll fix CI failures and address comments from users with write access that start with 'Devin'.

  • Disable automatic comment, CI, and merge conflict monitoring

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 26, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-26T15:52:49.653546Z 3ebbe6a PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3ebbe6acee

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "Codex (@codex) review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "Codex (@codex) address that feedback".

Comment thread braintrust/templates/NOTES.txt Outdated
@@ -0,0 +1,4 @@
{{- if not (.Values.aiGateway | default dict).useGateway }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Account for an explicit GATEWAY_URL override

When a deployment supplies GATEWAY_URL through the supported api.extraEnvVars setting, _api-deployment.tpl places it directly in every API container's env, where it overrides values from envFrom; the API therefore routes through that configured gateway even though aiGateway.useGateway is false. This condition nevertheless prints the warning that the deprecated legacy proxy is in use, so existing external/custom Gateway configurations receive a false migration warning. Detect a GATEWAY_URL entry in the shared API environment before warning, and cover that supported input in the new tests.

AGENTS.md reference: AGENTS.md:L7-L7

Useful? React with 👍 / 👎.

> 🤖 **This text was AI-generated.**

Check the effective Gateway URL for every rendered API pool, including
shared and pool-specific environment overrides. Warn if any pool still
uses the legacy proxy.

Refs SDK-916

Co-authored-by: Abhijeet Prasad <abhijeet@braintrustdata.com>
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@greptile-apps

greptile-apps Bot commented Nov 27, 2026 •

Copy link
Copy Markdown

Confidence Score: 5/5 · The PR appears safe to merge; no actionable issues were found.RetriggerView in GreptileConfidence Score: 5/5 Tier: plus

[Medium impact] The PR appears safe to merge; no actionable issues were found.

Summary

Adds a legacy-proxy warning to Helm release notes.

  • Helm warns when any API pool still uses the legacy proxy.
  • Older Helm values can render without an aiGateway map.

Reviews (1) · Last reviewed commit: "fix(helm): respect custom gateway URLs i..." · Reviewed by Greptile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant