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
chore: add fillZero function to query builder functions list (#9651)
Amlan Kumar Nandye9afbede2473
diff --git a/frontend/src/constants/queryFunctionOptions.ts b/frontend/src/constants/queryFunctionOptions.tsindex fb7fdbe577..9653c13574 100644--- a/frontend/src/constants/queryFunctionOptions.ts+++ b/frontend/src/constants/queryFunctionOptions.ts@@ -68,8 +68,8 @@ export const metricQueryFunctionOptions: SelectOption<string, string>[] = [label: 'Time Shift',},{- value: QueryFunctionsTypes.TIME_SHIFT,- label: 'Time Shift',+ value: QueryFunctionsTypes.FILL_ZERO,+ label: 'Fill Zero',},];@@ -156,4 +156,7 @@ export const queryFunctionsTypesConfig: QueryFunctionConfigType = {showInput: true,inputType: 'text',},+ fillZero: {+ showInput: false,+ },};diff --git a/frontend/src/types/common/queryBuilder.ts b/frontend/src/types/common/queryBuilder.tsindex d4eb2bb393..ff6de1820b 100644--- a/frontend/src/types/common/queryBuilder.ts+++ b/frontend/src/types/common/queryBuilder.ts@@ -208,6 +208,7 @@ export enum QueryFunctionsTypes {MEDIAN_5 = 'median5',MEDIAN_7 = 'median7',TIME_SHIFT = 'timeShift',+ FILL_ZERO = 'fillZero',}export type PanelTypeKeys =diff --git a/frontend/src/utils/functionNameNormalizer.test.ts b/frontend/src/utils/functionNameNormalizer.test.tsindex 7ed2127511..3e03a5d6d8 100644--- a/frontend/src/utils/functionNameNormalizer.test.ts+++ b/frontend/src/utils/functionNameNormalizer.test.ts@@ -59,6 +59,9 @@ describe('functionNameNormalizer', () => {expect(normalizeFunctionName('median5')).toBe(QueryFunctionsTypes.MEDIAN_5);expect(normalizeFunctionName('median7')).toBe(QueryFunctionsTypes.MEDIAN_7);expect(normalizeFunctionName('anomaly')).toBe(QueryFunctionsTypes.ANOMALY);+ expect(normalizeFunctionName('fillzero')).toBe(+ QueryFunctionsTypes.FILL_ZERO,+ );});});diff --git a/frontend/src/utils/functionNameNormalizer.ts b/frontend/src/utils/functionNameNormalizer.tsindex 1d9aa1a887..b02bb89d06 100644--- a/frontend/src/utils/functionNameNormalizer.ts+++ b/frontend/src/utils/functionNameNormalizer.ts@@ -27,6 +27,7 @@ export const normalizeFunctionName = (functionName: string): string => {median5: QueryFunctionsTypes.MEDIAN_5,median7: QueryFunctionsTypes.MEDIAN_7,anomaly: QueryFunctionsTypes.ANOMALY,+ fillzero: QueryFunctionsTypes.FILL_ZERO,};// Convert to lowercase for case-insensitive matching