mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-08-11 10:38:59 +08:00
feat: add errorCount in top_operations API (#2636)
This commit is contained in:
parent
5ad367a0fc
commit
33ac5b79be
@ -1854,6 +1854,7 @@ func (r *ClickHouseReader) GetTopOperations(ctx context.Context, queryParams *mo
|
||||
quantile(0.95)(durationNano) as p95,
|
||||
quantile(0.99)(durationNano) as p99,
|
||||
COUNT(*) as numCalls,
|
||||
countIf(statusCode=2) as errorCount,
|
||||
name
|
||||
FROM %s.%s
|
||||
WHERE serviceName = @serviceName AND timestamp>= @start AND timestamp<= @end`,
|
||||
|
@ -272,6 +272,7 @@ type TopOperationsItem struct {
|
||||
Percentile95 float64 `json:"p95" ch:"p95"`
|
||||
Percentile99 float64 `json:"p99" ch:"p99"`
|
||||
NumCalls uint64 `json:"numCalls" ch:"numCalls"`
|
||||
ErrorCount uint64 `json:"errorCount" ch:"errorCount"`
|
||||
Name string `json:"name" ch:"name"`
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user