Package org.onosproject.mastership
Interface MastershipAdminService
- 
 public interface MastershipAdminServiceService for administering the inventory of device masterships.
- 
- 
Field SummaryFields Modifier and Type Field Description static longTIMEOUT_MILLIS
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidbalanceRoles()Balances the mastership to be shared as evenly as possibly by all online instances.java.util.concurrent.CompletableFuture<java.lang.Void>setRole(NodeId instance, DeviceId deviceId, MastershipRole role)Applies the current mastership role for the specified device.default voidsetRoleSync(NodeId instance, DeviceId deviceId, MastershipRole role)Synchronous version of setRole.
 
- 
- 
- 
Field Detail- 
TIMEOUT_MILLISstatic final long TIMEOUT_MILLIS - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
setRolejava.util.concurrent.CompletableFuture<java.lang.Void> setRole(NodeId instance, DeviceId deviceId, MastershipRole role) Applies the current mastership role for the specified device.- Parameters:
- instance- controller instance identifier
- deviceId- device identifier
- role- requested role
- Returns:
- future that is completed when the role is set
 
 - 
setRoleSyncdefault void setRoleSync(NodeId instance, DeviceId deviceId, MastershipRole role) Synchronous version of setRole. Applies the current mastership role for the specified device.- Parameters:
- instance- controller instance identifier
- deviceId- device identifier
- role- requested role
 
 - 
balanceRolesvoid balanceRoles() Balances the mastership to be shared as evenly as possibly by all online instances.
 
- 
 
-