Not compatible with GraalVM 19.3.3?
zheli opened this issue · 1 comments
zheli commented
I tried to clone the repository and run graalvm-native-image:packageBin
, then I got this error message:
[info] Build on Server(pid: 16456, port: 57691)
[info] [akka-graal-native:16456] classlist: 4,500.87 ms
[info] [akka-graal-native:16456] (cap): 914.70 ms
[info] WARNING: Could not resolve sun.reflect.Reflection for reflection configuration.
[info] [akka-graal-native:16456] setup: 1,165.78 ms
[info] WARNING GR-10238: VarHandle for static field is currently not fully supported. Static field private static volatile java.lang.System$Logger jdk.internal.event.EventHelper.securityLogger is not properly marked for Unsafe access!
[info] [akka-graal-native:16456] (typeflow): 19,886.90 ms
[info] [akka-graal-native:16456] (objects): 16,097.46 ms
[info] [akka-graal-native:16456] (features): 1,155.10 ms
[info] [akka-graal-native:16456] analysis: 40,284.30 ms
[error] Error: com.oracle.graal.pointsto.constraints.UnsupportedFeatureException: Invoke with MethodHandle argument could not be reduced to at most a single call or single field access. The method handle must be a compile time constant, e.g., be loaded from a `static final` field. Method that contains the method handle invocation: java.lang.invoke.MethodHandle.invokeBasic(Object)
[error] To diagnose the issue, you can add the option --report-unsupported-elements-at-runtime. The error is then reported at run time when the invoke is executed.
[error] Detailed message:
[error] Trace:
[error] at parsing java.lang.invoke.LambdaForm$MH/0x000000084149e440.invokeExact_MT(LambdaForm$MH)
[error] Call path from entry point to java.lang.invoke.LambdaForm$MH/1484067080.invokeExact_MT(Object, Object, Object):
[error] at java.lang.invoke.LambdaForm$MH/0x000000084149e440.invokeExact_MT(LambdaForm$MH)
[error] at akka.dispatch.affinity.AffinityPool$IdleStrategy.idle(AffinityPool.scala:89)
[error] at akka.dispatch.affinity.AffinityPool$AffinityPoolWorker.executeNext$1(AffinityPool.scala:271)
[error] at akka.dispatch.affinity.AffinityPool$AffinityPoolWorker.runLoop$1(AffinityPool.scala:289)
[error] at akka.dispatch.affinity.AffinityPool$AffinityPoolWorker.run(AffinityPool.scala:297)
[error] at java.lang.Thread.run(Thread.java:834)
[error] at com.oracle.svm.core.thread.JavaThreads.threadStartRoutine(JavaThreads.java:497)
[error] at com.oracle.svm.core.posix.thread.PosixJavaThreads.pthreadStartRoutine(PosixJavaThreads.java:193)
[error] at com.oracle.svm.core.code.IsolateEnterStub.PosixJavaThreads_pthreadStartRoutine_e1f4a8c0039f8337338252cd8734f63a79b5e3df(generated:0)
[error] Error: Use -H:+ReportExceptionStackTraces to print stacktrace of underlying exception
[error] Error: Image build request failed with exit status 1
[error] java.lang.RuntimeException: Failed to run native-image, exit status: 1
[error] at scala.sys.package$.error(package.scala:26)
[error] at com.typesafe.sbt.packager.graalvmnativeimage.GraalVMNativeImagePlugin$.$anonfun$projectSettings$3(GraalVMNativeImagePlugin.scala:52)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:40)
[error] at sbt.std.Transform$$anon$4.work(System.scala:67)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:269)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:278)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:269)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:178)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[error] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
[error] at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
[error] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
[error] at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
[error] at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
[error] at java.base/java.lang.Thread.run(Thread.java:834)
[error] (Graalvm-native-image / packageBin) Failed to run native-image, exit status: 1
[error] Total time: 50 s, completed Sep 19, 2020, 5:42:20 PM
However the --initialize-at-build-time
is specified in the build.sbt. Could you give me some points? Thanks! I cannot download GraalVM 19.1.1 anymore so I used the old version :(
chrthr commented
same problem here with graalvm-ce-java8-linux-amd64-19.3.4.
also tested with 20.2.0 , same issue.
is this related to oracle/graal#2761 ?