Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 23

Thread: M5 ws-handler error

  1. #11

    Default

    The proxy I mentioned is not a firewall proxy, rather a tcpmon proxy.
    And yes, the M3 snapshot ran fine without the proxy setup on the same url and the same machine.

  2. #12
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    Does the Web Service you are invoking require a SoapAction header? If so, can you provide the relevant code/configuration where you are setting the header on the Message? Also, please do provide the M3 configuration excerpt for the <ws-target/> so that I can compare it to the M5 <ws-handler/> that you provided earlier.

    Finally, as I mentioned above, the only change between M3 and M5 is related to the WebServiceMessageFactory. Are you providing the messageFactory in your configuration, or are you relying on the default? (I don't see it in your M5 example, but I haven't seen your M3 configuration yet).

  3. #13

    Default

    M3 config :
    Code:
    <endpoint input-channel="holidayRequestChannel"           handler-ref="magicAdapter"/>
    	
    <beans:bean id="magicAdapter" class="org.springframework.integration.ws.adapter.SimpleWebServiceTargetAdapter">
    <beans:constructor-arg value="${holiday.webservice.url}"/>
    <beans:property name="messageFactory" ref="messageFactory"/>
    	</beans:bean>
    
    <beans:bean id="messageFactory" class="org.springframework.ws.soap.saaj.SaajSoapMessageFactory">
         	<beans:property name="messageFactory">
    	<beans:bean class="com.sun.xml.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl"></beans:bean>
            </beans:property>
        </beans:bean>
    I do want to use the messageFactory config but I have not added that in the config yet <it works on standalone as is, issue is in Jboss , but im testing standalone right now>

    And yes, there is a soap action to be set which I mimicked from your WebService sample , i.e :
    Code:
    //Child class
    props.put(AbstractWebServiceHandler.SOAP_ACTION_PROPERTY_KEY, soapAction);
    
    //Parent class
    Enumeration<?> iter = props.keys();
    
    while (iter.hasMoreElements())
    {
    key = (String)iter.nextElement();
    header.setProperty(key, props.getProperty(key));
    }

  4. #14
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    Can you verify (or have you already) that the M3 version does actually work after removing the messageFactory configuration there? Also, can you try adding that same configuration to the M5 version (in M5, there is a "message-factory" attribute for specifying the reference on the <ws-handler/> element). I would just like to know what happens after removing all differences between your 2 versions. As I mentioned, there have been no code changes for the WebService target/handler itself other than the ability to set the messageFactory via the WebServiceTemplate constructor. Therefore, I don't think a change in Spring Integration is causing this. My hypothesis is that it is related to SAAJ handling of headers.

  5. #15

    Default

    For M3 :

    Yes , it was working fine without messageFactory in standalone environment , but we added the bean definition and messageFactory for JBoss setup.

    For M5 :

    I just added the messageFactory config as follows :
    Code:
    <ws-handler id="holidaycalendar" 
    	uri="http://myserver001/SDSServices/WebService/Gfp1.ASMX" 
    	message-factory="messageFactory" /> 
    <beans:bean id="messageFactory" class="org.springframework.ws.soap.saaj.SaajSoapMessageFactory">
          	<beans:property name="messageFactory">
        	<beans:bean class="com.sun.xml.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl"></beans:bean>
            </beans:property>
        </beans:bean>
    It still works as before , i.e with the properties set , and gives a 404 without those.

    I dont think its Spring Integration either, but maybe Spring web service since we upgraded it to 1.5.1.A .

  6. #16
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    I will check on that for Spring-WS, but didn't you originally have this issue before upgrading to 1.5.1.A?

    If not, can you try to use the same Spring-WS version with the M5 example while also keeping the same <ws-handler/> configuration (including the 'message-factory')? In other words - using everything exactly the same between M3 and M5.

  7. #17

    Default

    Actually it seems i had the issue with the old version i.e 1.5.0 too with SI M5.

    Im not sure exactly what is going wrong and where but the main variables is SI M5 .

  8. #18
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    Do you see the soapAction header on the request WS message in tcpmon?

  9. #19

    Default

    Yes , as follows :
    Code:
    POST http://myserver001/SDSServices/WebService/Gfp1.ASMX HTTP/1.1
    Accept-Encoding: gzip
    Accept: text/xml, text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
    SOAPAction: "http://www.domain.sds.gfp1/GetUSBankHolidays"
    Content-Type: text/xml; charset=utf-8

  10. #20
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    Can you try running the WebServiceDemo in the Spring Integration samples using your M5 environment?

    I just did another line-by-line comparison between the M3 ws-target and M5 ws-handler implementations. Indeed, the only variable is the support for setting the messageFactory as a constructor argument. Since you do see the soapAction header, I really don't see any change that could possible produce this.

    Are there are *any* other differences at all? Java version, JARs on the classpath, different VM args, etc?

    If not, can you paste side-by-side tcpmon results from the M3 and M5 request messages?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •