fluent-plugin-stats-notifier 
Fluentd plugin to calculate statistics and then thresholding
Configuration
Assuming following inputs are coming:
foo.bar1: {"4xx_count":1,"foobar":2"}
foo.bar2: {"4xx_count":6,"":2"}
then this plugin emits an message because the max of 4xx_count is greater than or equal to the specified value 4. Output will be as following:
notifier: {"4xx_count":6.0}
Parameters
target_key (required)
The target key in the event record.
interval
The interval time of calculation and bounding. Default is 60.
less_than
A
less thanthreshold value, that is, emit iftarget_keyvalue < specified value.less_equal
A
less than or eqaulthreshold value, that is, emit iftarget_keyvalue <= specified value.greater_than
A
greater thanthreshold value, that is, emit iftarget_keyvalue > specified value.greater_equal
A
greater than or eqaulthreshold value, that is, emit iftarget_keyvalue >= specified value.compare_with
max,avg,min,sumcan be specified. Default ismax.tag
The output tag name. Required for
aggregate all.add_tag_prefix
Add tag prefix for output message. Required for
aggregate tag.aggragate
Do calculation for each
tagorall. The defaultisall.store_file
Store internal data into a file of the given path on shutdown, and load on starting.
ChangeLog
See CHANGELOG.md for details.
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create new Pull Request
Copyright
Copyright (c) 2013 Naotoshi Seo. See LICENSE for details.