Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify config defaulting for externally provided inputs #2481

Closed
BrynCooke opened this issue Jan 26, 2023 · 0 comments · Fixed by #2490
Closed

Unify config defaulting for externally provided inputs #2481

BrynCooke opened this issue Jan 26, 2023 · 0 comments · Fixed by #2490
Assignees

Comments

@BrynCooke
Copy link
Contributor

Currently we have no centralized way of overriding config in the case of env variable or command-line flag.

This has lead to pieces scattered across the codebase that approach things in a non-uniform manner, in addition they often rely on env variables, and are therefore prone to environmental issues during testing.

Bring defaulting into a central location.

BrynCooke pushed a commit that referenced this issue Jan 27, 2023
Fixes #4202 #2481

Moves defaulting logic from hard coded section in config init to a central location that uses transformers.

Previously `dev` mode was operating against the configuration object model. This meant that it would sometimes replace pieces of configuration where really it should just have modified it.
Now dev mode will override the following in the yaml config, but it will leave any adjacent configuration as it was:

```yaml
homepage:
  enabled: false
include_subgraph_errors:
  all: true
plugins:
  experimental.expose_query_plan: true
sandbox:
  enabled: true
supergraph:
  introspection: true
telemetry:
  tracing:
    experimental_response_trace_id:
      enabled: true
```
@abernix abernix linked a pull request Jan 27, 2023 that will close this issue
6 tasks
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 a pull request may close this issue.

1 participant