I have been trying for a day or so to work around this problem, and I think I've finally exhausted my ability to make forward progress on my own.

My situation is that I am running a service over SSL, but SSL is handled by a hardware accelerator that also does load balancing. I imagine that many people on this list also run in such a configuration.

The problem is that my WSDL is being returned by Axis with an http URL, even though the service is running behind https as far as clients are concerned. After a fair amount of investigation, I came up with two significant possibilities that might help me work around this issue:

1) Add a handler to the request chain that rewrites the msgContext TransportName. I tried doing this, and still it was coming back as http, even though I was able to confirm that my handler was being called, and the msgContext was being updated properly.

2) Add a <wsdlFile> element to my service description, with the location obviously being specified as https instead of http. I was also able to confirm that my file was being read, but the location was being rewritten as http.

I dug into this further, and the final bit of code in QSWSDLHandler.invoke() showed me the problem:

           if (wsdlDoc != null) {
               try {
                   updateSoapAddressLocationURLs(wsdlDoc, msgContext);
               } catch (RuntimeException re) { ... }
               response.setContentType(
                       "text/xml; charset=" +
                       XMLUtils.getEncoding().toLowerCase());
               reportWSDL(wsdlDoc, writer);
           } else { ... }

And the Javadoc for updateSoapAddressLocationURLs is:

   /**
    * Updates the soap:address locations for all ports in the WSDL using the URL from the request as
    * the base portion for the updated locations, ensuring the WSDL returned to the client contains
    * the correct location URL.
    * ...
    */

This behavior is obviously incorrect for my situation, but I do not see anywhere in the code that I can override it. In fact, it overrides all attempts to do so.

Any ideas?

James

Reply via email to