hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Kalnichevski (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (HTTPASYNC-38) Too many file open in httpclient
Date Tue, 02 Apr 2013 08:55:15 GMT

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

Oleg Kalnichevski resolved HTTPASYNC-38.
----------------------------------------

    Resolution: Invalid

Is this a question or a bug report? If the latter I see no evidence of the problem being a
bug in HttpClient. System can run out of descriptors for various reasons depending on local
TCP/IP settings.

Oleg
                
> Too many file open in httpclient
> --------------------------------
>
>                 Key: HTTPASYNC-38
>                 URL: https://issues.apache.org/jira/browse/HTTPASYNC-38
>             Project: HttpComponents HttpAsyncClient
>          Issue Type: Bug
>            Reporter: LeninGovi
>
> I have written a thread program which is running one minute once to get document from
couchDB database  using httpclient 4.2.3 ,it is working for some time after that giving exception
as "Too many file open"
> This is my code :
> PoolingClientConnectionManager connectionManager = new PoolingClientConnectionManager();
> 		HttpClient httpclient = new DefaultHttpClient(connectionManager);
> 		HttpGet get = new HttpGet("http://10.163.29.105:5984/crl_archive1/_design/DataView/_view/viewAll");
> 		try{
> 			HttpResponse response = httpclient.execute(get);
> 	        BufferedReader reader = new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
> try{       
> 	while( (strdata =reader.readLine())!=null)
> 	{     
> 	   output+=strdata;
> 	}
> 	}catch (Exception e) {
> 		e.printStackTrace();
> 	}
> }}catch (Exception e) {
> 		System.out.println("Error:"+e.getMessage());
> 		e.printStackTrace();
> 		log.error(e.getMessage());
> 		}
> try{
> 			Thread.sleep("60000");
> get.releaseConnection();
> 			get.abort();
> 			connectionManager.closeExpiredConnections();
> 			Fetch();	
> 		}catch (InterruptedException ie) {
> 			Thread.currentThread().interrupt();
> 			log.error(ie.getMessage());
> 		}
> i am closing connection eventhough, it is still same error coming,
> what would be the problem,
> Please Help me
> Thanks in advance
> Regards
> G.Lenin

--
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


Mime
View raw message