• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Axis client for jboss ejb3 session bean web service

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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?




 
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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!
 
Attractive, successful people love this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic