🚀 DAY 5 OF LAUNCH WEEK: Introducing Socket Firewall Enterprise.Learn more →
Socket
Book a DemoInstallSign in
Socket

fluent-plugin-inline-classifier

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fluent-plugin-inline-classifier

bundlerRubygems
Version
0.1.0
Version published
Maintainers
1
Created
Source

fluent-plugin-inline-classifier

Build Status

fluent-plugin-inline-classifier is a plugin for Fluentd, which provides some features to classify each incoming message. A new keys added into the message and that values hold classified result by user-defined rules.

This is especially useful for converting numeric values into some categories. Because categories are limited, classified messages is easy to grep, or even easy to search by Elasticsearch and Kibana!

The plugin tested on ruby 1.9.3-p448 and fluentd-0.10.45.

Installation

Using gem:

$ gem install fluent-plugin-inline-classifier

Configuration

To use the plugin, specify type to inline_classifier. Also, add_prefix and remove_prefix are needed in most cases to prevent the loop.

Each classifying rule is specified in the rule section. rule sections can be written multiple times.

  • key: specifies the input key of each message, the corresponding value is used to classify.
  • type: specifies classifier type, currently supported value is range only.
  • store: specifies the output key of each message, a classified result stores to the corresponding value.
  • classN: specifies class name and conditions which depend on classifier type. N is a integer number. Classifiers evaluate conditions in the order of N and determine what a class is by a first matching condition.

range classifier

Conditions specified as min max form. A min value is inclusive, by contrast, a max value is exclusive. min and max values have a special form *, which means the classifier no matter what a value is.

Note: * * is not supported currently.

<match raw.**>
  type inline_classifier
  add_prefix classified
  remove_prefix raw
  <rule>
    key reqtime
    type range
    store speed
    class1 fast * 0.1
    class2 normal 0.1 0.5
    class3 slow 0.5 *
  </rule>
</match>

License

Apache License, Version 2.0

FAQs

Package last updated on 19 Apr 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts