fluent-plugin-tag_rewrite
Overview
Rewrite tag for Fluentd. It is designed to rewrite the tags and re-emit the record with rewritten tag. Values can only be added at the start or the end of the tag.
This is an output plugin because fluentd's filter doesn't allow tag rewriting.
Installation
gem install fluent-plugin-tag_rewrite
Configuration
<match **>
@type tag_rewrite
tag_prefix start
tag_suffix end
</match>
You must provide at least one of tag_prefix or tag_suffix
Example
If your fluentd match configuration is the same as above followed by a match configuration like this:
<match start.fluent.**>
@type stdout
</match>
The output will be:
| original record | rewritten tag record |
|---------------------------------------|-------------------------------------------------|
| fluent.warn {"message":"[info]: ..."} | start.fluent.warn.end {"message":"[info]: ..."} |
Requirements
fluent-plugin-tag_rewrite | fluentd |
---|---|
>= 1.0.0 | >= v1.14.0 < 2 |
Contributing
- Fork it ( http://github.com/tombolaltd/fluent-plugin-tag_rewrite/fork )
- 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 a new Pull Request
Copyright
Copyright (c) 2019 - tombola.
License
The gem is available as open source under the terms of the MIT License.