2 Replies Latest reply on Sep 23, 2005 9:46 AM by Thomas Diesler

    RPC/Literal return value or null

    Andre Simon Newbie

      Hi

      I use an RPC/literal WS4EE JBoss EJB Endpoint.
      The Service Methods returns an Bytearray or null.
      And this is a problem, if the method returns an Bytearray everything
      works fine, but if the Service returns null following Remoteexception is
      thrown by my JWSDP 1.6 Client:

      RemoteException: Runtime exception; nested exception is: unexpected null value for literal data
       at com.sun.xml.rpc.client.StreamingSender._handleRuntimeExceptionInSend(StreamingSender.java:318)
       at com.sun.xml.rpc.client.StreamingSender._send(StreamingSender.java:300)
      


      the SOAP Response :

      <?xml version="1.0" encoding="UTF-8"?>
      <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">
       <soapenv:Body>
       <ns1:myMethodResponse xmlns:ns1="http://myWS.org/method">
       <result xsi:type="xsd:base64Binary" xsi:nil="1"/>
       </ns1:myMethodResponse >
       </soapenv:Body>
      </soapenv:Envelope>
      


      Is there a way that my JAXRPC Client recognize the xsi:nil attribute
      and get a null as return value?

      thx

      dre