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
fix: save app's env when bootstrapping and reloading #9750
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zhongwencool
requested review from
a team,
lafirest and
thalesmg
as code owners
January 13, 2023 10:37
zhongwencool
changed the title
save app's env when bootstrapping and reloading
fix: save app's env when bootstrapping and reloading
Jan 13, 2023
zmstone
reviewed
Jan 13, 2023
zmstone
reviewed
Jan 13, 2023
zhongwencool
force-pushed
the
bootstrap-app-env
branch
from
January 13, 2023 15:35
ba57049
to
588140b
Compare
zhongwencool
commented
Jan 13, 2023
@@ -463,7 +463,7 @@ fields("node") -> | |||
)}, | |||
{"config_files", | |||
sc( | |||
list(string()), |
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.
when we config node.config_files = ["test"]
node {
name = "emqx@127.0.0.1"
cookie = "emqxsecretcookie"
data_dir = "data"
config_files = ["test"]
}
the config schema check will fail by:
exception throw: {emqx_conf_schema,[#{kind => validation_error,
path => "node.config_files",
reason =>
#{expected_type => <<"[string()]">>},
value => [<<"test">>]}]}
in function hocon_tconf:assert_no_error/2 (hocon_tconf.erl, line 1142)
in call from hocon_tconf:map/4 (hocon_tconf.erl, line 295)
in call from hocon_cli:get_values/3 (hocon_cli.erl, line 194)
in call from hocon_cli:multi_get/2 (hocon_cli.erl, line 182)
in call from escript:run/2 (escript.erl, line 750)
in call from escript:start/1 (escript.erl, line 277)
in call from init:start_em/1
in call from init:do_boot/3
So we change the type to hocon:array(string()).
zmstone
approved these changes
Jan 14, 2023
zmstone
added a commit
to zmstone/emqx
that referenced
this pull request
Jan 16, 2023
zmstone
added a commit
to zmstone/emqx
that referenced
this pull request
Jan 16, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
If we configure
logger
andprometheus
incluster-override.conf
These configurations will have no effect. This is because
log
is an environment variable forkernal
applications.*_collector
are the environment variable for theprometheus
application.we need to save those two applications' env after init_load.
close #8895