Hi Asanka,
Its a small mistake I guess, you have used a closing tag to declare the
style sheet which is wrong;
<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fn="http://www.w3.org/2005/02/xpath-functions"*/>*
change this to
<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fn="http://www.w3.org/2005/02/xpath-functions">
Please try this and let me know the results :-)
Thanks,
Ruwan
On Mon, Jun 23, 2008 at 11:24 PM, Asanka Abeysinghe <[EMAIL PROTECTED]>
wrote:
> XSL style sheet is attached.
> Asanka A.
>
> Andreas Veithen wrote:
>
>> Looks like the output of the XSL transformation is not well formed. Can
>> you send the XSL stylesheet?
>>
>> Andreas
>>
>> On 23 juin 08, at 19:29, Asanka Abeysinghe wrote:
>>
>>
>>> To make axiom-impl SNAPSHOT working I had to replace SNAPSHOT of
>>> axiom-api and axiom-dom. With the SNAPSHOT version of the axiom libraries
>>> synapse logged the following exception.
>>> Asanka A.
>>>
>>> 2008-06-23 22:31:27,918 [127.0.1.1-asankaa-laptop] [fix-Worker-2] INFO
>>> LogMediator To: , WSAction: urn:mediate, SOAPAction: urn:mediate, MessageID:
>>> urn:uuid:6A40DDA878C380B5951214240487925, Direction: request, Envelope:
>>> FIX.4.010625DBANZAI20080623-17:01:27SYNAPSE12142404879101100011sunw0205
>>> 2008-06-23 22:31:27,970 [127.0.1.1-asankaa-laptop] [fix-Worker-2] ERROR
>>> XSLTMediator Unable to perform XSLT transformation using : xslt-key-req
>>> against source XPath : s11:Body/child::*[position()=1] |
>>> s12:Body/child::*[position()=1]
>>> org.apache.axiom.om.OMException:
>>> com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character 'F' (code
>>> 70) in prolog; expected '<'
>>> at [row,col {unknown-source}]: [1,39]
>>> at
>>> org.apache.axiom.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:249)
>>> at
>>> org.apache.axiom.om.impl.llom.OMDocumentImpl.getOMDocumentElement(OMDocumentImpl.java:132)
>>>
>>> at
>>> org.apache.axiom.om.impl.builder.StAXOMBuilder.getDocumentElement(StAXOMBuilder.java:411)
>>>
>>> at
>>> org.apache.synapse.mediators.transform.XSLTMediator.performXSLT(XSLTMediator.java:368)
>>>
>>> at
>>> org.apache.synapse.mediators.transform.XSLTMediator.mediate(XSLTMediator.java:177)
>>>
>>> at
>>> org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:58)
>>>
>>> at
>>> org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:125)
>>>
>>> at
>>> org.apache.synapse.core.axis2.ProxyServiceMessageReceiver.receive(ProxyServiceMessageReceiver.java:158)
>>>
>>> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:176)
>>> at
>>> org.apache.synapse.transport.base.AbstractTransportListener.handleIncomingMessage(AbstractTransportListener.java:256)
>>>
>>> at
>>> org.apache.synapse.transport.fix.FIXIncomingMessageHandler$FIXWorkerThread.handleIncomingRequest(FIXIncomingMessageHandler.java:319)
>>>
>>> at
>>> org.apache.synapse.transport.fix.FIXIncomingMessageHandler$FIXWorkerThread.run(FIXIncomingMessageHandler.java:355)
>>>
>>> at
>>> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
>>>
>>> at
>>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
>>>
>>> at java.lang.Thread.run(Thread.java:595)
>>> Caused by: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected
>>> character 'F' (code 70) in prolog; expected '<'
>>> at [row,col {unknown-source}]: [1,39]
>>> at
>>> com.ctc.wstx.sr.StreamScanner.throwUnexpectedChar(StreamScanner.java:623)
>>> at
>>> com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(BasicStreamReader.java:2047)
>>>
>>> at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1069)
>>> at
>>> org.apache.axiom.om.impl.builder.StAXOMBuilder.parserNext(StAXOMBuilder.java:506)
>>>
>>> at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.jav
>>>
>>>
>>>
>>>
>>> ----------------------------------------
>>>
>>>> CC: [email protected]
>>>> From: [EMAIL PROTECTED]
>>>> To: [EMAIL PROTECTED]
>>>> Subject: Re: Synapse-1.2 Exception when using XSLT mediator
>>>> Date: Mon, 23 Jun 2008 11:45:54 +0200
>>>>
>>>> I just checked and apparently the patch for WSCOMMONS-338 didn't make
>>>> it into the Axiom 1.2.7 release. As a workaround you can try to
>>>> replace axiom-impl-1.2.7.jar by a recent snapshot from here:
>>>>
>>>>
>>>> http://people.apache.org/repo/m2-snapshot-repository/org/apache/ws/commons/axiom/axiom-impl/SNAPSHOT/
>>>>
>>>> Andreas
>>>>
>>>> On 23 juin 08, at 10:02, Andreas Veithen wrote:
>>>>
>>>> This looks a bit like issue WSCOMMONS-338. However this is supposed
>>>>> to be solved in Axiom 1.2.7. Can you check that you have that
>>>>> version of Axiom in the classpath?
>>>>>
>>>>> Andreas
>>>>>
>>>>> On 23 juin 08, at 06:15, Asanka Abeysinghe wrote:
>>>>>
>>>>>
>>>>>> Hi,
>>>>>> My requirement is to transform a SOAP message that stores FIX
>>>>>> information in the payload to another structure using a XSLT
>>>>>> mediator. Original message structure looks like following, which
>>>>>> contains repeating groups, CDATA and it got siblings for the first
>>>>>> child element after the SOAP body.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> FIX.4.0
>>>>>> 136
>>>>>> 3
>>>>>> 8
>>>>>> EXEC
>>>>>> 20080618-08:41:56
>>>>>> SYNAPSE
>>>>>>
>>>>>>
>>>>>> 12.3
>>>>>> 0
>>>>>> 12.3
>>>>>> 100
>>>>>> 2
>>>>>> 100 GOOG
>>>>>>
>>>>>>
>>>>>> 041
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Configuration file and the xslt file used is attached. When the
>>>>>> input message comes, application throws the following exception
>>>>>> before doing any transformation.
>>>>>>
>>>>>> 2008-06-19 23:20:44,105 [127.0.1.1-asankaa-laptop] [fix-Worker-1]
>>>>>> DEBUG XSLTMediator Using byte array serialization for transformation
>>>>>> 2008-06-19 23:20:44,449 [127.0.1.1-asankaa-laptop] [fix-Worker-1]
>>>>>> ERROR XSLTMediator Unable to perform XSLT transformation using :
>>>>>> xslt-key-req against source XPath : s11:Body/child::*[position()=1]
>>>>>> | s12:Body/child::*[position()=1]
>>>>>> java.lang.NullPointerException
>>>>>> at java.lang.System.arraycopy(Native Method)
>>>>>> at
>>>>>> org.apache.xml.utils.FastStringBuffer.append(FastStringBuffer.java:
>>>>>> 663)
>>>>>> at
>>>>>> org.apache.xml.dtm.ref.sax2dtm.SAX2DTM.characters(SAX2DTM.java:2082)
>>>>>> at
>>>>>> org
>>>>>> .springframework
>>>>>> .xml
>>>>>> .stream
>>>>>> .StaxStreamXmlReader.handleCharacters(StaxStreamXmlReader.java:121)
>>>>>> at
>>>>>> org
>>>>>> .springframework
>>>>>> .xml
>>>>>> .stream.StaxStreamXmlReader.parseInternal(StaxStreamXmlReader.java:
>>>>>> 89)
>>>>>> at
>>>>>> org
>>>>>> .springframework
>>>>>> .xml.stream.AbstractStaxXmlReader.parse(AbstractStaxXmlReader.java:
>>>>>> 68)
>>>>>>
>>>>>> Appreciate your comments to solve this problem.
>>>>>> Asanka A .
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> _________________________________________________________________
>>>>>> Connect to the next generation of MSN Messenger
>>>>>>
>>>>>> http://imagine-msn.com/messenger/launch80/default.aspx?locale=en-us&source=wlmailtagline
>>>>>>
>>>>>>
>>>>>
>>>>
>>> _________________________________________________________________
>>> News, entertainment and everything you care about at Live.com. Get it
>>> now!
>>> http://www.live.com/getstarted.aspx
>>>
>>
>>
>>
>
--
Ruwan Linton
http://wso2.org - "Oxygenating the Web Services Platform"
http://ruwansblog.blogspot.com/