hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kalnichevski, Oleg" <oleg.kalnichev...@bearingpoint.com>
Subject RE: Thounds of "Response content length is not known" in the log file
Date Fri, 21 Nov 2003 14:53:21 GMT
Odi,
If I interpret the spec right, there's not much of a difference. In HTTP/1.0 an entity enclosing
response must have 'Content-Type'. In HTTP/1.1 an entity enclosing response must have 'Content-Type'
OR 'Transfer-Encoding'. It is not allowed to have neither.

Actually the spec goes as far as suggesting the following: 

   For compatibility with HTTP/1.0 applications, HTTP/1.1 requests
   containing a message-body MUST include a valid Content-Length header
   field unless the server is known to be HTTP/1.1 compliant. If a
   request contains a message-body and a Content-Length is not given,
   the server SHOULD respond with 400 (bad request) if it cannot
   determine the length of the message, or with 411 (length required) if
   it wishes to insist on receiving a valid Content-Length.

In fact HttpClient plays way too nicely with non-compliant web servers.

Oleg

-----Original Message-----
From: Ortwin Gl├╝ck [mailto:ortwin.glueck@nose.ch]
Sent: Friday, November 21, 2003 15:44
To: Commons HttpClient Project
Subject: Re: Thounds of "Response content length is not known" in the
log file


oh I see that transfer encoding is taken care of. So ignore the passage 
about that in my previous posting. Still we should engange 
shouldCloseConnection here because of the difference in HTTP/1.0 and 1.1


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-httpclient-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-httpclient-dev-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-httpclient-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-httpclient-dev-help@jakarta.apache.org


Mime
View raw message