Skip to content

Minor fixes#1007

Merged
kmesh-bot merged 8 commits intokmesh-net:mainfrom
hzxuzhonghu:minor-fixes
Nov 7, 2024
Merged

Minor fixes#1007
kmesh-bot merged 8 commits intokmesh-net:mainfrom
hzxuzhonghu:minor-fixes

Conversation

@hzxuzhonghu
Copy link
Copy Markdown
Member

What type of PR is this?

/kind cleanup

What this PR does / why we need it:

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:



func (m *OperationMetricController) updateOperationMetricCache(data operationUsageInfo, labels operationMetricLabels) {
func (m *BpfProgMetric) updateOperationMetricCache(data operationDuration, labels operationMetricLabels) {
m.mutex.Lock()
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Lock twice?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Oh, i meant to move lock into hte function

}
}
c.client = NewXdsClient(c.mode, c.bpfAdsObj, c.bpfWorkloadObj, c.enableAccesslog)
c.client = NewXdsClient(c.mode, c.bpfAdsObj, c.bpfWorkloadObj, c.enableAccesslog, c.enablePerfMonitor)
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.

We should add the ability of kmeshctl to control the bpf perf monitor

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SGTM

@codecov
Copy link
Copy Markdown

codecov bot commented Nov 1, 2024

Codecov Report

Attention: Patch coverage is 8.43373% with 76 lines in your changes missing coverage. Please review.

Project coverage is 48.49%. Comparing base (5c1963a) to head (cce43a9).
Report is 103 commits behind head on main.

Files with missing lines Patch % Lines
pkg/controller/telemetry/bpf_prog_metric.go 0.00% 25 Missing ⚠️
pkg/controller/controller.go 0.00% 14 Missing ⚠️
pkg/controller/telemetry/map_metric.go 0.00% 14 Missing ⚠️
pkg/controller/workload/workload_controller.go 0.00% 11 Missing ⚠️
pkg/controller/config/config.go 25.00% 6 Missing ⚠️
pkg/status/status_server.go 25.00% 5 Missing and 1 partial ⚠️
Files with missing lines Coverage Δ
pkg/controller/client.go 66.32% <100.00%> (+0.70%) ⬆️
pkg/controller/telemetry/utils.go 64.81% <100.00%> (ø)
pkg/controller/config/config.go 60.00% <25.00%> (-3.08%) ⬇️
pkg/status/status_server.go 38.85% <25.00%> (+0.09%) ⬆️
pkg/controller/workload/workload_controller.go 51.21% <0.00%> (-2.63%) ⬇️
pkg/controller/controller.go 0.00% <0.00%> (ø)
pkg/controller/telemetry/map_metric.go 0.00% <0.00%> (ø)
pkg/controller/telemetry/bpf_prog_metric.go 0.00% <0.00%> (ø)

... and 10 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ed6956e...cce43a9. Read the comment docs.

Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
Signed-off-by: Zhonghu Xu <xuzhonghu@huawei.com>
@hzxuzhonghu
Copy link
Copy Markdown
Member Author

@nlgwcy ptal

@nlgwcy
Copy link
Copy Markdown
Contributor

nlgwcy commented Nov 7, 2024

/lgtm
/approve

@kmesh-bot
Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: nlgwcy

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

The pull request process is described here

Details 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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants