{"record":{"id":"bc0cdc6a4a4336f4","repo":"jaegertracing/jaeger","slug":"this-query-parameter-is-not-supported-yet","errorCode":null,"errorMessage":"this query parameter is not supported yet","messagePattern":"this query parameter is not supported yet","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"info","filePath":"internal/storage/v1/badger/spanstore/reader.go","lineNumber":46,"sourceCode":"\tErrServiceNameNotSet = errors.New(\"service name must be set\")\n\n\t// ErrStartTimeMinGreaterThanMax occurs when start time min is above start time max\n\tErrStartTimeMinGreaterThanMax = errors.New(\"min start time is above max\")\n\n\t// ErrDurationMinGreaterThanMax occurs when duration min is above duration max\n\tErrDurationMinGreaterThanMax = errors.New(\"min duration is above max\")\n\n\t// ErrMalformedRequestObject occurs when a request object is nil\n\tErrMalformedRequestObject = errors.New(\"malformed request object\")\n\n\t// ErrStartAndEndTimeNotSet occurs when start time and end time are not set\n\tErrStartAndEndTimeNotSet = errors.New(\"start and end time must be set\")\n\n\t// ErrUnableToFindTraceIDAggregation occurs when an aggregation query for TraceIDs fail.\n\tErrUnableToFindTraceIDAggregation = errors.New(\"could not find aggregation of traceIDs\")\n\n\t// ErrNotSupported during development, don't support every option - yet\n\tErrNotSupported = errors.New(\"this query parameter is not supported yet\")\n\n\t// ErrInternalConsistencyError indicates internal data consistency issue\n\tErrInternalConsistencyError = errors.New(\"internal data consistency issue\")\n)\n\nconst (\n\tdefaultNumTraces = 100\n\tsizeOfTraceID    = 16\n\tencodingTypeBits = 0x0F\n)\n\n// TraceReader reads traces from the local badger store\ntype TraceReader struct {\n\tstore *badger.DB\n\tcache *CacheStore\n}\n\n// executionPlan is internal structure to track the index filtering","sourceCodeStart":28,"sourceCodeEnd":64,"githubUrl":"https://github.com/jaegertracing/jaeger/blob/806f4447841ecdb60519f408b004a599d515f437/internal/storage/v1/badger/spanstore/reader.go#L28-L64","documentation":"ErrNotSupported is the badger backend's placeholder for query parameters it does not implement yet, per the source comment ('during development, don't support every option - yet'). It is declared as a public sentinel so callers can errors.Is-check for unsupported features. In the current badger reader no active call site returns it — unsupported parameters are effectively ignored rather than rejected.","triggerScenarios":"Expected when passing query features the badger backend does not plan to honor (e.g. advanced aggregation options in historical code paths). In the shipped code it is declared but not returned, so no current API call produces it.","commonSituations":"Porting applications from ES/Cassandra backends that support richer query parameters to badger; writing portable code that switches on backend-specific unsupported-feature errors; reviewing legacy Jaeger versions where it was returned.","solutions":["Do not rely on badger rejecting unsupported parameters — verify which TraceQueryParameters fields your backend honors and avoid the rest.","Write portable query code that degrades gracefully when a filter is not applied (validate results server-side).","If you need full parameter support, use the Elasticsearch or Cassandra backend instead of badger (badger is aimed at local/development use)."],"exampleFix":"// before\nq := &spanstore.TraceQueryParameters{ServiceName: \"svc\", StartTimeMin: a, StartTimeMax: b, // plus unsupported filters\n}\nids, _ := reader.FindTraceIDs(ctx, q) // silently ignored filters\n// after\nq := &spanstore.TraceQueryParameters{ServiceName: \"svc\", StartTimeMin: a, StartTimeMax: b}\nids, err := reader.FindTraceIDs(ctx, q)\nif err != nil { return err }","handlingStrategy":"fallback","validationCode":"var badgerSupportedFields = map[string]bool{\n\t\"ServiceName\": true, \"OperationName\": true, \"Tags\": true,\n\t\"StartTimeMin\": true, \"StartTimeMax\": true,\n\t\"DurationMin\": true, \"DurationMax\": true, \"NumTraces\": true,\n}\n// strip or reject unsupported fields before querying badger","typeGuard":null,"tryCatchPattern":"ids, err := reader.FindTraceIDs(ctx, q)\nif errors.Is(err, spanstore.ErrNotSupported) {\n\t// degrade: retry with only the universally supported parameters\n\tids, err = reader.FindTraceIDs(ctx, minimalQuery(q))\n}\nif err != nil { return nil, err }","preventionTips":["Restrict queries against the badger backend to the parameters it implements.","Feature-detect backend capabilities in wrapper code and disable unsupported filters in the UI.","Use ES/Cassandra when advanced query features are required; badger targets local/development use.","Add integration tests per backend so silently-ignored filters are caught."],"tags":["go","badger","unsupported-feature","compatibility"],"backgroundTag":"feature-not-supported","analyzedSha":"806f4447841ecdb60519f408b004a599d515f437","analyzedAt":"2026-09-01T02:39:22.140Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T05:18:18.240Z"}