ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Exposing WebService in a flow with and calling it with AXIS2

Post new topic  Reply to topic Goto page 1, 2  Next
 Exposing WebService in a flow with and calling it with AXIS2 « View previous topic :: View next topic » 
Author Message
hbilbao
PostPosted: Thu May 15, 2008 12:01 am    Post subject: Exposing WebService in a flow with and calling it with AXIS2 Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

Hi,
I'm trying to expose a webservice in a messageflow. I do the following steps:
1- Create a WSDL flOw with the toolkit wizard.
2- Create a new message definition file from this WSDL to deploy iy in a flow.
3- Take this WSDL (and the xsd is referenceing to it ) and create the java classes with AXIS2 (WSDL2JAVA)
4- Deploy the flow with the Webservice int he broker
5- Make the request to the WebService with the java classes.
At this point I get a "SOAP parser error " in the SOAP input node in my message flow.

The thing is that if I try to do the same but I create the classes with AXIS1, I don't get the SOAP parser error....

This is the script to create the .java classes with AXIS2:
wsdl2java -wv 1.1 -u -uri XXXXXXXXXX.wsdl

Thank you
Back to top
View user's profile Send private message
hbilbao
PostPosted: Thu May 15, 2008 3:33 am    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

Also if I run the "Asynchronous Consumer sample" sample, I get the SOAP parser error.......
Back to top
View user's profile Send private message
mgk
PostPosted: Thu May 15, 2008 3:38 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

What SOAP Parser Error? Can you paste the error?

Can you post the WSDL as well?
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
hbilbao
PostPosted: Thu May 15, 2008 4:45 am    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

Thanks for the reply mgk.

This is the wsdl:

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://rdrm.gvdi.com/Mensajeria" xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="WSAsincronoMessageSet" targetNamespace="http://rdrm.gvdi.com/Mensajeria">
<wsdl:types>
<xsd:schema xmlns:mrm="http://rdrm.gvdi.com/Mensajeria" targetNamespace="http://rdrm.gvdi.com/Mensajeria" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:include schemaLocation="SDRXMLSchema.xsd"/>
</xsd:schema>
</wsdl:types>
<wsdl:message name="enviarMensaje_in">
<wsdl:part element="tns:RDRM_MENSAJE" name="RDRM_MENSAJE_in"/>
</wsdl:message>
<wsdl:message name="enviarMensaje_out">
<wsdl:part element="tns:RDRM_MENSAJE" name="RDRM_MENSAJE_out"/>
</wsdl:message>
<wsdl:portType name="WSAsincronoMessageSetPortType">
<wsdl:operation name="enviarMensaje">
<wsdl:input message="tns:enviarMensaje_in" name="enviarMensaje_Input"/>
<wsdl:output message="tns:enviarMensaje_out" name="enviarMensaje_Output"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="WSAsincronoMessageSetSOAP_HTTP_Binding"
type="tns:WSAsincronoMessageSetPortType">
<soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
<wsdl:operation name="enviarMensaje">
<soap:operation soapAction="SOAPaction" />
<wsdl:input name="enviarMensaje_Input">
<soap:body parts="RDRM_MENSAJE_in" use="literal" />
</wsdl:input>
<wsdl:output name="enviarMensaje_Output">
<soap:body parts="RDRM_MENSAJE_out" use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="WSAsincronoMessageSetSOAP_HTTP_Service">
<wsdl:port binding="tns:WSAsincronoMessageSetSOAP_HTTP_Binding" name="SOAP_HTTP_Port">
<soap:address location="http://localhost:7800/RDRMMensajeria"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>




I see the SOAP parser error when I debug the flow.

I receive the following message strucuture.

Message
- Properties
................................
- HTTPInputHeaders
...............................
- SOAP
SOAP parser error

It seems like the broker can't parse the message with the soap.mxsd.
Back to top
View user's profile Send private message
mgk
PostPosted: Thu May 15, 2008 9:24 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

Hi, thanks for the WSDL, but I would like to the teh ACTUAL exception you see. All of it


Cheers,
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
hbilbao
PostPosted: Thu May 15, 2008 10:36 pm    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

My flow looks like this:

SOAP Input node --------subflow with SOAP extract node-------- another nodes...


When I receive the message in the SOAP Input node, The message looks like this:

Message
- Properties
- HTTPInputHeaders
- SOAP
"SOAP parser error"


I get the error in the extract node, but I think it is caused because of the SOAP parser error.


The exceptionList I get is this:


Code:

ExceptionList
   RecoverableException      File:CHARACTER:F:\build\S610_P\src\DataFlowEngine\ImbDataFlowNode.cpp
   Line:INTEGER:739
         Function:CHARACTER:ImbDataFlowNode::createExceptionList
         Type:CHARACTER:ComIbmSOAPInputNode
         Name:CHARACTER:RDRMMensajeria/RDRMMensajeriaSolicitudWebService#FCMComposite_1_15
         Label:CHARACTER:RDRMMensajeria.RDRMMensajeriaSolicitudWebService.Input1
         Catalog:CHARACTER:BIPv610
         Severity:INTEGER:3
         Number:INTEGER:2230
         Text:CHARACTER:Node throwing exception
         RecoverableException
               File:CHARACTER:F:\build\S610_P\src\DataFlowEngine\PluginInterface\ImbJniNode.cpp
               Line:INTEGER:1022
               Function:CHARACTER:ImbJniNode::evaluate
               Type:CHARACTER:ComIbmJniNode
               Name:CHARACTER:RDRMMensajeria/RDRMMensajeriaSolicitudWebService#FCMComposite_1_16.RDRMMensajeria/gen/RDRMMensajeriaWMBMSService_RDRMMensajeriaSolicitudWebService#FCMComposite_1_1
               Label:CHARACTER:RDRMMensajeria.RDRMMensajeriaSolicitudWebService.RDRMMensajeriaWMBMSService.Extract
               Catalog:CHARACTER:BIPv610
               Severity:INTEGER:3
               Number:INTEGER:2230
               Text:CHARACTER:Caught exception and rethrowing
               RecoverableException
                     File:CHARACTER:F:\build\S610_P\src\DataFlowEngine\PluginInterface\com_ibm_broker_plugin_CMbService.cpp
                     Line:INTEGER:1840
                     Function:CHARACTER:ImbJavaExceptionUtils::throwableToNativeException
                     Type:CHARACTER:
                     Name:CHARACTER:
                     Label:CHARACTER:
                     Catalog:CHARACTER:BIPv610
                     Severity:INTEGER:3
                     Number:INTEGER:4367
                     Text:CHARACTER:Unhandled exception in plugin method.
                     Insert
                           Type:INTEGER:5
                           Text:CHARACTER:evaluate
                     Insert
                           Type:INTEGER:5
                           Text:CHARACTER:RDRMMensajeriaWMBMSService.Extract
                     Insert
                           Type:INTEGER:5
                           Text:CHARACTER:java.lang.RuntimeException: An invalid SOAP message was received in the SOAPExtract node: RDRMMensajeriaWMBMSService.Extract
                     RecoverableException
                           File:CHARACTER:F:\build\S610_P\src\DataFlowEngine\PluginInterface\com_ibm_broker_plugin_CMbService.cpp
                           Line:INTEGER:1858
                           Function:CHARACTER:ImbJavaExceptionUtils::throwableToNativeException
                           Type:CHARACTER:
                           Name:CHARACTER:
                           Label:CHARACTER:
                           Catalog:CHARACTER:BIPv610
                           Severity:INTEGER:3
                           Number:INTEGER:4395
                           Text:CHARACTER:Unhandled exception in plugin method
                           Insert
                                 Type:INTEGER:5
                                 Text:CHARACTER:java.lang.RuntimeException
                           Insert
                                 Type:INTEGER:5
                                 Text:CHARACTER:com.ibm.broker.soap.SoapExtractNode
                           Insert
                                 Type:INTEGER:5
                                 Text:CHARACTER:removeSOAPEnvelope
                           Insert
                                 Type:INTEGER:5
                                 Text:CHARACTER:SoapExtractNode.java
                           Insert
                                 Type:INTEGER:2
                                 Text:CHARACTER:250
Back to top
View user's profile Send private message
mgk
PostPosted: Fri May 16, 2008 12:15 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

Ok. The ExceptionList shows this error: "An invalid SOAP message was received in the SOAPExtract node" which is an error in the SOAPExtract node, NOT the SOAPParser. It is normally thrown if the incoming mesage has not SOAPBody or SOAPEnvelope. Therefore, could you place a TraceNode directly after the SOAPInputNode and BEFORE the subflow and paste the output here please. Can you also paste you input message here too?

I'm still not sure why you think the error is caused by the SOAPParser. Perhaps you could explain that as well?
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
hbilbao
PostPosted: Fri May 16, 2008 1:04 am    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

Thank you mgk!

Quote:
I'm still not sure why you think the error is caused by the SOAPParser. Perhaps you could explain that as well?

Quote:
It is normally thrown if the incoming mesage has not SOAPBody or SOAPEnvelope


When the message arrives to the extract node, the input message doesn't have any SOAP body or SOAP envelope, so the error is normal.

I think it's a SOAP parser error, because when the WMB try to parse the incoming message with the soap.mxsd schema (after the SOAP input node), it can't parse it, and says me that SOAP parser error occurs.

Quote:
could you place a TraceNode directly after the SOAPInputNode and BEFORE the subflow and paste the output here please

Code:
(
  (0x01000000):Properties      = (
    (0x03000000):MessageSet             = 'RDRMMensajeriaWMBMS'
    (0x03000000):MessageType            = ''
    (0x03000000):MessageFormat          = ''
    (0x03000000):Encoding               = 546
    (0x03000000):CodedCharSetId         = 1208
    (0x03000000):Transactional          = FALSE
    (0x03000000):Persistence            = FALSE
    (0x03000000):CreationTime           = GMTTIMESTAMP '2008-05-16 09:05:12.048'
    (0x03000000):ExpirationTime         = -1
    (0x03000000):Priority               = 0
    (0x03000000):ReplyIdentifier        = X'000000000000000000000000000000000000000000000000'
    (0x03000000):ReplyProtocol          = 'SOAP-AXIS2'
    (0x03000000):Topic                  = NULL
    (0x03000000):ContentType            = 'text/xml; charset=UTF-8'
    (0x03000000):IdentitySourceType     = ''
    (0x03000000):IdentitySourceToken    = ''
    (0x03000000):IdentitySourcePassword = ''
    (0x03000000):IdentitySourceIssuedBy = ''
    (0x03000000):IdentityMappedType     = ''
    (0x03000000):IdentityMappedToken    = ''
    (0x03000000):IdentityMappedPassword = ''
    (0x03000000):IdentityMappedIssuedBy = ''
  )
  (0x01000000):HTTPInputHeader = (
    (0x03000000):X-Original-HTTP-Command = 'POST http://10.0.2.11:7800/RDRMMensajeria HTTP/1.1'
    (0x03000000):Content-Type            = 'text/xml; charset=UTF-8'
    (0x03000000):SOAPAction              = '"accionSOAP"'
    (0x03000000):User-Agent              = 'Axis2'
    (0x03000000):Host                    = '10.0.2.11:7800'
    (0x03000000):Transfer-Encoding       = 'chunked'
    (0x03000000):X-Server-Name           = '10.0.2.11'
    (0x03000000):X-Server-Port           = '7800'
    (0x03000000):X-Query-String          = ''
  )
  (0x01000000):SOAP            =


If I debug the flow, I can see a "SOAP parser error" after the SOAP folder.


The message I throw with the client is this (in the step before execute it):

[codens][code]


Last edited by hbilbao on Thu Sep 18, 2008 11:58 pm; edited 2 times in total
Back to top
View user's profile Send private message
mgk
PostPosted: Fri May 16, 2008 3:42 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

Thanks for the above, but still you say "I think it's a SOAP parser error, because when the WMB try to parse the incoming message with the soap.mxsd schema (after the SOAP input node), it can't parse it, and says me that SOAP parser error occurs." but you still have not posted this error

Can you please post this error?
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
hbilbao
PostPosted: Fri May 16, 2008 4:31 am    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

Thank you mgk,

The problem is that I don't know where can't I see this error
When I debug the flow, I can see more information than "SOAP parser error"..........
Back to top
View user's profile Send private message
mgk
PostPosted: Fri May 16, 2008 4:40 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

Well try having a look in the event / syslog to see if there are any exceptions there. If there are, please post them all here.

Also, can you post what options you have set on the SOAPInput node, and what terminals you have wired up?
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
hbilbao
PostPosted: Mon May 19, 2008 10:20 pm    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

Quote:
Well try having a look in the event / syslog to see if there are any exceptions there. If there are, please post them all here.


I have already seen this logs, but they don't tell me more than the ExceptionList shown above.
If you need it, I post it later (the system administrator doesn't come yet)

Quote:
Also, can you post what options you have set on the SOAPInput node, and what terminals you have wired up?


Tabs:
- Basic (this should be correct)
- HTTP Transport (this should be correct)
- Advanced
- SOAP 1.1 actor = Ultimate destination (Ultimate receiver)
- WS Extension (Nothing...........)
- Input Message parsing
- Message Domain:SOAP : For SOAP Web Services (WS- Standards support)
-MessageSet: my messageset
-Parser Option
- On demand



I have wired all the outputs(out, catch, failure). The message goes to the out terminal.

-
Back to top
View user's profile Send private message
mgk
PostPosted: Mon May 19, 2008 11:57 pm    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

OK, If you unwire the Out and Catch terminals, then all exceptions thrown down the flow will be written the the Event/Sys log. If you could do this and post all errors written the the Event/Sys log that would be great...
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue May 20, 2008 12:04 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
If I debug the flow, I can see a "SOAP parser error" after the SOAP folder.
Tip: If you get a parser error, disconnect the debugger and take a user trace, The debugger does not handle parser errors very well. User trace will show the full text of the exception, and may show you other useful info as well.
Back to top
View user's profile Send private message
hbilbao
PostPosted: Tue May 20, 2008 2:57 am    Post subject: Reply with quote

Newbie

Joined: 14 May 2008
Posts: 9

mgk wrote:
OK, If you unwire the Out and Catch terminals, then all exceptions thrown down the flow will be written the the Event/Sys log. If you could do this and post all errors written the the Event/Sys log that would be great...


This is it.
Code:
( BROKERDESA.RDRM ) Exception condition detected on input node 'RDRMMensajeria.RDRMMensajeriaSolicitudWebService.Input1'.   

The input node 'RDRMMensajeria.RDRMMensajeriaSolicitudWebService.Input1' detected an error whilst processing a message.  The message flow has been rolled-back and, if the message was being processed in a unit of work, it will remain on the input queue to be processed again.  Following messages will indicate the cause of this exception.   

Check the error messages which follow to determine why the exception was generated, and take action as described by those messages. 



( BROKERDESA.RDRM ) Error detected whilst processing a message in node 'RDRMMensajeria.RDRMMensajeriaSolicitudWebService.RDRMMensajeriaWMBMSService.Extract'.   

The message broker detected an error whilst processing a message in node 'RDRMMensajeria.RDRMMensajeriaSolicitudWebService.RDRMMensajeriaWMBMSService.Extract'. An exception has been thrown to cut short the processing of the message.   



( BROKERDESA.RDRM ) A SOAP logical tree cannot be built from the supplied bitstream.   

A SOAP logical tree can only be built from a previously serialised SOAP tree.   

Review further error messages for an indication to the cause of the error. Check that the bitstream supplied is a correctly serialised SOAP tree. 


( BROKERDESA.RDRM ) XML Parsing Errors have occurred.   

Errors have occurred during parsing of XML.   

Review further error messages for an indication to the cause of the errors. 


 BROKERDESA.RDRM ) An XML parsing error ''The root element is required in a well-formed document.'' occurred on line 1 column 1 when parsing element ''/XMLNSC''.   
 Internal error codes : '1500', '2'.   

This error was reported by the generic XML parser. It is usually the result of a badly-formed XML message.   

Check that the input XML message is a well-formed XML message that adheres to the XML specification. Note that the line number and column number quoted give the position where the parser discovered the problem. The actual error might be earlier in the message.   
 Other possible causes could be:   
 1. A character not supported by XML in the instance message data.   
      XML only supports a subset of control characters so ensure that no unsupported characters, such as X'00', appear in the document.   
 2. The Coded Character Set ID defined in the message header does not reflect the contents of the instance message.   
      If the XML document has an XML prologue, the WebSphere MQ CodedCharSetId should be consistent with the XML Encoding field.   
 3. A reserved XML character appears in the instance message data.   
      Characters that could otherwise be recognised as XML mark-up such as < or & should be replaced with the comparable XML entities such as &lt; or &amp;. 
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2  Next Page 1 of 2

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Exposing WebService in a flow with and calling it with AXIS2
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.