Skip to content

Commit b990a44

Browse files
Fix bug: assign error rate values to ErrorRate field instead of ResponseTime field
1 parent 06e1d98 commit b990a44

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

internal/apm/apm.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -200,15 +200,15 @@ func NewServiceSummaryHandler(client *http.Client, cfg models.Config) func(mcp.C
200200
valStr, _ := r.Value[1].(string)
201201
val, _ := strconv.ParseFloat(valStr, 64)
202202
if summary, ok := promResp[serviceName]; ok {
203-
summary.ResponseTime = val
203+
summary.ErrorRate = val
204204
promResp[serviceName] = summary
205205
} else {
206206
promResp[serviceName] = ServiceSummary{
207207
ServiceName: serviceName,
208208
Env: env,
209209
Throughput: 0,
210-
ErrorRate: 0,
211-
ResponseTime: val,
210+
ErrorRate: val,
211+
ResponseTime: 0,
212212
}
213213
}
214214
}

0 commit comments

Comments
 (0)