tail_exporter

command module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 12, 2017 License: Apache-2.0 Imports: 21 Imported by: 0

README

Build Status Coverage Status Go Report Card

Tail Exporter

This is a prometheus exporter in a similar vein as mtail, but implemented to be able to read on TCP sockets, and with a YAML format. It is also capable of reading from log files or pipes.

It links against the libpcre library for faster regex'ing.

Configuration File

The configuration file is based on YAML. Prometheus metrics are required to have a consistent set of labels, but metrics may be repeated in the config file to allow multiple regexes to populate different timeseries.

Example

Counting mail processing stages from exim:

metric_configs:
- name: exim_mail_count
  help: counter of mail processing results
  type: counter
  regex: '^METRICS: uuid=(\S+) result=(\S+)'
  labels:
  - name: uuid
    value: $1
  - name: result
    value: $2
  value: increment
  timeout: 15m

TODO

The lockfree hashmap used is non-deterministic on inserts being available before the next line is processed. We need to add an intermediate queue operation to wait of the hashmap to reflect an insert being complete.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL