fluent/fluentd-docs

Parser plugin page does not show detailed usage examples

kriston13 opened this issue · 2 comments

The Parser plugin overview page describes how to "use" a plugin, by stating to call it by name.

The given example is:

<source>
  @type tail
  path /path/to/input/file
  format my_custom_parser
</source>

However, this only uses the default parameters. How would a person then specify the additional parameter configurations?

This is alluded to in the individual parser pages like CSV, or multiline, but it's not clearly called out.

I suggest having an example that is broader. Something more like:

<source>
  @type tail
  path /path/to/input/file
  format a_parser
  a_parser_configuration configuration
  another_parser_configuration another_configuration
</source>

Then with an actual example of something like

  @type tail
  path /path/to/file
  format json
  time_key timestamp
  time_format YYYY/MM/DDTHH:mm:ss

Thoughts?

I basically agree with you that the current example is somewhat ill chosen.

I suggest having an example that is broader. Something more like:

My impression is that most users are looking forward to something very
concrete that is (almost) directly copy-pastable, and not much grateful
for abstract one.

So here is my patch to address the issue: #534

If you have any option about the patch, please let me know.

OK. Now I have merged #534.

If you have noticed anything about it, please comment here.