Accessing a web service through mod_jk results in chunked encoding
Issue
- A
JSON
web service deployed on a 2 node cluster. - When accessing the
JSON
web service throughEWS
the server is stripping out the content-length in the response header and the browser (Firefox, IE, Chrome) is not able to render the content. - This is the response header output from Fiddler when accessing the web service directly:
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
X-Powered-By: Servlet 2.5; JBoss-5.0/JBossWeb-2.1
Date: Tue, 09 Aug 2011 14:19:01 GMT
Content-Type: application/json
Content-Length: 67397
- This is the response header output from Fiddler when accessing the web service through
EWS
:
HTTP/1.1 200 OK
Date: Tue, 09 Aug 2011 14:19:02 GMT
Server: Apache/2.2.14 (Red Hat)
X-Powered-By: Servlet 2.5; JBoss-5.0/JBossWeb-2.1
Transfer-Encoding: chunked
Keep-Alive: timeout=10, max=100
Connection: Keep-Alive
Content-Type: application/json
X-Pad: avoid browser bug
Environment
- JBoss Enterprise Web Server (EWS)
- JBoss Enterprise Application Platform (EAP)
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.