diff options
| author | Chris Lu <chris.lu@gmail.com> | 2019-06-22 12:23:25 -0700 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2019-06-22 12:23:25 -0700 |
| commit | c369e5a13b1424e1fe4fec0c9c92d8c179fd1079 (patch) | |
| tree | 0b0ace47908fe61a5d84120cae39965b38092b4d /weed/stats/metrics.go | |
| parent | 6bc3dee5b37aefc0a04603c6f00670dd6ec2d2ea (diff) | |
| download | seaweedfs-c369e5a13b1424e1fe4fec0c9c92d8c179fd1079.tar.xz seaweedfs-c369e5a13b1424e1fe4fec0c9c92d8c179fd1079.zip | |
add metrics for filer store
Diffstat (limited to 'weed/stats/metrics.go')
| -rw-r--r-- | weed/stats/metrics.go | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/weed/stats/metrics.go b/weed/stats/metrics.go index b7f184e87..46ea6d74e 100644 --- a/weed/stats/metrics.go +++ b/weed/stats/metrics.go @@ -31,6 +31,23 @@ var ( Buckets: prometheus.ExponentialBuckets(0.0001, 2, 24), }, []string{"type"}) + FilerStoreCounter = prometheus.NewCounterVec( + prometheus.CounterOpts{ + Namespace: "SeaweedFS", + Subsystem: "filerStore", + Name: "request_total", + Help: "Counter of filer store requests.", + }, []string{"store", "type"}) + + FilerStoreHistogram = prometheus.NewHistogramVec( + prometheus.HistogramOpts{ + Namespace: "SeaweedFS", + Subsystem: "filerStore", + Name: "request_seconds", + Help: "Bucketed histogram of filer store request processing time.", + Buckets: prometheus.ExponentialBuckets(0.0001, 2, 24), + }, []string{"store", "type"}) + VolumeServerRequestCounter = prometheus.NewCounterVec( prometheus.CounterOpts{ Namespace: "SeaweedFS", @@ -77,6 +94,8 @@ func init() { FilerGather.MustRegister(FilerRequestCounter) FilerGather.MustRegister(FilerRequestHistogram) + FilerGather.MustRegister(FilerStoreCounter) + FilerGather.MustRegister(FilerStoreHistogram) VolumeServerGather.MustRegister(VolumeServerRequestCounter) VolumeServerGather.MustRegister(VolumeServerRequestHistogram) |
