lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cyang2010 <>
Subject Too many open files exception related to solrj getServer too often?
Date Mon, 11 Apr 2011 21:23:33 GMT

I get this solrj error in development environment.

Too many open files

At the time there was no reindexing or any write to the index.   There were
only different queries genrated using solrj to hit solr server:

        CommonsHttpSolrServer server = new CommonsHttpSolrServer(url);
        server.setSoTimeout(1000); // socket read timeout
        QueryResponse rsp = server.query(solrQuery);

I did NOT share reference of solrj CommonsHttpSolrServer among requests.  
So every http request will obtain a solj solr server instance and run query
on it.  

The question is:

1. Should solrj client share one instance of CommonHttpSolrServer?   Why? 
Is every CommonHttpSolrServer matched to one solr/lucene reader?  But from
the source code, it just shows it related to one apache http client.

2. Is TooManyOpenFiles exeption related to my possible wrong usage of

3. server.query(solrQuery) throws SolrServerException.  How can concurrent
solr queries triggers Too many open file exception?

Look forward to your input.  Thanks,


View this message in context:
Sent from the Solr - User mailing list archive at

View raw message