-
Notifications
You must be signed in to change notification settings - Fork 304
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
playground: fix can not set runtime config in config file & set TiFlash logger level to debug #2346
playground: fix can not set runtime config in config file & set TiFlash logger level to debug #2346
Conversation
Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com>
/cc @JaySon-Huang |
@Lloyd-Pottiger: GitHub didn't allow me to request PR reviews from the following users: JaySon-Huang. Note that only pingcap members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #2346 +/- ##
==========================================
- Coverage 55.40% 55.35% -0.05%
==========================================
Files 329 329
Lines 34845 34865 +20
==========================================
- Hits 19304 19297 -7
- Misses 13232 13257 +25
- Partials 2309 2311 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@@ -139,6 +139,7 @@ func (inst *TiFlashInstance) Start(ctx context.Context, version utils.Version) e | |||
fmt.Sprintf("--path=%s", filepath.Join(inst.Dir, "data")), | |||
fmt.Sprintf("--listen_host=%s", inst.Host), | |||
fmt.Sprintf("--logger.log=%s", inst.LogFile()), | |||
"--logger.level=debug", |
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.
can we overwrite this config when running playground?
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.
Fixed in 7ccb33d
Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com>
/cc @breezewish |
var err error | ||
} | ||
runtimeConfig := [][]string{ | ||
{"tmp_path", filepath.Join(inst.Dir, "tmp")}, |
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.
I think tmp_path can be removed, TiFlash's default behavior "${path}/tmp" can handle it.
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.
removed 8ec2aa8
userConfig, err := unmarshalConfig(configPath) | ||
if err != nil { | ||
return errors.Trace(err) | ||
} |
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 should continue the following logic when the config file in configPath
is not exists
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.
configPath := filepath.Join(inst.Dir, "tiflash.toml")
if err := prepareConfig(
configPath,
inst.ConfigPath,
inst.getConfig(),
); err != nil {
return err
}
configPath
always exists.
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.
got it
Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com>
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
@JaySon-Huang: adding LGTM is restricted to approvers and reviewers in OWNERS files. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Just curious, in what case do we need to override the runtime config in the config file? AFAIK for TiKV and TiDB these runtime configurations (like port) are also specified via parameters so that it will not be overridden by config files. |
Signed-off-by: Lloyd-Pottiger <yan1579196623@gmail.com>
case like: My tiup installed in /data1, but /data1 is full and /data2 is almost empty |
/lgtm |
/approve |
/assign @kaaaaaaang |
/approve |
/lgtm /approve |
/lgtm |
[LGTM Timeline notifier]Timeline:
|
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: kaaaaaaang, Lloyd-Pottiger The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…sh logger level to debug (#2346)
What problem does this PR solve?
What is changed and how it works?
--tiflash.config
now:
Check List
Tests
Code changes
Side effects
Related changes
Release notes: