camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <james.strac...@gmail.com>
Subject Re: Message transformation using XML in Spring XML config
Date Fri, 28 Mar 2008 20:00:12 GMT
Do you have camel-spring.jar on your classpath?

On 28/03/2008, David Siefert <siefert.david.mailinglist@gmail.com> wrote:
> On Fri, Mar 28, 2008 at 1:44 PM, James Strachan <james.strachan@gmail.com>
>  wrote:
>
>
> > On 28/03/2008, David Siefert <siefert.david.mailinglist@gmail.com> wrote:
>  > > Hello,
>  > >
>  > >  Is there an example of using an XSLT in the Spring XML configuration?
>  >
>  > Yes I've just added one here...
>  >
>  > http://svn.apache.org/repos/asf/activemq/camel/trunk/components/camel-spring/src/test/java/org/apache/camel/spring/processor/XsltTest.java
>  >
>  > the XML is linked below...
>  >
>  >
>  > >  I have something like the following:
>  > >
>  > >  <route>
>  > >   <from uri="..." />
>  > >   <to uri="xslt:..." />
>  > >   <!-- *but now what?* -->
>  >
>  > if you have an InOut route (e.g. a WS invocation, a request response
>  > over JMS using a JMSReplyTo or via a HTTP POST) then you're done, the
>  > result is returned.
>  >
>  > If you are doing one-way messaging, just add another destination for
>  > the result. e.g. another <to/>
>  >
>  > >  </route>
>  > >
>  > >  The XML Schema says I can only have one <to />.
>  >
>  > I don't think it does (or rather maybe thats an old XSD you're looking
>  > at?)
>  >
>  > e.g. see the test XML..
>  >
>  > http://svn.apache.org/repos/asf/activemq/camel/trunk/components/camel-spring/src/test/resources/org/apache/camel/spring/processor/XsltTest-context.xml
>  >
>  >
>  > --
>  > James
>  > -------
>  > http://macstrac.blogspot.com/
>  >
>  > Open Source Integration
>  > http://open.iona.com
>  >
>
>
>
> I seem to be having some trouble with specifying xslt: as an endpoint.  I
>  simplified my problem as much as possible by putting the XSL at the root of
>  the classpath (another words, its not in any package).  So in Maven I have:
>
>  /trunk
>   /src
>     /main
>       ...
>     /resources
>       /META-INF
>         /spring.xml
>       /transform.xsl
>   /test
>     /main
>       ...
>  I use the ClassPathXmlApplicationContext to load spring.xml from META-INF
>  which works fine.  Then I get the following exception when running my test
>  (during test phase):
>
>  org.apache.camel.RuntimeCamelException:
>  org.apache.camel.NoSuchEndpointException: No endpoint could be found for:
>  xslt:transform.xsl
>
>  when it tries to process:
>
>  <to uri="xslt:transform.xsl" />
>
>  Any idea?
>
>  Thanks,
>
>
>  David
>


-- 
James
-------
http://macstrac.blogspot.com/

Open Source Integration
http://open.iona.com

Mime
View raw message