Andrzej Bialecki  created SOLR-11171:
----------------------------------------

             Summary: OverseerTriggerThread throws a fatal exception when 
ScheduledTriggers is closed
                 Key: SOLR-11171
                 URL: https://issues.apache.org/jira/browse/SOLR-11171
             Project: Solr
          Issue Type: Bug
      Security Level: Public (Default Security Level. Issues are Public)
          Components: AutoScaling
            Reporter: Andrzej Bialecki 
            Assignee: Andrzej Bialecki 
             Fix For: 7.1


[~caomanhdat] reports that some test runs encounter errors like this:
{code}
FAILED:  org.apache.solr.cloud.LeaderInitiatedRecoveryOnCommitTest.test

Error Message:
Captured an uncaught exception in thread: Thread[id=3592, 
name=OverseerAutoScalingTriggerThread-98399623586316301-127.0.0.1:46752__jbu%2Fl-n_0000000002,
 state=RUNNABLE, group=Overseer autoscaling triggers]

Stack Trace:
com.carrotsearch.randomizedtesting.UncaughtExceptionError: Captured an uncaught 
exception in thread: Thread[id=3592, 
name=OverseerAutoScalingTriggerThread-98399623586316301-127.0.0.1:46752__jbu%2Fl-n_0000000002,
 state=RUNNABLE, group=Overseer autoscaling triggers]
        at 
__randomizedtesting.SeedInfo.seed([829F220930068B70:ACB1DD39EFAE688]:0)
Caused by: org.apache.lucene.store.AlreadyClosedException: ScheduledTriggers 
has been closed and cannot be used anymore
        at __randomizedtesting.SeedInfo.seed([829F220930068B70]:0)
        at 
org.apache.solr.cloud.autoscaling.ScheduledTriggers.add(ScheduledTriggers.java:137)
        at 
org.apache.solr.cloud.autoscaling.OverseerTriggerThread.run(OverseerTriggerThread.java:189)
        at java.lang.Thread.run(Thread.java:745)
{code}

This is caused by the ordering of {{isClosed}} checks vs. the places where 
OverseerTriggerThread attempts to modify scheduled triggers - 
{{OverseerTriggerThread.close()}} sets the flag and closes 
{{ScheduledTriggers}} but the main loop in {{run()}} will continue executing 
until the loop's end and may try to use already closed {{ScheduleTriggers}}.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to