Package org.apache.solr.common.cloud
Interface DocCollectionWatcher
public interface DocCollectionWatcher
Callback registered with
ZkStateReader.registerDocCollectionWatcher(String, DocCollectionWatcher) and called whenever the DocCollection changes.-
Method Summary
Modifier and TypeMethodDescriptionbooleanonStateChanged(org.apache.solr.common.cloud.DocCollection collection) Called when the collection we are registered against has a change of state.
-
Method Details
-
onStateChanged
boolean onStateChanged(org.apache.solr.common.cloud.DocCollection collection) Called when the collection we are registered against has a change of state.Note that, due to the way Zookeeper watchers are implemented, a single call may be the result of several state changes. Also, multiple calls to this method can be made with the same state, ie. without any new updates.
- Parameters:
collection- the new collection state (may be null if the collection has been deleted)- Returns:
- true if the watcher should be removed
-