{"record":{"id":"134c87e54e15d00a","repo":"prestodb/presto","slug":"not-supported-134c87","errorCode":"NOT_SUPPORTED","errorMessage":"Unsupported type ${type}","messagePattern":"Unsupported type (.+?)","errorType":"error_code","errorClass":"PrestoException","httpStatus":null,"severity":"error","filePath":"presto-prometheus/src/main/java/com/facebook/presto/plugin/prometheus/PrometheusRecordCursor.java","lineNumber":232,"sourceCode":"\n    @Override\n    public boolean getBoolean(int field)\n    {\n        return true;\n    }\n\n    @Override\n    public long getLong(int field)\n    {\n        Type type = getType(field);\n        if (type.equals(TIMESTAMP_WITH_TIME_ZONE)) {\n            Instant dateTime = (Instant) requireNonNull(getFieldValue(field));\n            // render with the fixed offset of the Presto server\n            int offsetMinutes = dateTime.atZone(ZoneId.systemDefault()).getOffset().getTotalSeconds() / 60;\n            return packDateTimeWithZone(dateTime.toEpochMilli(), offsetMinutes);\n        }\n        else {\n            throw new PrestoException(NOT_SUPPORTED, \"Unsupported type \" + getType(field));\n        }\n    }\n\n    @Override\n    public double getDouble(int field)\n    {\n        checkFieldType(field, DOUBLE);\n        return (double) getFieldValue(field);\n    }\n\n    @Override\n    public Slice getSlice(int field)\n    {\n        checkFieldType(field, createUnboundedVarcharType());\n        return Slices.utf8Slice((String) requireNonNull(getFieldValue(field)));\n    }\n\n    @Override","sourceCodeStart":214,"sourceCodeEnd":250,"githubUrl":"https://github.com/prestodb/presto/blob/55bb57d202de3b926896fa966c2c4a44c779634e/presto-prometheus/src/main/java/com/facebook/presto/plugin/prometheus/PrometheusRecordCursor.java#L214-L250","documentation":"Type dispatch guard in PrometheusRecordCursor.getLong: the column's Type is not one the cursor can convert to a long (only TIMESTAMP_WITH_TIME_ZONE is handled here), so the unsupported type is reported. Fires on schema/connector drift rather than data problems.","triggerScenarios":"Thrown at presto-prometheus/src/main/java/com/facebook/presto/plugin/prometheus/PrometheusRecordCursor.java:232 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Only select columns whose Prometheus types map to supported Presto types","Add a mapping branch for the new type in getLong if support is needed","Check the connector type mapping configuration"],"exampleFix":null,"handlingStrategy":"type-guard","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"55bb57d202de3b926896fa966c2c4a44c779634e","analyzedAt":"2026-09-04T12:50:26.162Z","contentChangedAt":"2026-09-04T12:50:26.162Z","schemaVersion":2},"datasetVersion":"2026-09-11T21:17:09.523Z"}