{"record":{"id":"cddc41d185dca936","repo":"prestodb/presto","slug":"not-supported-cddc41","errorCode":"NOT_SUPPORTED","errorMessage":"NOT_SUPPORTED (message from NotSupportedException)","messagePattern":"NOT_SUPPORTED \\(message from NotSupportedException\\)","errorType":"error_code","errorClass":"PrestoException","httpStatus":null,"severity":"error","filePath":"presto-hive/src/main/java/com/facebook/presto/hive/util/TempFileWriter.java","lineNumber":106,"sourceCode":"                    ORC,\n                    LZ4,\n                    Optional.empty(),\n                    NO_ENCRYPTION,\n                    OrcWriterOptions.builder()\n                            .withMaxStringStatisticsLimit(new DataSize(0, BYTE))\n                            .withFlushPolicy(DefaultOrcWriterFlushPolicy.builder()\n                                    .withStripeMinSize(new DataSize(64, MEGABYTE))\n                                    .build())\n                            .withDictionaryMaxMemory(new DataSize(1, MEGABYTE))\n                            .build(),\n                    ImmutableMap.of(),\n                    UTC,\n                    false,\n                    OrcWriteValidationMode.BOTH,\n                    NOOP_WRITER_STATS);\n        }\n        catch (NotSupportedException e) {\n            throw new PrestoException(NOT_SUPPORTED, e.getMessage(), e);\n        }\n    }\n}\n","sourceCodeStart":88,"sourceCodeEnd":110,"githubUrl":"https://github.com/prestodb/presto/blob/55bb57d202de3b926896fa966c2c4a44c779634e/presto-hive/src/main/java/com/facebook/presto/hive/util/TempFileWriter.java#L88-L110","documentation":"TempFileWriter.createOrcFileWriter builds an ORC writer for spilled temporary data using the aircompressor/encoder stack, which can throw org.apache.parquet/aircompressor NotSupportedException for unsupported compression codecs. The code converts it to a PrestoException with NOT_SUPPORTED so the failure is reported as a configuration/capability problem rather than an internal error.","triggerScenarios":"Creating an ORC temp file writer with a HiveWriterFactory compression codec the ORC writer implementation does not support — e.g. hive.compression-codec set to a codec (LZ4, ZSTD on older builds) not compiled in for this writer path.","commonSituations":"Cluster configured with an exotic compression codec while the spill path only supports GZIP/SNAPPY/ZSTD depending on version; upgrading Presto changes the supported codec set; copy-pasted codec name typo in catalog properties.","solutions":["Set hive.compression-codec to a supported value (GZIP, SNAPPY, or ZSTD if your version supports it) in the Hive catalog properties.","Check the exact NotSupportedException message for the unsupported codec/feature name.","Upgrade Presto if the desired codec is supported in a newer release.","For temp/spill files, consider keeping the default compression since temp data is short-lived."],"exampleFix":"// before (hive.properties)\nhive.compression-codec=LZ4\n// after\nhive.compression-codec=ZSTD\n","handlingStrategy":"validation","validationCode":"Set<String> supported = Set.of(\"GZIP\", \"SNAPPY\", \"ZSTD\");\nif (!supported.contains(compressionCodec.toUpperCase())) {\n    throw new IllegalArgumentException(\"unsupported codec for ORC temp writer: \" + compressionCodec);\n}","typeGuard":null,"tryCatchPattern":"try {\n    writer = TempFileWriter.createOrcFileWriter(...);\n} catch (PrestoException e) {\n    if (e.getErrorCode() == StandardErrorCode.NOT_SUPPORTED.toErrorCode()) {\n        // fall back to default compression\n    }\n}","preventionTips":["Pin hive.compression-codec to a codec known supported by your Presto version for ORC writes.","After upgrades, re-validate catalog properties against release notes.","Use default compression for spill/temp files — it is short-lived data."],"tags":["hive","orc","compression","configuration"],"backgroundTag":"unsupported-compression-codec","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"}