My web application is currently running on jboss, but I have an Apache server which is used as a proxy server for my application. I have the ability to upload XML files on my jboss server. When it loads, it returns an HTTP 200 and XML response Content-Type: text/xml .
Some users use this function in an apache instance that redirects to jboss. These users sometimes use Content-Type: application / xml when loading the file and Accept: / header. Jboss works fine with this header, but apache always returns a bad reaction:
HTTP/1.1 502 Bad Gateway < Date: Mon, 31 Jan 2011 23:33:47 GMT < Server: Apache/2.0.63 (Unix) mod_jk/1.2.27 < Content-Length: 232 < Content-Type: text/html; charset=iso-8859-1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <html><head> <title>502 Bad Gateway</title> </head><body> <h1>Bad Gateway</h1> <p>The proxy server received an invalid response from an upstream server.<br /> </p>
Why does this happen when users use the / xml application instead of the text / xml header value? Does Apache somehow compare these headers? When users use text / xml, everything is fine and apache prints jboss 200 OK response.
user253202
source share