-
Notifications
You must be signed in to change notification settings - Fork 590
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
feat: support initializing license key from env var #17906
Conversation
@@ -143,7 +143,6 @@ impl SystemParamsController { | |||
let params = SystemParameter::find().all(&db).await?; | |||
let params = merge_params(system_params_from_db(params)?, init_params); | |||
|
|||
info!("system parameters: {:?}", params); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're going to set a key for integration tests in CI. Removing these log lines to prevent any information leaks. 🥵
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A thorough solution is to not impl Debug
for the SystemParams
message with https://docs.rs/prost-build/latest/prost_build/struct.Config.html#method.skip_debug. However it's not possible in tonic-build
now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. 343cdae
(#17936)
1ed0430
to
96590bf
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will base on #17936 instead
src/frontend/src/handler/variable.rs
Outdated
@@ -152,6 +152,7 @@ async fn handle_show_system_params(handler_args: HandlerArgs) -> Result<RwPgResp | |||
.meta_client() | |||
.get_system_params() | |||
.await?; | |||
// TODO: for secret params (like `license_key`), redact the value in the response. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Address in #17936
@@ -143,7 +143,6 @@ impl SystemParamsController { | |||
let params = SystemParameter::find().all(&db).await?; | |||
let params = merge_params(system_params_from_db(params)?, init_params); | |||
|
|||
info!("system parameters: {:?}", params); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A thorough solution is to not impl Debug
for the SystemParams
message with https://docs.rs/prost-build/latest/prost_build/struct.Config.html#method.skip_debug. However it's not possible in tonic-build
now.
96590bf
to
bc79397
Compare
This stack of pull requests is managed by Graphite. Learn more about stacking. Join @BugenZhao and the rest of your teammates on Graphite |
54a0a54
to
5045523
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Can we get this merge? @BugenZhao |
Signed-off-by: Bugen Zhao <[email protected]>
4453593
to
365172f
Compare
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
As title. Since
license_key
is a system parameter, we reuse the code path for initializing system parameters with env var.Checklist
./risedev check
(or alias,./risedev c
)Documentation
Release note
If this PR includes changes that directly affect users or other significant modifications relevant to the community, kindly draft a release note to provide a concise summary of these changes. Please prioritize highlighting the impact these changes will have on users.