README.md in fluent-plugin-elastic-log-0.4.1 vs README.md in fluent-plugin-elastic-log-0.4.2

- old
+ new

@@ -1,41 +1,66 @@ # fluent-plugin-elastic-log -[Fluentd](https://fluentd.org/) filter plugin to do something. +[Fluentd](https://fluentd.org/) filter plugin to process elastic logs. -TODO: write description for you plugin. +## plugins -## Installation +### out - elastic_audit_log_metric -### RubyGems +process audit logs and transform to metrics. +Example: + +``` conf +<match my_tag_pattern> + @type elastic_audit_log_metric + + tag elastic_audit_log_metric + timestamp_key timestamp + timestamp_format epochmillis + prefix tags_ +</match> ``` -$ gem install fluent-plugin-elastic-log -``` -### Bundler +parameters are: +* tag : Tag to emit metric events -Add following line to your Gemfile: +parameters for input record: +* categories: Categories selected to be converted to metrics +* category_key: Category key in input record +* layer_key: Layer key in input record +* request_type_key: Request type key in input record +* cluster_key: Cluster key in input record +* user_key: Request user key in input record +* indices_key: Indices key in input record +* r_indices_key: Resolved indices key in input record +* timestamp_key: Timestamp key in input record +* privilege_key: Request privilege key in input record -```ruby -gem "fluent-plugin-elastic-log" -``` +parameters for output metric: +* timestamp_format: Timestamp format (iso, epochmillis, epochmillis_str) +* prefix: Attribute prefix for output metric +* aggregate_ilm: Aggregate ILM on resolved indices -And then execute: +More details from the +[elastic_audit_log_metric output plugin code](lib/fluent/plugin/out_elastic_audit_log_metric.rb#L49) -``` -$ bundle -``` +## Installation -## Configuration -You can generate configuration template: +Manual install, by executing: -``` -$ fluent-plugin-config-format filter elastic-log -``` + $ gem install fluent-plugin-elastic-log -You can copy and paste generated documents here. +Add to Gemfile with: + + $ bundle add fluent-plugin-elastic-log + +## Compatibility + +plugin in 1.x.x will work with: +- ruby >= 2.4.10 +- td-agent >= 3.8.1-0 ## Copyright * Copyright(c) 2023- Thomas Tych * License