Clarify or implement runtime semantics for router.enabled
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 4k
- Forks
- 453
- Avg merge
- 12h 30m
- Merged PRs (30d)
- 46
Description
Problem
router.enabled is exposed through the config/UI, but setting it to false does not currently change runtime behavior.
This appears to be an accidental config/runtime contract mismatch rather than intentional behavior: the config surface suggests that router behavior can be disabled, but the gateway runtime still creates and uses the router.
Current Behavior
- Users can set
router.enabled: falsein the config. - The gateway runtime still creates the router runtime.
- Router-related defaults may still be normalized/populated.
- Routing features such as scenarios, fallback, token saver, and stats are not clearly disabled by this flag.
Expected Behavior
router.enabled should have a clear and enforced meaning.
Either:
- The router is required and cannot be disabled, in which case the UI/config surface should stop presenting
router.enabledas an effective toggle.
Or:
- The router can be disabled, in which case the runtime should explicitly read
router.enabled === falseand disable the relevant router behavior.
Impact
This can mislead users into believing routing has been disabled when it has not. It also makes debugging routing behavior difficult because the saved config and runtime behavior disagree.
Evidence / Code Areas
Relevant areas to inspect:
- Config/UI surface that exposes
router.enabled - Runtime gateway creation path
- Router config normalization/defaulting path
- Router status/reload reporting
Product Decision Needed
Please decide which semantic is intended:
- Remove or rename
router.enabledif the router is mandatory. - Implement runtime support for
router.enabled: falseif the router should be optional.
Acceptance Criteria
router.enabled: falseis no longer a no-op.- Either the UI/config no longer implies the router can be disabled, or the runtime actually disables router behavior.
- Runtime status/API responses accurately reflect the router enabled/disabled state.
- Tests cover the chosen behavior.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Inspect the config/UI surface for router.enabled, the runtime gateway creation path, router config normalization/defaulting, and router status or reload reporting. First determine whether the router is mandatory or optional; done means the setting is no longer a no-op, status/API behavior matches the chosen meaning, and tests cover it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- full-stack
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100