Package io.grpc.rls
Class SubchannelStateManagerImpl
java.lang.Object
io.grpc.rls.SubchannelStateManagerImpl
- All Implemented Interfaces:
SubchannelStateManager
Implementation of
SubchannelStateManager.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ConnectivityStateprivate final HashMap<String, ConnectivityState> private final com.google.common.collect.Multiset<ConnectivityState> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns representative subchannel status from all registered subchannels.Returns current subchannel state for given subchannel name if exists, otherwise returnsnull.toString()voidupdateState(String name, ConnectivityState newState) Registers and updates state for given subchannel.
-
Field Details
-
stateMap
-
stateMultiset
-
currentState
-
-
Constructor Details
-
SubchannelStateManagerImpl
SubchannelStateManagerImpl()
-
-
Method Details
-
updateState
Description copied from interface:SubchannelStateManagerRegisters and updates state for given subchannel.ConnectivityState.SHUTDOWNunregisters the subchannel.- Specified by:
updateStatein interfaceSubchannelStateManager
-
getState
Description copied from interface:SubchannelStateManagerReturns current subchannel state for given subchannel name if exists, otherwise returnsnull.- Specified by:
getStatein interfaceSubchannelStateManager
-
getAggregatedState
Description copied from interface:SubchannelStateManagerReturns representative subchannel status from all registered subchannels.- Specified by:
getAggregatedStatein interfaceSubchannelStateManager
-
toString
-