Answer the question
In order to leave comments, you need to log in
How to set up data aggregation in Graphite?
Welcome all. There is a task to stick monitoring to one application. There is a thing that sends metrics, everything is fine with that.
But there is a parameter that needs to be stored differently from everything else. Namely: the number of requests. Those. a request arrives, is processed, and the following metrics are sent to Graphite:
1) time spent on an external request;
2) application running time
3) the very fact of launching the application
In this Graphite, I need to somehow calculate the number of these launches. I already set up schemas and aggregation too, but why the hell can't he do what I want from him?
The very fact of the launch is recorded as follows: just a unit is sent to the def. metric and all. Then, let's say, I need to calculate the number of these units every hour and display it on the chart, but of course it does not display it.
storage-schemas.conf
# Schema definitions for Whisper files. Entries are scanned in order,
# and first match wins. This file is scanned for changes every 60 seconds.
#
# [name]
# pattern = regex
# retentions = timePerPoint:timeToStore, timePerPoint:timeToStore, ...
# Carbon's internal metrics. This entry should match what is specified in
# CARBON_METRIC_PREFIX and CARBON_METRIC_INTERVAL settings
[carbon]
pattern = ^carbon\.
retentions = 60:90d
[app]
pattern = ^app\.api\.*
retentions = 10s:10m,10m:30d,60m:1y
[collectd]
pattern = ^collectd\.
xFilesFactor = 0.7
aggregationMethod = max
[count]
pattern = \.count$
xFilesFactor = 0
aggregationMethod = sum
[default]
pattern = .*
xFilesFactor = 0.5
aggregationMethod = average
Answer the question
In order to leave comments, you need to log in
Faced a similar problem in its essence.
I conditionally send several units in a row and want to see on the chart the total number of these units over a period of time. BOLT :)
At first I played with the functions in the graphite itself (graphana), then I got to the bottom of the settings in carbon - I played with them. Nothing happened.
Then, on the carbon offline branch in the Gita, they inserted a brain into me that carbon + graphite is a database of time series with a fixed interval. Those. when several events arrive in a period of time, they are simply overwritten. Well, they advised me to dig towards statsd.
I sit crying, because I have Debian, but there are no ready-made packages for Debian, plus, it works on node.js
The problem has not yet been solved, so if one of the four subscribers has an answer to this topic, I will be sincerely grateful if you share :)
Good luck to everyone!
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question