You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by NarasimhaRaju <ra...@yahoo.com> on 2010/06/17 13:38:42 UTC

RejectedExecutionException when shutttingdown corecontainer

Hi,

I am using solr 1.3 and when indexing i am getting RejectedExecutionException after processing the last batch of update records from the database.
happening when coreContainer.shutdown() is called after processing the last record.
i have autocommits enabled based on maxTime which is 10 minutes.

from the exception below i see it's happening from commitTracker of DefaultUpdateHandler2.

looking at the SolrCore.close method searchExecutor.shutdown() is called before updateHandler.close()

I still don't understand why updateHandler is called after searchExcecutor when updateHandler has the possibility of adding/submitting to searchExecutor.

is this a bug or am i doing something wrong with my autocommit.




SEVERE: java.util.concurrent.RejectedExecutionException
        at java.util.concurrent.ThreadPoolExecutor$AbortPolicy.rejectedExecution(ThreadPoolExecutor.java:1760)
        at java.util.concurrent.ThreadPoolExecutor.reject(ThreadPoolExecutor.java:767)
        at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:658)
        at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:92)
        at java.util.concurrent.Executors$DelegatedExecutorService.submit(Executors.java:603)
        at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1029)
        at org.apache.solr.update.DirectUpdateHandler2.commit(DirectUpdateHandler2.java:368)
        at org.apache.solr.update.DirectUpdateHandler2$CommitTracker.run(DirectUpdateHandler2.java:515)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:207)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)



 
Regards,
Narasimha



      

Re: RejectedExecutionException when shutttingdown corecontainer

Posted by Chris Hostetter <ho...@fucit.org>.
Sorry for such a late reply...

: I still don't understand why updateHandler is called after 
: searchExcecutor when updateHandler has the possibility of 
: adding/submitting to searchExecutor.

...i believe you are correct, this does look like a race condition bug.  

I've opened SOLR-2008 to track fixing this...
https://issues.apache.org/jira/browse/SOLR-2008

Thanks for bringing this up!


-Hoss