79275243

Date: 2024-12-12 13:17:00
Score: 1
Natty:
Report link

This just works for me, and then I can do whatever I want with the logs. e.g. calculating metrics:

  pipeline_stages:
  - decolorize:
  - regex:
      expression: 'REQUEST FINISHED:.*-\s(?P<latency>\d+)ms$'
      action: keep
  - metrics:
      insly_request_latency_ms:
        type: Histogram
        description: "Histogram of request latencies (ms)"
        source: latency
        config:
          buckets: [100, 250, 500, 1000, 5000, 10000, 30000, 60000]

https://grafana.com/docs/loki/latest/send-data/promtail/stages/decolorize/

Reasons:
  • Whitelisted phrase (-1): works for me
  • RegEx Blacklisted phrase (1): I want
  • Probably link only (1):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Florin Marin