Skip to content

feat(web): load deploy route options from the gateway - #67

Merged
imneov merged 2 commits into
mainfrom
feat/route-options-catalog
Oct 15, 2026
Merged

imneov merged 2 commits into
mainfrom
feat/route-options-catalog

Conversation

@imneov

@imneov imneov commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

What type of PR is this?

  • bug fix
  • feature
  • documentation
  • CI / tooling
  • breaking: API, config key, chart value, or CRD field changed

What this PR does and why

The deploy form's bundled option list and placeholders drifted from the running OpenResty engine. Read its public /<route>/_route_opts catalog through an authenticated console API instead.

  • Group common directives and keep engine internals in the advanced picker.
  • Show deployment-specific defaults as placeholders; keep existing route runtime values and their source separate from editable overrides.
  • Use bundled metadata without default values only when the catalog is unsupported or no route exists; surface other failures.
  • Preserve unknown options, per-key locale fallback, existing chart/SLO semantics and the copied Swiss module.
  • Cover missing-gateway SPA fallthrough, old-plan route identity and native desktop picker interaction.

Which issue(s) this PR fixes

Fixes #52

How it was tested

  • go test ./..., go vet ./..., Go formatting and patch whitespace checks.
  • npm run typecheck, full frontend suite and npm run build on the branch based on current main.
  • Real released OpenResty 0.1.26 in an isolated local container: 16 common and 24 advanced options; changed host defaults (TPS 73, floor fraction 0.61) and route value 81/set=true.
  • Existing preview APIs and desktop browser: live defaults render without becoming submitted overrides; blank advanced values are omitted; native pointer selection remains usable.
  • Portable live check: CONSOLE_URL=<preview-url> node hack/check-route-catalog-live.mjs.
  • No install/apply operation, no business-release history rewrite, no mobile sizing changes.

Checks

  • go test ./... and gofmt -l . is empty
  • npm run typecheck && npm test && npm run build in web/
  • helm lint --strict helm/console (chart unchanged)
  • Docs updated where behaviour changed
  • No internal hostnames, IPs, registries or credentials

Notes for reviewers

Start with the route catalog handler and gateway catalog discovery, then the inference-module API adapter and form. The API is additive and reuses the existing backend read grant. Engine-side validation remains authoritative. Desktop-only acceptance per the originating request.

Release note

Deploy and upgrade forms now read route options and host defaults from OpenResty, with a safe legacy fallback and separate runtime-state display.

imneov added 2 commits October 13, 2026 19:46
The deploy form's bundled catalog and independent placeholders drifted from the running engine. Proxy the public route catalog, render its host defaults and separate runtime state from editable overrides, and keep legacy metadata without stale defaults.

Cover missing-gateway SPA fallthrough, old-plan route identity and live desktop picker behavior. Keep copied Swiss code and mobile sizing unchanged.

Fixes #52
Keep legacy metadata exclusive to explicit unsupported/empty responses, discover catalog routes independently of inference pins, and put transport under the inference module API boundary.
@imneov
imneov merged commit 47b2faa into main Oct 15, 2026
6 of 7 checks passed
@imneov
imneov deleted the feat/route-options-catalog branch October 15, 2026 05:28
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.

Deploy form: read route options from openresty's /_route_opts instead of hardcoding them

1 participant