0 Replies Latest reply on Feb 16, 2006 6:34 AM by Manuel Valladares

    WSMessageEndpoints not working in WS4EE?

    Manuel Valladares Newbie

      I am trying to implement a webservice similar to the message endpoints example that was posted at the wiki http://www.jboss.org/wiki/Wiki.jsp?page=WSMessageEndpoints.

      It doesn't seem to work under Jboss-4.0.4 and WS4EE.
      It doesn't give any error, but when I construct the response using dom and I send it to the serializer the client gets an empty response.

      The interfaz of the webservice is:

      public Element getCacheAvailabilityPrice(CacheAvailabilityPriceRequest input) throws RemoteException;

      The server side webservice sends the response like this:
       // Setup document builder
       DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
       // Prepare response
       DocumentBuilder builder = docBuilderFactory.newDocumentBuilder();
       return doc.getDocumentElement();

      This is what the client receives:
      <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
       <ns1:getCacheAvailabilityPriceResponse xmlns:ns1="http://ReservationSystem.hotelebusiness.com/webservices/types">

      I see that the type Element is mapped to tns:Element instead of xsd:anyType like in the example of the wiki. The rest seems similar.

      The part of the WSDL for the Element object is like this:
      <complexType name="getCacheAvailabilityPriceResponse">
      <element name="result" nillable="true" type="tns:Element"/>
       <complexType name="Element">
      <element name="nodeValue" nillable="true" type="string"/>
      <element name="prefix" nillable="true" type="string"/>
      <element name="textContent" nillable="true" type="string"/>

      If you need more information just let me know.

      Thank you very much for your time and your attention.
      Manuel Valladares