Skip to content

[pick]support cgroup v2#42465

Merged
yiguolei merged 3 commits intoapache:branch-2.1from
wangbo:1025_pick_cg_v2
Oct 25, 2024
Merged

[pick]support cgroup v2#42465
yiguolei merged 3 commits intoapache:branch-2.1from
wangbo:1025_pick_cg_v2

Conversation

@wangbo
Copy link
Copy Markdown
Contributor

@wangbo wangbo commented Oct 25, 2024

Proposed changes

pick #39991 #39374 #36663

1 Fix typos in class name.
2 use correct return Status.
## Proposed changes
1 Add a step to write pid to query path's cgroup.procs, otherwrise write
thread id may failed.
2 Move some cgroup v2's public file to parent class to init init them
once.
@doris-robot
Copy link
Copy Markdown

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR

Since 2024-03-18, the Document has been moved to doris-website.
See Doris Document.

@wangbo
Copy link
Copy Markdown
Contributor Author

wangbo commented Oct 25, 2024

run buildall

Copy link
Copy Markdown
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

clang-tidy made some suggestions

static Status init_cgroup_v2_query_path_public_file(std::string home_path,
std::string query_path);

protected:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

warning: redundant access specifier has the same accessibility as the previous access specifier [readability-redundant-access-specifiers]

Suggested change
protected:
Additional context

be/src/agent/cgroup_cpu_ctl.h:60: previously declared here

protected:
^

inline static std::string _cgroup_v2_query_path_subtree_ctl_file = "";
inline static std::string _doris_cg_v2_procs_file = "";

protected:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

warning: redundant access specifier has the same accessibility as the previous access specifier [readability-redundant-access-specifiers]

Suggested change
protected:
Additional context

be/src/agent/cgroup_cpu_ctl.h:60: previously declared here

protected:
^

}

void RuntimeQueryStatiticsMgr::report_runtime_query_statistics() {
void RuntimeQueryStatisticsMgr::report_runtime_query_statistics() {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

warning: function 'report_runtime_query_statistics' exceeds recommended size/complexity thresholds [readability-function-size]

void RuntimeQueryStatisticsMgr::report_runtime_query_statistics() {
                                ^
Additional context

be/src/runtime/runtime_query_statistics_mgr.cpp:49: 117 lines including whitespace and comments (threshold 80)

void RuntimeQueryStatisticsMgr::report_runtime_query_statistics() {
                                ^

@doris-robot
Copy link
Copy Markdown

TeamCity be ut coverage result:
Function Coverage: 36.01% (9366/26006)
Line Coverage: 27.59% (76955/278969)
Region Coverage: 26.36% (39511/149901)
Branch Coverage: 23.14% (20096/86840)
Coverage Report: http://coverage.selectdb-in.cc/coverage/a46237a67ebf7be9af9c89541679e57f75d978a1_a46237a67ebf7be9af9c89541679e57f75d978a1/report/index.html

@yiguolei yiguolei merged commit 9eef393 into apache:branch-2.1 Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants