I have cloverETLDesigner 3.2.1 and cloverETLServer 3.2.1 and in neither of both places can run a graph with a XML_XPATH_READER node. Basically it doesn’t seem to be loadingthe saxon8.jar into the classpath. The jar file is the plugins/org.jetel.component/lib directory. Shouldn’t cloverETL automatically load that lib?
ERROR [main] - Can't create object of type XML_XPATH_READER with reason: net/sf/saxon/sxpath/XPathEvaluator
Exception in thread "main" java.lang.RuntimeException: Can't create object of type XML_XPATH_READER with reason: net/sf/saxon/sxpath/XPathEvaluator
at org.jetel.component.ComponentFactory.createComponent(ComponentFactory.java:139)
at org.jetel.graph.TransformationGraphXMLReaderWriter.instantiateNodes(TransformationGraphXMLReaderWriter.java:486)
at org.jetel.graph.TransformationGraphXMLReaderWriter.instantiatePhases(TransformationGraphXMLReaderWriter.java:449)
at org.jetel.graph.TransformationGraphXMLReaderWriter.read(TransformationGraphXMLReaderWriter.java:364)
at org.jetel.graph.TransformationGraphXMLReaderWriter.read(TransformationGraphXMLReaderWriter.java:284)
at org.jetel.graph.TransformationGraphXMLReaderWriter.loadGraph(TransformationGraphXMLReaderWriter.java:213)
at org.jetel.main.runGraph.main(runGraph.java:313)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jetel.component.ComponentFactory.createComponent(ComponentFactory.java:119)
... 6 more
Caused by: java.lang.NoClassDefFoundError: net/sf/saxon/sxpath/XPathEvaluator
at org.jetel.data.parser.XPathParser.<init>(XPathParser.java:106)
at org.jetel.component.XmlXPathReader.<init>(XmlXPathReader.java:179)
at org.jetel.component.XmlXPathReader.fromXML(XmlXPathReader.java:343)
... 11 more
Caused by: java.lang.ClassNotFoundException: net.sf.saxon.sxpath.XPathEvaluator
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.Cla
> That library should be on classpath cause is referred via “plugins/org.jetel.component/plugin.xml”. You can check that.
I was expecting that behavior, and I’m writing here because that is not happening, it is loading the extensions and those classes but not the libraries defined there.
> I guess your question is related to viewtopic.php?f=4&t=6490#p9944 , right? From that post it seems that you are able to run graph in Designer on local Engine, but not on Server. Is this assumption correct?
Yes, is related, and also yes, we can run it. But the only reason we can run the graphs that require saxon is because we get it into the classpath from a dependency we have in the sandbox project. If we remove that dependency the saxon library is not being added to the classpath by clover (like we expected). So, the correct answer should be that we can’t run it, neither form Eclipse or the server.
> Did you deployed CloverETL Server into clean Application server or did you upgrade existing? What application server and version do you use?
Yes, the only change we make to the cloverServer.war is to add a couple of libraries into the lib directory, a custom components jar and some dependencies for it. We use Jetty 6.
> the only change we make to the cloverServer.war is to add a couple of libraries into the lib directory, a custom components jar and some dependencies for it
1. We are getting the same error if we replace our saxon8.jar in C:\Program Files (x86)\CloverETL Designer 3.2.1\plugins\com.cloveretl.gui_3.2.1\lib\plugins\org.jetel.component\lib\saxon8.jar with some older version. (We use in fact saxon 8.9 and net/sf/saxon/sxpath/XPathEvaluator is present since version 8.4, so e.g. version 8.0 causes the problem).
2. Please, try a fresh installation of Designer (in different folder) without any of your changes and run some simple graph involving just XMLXPathReader and Trash. This way we can see if problem persists even in this new installation.
3. If graph finishes successfully, try to add your libraries one by one and see where the problem appears. If this procedure does not bring you answer, please write down some list of all changes you made plus names and versions of libraries you added or modified.
By the way, the proper way to import new libraries is in Designer via Run Configuration->classpath->add external jar and in Jetty Server via [jetty]/lib. But we should solve Designer problem first and only then move to Server. Moreover, even if you add the new library while leaving also our default library untouched, graph run will fail. Only the exception will be different.