Closed stevenjm closed 5 years ago
I want to confirm it works. Do you have an example of configuration to use timekeys?
I want to confirm it works. Do you have an example of configuration to use timekeys?
Sorry for the delayed response. Here's a minimal config to test this change:
<source>
@type dummy
@id test
tag test
</source>
<source>
@type prometheus
@id prometheus
bind 127.0.0.1
port 24231
</source>
<source>
@type prometheus_monitor
@id prometheus_monitor
</source>
<source>
@type prometheus_output_monitor
@id prometheus_output_monitor
</source>
<match test>
@type stdout
@id out
<buffer time>
timekey 5s
timekey_wait 2s
</buffer>
</match>
thanks. I confirmed it worked.
A metric listing all timekeys in each buffer was added to fluentd in https://github.com/fluent/fluentd/pull/2343. This exports the oldest and newest values in that list as Prometheus metrics. See discussion in https://github.com/fluent/fluent-plugin-prometheus/issues/89 for context and rationale.