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

Add a metric to statistics expansion or reused. #4619

Merged
merged 10 commits into from
May 9, 2022
Merged

Add a metric to statistics expansion or reused. #4619

merged 10 commits into from
May 9, 2022

Conversation

jiaqizho
Copy link
Contributor

@jiaqizho jiaqizho commented Apr 11, 2022

What problem does this PR solve?

Issue Number: ref #3594

Problem Summary:

What is changed and how it works?

  • Add a return value from spacemap after request search which can help to count whether the address is reused.
  • also added two metrics in tiflash.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

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

None

@jiaqizho jiaqizho requested a review from JaySon-Huang April 11, 2022 07:50
@ti-chi-bot
Copy link
Member

ti-chi-bot commented Apr 11, 2022

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • flowbehappy
  • hehechen

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added 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. labels Apr 11, 2022
@flowbehappy
Copy link
Contributor

flowbehappy commented Apr 29, 2022

@jiaqizho Please explain about "What is changed and how it works?" of this PR. You can also post a screenshot of the newly added metric panel.

@jiaqizho
Copy link
Contributor Author

@jiaqizho Please explain about "What is changed and how it works?" of this PR. You can also post a screenshot of the newly added metric panel.

that is the problem, actually, this pr has not been tested in tiup yet. only tested in ut.

@jiaqizho jiaqizho requested a review from hehechen May 5, 2022 03:56
@jiaqizho jiaqizho requested review from flowbehappy and hehechen May 6, 2022 14:58
@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label May 7, 2022
Copy link
Contributor

@JaySon-Huang JaySon-Huang left a comment

Choose a reason for hiding this comment

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

Code parts LGTM.
But seems we need to create a new panel rather than mixed them in "Disk Write OPS" panel

@jiaqizho
Copy link
Contributor Author

jiaqizho commented May 7, 2022

image

@JaySon-Huang new pannel looks like.

@jiaqizho
Copy link
Contributor Author

jiaqizho commented May 7, 2022

image

@JaySon-Huang new pannel looks like.

also changed width 24 to 12.

@jiaqizho jiaqizho requested a review from JaySon-Huang May 7, 2022 11:11
flowbehappy
flowbehappy previously approved these changes May 9, 2022
@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels May 9, 2022
@flowbehappy flowbehappy self-requested a review May 9, 2022 04:12
@jiaqizho jiaqizho requested a review from JaySon-Huang May 9, 2022 06:05
Copy link
Contributor

@JaySon-Huang JaySon-Huang left a comment

Choose a reason for hiding this comment

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

some comments about description

metrics/grafana/tiflash_summary.json Outdated Show resolved Hide resolved
metrics/grafana/tiflash_summary.json Outdated Show resolved Hide resolved
metrics/grafana/tiflash_summary.json Outdated Show resolved Hide resolved
@jiaqizho jiaqizho requested a review from JaySon-Huang May 9, 2022 09:24
Copy link
Contributor

@JaySon-Huang JaySon-Huang left a comment

Choose a reason for hiding this comment

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

LGTM

@jiaqizho
Copy link
Contributor Author

jiaqizho commented May 9, 2022

/merge

@ti-chi-bot
Copy link
Member

@jiaqizho: It seems you want to merge this PR, I will help you trigger all the tests:

/run-all-tests

You only need to trigger /merge once, and if the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

If you have any questions about the PR merge process, please refer to pr process.

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 ti-community-infra/tichi repository.

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: 7a88dc7

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label May 9, 2022
@sre-bot
Copy link
Collaborator

sre-bot commented May 9, 2022

Coverage for changed files

Filename                                         Regions    Missed Regions     Cover   Functions  Missed Functions  Executed       Lines      Missed Lines     Cover    Branches   Missed Branches     Cover
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Common/ProfileEvents.cpp                             140                 0   100.00%           2                 0   100.00%          11                 0   100.00%           0                 0         -
Storages/Page/V3/BlobStore.cpp                       483               159    67.08%          49                 3    93.88%         995               241    75.78%         302               119    60.60%
Storages/Page/V3/spacemap/SpaceMap.h                   7                 2    71.43%           4                 1    75.00%          18                 5    72.22%           6                 1    83.33%
Storages/Page/V3/spacemap/SpaceMapRBTree.cpp         343                95    72.30%          18                 1    94.44%         568               117    79.40%         200                64    68.00%
Storages/Page/V3/spacemap/SpaceMapRBTree.h             2                 0   100.00%           2                 0   100.00%           5                 0   100.00%           0                 0         -
Storages/Page/V3/spacemap/SpaceMapSTDMap.h           155                19    87.74%          11                 0   100.00%         255                20    92.16%          98                20    79.59%
Storages/Page/V3/tests/gtest_free_map.cpp           2176               357    83.59%          13                 0   100.00%         270                 0   100.00%         712               356    50.00%
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                               3306               632    80.88%          99                 5    94.95%        2122               383    81.95%        1318               560    57.51%

Coverage summary

Functions  MissedFunctions  Executed  Lines   MissedLines  Cover
18077      10153            43.83%    200553  101020       49.63%

full coverage report (for internal network access only)

@sre-bot
Copy link
Collaborator

sre-bot commented May 9, 2022

Coverage for changed files

Filename                                         Regions    Missed Regions     Cover   Functions  Missed Functions  Executed       Lines      Missed Lines     Cover    Branches   Missed Branches     Cover
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Common/ProfileEvents.cpp                             140                 0   100.00%           2                 0   100.00%          11                 0   100.00%           0                 0         -
Storages/Page/V3/BlobStore.cpp                       489               161    67.08%          49                 3    93.88%        1006               245    75.65%         308               122    60.39%
Storages/Page/V3/spacemap/SpaceMap.h                   7                 2    71.43%           4                 1    75.00%          18                 5    72.22%           6                 1    83.33%
Storages/Page/V3/spacemap/SpaceMapRBTree.cpp         343                95    72.30%          18                 1    94.44%         568               117    79.40%         200                64    68.00%
Storages/Page/V3/spacemap/SpaceMapRBTree.h             2                 0   100.00%           2                 0   100.00%           5                 0   100.00%           0                 0         -
Storages/Page/V3/spacemap/SpaceMapSTDMap.h           155                19    87.74%          11                 0   100.00%         255                20    92.16%          98                20    79.59%
Storages/Page/V3/tests/gtest_free_map.cpp           2176               357    83.59%          13                 0   100.00%         270                 0   100.00%         712               356    50.00%
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                               3312               634    80.86%          99                 5    94.95%        2133               387    81.86%        1324               563    57.48%

Coverage summary

Functions  MissedFunctions  Executed  Lines   MissedLines  Cover
18091      10149            43.90%    200992  100983       49.76%

full coverage report (for internal network access only)

@ti-chi-bot ti-chi-bot merged commit 8781b0f into pingcap:master May 9, 2022
@jiaqizho jiaqizho deleted the add-expansion-metrics branch May 9, 2022 14:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants