tidb
tidb copied to clipboard
util: get cpu/memory info from cgroup to support Vertical Pod Autoscaler
Signed-off-by: Weizhen Wang [email protected]
What problem does this PR solve?
Issue Number: close #xxx
Problem Summary:
What is changed and how it works?
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
Please refer to Release Notes Language Style Guide to write a quality release note.
None
[REVIEW NOTIFICATION]
This pull request has been approved by:
- Benjamin2037
- Defined2014
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.
/gray-debug
Build triggered for merge commit.
Build triggered for merge commit.
Build triggered for merge commit.
Build triggered for merge commit.
Build triggered for merge commit.
Code Coverage Details: https://codecov.io/github/pingcap/tidb/commit/a4f227a75401fddb03b4dacc6fe7b9862c96bbbb
/run-unit-test
/run-build
@mengxin9014: Thanks for your review. The bot only counts approvals from reviewers and higher roles in list, but you're still welcome to leave your comments.
In response to this:
LGTM
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.
I didn't find where called memory related function, did I miss it?
All the memory related function is in the util/cgroup/cgroup_memory.go. But They are not used. But they will be used in the #36307 and #32091 .
@Defined2014 PTAL
@Benjamin2037 @tangenta @zimulala PTAL
@tangenta PTAL
/merge
This pull request has been accepted and is ready to merge.
/run-build
@hawkingrei: Your PR was out of date, I have automatically updated it for you.
At the same time I will also trigger all tests for you:
/run-all-tests
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.
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.
/run-unit-test