fix(isthmus): use reachability-metadata.json for native image build#979
Draft
nielspardon wants to merge 1 commit into
Draft
Conversation
The native image build passed GraalVM options that are now deprecated and emitted build warnings (issue substrait-io#531): - -H:IncludeResources (resource inclusion) - -H:DynamicProxyConfigurationFiles (dynamic proxy config, via proxies.json) Both are replaced by a single declarative reachability-metadata.json on the classpath under META-INF/native-image/io.substrait/isthmus-cli/, which is the approach GraalVM now expects. Also: - Drop --report-unsupported-elements-at-runtime, itself deprecated and now a no-op (unsupported elements are always reported at run time). - Strip picocli-codegen's empty ([]) proxy-config.json after compile; its mere presence triggered the deprecated DynamicProxyConfigurationResources warning. reflect-config.json / resource-config.json (the real picocli metadata) are left intact. Verified with a native build (Oracle GraalVM 25.0.2): the build no longer emits any of these deprecation warnings, and smoke.sh / tpch_smoke.sh pass against the produced binary.
34b42f4 to
a595551
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What & why
The
isthmus-clinative image build passed GraalVM options that are now deprecated and emitted build warnings (fixes #531):-H:IncludeResources— resource inclusion-H:DynamicProxyConfigurationFiles— dynamic proxy config, backed byproxies.jsonBoth are replaced by a single declarative
reachability-metadata.jsonon the classpath underMETA-INF/native-image/io.substrait/isthmus-cli/— the approach GraalVM now expects. Theresourcessection (glob**/*.yaml) replacesIncludeResources, and thereflectionsection carries over all proxy interfaces from the oldproxies.json.Additional cleanups so the build is warning-free:
--report-unsupported-elements-at-runtime, itself deprecated and now a no-op (unsupported elements are always reported at run time).[])proxy-config.jsonafter compile; its mere presence triggered the deprecatedDynamicProxyConfigurationResourceswarning (the other warning quoted in the issue).reflect-config.json/resource-config.json— the real picocli metadata — are left untouched.Verification
Built locally with Oracle GraalVM 25.0.2 (
./gradlew :isthmus-cli:nativeCompile):smoke.shandtpch_smoke.shboth pass against the produced binary, andisthmus --versionworks — confirming the migrated YAML resources, Calcite metadata proxies, and picocli arg-parsing all still function in the native image.🤖 Generated with AI