[graalvm-users] Issue with using js-scriptEngine in OPENjdk17
Ikonne, Eze
ike.ikonne at capgemini.com
Thu Jan 26 03:49:13 UTC 2023
Hi all,
I am trying to use the following jars to enable me to perform java scripting in my application running on OpenJDK17. I would
appreciate it if someone in this group could point me to right direction. Also, is what am trying to do actually possible?
Here is the scenario
1. Jar files:
js-scriptengine-22.3.1.jar
truffle-api-22.3.1.jar
compiler-22.3.1.jar
graal-sdk-22.3.1.jar
1. JDK - OpenJDK17
1. Code snippet
ScriptEngine engine = null;
engine = GraalJSScriptEngine.create();
ScriptEngineFactory factory = engine.getFactory();
1. Then I got the following exception
java.lang.NoClassDefFoundError: jdk.vm.ci.services.Services
at org.graalvm.libgraal.LibGraal.<clinit>(LibGraal.java:71)
at org.graalvm.compiler.truffle.runtime.hotspot.libgraal.LibGraalTruffleRuntimeAccess.getPriority(LibGraalTruffleRuntimeAccess.java:44)
at com.oracle.truffle.api.Truffle.selectTruffleRuntimeAccess(Truffle.java:90)
at com.oracle.truffle.api.Truffle$1.run(Truffle.java:131)
at com.oracle.truffle.api.Truffle$1.run(Truffle.java:108)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:692)
at com.oracle.truffle.api.Truffle.initRuntime(Truffle.java:108)
at com.oracle.truffle.api.Truffle.<clinit>(Truffle.java:63)
at com.oracle.truffle.api.impl.Accessor.getTVMCI(Accessor.java:1365)
at com.oracle.truffle.api.impl.Accessor$Constants.<clinit>(Accessor.java:1245)
at com.oracle.truffle.api.impl.Accessor.engineSupport(Accessor.java:1306)
This message contains information that may be privileged or confidential and is the property of the Capgemini Group. It is intended only for the person to whom it is addressed. If you are not the intended recipient, you are not authorized to read, print, retain, copy, disseminate, distribute, or use this message or any part thereof. If you receive this message in error, please notify the sender immediately and delete all copies of this message.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://oss.oracle.com/pipermail/graalvm-users/attachments/20230126/1f43cd28/attachment.html>
More information about the GraalVM-Users
mailing list