You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "shin (JIRA)" <ji...@apache.org> on 2013/01/04 15:12:13 UTC
[jira] [Created] (HTTPCLIENT-1289) Timeout exception caused by http
500 error
shin created HTTPCLIENT-1289:
--------------------------------
Summary: Timeout exception caused by http 500 error
Key: HTTPCLIENT-1289
URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1289
Project: HttpComponents HttpClient
Issue Type: Bug
Reporter: shin
I'm trying using fluent client, but getting a strange issue.
Here is the pseudo code
-----------------------------------------
public String get(String url) throw Exception
{
return .Get("http://somehost/")
.connectTimeout(1000)
.socketTimeout(1000)
.execute().returnContent().asString();
}
int main()
{
try
{
get("urlA");
}
catch(Exception e)
e.printstack();
try
{
get("urlB");
}
catch(Exception e)
e.printstack();
}
-------------------------
Here is the problem
If I enter the first get function, get a http 500 exception.
Then get urlB , it would block until the socket timeout, and throw a timeout exception.
any solution?
urlB can be executed in front of urlA
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org