Hi Vashul,
Thanks very much. Actually ActiveMQ is not required any pom or Gradle files but I have included Saxon-HE-9.5.1-5.jar under camel lib folder and it is working now without any errors. Thanks Mallesh -----Original Message----- From: Vanshul.Chawla [mailto:[email protected]] Sent: Wednesday, September 6, 2017 1:47 PM To: [email protected] Subject: RE: [EXTERNAL] Active MQ 5.15.5 - XSLT2.0 - Compilation Issue Add Saxon 9.5 dependency in your pom.xml(or gradle whichever u use) <dependency> <groupId>org.apache.camel</groupId> <artifactId>camel-saxon</artifactId> <version>2.15.0</version> </dependency> <dependency> <groupId>net.sf.saxon</groupId> <artifactId>Saxon-HE</artifactId> <version>9.5.1-5</version> </dependency> Change Camel version as per your case. Also when you call xslt, call like this <to uri="xslt:xxxx.xsl?saxon=true"/> It will work fine then. Vanshul -----Original Message----- From: Mallesh Gorupati [mailto:[email protected]] Sent: Wednesday, September 06, 2017 12:52 PM To: '[email protected]' <[email protected]> Subject: [EXTERNAL] Active MQ 5.15.5 - XSLT2.0 - Compilation Issue Hi Getting below compilation error when I start ActiveMQ. Error: Caused by: org.apache.camel.FailedToCreateRouteException: Failed to create route route1: Route(route1)[[From[{{camel.xslt.file.directory}}?delay={{ca... because of Error checking type of the expression 'funcall(current-dateTime,[])'. I got the same error when I ran java standalone camel program but it is solved once I copied camel-saxon.jar under java class path. But for spring configuration, it is not working if I copy camel-saxon.jar in the ActiveMq class path libs like ../optional or../ camel or ../extra etc,. I have tried below options as suggested in the forums but still couldn't solve the issue. 1. <to uri="xslt:file:xsl/my.xsl?transformerFactory=tFactory" /> <bean > id="tFactory" class="net.sf.saxon.TransformerFactoryImpl" /> 2. Environment variable setup in the camel-configuration file <prop key="javax.xml.transform.TransformerFactory">net.sf.saxon.xpath.XPathFactoryImpl</prop> Appreciate your help.. Just adding the code snippets here.. Camel.xml ----------------- <camelContext xmlns="http://activemq.apache.org/camel/schema/spring"> <route> <from uri="activemq:My.Queue"/> <to uri=" xslt:{{camel.xslt.file.directory}}/test.xslt"/> <to uri="activemq:Another.Queue"/> </route> </camelContext> test.xslt ------------- <xsl:value-of select="current-dateTime()"/> Thanks Mallesh
