I'll start by telling you why I am trying to do this, what approaches I have taken in my attempts to do it, and then I'll ask for some suggestions on other approaches that may work better.
*Why*
We have an MS .Net (1.1) client talking SOAP over HTTP to Webservices built on Sun's JWSDP 1.3 (via Tomcat). There is a pretty strict requirement to compress responses as they are usually 200-1000KB. There is a 'lack of feature' in the MS .Net Webservice client implementation in that it is not possible to decompress the HTTP response when there is a server response code of 500. The SOAP spec requires that SOAP Faults on the server set the response code to 500, and thus we are unable to process any SOAP faults on the client. In all other cases we are cool in decompressing the responses. Since there don't exist any options for us on the client we are limited to the server for solutions.
*Approaches attempted and failed*
-Servlet filters - a servlet filter only has access to the HttpServletRequest and the HttpServletResponse and neither of these is aware of the response status code.
-Coyote's compression option with a numerical value higher than all Soap Fault sizes - it seems that the content-length of the response is always set to -1, either by Sun's JWSDP or because the HTTP response is chunked. I'm not sure which is the cause, but when the content-length is -1, the response is always compressed.
-We tried an endless list of things on the .Net client in an attempt to decompress the SOAP Fault responses to no avail.
*Approaches attempted and suceeded*
-Modifying org.apache.coyote.http11.Http11Processor.class by adding this immediately inside of isCompressible()
if ( response.getStatus() == 500 ) {
return false;
}
I know this isn't pretty but it works. This will be acceptable if I can't find a better option, but it will require that each time we upgrade Tomcat, we'll need to compile a custom Http11Processor. I'll also need to check that we aren't violating the Apache License.
Anyone have any ideas?
Thanks in advance.
-- ------------------------------------------------------ Eric Butler VP Product Development & Founder MDinTouch 786.268.1161 X20 http://www.mdintouch.com [EMAIL PROTECTED] ------------------------------------------------------
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
