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
We have a Confluence app which uses javax.script.* packages provided by Java as part our JavaScript macro. The javax.script.* packages have been removed from Java17. As per the Java docs we need to use GraalVM JDK. Unfortunately, Atlassian does not recommend GraalVM JDK, hence we need to make GraalJS with OpenJDK.
The above examples work for standalone Java application. Noticed, while executing the maven goals it added module path, upgrade module path and VM options
(-XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI --add-exports=java.base/jdk.internal.misc=jdk.graal.compiler --upgrade-module-path=${compiler.dir})
When we use this as part Confluence P2 app we are facing issues. We are able build the app but at run time, we are getting script engine object as null. ScriptEngine engine = new ScriptEngineManager().getEngineByName("graal.js");
If you guys were able to run the GraalJS code as tomcat web application/Confluence P2 app, please share your insights.
Thanks and regards,
Kiran M
The text was updated successfully, but these errors were encountered:
Hi everyone,
We have a Confluence app which uses javax.script.* packages provided by Java as part our JavaScript macro. The javax.script.* packages have been removed from Java17. As per the Java docs we need to use GraalVM JDK. Unfortunately, Atlassian does not recommend GraalVM JDK, hence we need to make GraalJS with OpenJDK.
We followed these docs
The above examples work for standalone Java application. Noticed, while executing the maven goals it added module path, upgrade module path and VM options
(-XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI --add-exports=java.base/jdk.internal.misc=jdk.graal.compiler --upgrade-module-path=${compiler.dir})
When we use this as part Confluence P2 app we are facing issues. We are able build the app but at run time, we are getting script engine object as null.
ScriptEngine engine = new ScriptEngineManager().getEngineByName("graal.js");
If you guys were able to run the GraalJS code as tomcat web application/Confluence P2 app, please share your insights.
Thanks and regards,
Kiran M
The text was updated successfully, but these errors were encountered: