Interface CollectionCommandContext
-
- All Known Implementing Classes:
DistributedCollectionCommandContext,OcmhCollectionCommandContext
public interface CollectionCommandContextData passed to Collection API command execution, to allow calls from either theOverseerCollectionMessageHandlerwhen commands are executed on the Overseer, or - in a future change - allow Collection API commands to be executed in a distributed way, unrelated to and not depending upon Overseer abstractions (including overseer collection message handling).
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default CollectionHandlingUtils.ShardRequestTrackerasyncRequestTracker(String asyncId)default StringgetAdminPath()admin path passed to Overseer is a constant, including in tests.org.apache.solr.common.SolrCloseablegetCloseableToLatchOn()CoreContainergetCoreContainer()DistributedClusterStateUpdatergetDistributedClusterStateUpdater()ExecutorServicegetExecutorService()default StringgetOverseerId()default StatsgetOverseerStats()Command delegating to Overseer to retrieve cluster state update stats from a Collection API call.org.apache.solr.client.solrj.cloud.SolrCloudManagergetSolrCloudManager()org.apache.solr.common.cloud.ZkStateReadergetZkStateReader()booleanisDistributedCollectionAPI()When this method returnstrue, Overseer specific actions do not make sense and commands should not be doing them.ShardHandlernewShardHandler()default voidofferStateUpdate(byte[] data)This method enables the commands to enqueue to the overseer cluster state update.default voidofferStateUpdate(org.apache.solr.common.MapWriter data)default voidsubmitIntraProcessMessage(Overseer.Message message)Method used by Per Replica States implementation to force the cluster state updater to immediately reload a collection from Zookeeper.
-
-
-
Method Detail
-
isDistributedCollectionAPI
boolean isDistributedCollectionAPI()
When this method returnstrue, Overseer specific actions do not make sense and commands should not be doing them.
-
newShardHandler
ShardHandler newShardHandler()
-
getSolrCloudManager
org.apache.solr.client.solrj.cloud.SolrCloudManager getSolrCloudManager()
-
getZkStateReader
org.apache.solr.common.cloud.ZkStateReader getZkStateReader()
-
getDistributedClusterStateUpdater
DistributedClusterStateUpdater getDistributedClusterStateUpdater()
-
getCoreContainer
CoreContainer getCoreContainer()
-
asyncRequestTracker
default CollectionHandlingUtils.ShardRequestTracker asyncRequestTracker(String asyncId)
-
getAdminPath
default String getAdminPath()
admin path passed to Overseer is a constant, including in tests.
-
getCloseableToLatchOn
org.apache.solr.common.SolrCloseable getCloseableToLatchOn()
-
getExecutorService
ExecutorService getExecutorService()
-
offerStateUpdate
default void offerStateUpdate(byte[] data) throws org.apache.zookeeper.KeeperException, InterruptedExceptionThis method enables the commands to enqueue to the overseer cluster state update. This should only be used when the cluster state update is running in the Overseer (and will throw an exception if called when Collection API is distributed given that distributed Collection API implies distributed Cluster State Update)- Throws:
org.apache.zookeeper.KeeperExceptionInterruptedException
-
offerStateUpdate
default void offerStateUpdate(org.apache.solr.common.MapWriter data) throws org.apache.zookeeper.KeeperException, InterruptedException- Throws:
org.apache.zookeeper.KeeperExceptionInterruptedException
-
getOverseerId
default String getOverseerId()
-
getOverseerStats
default Stats getOverseerStats()
Command delegating to Overseer to retrieve cluster state update stats from a Collection API call. This does not make sense when cluster state updates are distributed given Overseer does not see them and can't collect stats.
-
submitIntraProcessMessage
default void submitIntraProcessMessage(Overseer.Message message)
Method used by Per Replica States implementation to force the cluster state updater to immediately reload a collection from Zookeeper. This method is not used when cluster state updates are distributed.
-
-