Skip to content

temoon/fluent-plugin-array-spin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fluent-plugin-array-spin

Fluentd filter plugin to spin entry with an array field into multiple entries.

Examples

In:

{"foo": "bar", "baz": [{"a": 1}, {"a": 2}, {"b": 3}]}

Out:

{"foo": "bar", "a": 1}
{"foo": "bar", "a": 2}
{"foo": "bar", "b": 3}

In:

{"foo": "bar", "baz": [1, 2, {"b": 3}]}

Out:

{"foo": "bar", "data": 1}
{"foo": "bar", "data": 2}
{"foo": "bar", "b": 3}

Installation

RubyGems

$ gem install fluent-plugin-array-spin

Bundler

Add following line to your Gemfile:

gem "fluent-plugin-array-spin"

And then execute:

$ bundle

Configuration

  • key_name (string) (required): Key name to spin

  • reserve_key (bool) (optional): Keep original key in parsed result.

  • hash_value_field (string) (optional): Store parsed values as a hash value in a field in case of value is not an object.

    • Default value: data.
  • See also: Filter Plugin Overview

Copyright

  • Copyright(c) 2017, Tema Novikov
  • License
    • Apache License, Version 2.0

About

Fluent Plugin: Array spin

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages