1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-25 00:07:47 +01:00

fix: Sliding window functionality for summaries (#1999)

Make the percentile metrics more adaptive to changes.
https://github.com/siimon/prom-client#summary
This commit is contained in:
Ivar Conradi Østhus 2022-08-30 13:53:28 +02:00 committed by GitHub
parent 1c752590d5
commit 8ef7789769
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -50,12 +50,16 @@ export default class MetricsMonitor {
help: 'App response time',
labelNames: ['path', 'method', 'status'],
percentiles: [0.1, 0.5, 0.9, 0.95, 0.99],
maxAgeSeconds: 600,
ageBuckets: 5,
});
const dbDuration = new client.Summary({
name: 'db_query_duration_seconds',
help: 'DB query duration time',
labelNames: ['store', 'action'],
percentiles: [0.1, 0.5, 0.9, 0.95, 0.99],
maxAgeSeconds: 600,
ageBuckets: 5,
});
const featureToggleUpdateTotal = new client.Counter({
name: 'feature_toggle_update_total',