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 method tag for metadata access monitoring #3501

Merged
merged 2 commits into from
Apr 21, 2023

Conversation

shichanglin5
Copy link
Contributor

a label(method anme) is added to the opDist metrics collector of metadata operations at pkg/meta/base.go:217

so that we can clearly view the time duration and qps of different methods through monitoring, which is useful for troubleshooting problems and analyzing performance bottlenecks.

@codecov-commenter
Copy link

codecov-commenter commented Apr 20, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.01 🎉

Comparison is base (d95ad52) 56.51% compared to head (7025ea9) 56.53%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3501      +/-   ##
==========================================
+ Coverage   56.51%   56.53%   +0.01%     
==========================================
  Files         149      149              
  Lines       36306    36321      +15     
==========================================
+ Hits        20520    20535      +15     
  Misses      13543    13543              
  Partials     2243     2243              
Impacted Files Coverage Δ
pkg/meta/base.go 63.89% <100.00%> (ø)
pkg/meta/redis.go 66.93% <100.00%> (ø)
pkg/meta/sql.go 58.53% <100.00%> (-0.13%) ⬇️
pkg/meta/tkv.go 71.57% <100.00%> (-0.11%) ⬇️
pkg/vfs/internal.go 50.00% <100.00%> (+1.73%) ⬆️

... and 8 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@SandyXSD
Copy link
Contributor

Usually we use access log and juicefs profile if we want to know details of each operation.

@SandyXSD
Copy link
Contributor

It shall be useful as a history record in prometheus. However, we need fix the display in juicefs stats, since it uses juicefs_meta_ops_durations_histogram_seconds directly there.

@SandyXSD
Copy link
Contributor

@shichanglin5 Could you keep the original opDist (so juicefs stats still works), and add a new HistogramVec for the metrics with tags?

@shichanglin5
Copy link
Contributor Author

@shichanglin5 Could you keep the original opDist (so juicefs stats still works), and add a new HistogramVec for the metrics with tags?

This way is feasible, but there will be two opDist; How about modifying the stats code and merging the different label statistics of this opDist?

@davies davies merged commit 9137689 into juicedata:main Apr 21, 2023
@shichanglin5 shichanglin5 deleted the add_prom_method_tag branch April 23, 2023 02:12
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.

4 participants