You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have followed this README to set up sentinel prometheus exporter. However, I've observed that the metric name is currently tied to the appName, which is typically the JAR's name or specified by the VM option csp.sentinel.prometheus.app. The logic can be found at SentinelCollector.java#L83.
Querying metrics using appName in PromQL seems unconventional and inconvenient. In scenarios where multiple services enable the Prometheus exporter feature, prometheus will receive numerous distinct metrics that essentially convey the same information.
I propose using a fixed metric name and introducing an additional label (app_name) representing the appName.
Desired Feature
I would like the Prometheus exporter to provide a fixed metric name and an extra label (app_name). This would enable querying with a consistent PromQL expression like sentinel_metric_log{app_name="xx", resource="xxx", type="xxx"}. With this enhancement, every service can be queried using the same PromQL, requiring only the label's value to be adjusted.
The text was updated successfully, but these errors were encountered:
Issue Description
Type: Enhancement
I have followed this README to set up sentinel prometheus exporter. However, I've observed that the metric name is currently tied to the
appName
, which is typically the JAR's name or specified by the VM optioncsp.sentinel.prometheus.app
. The logic can be found at SentinelCollector.java#L83.Querying metrics using
appName
in PromQL seems unconventional and inconvenient. In scenarios where multiple services enable the Prometheus exporter feature, prometheus will receive numerous distinct metrics that essentially convey the same information.I propose using a fixed metric name and introducing an additional label (
app_name
) representing theappName
.Desired Feature
I would like the Prometheus exporter to provide a fixed metric name and an extra label (
app_name
). This would enable querying with a consistent PromQL expression likesentinel_metric_log{app_name="xx", resource="xxx", type="xxx"}
. With this enhancement, every service can be queried using the same PromQL, requiring only the label's value to be adjusted.The text was updated successfully, but these errors were encountered: