Apache Iceberg version
1.11.0 (latest release)
Query engine
None
Please describe the bug π
GenericFormatModels.register() references org.apache.iceberg.orc.OrcRowWriter as a class literal. When iceberg-orc is absent, the JVM throws NoClassDefFoundError (an Error). DynMethods.invoke() rethrows Error directly, bypassing the catch, so <clinit> fails and permanently poisons FormatModelRegistry for the classloader's lifetime.
Stack trace:
Caused by: java.lang.NoClassDefFoundError: org/apache/iceberg/orc/OrcRowWriter
at org.apache.iceberg.data.GenericFormatModels.register(GenericFormatModels.java:55)
at org.apache.iceberg.formats.FormatModelRegistry.registerSupportedFormats(FormatModelRegistry.java:207)
at org.apache.iceberg.formats.FormatModelRegistry.<clinit>(FormatModelRegistry.java:69)
Caused by: java.lang.ClassNotFoundException: org.apache.iceberg.orc.OrcRowWriter
Maybe need to widen the catch in `registerSupportedFormats()`?
### Willingness to contribute
- [ ] I can contribute a fix for this bug independently
- [ ] I would be willing to contribute a fix for this bug with guidance from the Iceberg community
- [ ] I cannot contribute a fix for this bug at this time
Apache Iceberg version
1.11.0 (latest release)
Query engine
None
Please describe the bug π
GenericFormatModels.register()referencesorg.apache.iceberg.orc.OrcRowWriteras a class literal. Wheniceberg-orcis absent, the JVM throwsNoClassDefFoundError(anError).DynMethods.invoke()rethrowsErrordirectly, bypassing the catch, so<clinit>fails and permanently poisonsFormatModelRegistryfor the classloader's lifetime.Stack trace: