@Beta
public interface CDSShardAccess
| Modifier and Type | Method and Description | 
|---|---|
| @NonNull LeaderLocation | getLeaderLocation()Return the shard leader location relative to the local node. | 
| @NonNull org.opendaylight.mdsal.dom.api.DOMDataTreeIdentifier | getShardIdentifier()Return the shard identifier. | 
| @NonNull CompletionStage<Void> | makeLeaderLocal()Request the shard leader to be moved to the local node. | 
| <L extends LeaderLocationListener> | registerLeaderLocationListener(L listener)Register a listener to shard location changes. | 
@NonNull org.opendaylight.mdsal.dom.api.DOMDataTreeIdentifier getShardIdentifier()
IllegalStateException - if the CDSDataTreeProducer from which the associated
         CDSDataTreeProducer is no longer valid.@NonNull LeaderLocation getLeaderLocation()
IllegalStateException - if the CDSDataTreeProducer from which the associated
         CDSDataTreeProducer is no longer valid.@NonNull CompletionStage<Void> makeLeaderLocal()
CompletionStage will report an exception.
 This is a one-time operation, which does not prevent further movement happening in future. Even if this request succeeds, there is no guarantee that the leader will remain local in face of failures, shutdown or any future movement requests from other nodes.
 Note that due to asynchronous nature of CDS, the leader may no longer be local by the time the returned
 CompletionStage reports success.
CompletionStage representing the request.IllegalStateException - if the CDSDataTreeProducer from which the associated
         CDSDataTreeProducer is no longer valid.<L extends LeaderLocationListener> @NonNull LeaderLocationListenerRegistration<L> registerLeaderLocationListener(L listener)
listener - Listener objectLeaderLocationListenerRegistration for the listener.IllegalArgumentException - if the specified listener is already registered.IllegalStateException - if the CDSDataTreeProducer from which the associated
         CDSDataTreeProducer is no longer valid.NullPointerException - if listener is null.Copyright © 2019 OpenDaylight. All rights reserved.