{"record":{"id":"5d03bbf3b2d4e625","repo":"quarkusio/quarkus","slug":"unrecognized-aggregation-temporality","errorCode":null,"errorMessage":"Unrecognized aggregation temporality: ","messagePattern":"Unrecognized aggregation temporality: ","errorType":"exception","errorClass":"ConfigurationException","httpStatus":null,"severity":"error","filePath":"extensions/opentelemetry/runtime/src/main/java/io/quarkus/opentelemetry/runtime/exporter/otlp/OTelExporterRecorder.java","lineNumber":363,"sourceCode":"                    .getDefault()\n                    .with(InstrumentType.HISTOGRAM, Aggregation.base2ExponentialBucketHistogram());\n\n        } else {\n            throw new ConfigurationException(\n                    \"Unrecognized default histogram aggregation: \" + defaultHistogramAggregation);\n        }\n        return aggregationSelector;\n    }\n\n    private static AggregationTemporalitySelector aggregationTemporalityResolver(OtlpExporterMetricsConfig metricsConfig) {\n        String temporalityValue = metricsConfig.temporalityPreference()\n                .map(s -> s.toLowerCase(Locale.ROOT))\n                .orElse(\"cumulative\");\n        AggregationTemporalitySelector temporalitySelector = switch (temporalityValue) {\n            case \"cumulative\" -> AggregationTemporalitySelector.alwaysCumulative();\n            case \"delta\" -> AggregationTemporalitySelector.deltaPreferred();\n            case \"lowmemory\" -> AggregationTemporalitySelector.lowMemory();\n            default -> throw new ConfigurationException(\"Unrecognized aggregation temporality: \" + temporalityValue);\n        };\n        return temporalitySelector;\n    }\n\n    private static boolean determineCompression(OtlpExporterConfig config) {\n        if (config.compression().isPresent()) {\n            return (config.compression().get() == CompressionType.GZIP);\n        }\n        return false;\n    }\n\n    private static Map<String, String> populateTracingExportHttpHeaders(OtlpExporterConfig config) {\n        Map<String, String> headersMap = new HashMap<>();\n        OtlpUserAgent.addUserAgentHeader(headersMap::put);\n        if (config.headers().isPresent()) {\n            List<String> headers = config.headers().get();\n            if (!headers.isEmpty()) {\n                for (String header : headers) {","sourceCodeStart":345,"sourceCodeEnd":381,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/extensions/opentelemetry/runtime/src/main/java/io/quarkus/opentelemetry/runtime/exporter/otlp/OTelExporterRecorder.java#L345-L381","documentation":"`quarkus.otel.exporter.otlp.metrics.aggregation_temporality` accepts only `cumulative`, `delta`, or `lowmemory` (case-insensitive). Any other value makes `aggregationTemporalityResolver` throw a ConfigurationException. Temporality controls how metric values are reported to the collector.","triggerScenarios":"Setting `quarkus.otel.exporter.otlp.metrics.aggregation_temporality` to an unrecognized value such as `low-memory`, `deltatemporal`, or `cumulative_only`.","commonSituations":"Confusing upstream OTel temporality preference strings with Quarkus' three-value set; hyphenating `lowmemory`; typos in long property names.","solutions":["Set the value to `cumulative` (default)","Or `delta` if your collector prefers delta temporality","Or `lowmemory` for the low-memory temporality selector","Mind the exact spelling — `lowmemory` has no space or hyphen"],"exampleFix":"# before\nquarkus.otel.exporter.otlp.metrics.aggregation_temporality=low-memory\n# after\nquarkus.otel.exporter.otlp.metrics.aggregation_temporality=lowmemory","handlingStrategy":"validation","validationCode":"String t = ConfigProvider.getConfig().getOptionalValue(\"quarkus.otel.exporter.otlp.metrics.aggregation_temporality\", String.class).orElse(\"cumulative\");\nif (!java.util.List.of(\"cumulative\", \"delta\", \"lowmemory\").contains(t.toLowerCase(java.util.Locale.ROOT))) {\n    throw new IllegalArgumentException(\"Invalid aggregation_temporality: \" + t);\n}","typeGuard":"static boolean isSupportedTemporality(String t) {\n    String v = t == null ? \"cumulative\" : t.toLowerCase(java.util.Locale.ROOT);\n    return java.util.List.of(\"cumulative\", \"delta\", \"lowmemory\").contains(v);\n}","tryCatchPattern":"try {\n    app.start();\n} catch (RuntimeException e) {\n    if (String.valueOf(e.getMessage()).startsWith(\"Unrecognized aggregation temporality\")) {\n        LOG.error(\"Use cumulative, delta, or lowmemory\");\n    }\n}","preventionTips":["Remember the exact token `lowmemory` (no hyphen/space)","The value is case-insensitive but spelling must match exactly","Document the chosen temporality next to collector config since it affects data shape"],"tags":["opentelemetry","configuration","metrics","temporality"],"backgroundTag":"invalid-enum-config-value","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}