Class OverseerTriggerThread
- java.lang.Object
-
- org.apache.solr.cloud.autoscaling.OverseerTriggerThread
-
- All Implemented Interfaces:
Closeable,AutoCloseable,Runnable,SolrCloseable
public class OverseerTriggerThread extends Object implements Runnable, SolrCloseable
Overseer thread responsible for reading triggers from zookeeper and adding/removing them fromScheduledTriggers
-
-
Constructor Summary
Constructors Constructor Description OverseerTriggerThread(SolrResourceLoader loader, SolrCloudManager cloudManager, CloudConfig cloudConfig)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()intgetProcessedZnodeVersion()For tests, to ensure that all processing has been completed in response to an update of /autoscaling.json.ScheduledTriggersgetScheduledTriggers()For tests.booleanisClosed()voidrun()
-
-
-
Constructor Detail
-
OverseerTriggerThread
public OverseerTriggerThread(SolrResourceLoader loader, SolrCloudManager cloudManager, CloudConfig cloudConfig)
-
-
Method Detail
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
getScheduledTriggers
public ScheduledTriggers getScheduledTriggers()
For tests.- Returns:
- current
ScheduledTriggersinstance - NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.
-
getProcessedZnodeVersion
public int getProcessedZnodeVersion()
For tests, to ensure that all processing has been completed in response to an update of /autoscaling.json.- Returns:
- version of /autoscaling.json for which all configuration updates & processing have been completed. Until then this value will always be smaller than the current znodeVersion of /autoscaling.json.
- NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.
-
isClosed
public boolean isClosed()
- Specified by:
isClosedin interfaceSolrCloseable
-
-