I want to use a Java object new Train() as an argument to pass into a JavaScript function, here is the Java code JavaScript code As of right now it puts this error in the console [16:56:42] [INFO]: [STDERR]: javax.script.ScriptException: org.graalvm.polyglot.PolyglotException: TypeError: invokeMember (getSpeed) on ScriptExecutor$Train@429b2a7b failed due to: Unknown identifier: getSpeed [16:56:42] [INFO]: [STDERR]: at com.oracle.truffle.js.scriptengine.GraalJSScriptEngine.toScriptException(GraalJSScriptEngine.java:483) [16:56:42] [INFO]: [STDERR]:
Tag: graaljs
How to exit infinite JS execution loop when reading/loading Javascript in Java using GraalVM?
I found sandbox options as a way to set sandbox.MaxCPUTime in the graalVM documentation, to limit how long the thread runs – https://www.graalvm.org/reference-manual/embed-languages/ I’ve tried the following code – This has been failing for me with the error – Is there a better way to achieve this or a way I can make these sandbox options work? Answer You may