Skip to content

refactor: remove environment variable configuration for metasrv - #19333

Merged
drmingdrmer merged 1 commit into
databendlabs:mainfrom
drmingdrmer:1021-rm-env-config
Jan 25, 2026
Merged

refactor: remove environment variable configuration for metasrv#19333
drmingdrmer merged 1 commit into
databendlabs:mainfrom
drmingdrmer:1021-rm-env-config

Conversation

@drmingdrmer

@drmingdrmer drmingdrmer commented Jan 25, 2026

Copy link
Copy Markdown
Member

I hereby agree to the terms of the CLA available at: https://docs.databend.com/dev/policies/cla/

Summary

change: remove environment variable configuration for metasrv

Remove ConfigViaEnv struct and environment variable loading from
metasrv config system. Configuration is now supported only via TOML
config files and CLI arguments. The METASRV_CONFIG_FILE env var for
specifying the config file path is preserved.

Changes:

  • Remove ConfigViaEnv struct and its From/Into implementations
  • Remove env loading step from Config::load()
  • Remove tests for METASRV_LOG_LEVEL and KVSRV_API_PORT env overrides

Upgrade tip:

Environment variables like METASRV_LOG_LEVEL, KVSRV_API_PORT, etc.
no longer work for configuring metasrv. Migrate to one of:

  • TOML config file (use METASRV_CONFIG_FILE env var or --config-file to specify path)
  • CLI arguments (e.g., --log-level DEBUG, --raft-api-port 28004)

Tests

  • Unit Test
  • Logic Test
  • Benchmark Test
  • No Test - Explain why

Type of change

  • Other

Related Issues


This change is Reviewable

Remove `ConfigViaEnv` struct and environment variable loading from
metasrv config system. Configuration is now supported only via TOML
config files and CLI arguments. The `METASRV_CONFIG_FILE` env var for
specifying the config file path is preserved.

Changes:
- Remove `ConfigViaEnv` struct and its `From`/`Into` implementations
- Remove env loading step from `Config::load()`
- Remove tests for `METASRV_LOG_LEVEL` and `KVSRV_API_PORT` env overrides

Upgrade tip:

Environment variables like `METASRV_LOG_LEVEL`, `KVSRV_API_PORT`, etc.
no longer work for configuring metasrv. Migrate to one of:
- TOML config file (use `METASRV_CONFIG_FILE` env var or `--config-file` to specify path)
- CLI arguments (e.g., `--log-level DEBUG`, `--raft-api-port 28004`)
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@drmingdrmer drmingdrmer changed the title change: remove environment variable configuration for metasrv refactor: remove environment variable configuration for metasrv Jan 25, 2026
@github-actions github-actions Bot added the pr-refactor this PR changes the code base without new features or bugfix label Jan 25, 2026

@xp-trumpet xp-trumpet left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@xp-trumpet reviewed 2 files and all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @drmingdrmer).

@drmingdrmer
drmingdrmer merged commit 1b0d293 into databendlabs:main Jan 25, 2026
93 of 95 checks passed
@drmingdrmer
drmingdrmer deleted the 1021-rm-env-config branch January 25, 2026 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-refactor this PR changes the code base without new features or bugfix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants