2 Replies Latest reply on Feb 21, 2008 10:57 AM by Kevin Conner

    SOAPClient - unwanted WARN

    Jarek Pekala Newbie

      Hi

      I found repeating WARN when I call WebService through SOAPClient.

      WARN [HttpMethodBase] Going to buffer response body of large or unknown size. Using getResponseBodyAsStream instead is recommended.


      Everything works fine, but I want know what does it mean. Is there any possibility to use suggested method? How the response is buffered? Should I clear this 'buffer'? Is there any way to hide this message if this warn can be ignored?

      regards
      jarek

        • 1. Re: SOAPClient - unwanted WARN
          Jarek Pekala Newbie

          I'm using JBossESB 4.2.1 and below is sample call
          jboss-esb.xml

          <action name="sendPagerRequestMapper"
           class="SendPagerRequestMapper">
           </action>
           <action name="sendPagerWs" class="org.jboss.soa.esb.actions.soap.SOAPClient">
           <property name="wsdl" value="http://validserver:8080/EMapComm/services/EMapCommSOAP?wsdl" />
           <property name="responseAsOgnlMap" value="true" />
           <property name="SOAPAction" value="PagerSend"/>
          </action>


          process method from SendPagerRequestMapper

          public Message process(Message message) throws Exception
           {
           try
           {
           AutoMessage varMsg=(AutoMessage)message.getBody().get();
           HashMap requestMap = new HashMap();
          
           requestMap.put("PagerSend.capCode", varMsg.getCommServer());
           requestMap.put("PagerSend.message", varMsg.getMessage());
          
           message.getBody().add(requestMap);
           }
           catch(Exception ex)
           {
           ex.printStackTrace();
           }
           return message;
           }


          • 2. Re: SOAPClient - unwanted WARN
            Kevin Conner Master

            The WARN would suggest that the webservice is responding using chunking and not specifying the content length. As a result, the HttpClient is buffering the message internally and emitting the warning.

            On the whole this should be harmless unless, that is, your webservice is returning MBs.