diff options
author | Boss Marco <bossm8@bfh.ch> | 2022-06-08 13:58:35 +0200 |
---|---|---|
committer | Boss Marco <bossm8@bfh.ch> | 2022-06-08 13:58:35 +0200 |
commit | 964dcdd46192a18823b1a7d927a58c5aad7e110e (patch) | |
tree | ba9e4d3d8c7c924f155a2f1700daedc4b6dd1681 | |
parent | aaa90612b2c7e7330777195c9e534e3822801ed9 (diff) | |
download | grid5k-964dcdd46192a18823b1a7d927a58c5aad7e110e.tar.gz grid5k-964dcdd46192a18823b1a7d927a58c5aad7e110e.tar.bz2 grid5k-964dcdd46192a18823b1a7d927a58c5aad7e110e.zip |
fix template
-rw-r--r-- | configs/etc/monitor/promtail.yaml | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/configs/etc/monitor/promtail.yaml b/configs/etc/monitor/promtail.yaml index f87698d..9187129 100644 --- a/configs/etc/monitor/promtail.yaml +++ b/configs/etc/monitor/promtail.yaml @@ -77,10 +77,13 @@ scrape_configs: selector: '{job="proxy"}' stages: - regex: - expression: 'uri=/(?P<ep>[a-zA-Z]+)(?:/\w+)?(?:/(?P<act>[a-zA-Z-]+))? s=(?P<status>\d{3}).*urt=(?P<upstream_response_time>\d+\.\d+) rt=(?P<response_time>\d+\.\d+) rl=(?P<request_length>\d+) bs=(?P<bytes_sent>\d+)' + expression: 'uri=/(?P<ep>[a-zA-Z]+)(?:/\w+)?(?:/(?P<act>[a-zA-Z-]+))? s=(?P<status>\d{3}).*urt=(?P<urt>\d+\.\d+|-) rt=(?P<response_time>\d+\.\d+) rl=(?P<request_length>\d+) bs=(?P<bytes_sent>\d+)' - template: source: endpoint template: '{{ printf "%s-%s" .ep .act | trimSuffix "-" }}' + - template: + source: upstream_response_time + template: '{{ .urt | replace "-" "0" }}' - labels: endpoint: status: |