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

cli: avoid glog flags inject into tidb cli #47205

Merged
merged 7 commits into from
Sep 26, 2023

Conversation

hawkingrei
Copy link
Member

@hawkingrei hawkingrei commented Sep 22, 2023

What problem does this PR solve?

Issue Number: close #47204

Problem Summary:

What is changed and how it works?

In the initial version, the initialization process would include glog. Now, with this update, we have made a few changes. After the main function starts, the initflag function will be cleared first, and then the program will continue to execute.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
tidb-server --help

  -log-file string
        log file path
  -log-slow-query string
        slow query file path

  • No need to test
    • I checked and no code files have been changed.

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. do-not-merge/needs-tests-checked size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed do-not-merge/needs-tests-checked labels Sep 22, 2023
@codecov
Copy link

codecov bot commented Sep 22, 2023

Codecov Report

Merging #47205 (2297944) into master (db4ebd7) will increase coverage by 0.1970%.
Report is 34 commits behind head on master.
The diff coverage is 98.4848%.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #47205        +/-   ##
================================================
+ Coverage   72.9511%   73.1482%   +0.1970%     
================================================
  Files          1340       1369        +29     
  Lines        399976     412360     +12384     
================================================
+ Hits         291787     301634      +9847     
- Misses        89282      91885      +2603     
+ Partials      18907      18841        -66     
Flag Coverage Δ
integration 34.1236% <98.4848%> (?)
unit 73.3667% <0.0000%> (+0.4156%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 53.9913% <ø> (ø)
parser 84.9340% <ø> (-0.0026%) ⬇️
br 48.8227% <ø> (-4.1973%) ⬇️

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@hawkingrei hawkingrei changed the title cli: avoid glog inject into tidb cli cli: avoid glog flags inject into tidb cli Sep 23, 2023
@hawkingrei
Copy link
Member Author

/test all

@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 25, 2023
tidb-server/main.go Outdated Show resolved Hide resolved
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 25, 2023
@ti-chi-bot
Copy link

ti-chi-bot bot commented Sep 25, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-09-25 01:49:12.82978617 +0000 UTC m=+239542.548128386: ☑️ agreed by tiancaiamao.
  • 2023-09-25 03:55:06.90515262 +0000 UTC m=+247096.623494836: ☑️ agreed by xhebox.

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@ti-chi-bot ti-chi-bot bot removed the approved label Sep 25, 2023
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@easonn7
Copy link

easonn7 commented Sep 26, 2023

/approve

@ti-chi-bot
Copy link

ti-chi-bot bot commented Sep 26, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: easonn7, tiancaiamao, xhebox

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added the approved label Sep 26, 2023
@hawkingrei
Copy link
Member Author

/retest

@hawkingrei
Copy link
Member Author

/retest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

glog flag in the tidb cli
4 participants