mirror of
https://github.com/Unleash/unleash.git
synced 2025-05-17 01:17:29 +02:00
chore: expose custom strategy metrics in prometheus (#9657)
## About the changes These metrics are sent to version info but not exposed in prometheus and they can provide valuable data about their usage
This commit is contained in:
parent
ef1b6ec227
commit
d11f39e401
@ -422,6 +422,20 @@ export function registerPrometheusMetrics(
|
||||
map: (result) => ({ value: result }),
|
||||
});
|
||||
|
||||
dbMetrics.registerGaugeDbMetric({
|
||||
name: 'custom_strategies_total',
|
||||
help: 'Number of custom strategies',
|
||||
query: () => instanceStatsService.customStrategiesCount(),
|
||||
map: (result) => ({ value: result }),
|
||||
});
|
||||
|
||||
dbMetrics.registerGaugeDbMetric({
|
||||
name: 'custom_strategies_in_use_total',
|
||||
help: 'Number of custom strategies in use',
|
||||
query: () => instanceStatsService.customStrategiesInUseCount(),
|
||||
map: (result) => ({ value: result }),
|
||||
});
|
||||
|
||||
dbMetrics.registerGaugeDbMetric({
|
||||
name: 'client_apps_total',
|
||||
help: 'Number of registered client apps aggregated by range by last seen',
|
||||
|
Loading…
Reference in New Issue
Block a user