SigNoz is an open-source, OpenTelemetry-native observability platform for your team and their AI agents. Get logs, metrics, and traces in one tool with features like APM, distributed tracing, log management, infra monitoring, etc. Combined with SigNoz MCP and a native AI teammate (in SigNoz Cloud) it helps you build more resilient apps.
TypeScript apmapplication-monitoringdistributed-tracinggogood-first-issuejaegerloglogsmetricsmonitoringnextjsobservabilityopen-sourceopentelemetryprometheusreactreactjsself-hostedtracingtypescript
fix: remove the top 10 limit on key operations table (#2824)
Srikanth Chekuria52c104562b8
diff --git a/pkg/query-service/app/clickhouseReader/reader.go b/pkg/query-service/app/clickhouseReader/reader.goindex 30d551e4b8..b12d3bbd9e 100644--- a/pkg/query-service/app/clickhouseReader/reader.go+++ b/pkg/query-service/app/clickhouseReader/reader.go@@ -1870,14 +1870,18 @@ func (r *ClickHouseReader) GetTopOperations(ctx context.Context, queryParams *moif errStatus != nil {return nil, errStatus}- query += " GROUP BY name ORDER BY p99 DESC LIMIT 10"+ query += " GROUP BY name ORDER BY p99 DESC"+ if queryParams.Limit > 0 {+ query += " LIMIT @limit"+ args = append(args, clickhouse.Named("limit", queryParams.Limit))+ }err := r.db.Select(ctx, &topOperationsItems, query, args...)zap.S().Debug(query)if err != nil {zap.S().Error("Error in processing sql query: ", err)- return nil, &model.ApiError{Typ: model.ErrorExec, Err: fmt.Errorf("Error in processing sql query")}+ return nil, &model.ApiError{Typ: model.ErrorExec, Err: fmt.Errorf("error in processing sql query")}}if topOperationsItems == nil {diff --git a/pkg/query-service/model/queryParams.go b/pkg/query-service/model/queryParams.goindex a94f57ad02..429471616f 100644--- a/pkg/query-service/model/queryParams.go+++ b/pkg/query-service/model/queryParams.go@@ -160,6 +160,7 @@ type GetTopOperationsParams struct {Start *time.TimeEnd *time.TimeTags []TagQueryParam `json:"tags"`+ Limit int `json:"limit"`}type GetUsageParams struct {