Like Prometheus, but for logs.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
loki/production/loki-mixin/recording_rules.libsonnet

13 lines
610 B

local utils = import 'mixin-utils/utils.libsonnet';
{
prometheusRules+:: {
groups+: [{
name: 'loki_rules',
rules:
utils.histogramRules('loki_request_duration_seconds', [$._config.per_cluster_label, 'job'], $._config.recording_rules_range_interval) +
utils.histogramRules('loki_request_duration_seconds', [$._config.per_cluster_label, 'job', 'route'], $._config.recording_rules_range_interval) +
utils.histogramRules('loki_request_duration_seconds', [$._config.per_cluster_label, 'namespace', 'job', 'route'], $._config.recording_rules_range_interval),
}],
},
}