Following is my router.xsl which was deployed inside xslt SU file. =================
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:jbi="xalan://org.apache.servicemix.components.xslt.XalanExtension" extension-element-prefixes="jbi" xmlns:xpathrouting="http://servicemix.apache.org/samples/xpathrouting" version="1.0"> <xsl:template match="/*"> <xsl:choose> <xsl:when test="@id = '4'"> <!-- lets forward the inbound message to a service --> <!-- forward doesn't seem to work !! use invoke instead --> <!-- <jbi:forward service="xpathrouting:trace"/> --> <jbi:invoke service="xpathrouting:trace"> <jbi:copyProperties/> <xsl:copy-of select="/" /> </jbi:invoke> </xsl:when> <!-- lets generate the output XML to use as input, copy the input properties and define some new propertes --> <xsl:when test="@id = '12'"> <jbi:invoke service="xpathrouting:trace"> <jbi:copyProperties/> <jbi:setOutProperty name="foo" select="@sent"/> <cheese code="[EMAIL PROTECTED]"> <description>This is some content generated from the routing XSL</description> </cheese> </jbi:invoke> </xsl:when> <xsl:when test="@id != '2'"> <jbi:forward service="xpathrouting:trace"/> </xsl:when> <xsl:otherwise> <jbi:forward service="xpathrouting:trace"/> </xsl:otherwise> </xsl:choose> </xsl:template> </xsl:stylesheet> -- View this message in context: http://www.nabble.com/%3Cjbi%3Afoward-...%3E-doesn%27t-work----%28Xpath-router%29-tf3771463s12049.html#a10729766 Sent from the ServiceMix - User mailing list archive at Nabble.com.
