Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 6.1.4
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Environment:Ubuntu 7.04
Apache/2.2.3 (mod_proxy_ajp)
-
Number of attachments :
Description
I use apache and mod_proxy_ajp for communicating with jetty.
When a client tries to send data to the server and the request is chunked,
i can not retrieve request parameters, just null values but no errors.
Indeed, after analysing the stream using wireshark i have the following request / response in this order :
----------------------------------------------------------------------------------
POST /_log HTTP/1.1
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,/;q=0.5
Content-Type: application/x-www-form-urlencoded
Host: host
Transfer-Encoding: chunked
HTTP/1.1 200 OK
Date: Tue, 31 Jul 2007 14:45:08 GMT
Server: Server: Jetty(6.0.x)
Content-Length: 0
Content-Type: text/plain
7e0
data=...&data2=...
19f
...
0
----------------------------------------------------------------------------------
I have not this problem using Apache with mod_proxy_http and the standard HTTP connector in jetty
or using directly Jetty.
After launching jetty in debug, i found in Ajp13Parser.java and especially the method blockForContent
that the parsing is stopped if the Content-Length header is not present, therefore _contentLength variable
will be HttpTokens.NO_CONTENT or HttpTokens.UNKNOWN_CONTENT.
But, i have read that this Content-Length header is not mandatory for chunked request.
I do not know if this part of the HTTP protocol is handled by mod_proxy_ajp or if it is up to jetty.
The real stream without \r\n pairs, this must be easier to read
----------------------------------------------------------------------------------
POST /_log HTTP/1.1
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,/;q=0.5
Content-Type: application/x-www-form-urlencoded
Host: host
Transfer-Encoding: chunked
HTTP/1.1 200 OK
Date: Tue, 31 Jul 2007 14:45:08 GMT
Server: Server: Jetty(6.0.x)
Content-Length: 0
Content-Type: text/plain
7e0
data=...&data2=...
19f
...
0
----------------------------------------------------------------------------------