• Post Reply Bookmark Topic Watch Topic
  • New Topic

Axis client for jboss ejb3 session bean web service

 
Kali Jp
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I use axis 1.3 client to invoke my ejb3 session bean webservice deployed on jboss. It produces SOAP message like below

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<processRequest xmlns="http://www.domain.org/webservices">
<requestId>56771</requestId>
</processRequest>
</soapenv:Body>
</soapenv:Envelope>

It throws 'Cannot find child element: requestId'.


Interestingly with SOAP UI client it works fine because SOAP UI produces following message:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://www.domain.org/webservices">
<soapenv:Header/>
<soapenv:Body>
<web:processRequest>
<requestId>56741</requestId>
</web:processRequest>
</soapenv:Body>
</soapenv:Envelope>

1. Can anyone explain what is the difference ?
2. How to make my Axis to produce message like the second one?




 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
It seems like the code in the client parsing the SOAP messages have a problem with namespaces.
In the second example, you have the namespace http://www.domain.org/webservices declared on the root element of the SOAP message with the namespace prefix "web".
In the first example, the namespace http://www.domain.org/webservices is declared on the <processRequest> element without any prefix, making it the default namespace.
In theory, the default namespace should be applied to the element in which it is declared and all child elements of that element, but it seems like some part of the code you are using fail to recognize this.
Since I don't usually use Axis, I regretfully have no idea how to make Axis produce the desired kind of SOAP messages.
Best wishes!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!