Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
1.11
-
None
-
None
-
None
-
Linux
Description
Rasterization of image failed with java exception after Batik version has been upgraded from 1.5 to 1.11
I have upgraded batik version from 1.5 to 1.11, and while doing rasterization of image using -onload option, the following command failed with java exception. The image we have used to rasterized is available with batik package.
If I remove onload option,following command works fine and rasterization is successful.
java -jar batik-rasterizer-1.11.jar -onload samples/3D.svg
About to transcode 1 SVG file(s) Converting 3D.svg to samples/3D.png ... Exception in thread "main" java.lang.NoClassDefFoundError: org/mozilla/javascript/JavaScriptException at org.apache.batik.bridge.RhinoInterpreterFactory.createInterpreter(RhinoInterpreterFactory.java:82) at org.apache.batik.script.InterpreterPool.createInterpreter(InterpreterPool.java:124) at org.apache.batik.bridge.BridgeContext.getInterpreter(BridgeContext.java:566) at org.apache.batik.bridge.BaseScriptingEnvironment.getInterpreter(BaseScriptingEnvironment.java:318) at org.apache.batik.bridge.BaseScriptingEnvironment.loadScript(BaseScriptingEnvironment.java:450) at org.apache.batik.bridge.BaseScriptingEnvironment.loadScripts(BaseScriptingEnvironment.java:354) at org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(SVGAbstractTranscoder.java:214) at org.apache.batik.transcoder.image.ImageTranscoder.transcode(ImageTranscoder.java:92) at org.apache.batik.transcoder.XMLAbstractTranscoder.transcode(XMLAbstractTranscoder.java:142) at org.apache.batik.transcoder.SVGAbstractTranscoder.transcode(SVGAbstractTranscoder.java:156) at org.apache.batik.apps.rasterizer.SVGConverter.transcode(SVGConverter.java:1002) at org.apache.batik.apps.rasterizer.SVGConverter.execute(SVGConverter.java:717) at org.apache.batik.apps.rasterizer.Main.execute(Main.java:937) at org.apache.batik.apps.rasterizer.Main.main(Main.java:990) Caused by: java.lang.ClassNotFoundException: org.mozilla.javascript.JavaScriptException at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521) ... 14 more
Java version details
java -version
openjdk version "11.0.1" 2018-10-16 LTS
OpenJDK Runtime Environment Zulu11.2+3 (build 11.0.1+13-LTS)
OpenJDK 64-Bit Server VM Zulu11.2+3 (build 11.0.1+13-LTS, mixed mode)