Package org.apache.catalina.ha
Class ClusterListener
java.lang.Object
org.apache.catalina.ha.ClusterListener
- All Implemented Interfaces:
- ChannelListener
- Direct Known Subclasses:
- ClusterSessionListener,- FarmWarDeployer
Receive SessionID cluster change from other backup node after primary session node is failed.
- Author:
- Peter Rossbach
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionfinal booleanaccept(Serializable msg, Member member) Invoked by the channel to determine if the listener will process this message or not.abstract booleanaccept(ClusterMessage msg) Accept only a certain type of messages.final voidmessageReceived(Serializable msg, Member member) Receive a message from the channelabstract voidCallback from the cluster, when a message is received, The cluster will broadcast it invoking the messageReceived on the receiver.voidsetCluster(CatalinaCluster cluster) 
- 
Field Details- 
cluster
 
- 
- 
Constructor Details- 
ClusterListenerpublic ClusterListener()
 
- 
- 
Method Details- 
getCluster
- 
setCluster
- 
messageReceivedDescription copied from interface:ChannelListenerReceive a message from the channel- Specified by:
- messageReceivedin interface- ChannelListener
- Parameters:
- msg- Serializable
- member- - the source of the message
 
- 
acceptDescription copied from interface:ChannelListenerInvoked by the channel to determine if the listener will process this message or not.- Specified by:
- acceptin interface- ChannelListener
- Parameters:
- msg- Serializable
- member- Member
- Returns:
- boolean
 
- 
messageReceivedCallback from the cluster, when a message is received, The cluster will broadcast it invoking the messageReceived on the receiver.- Parameters:
- msg- the message received from the cluster
 
- 
acceptAccept only a certain type of messages.- Parameters:
- msg- the message
- Returns:
- trueto indicate that messageReceived should be invoked. If- falseis returned, the messageReceived method will not be invoked.
 
 
-