You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[7/7] Creating image... (0.0s @ 3.06GB)
Fatal error: com.oracle.svm.core.util.VMError$HostedError: com.oracle.svm.core.util.VMError$HostedError: Registering type as reachable after analysis: AnalysisType<org.springframework.http.converter.HttpMessageConverter[], allocated: 0, inHeap: 0, reachable: 0>
at org.graalvm.nativeimage.builder/com.oracle.svm.core.util.VMError.shouldNotReachHere(VMError.java:72)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.NativeImageGenerator.doRun(NativeImageGenerator.java:682)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.NativeImageGenerator.run(NativeImageGenerator.java:521)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.NativeImageGeneratorRunner.buildImage(NativeImageGeneratorRunner.java:407)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.NativeImageGeneratorRunner.build(NativeImageGeneratorRunner.java:585)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.NativeImageGeneratorRunner.main(NativeImageGeneratorRunner.java:128)
Caused by: com.oracle.svm.core.util.VMError$HostedError: Registering type as reachable after analysis: AnalysisType<org.springframework.http.converter.HttpMessageConverter[], allocated: 0, inHeap: 0, reachable: 0>
at org.graalvm.nativeimage.builder/com.oracle.svm.core.util.VMError.shouldNotReachHere(VMError.java:68)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.ameta.AnalysisConstantReflectionProvider.registerAsReachable(AnalysisConstantReflectionProvider.java:332)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.ameta.HostedDynamicHubFeature.replace(HostedDynamicHubFeature.java:53)
at org.graalvm.nativeimage.pointsto/com.oracle.graal.pointsto.meta.AnalysisUniverse.replaceObject(AnalysisUniverse.java:583)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.image.NativeImageHeap.addArrayElements(NativeImageHeap.java:576)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.image.NativeImageHeap.addObjectToImageHeap(NativeImageHeap.java:473)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.image.NativeImageHeap.addObject(NativeImageHeap.java:295)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.image.NativeImageHeap.processAddObjectWorklist(NativeImageHeap.java:598)
------------------------------------------------------------------------------------------------------------------------
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.image.NativeImageHeap.addTrailingObjects(NativeImageHeap.java:198)
at org.graalvm.nativeimage.builder/com.oracle.svm.hosted.NativeImageGenerator.doRun(NativeImageGenerator.java:664)
... 4 more
To identify the additional entries you can do a diff between META-INF/native-image/spring-aot-smoke-tests/webmvc-tomcat/reflect-config.json (the version without the additional "queryAllDeclaredMethods": true entries which works fine) and resources/META-INF/native-image/reflect-config.json (the version with the "queryAllDeclaredMethods": true which fails).
The expected behavior is that additional "queryAllDeclaredMethods": true entries should not break the build.
In anticipation of behavior changes planned in GraalVM 23.0 related to metadata composability and described in https://github.com/graalvm/taming-build-time-initialization/blob/main/metadata-exceptions/Exceptions%20proposal.md, we have tried to add more
"queryAllDeclaredMethods": true
configuration as part of spring-projects/spring-framework#29246, but the outcome is that most builds are broken with this kind of error:To reproduce, checkout the
after-analysis-error
branch of my Spring AOT smoke test fork and run./gradlew webmvc-tomcat:nativeCompile
.To identify the additional entries you can do a diff between
META-INF/native-image/spring-aot-smoke-tests/webmvc-tomcat/reflect-config.json
(the version without the additional"queryAllDeclaredMethods": true
entries which works fine) andresources/META-INF/native-image/reflect-config.json
(the version with the"queryAllDeclaredMethods": true
which fails).The expected behavior is that additional
"queryAllDeclaredMethods": true
entries should not break the build.cc @bclozel @vjovanov
The text was updated successfully, but these errors were encountered: