diff options
| author | Shulhan <ms@kilabit.info> | 2018-11-30 15:20:58 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2018-11-30 15:20:58 +0700 |
| commit | c61d03ab8d355ac7d14ee86e29599e67fb2c5a66 (patch) | |
| tree | 5a93ad9b35e56d6e209974e13961765fd18a6ff4 | |
| parent | 57399dafaef33bc715502ad6a7751aa1dfc83036 (diff) | |
| download | haminer-c61d03ab8d355ac7d14ee86e29599e67fb2c5a66.tar.xz | |
influxdb: add tag http status code
| -rw-r--r-- | influxdb.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/influxdb.go b/influxdb.go index de25f4a..d266100 100644 --- a/influxdb.go +++ b/influxdb.go @@ -18,7 +18,8 @@ const ( "haproxy," + // tags "host=%q," + - "frontend=%q,backend=%q,server=%q" + + "frontend=%q,backend=%q,server=%q," + + "http_status_code=%d" + " " + // fields "http_proto=%q,http_method=%q,http_url=%q," + @@ -122,6 +123,7 @@ func (cl *InfluxdbClient) write(halogs []*Halog) (err error) { // tags cl.hostname, l.FrontendName, l.BackendName, l.ServerName, + l.HTTPStatus, // fields l.HTTPProto, l.HTTPMethod, l.HTTPURL, l.HTTPQuery, l.HTTPStatus, |
