mirror of
https://github.com/eolinker/apinto
synced 2025-10-20 23:40:13 +08:00
指标设置默认值
This commit is contained in:
@@ -43,7 +43,11 @@ func ReadProxy(ctx http_context.IHttpContext) []IPoint {
|
||||
"node": globalLabels["node_id"],
|
||||
}
|
||||
for key, label := range labels {
|
||||
labelMetrics[key] = ctx.GetLabel(label)
|
||||
value := ctx.GetLabel(label)
|
||||
if value == "" {
|
||||
value = "-"
|
||||
}
|
||||
labelMetrics[key] = value
|
||||
}
|
||||
|
||||
for _, key := range proxyRequestMetrics {
|
||||
|
Reference in New Issue
Block a user