hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vinay Patodia (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HTTPCLIENT-1647) HTTP Client reporting "Garbage in response" whereas response seems to be valid
Date Mon, 11 May 2015 21:50:00 GMT

     [ https://issues.apache.org/jira/browse/HTTPCLIENT-1647?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Vinay Patodia updated HTTPCLIENT-1647:
--------------------------------------
    Description: 
While we are using httpclient to communicate couchDB. At lot of times we encounter: 
{noformat}
Caused by: org.apache.http.ProtocolException: The server failed to respond with a valid HTTP
response
{noformat}

On enabling the log we found the following:
{noformat}
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "GET /bbc-metasea-artist-test/27655
HTTP/1.1[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "User-Agent:
Mozilla/5.0 HungamaHttpClient/2.0[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Host: 107.20.145.158:5984[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Connection:
Keep-Alive[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Accept-Encoding:
gzip,deflate[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "HTTP/1.1 200
OK[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Server: CouchDB/1.6.1
(Erlang OTP/R14B04)[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "ETag: "4-c76bb63a643c5fed36df0a059c94b94a"[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Date: Mon,
11 May 2015 21:25:18 GMT[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Content-Type:
text/plain; charset=utf-8[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Content-Length:
281[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Cache-Control:
must-revalidate[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "{"_id":"27655","_rev":"4-c76bb63a643c5fed36df0a059c94b94a","id":"ms2-Pramod
Chakraborty","title":"Pramod Chakraborty","roles":["producer","director"],"metaseaPublisherPulledAt":"2015-05-10T02:42:06.999+0000","metaseaInvalidatedOn":"2015-05-05T08:23:14.691+0000","metaseaId":27655}[\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.impl.conn.DefaultHttpResponseParser : 155 - Garbage
in response: {"_id":"27655","_rev":"4-c76bb63a643c5fed36df0a059c94b94a","id":"ms2-Pramod Chakraborty","title":"Pramod
Chakraborty","roles":["producer","director"],"metaseaPublisherPulledAt":"2015-05-10T02:42:06.999+0000","metaseaInvalidatedOn":"2015-05-05T08:23:14.691+0000","metaseaId":27655}
{noformat}

On the face of it, couchdb seems to be giving a proper response. 

Also we have encountered the thread blocks for reasonable amount not sure but it seems it
waits for timeout, though nothing found in the logs. Something similar behaviour as posted
in HTTPCLIENT-1616

  was:
While we are using httpclient to communicate couchDB. At lot of times we encounter: 
{noformat}
Caused by: org.apache.http.ProtocolException: The server failed to respond with a valid HTTP
response
{noformat}

On enabling the log we found the following:
{noformat}
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "GET /bbc-metasea-artist-test/27655
HTTP/1.1[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "User-Agent:
Mozilla/5.0 HungamaHttpClient/2.0[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Host: 107.20.145.158:5984[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Connection:
Keep-Alive[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Accept-Encoding:
gzip,deflate[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "HTTP/1.1 200
OK[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Server: CouchDB/1.6.1
(Erlang OTP/R14B04)[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "ETag: "4-c76bb63a643c5fed36df0a059c94b94a"[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Date: Mon,
11 May 2015 21:25:18 GMT[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Content-Type:
text/plain; charset=utf-8[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Content-Length:
281[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Cache-Control:
must-revalidate[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "[\r][\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "{"_id":"27655","_rev":"4-c76bb63a643c5fed36df0a059c94b94a","id":"ms2-Pramod
Chakraborty","title":"Pramod Chakraborty","roles":["producer","director"],"metaseaPublisherPulledAt":"2015-05-10T02:42:06.999+0000","metaseaInvalidatedOn":"2015-05-05T08:23:14.691+0000","metaseaId":27655}[\n]"
2015-05-12 02:54:55 DEBUG org.apache.http.impl.conn.DefaultHttpResponseParser : 155 - Garbage
in response: {"_id":"27655","_rev":"4-c76bb63a643c5fed36df0a059c94b94a","id":"ms2-Pramod Chakraborty","title":"Pramod
Chakraborty","roles":["producer","director"],"metaseaPublisherPulledAt":"2015-05-10T02:42:06.999+0000","metaseaInvalidatedOn":"2015-05-05T08:23:14.691+0000","metaseaId":27655}
{noformat}

On the face of it, couchdb seems to be giving a proper response. 


> HTTP Client reporting "Garbage in response" whereas response seems to be valid
> ------------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-1647
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1647
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient
>    Affects Versions: 4.4.1
>            Reporter: Vinay Patodia
>            Priority: Critical
>             Fix For: 4.4.1
>
>
> While we are using httpclient to communicate couchDB. At lot of times we encounter: 
> {noformat}
> Caused by: org.apache.http.ProtocolException: The server failed to respond with a valid
HTTP response
> {noformat}
> On enabling the log we found the following:
> {noformat}
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "GET /bbc-metasea-artist-test/27655
HTTP/1.1[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "User-Agent:
Mozilla/5.0 HungamaHttpClient/2.0[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Host:
107.20.145.158:5984[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Connection:
Keep-Alive[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "Accept-Encoding:
gzip,deflate[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 >> "[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "HTTP/1.1
200 OK[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Server:
CouchDB/1.6.1 (Erlang OTP/R14B04)[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "ETag:
"4-c76bb63a643c5fed36df0a059c94b94a"[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Date:
Mon, 11 May 2015 21:25:18 GMT[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Content-Type:
text/plain; charset=utf-8[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Content-Length:
281[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "Cache-Control:
must-revalidate[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "[\r][\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.wire : 72 - http-outgoing-2 << "{"_id":"27655","_rev":"4-c76bb63a643c5fed36df0a059c94b94a","id":"ms2-Pramod
Chakraborty","title":"Pramod Chakraborty","roles":["producer","director"],"metaseaPublisherPulledAt":"2015-05-10T02:42:06.999+0000","metaseaInvalidatedOn":"2015-05-05T08:23:14.691+0000","metaseaId":27655}[\n]"
> 2015-05-12 02:54:55 DEBUG org.apache.http.impl.conn.DefaultHttpResponseParser : 155 -
Garbage in response: {"_id":"27655","_rev":"4-c76bb63a643c5fed36df0a059c94b94a","id":"ms2-Pramod
Chakraborty","title":"Pramod Chakraborty","roles":["producer","director"],"metaseaPublisherPulledAt":"2015-05-10T02:42:06.999+0000","metaseaInvalidatedOn":"2015-05-05T08:23:14.691+0000","metaseaId":27655}
> {noformat}
> On the face of it, couchdb seems to be giving a proper response. 
> Also we have encountered the thread blocks for reasonable amount not sure but it seems
it waits for timeout, though nothing found in the logs. Something similar behaviour as posted
in HTTPCLIENT-1616



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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


Mime
View raw message