Hazelcast C++ Client
Public Member Functions | Friends | List of all members
hazelcast::client::MembershipListener Class Referenceabstract

Cluster membership listener. More...

#include <MembershipListener.h>

+ Inheritance diagram for hazelcast::client::MembershipListener:

Public Member Functions

virtual void memberAdded (const MembershipEvent &membershipEvent)=0
 Invoked when a new member is added to the cluster. More...
 
virtual void memberRemoved (const MembershipEvent &membershipEvent)=0
 Invoked when an existing member leaves the cluster. More...
 
virtual void memberAttributeChanged (const MemberAttributeEvent &memberAttributeEvent)=0
 Invoked when an attribute of a member was changed. More...
 

Friends

class Cluster
 
class MembershipListenerDelegator
 
class InitialMembershipListenerDelegator
 
class spi::impl::ClientClusterServiceImpl
 

Detailed Description

Cluster membership listener.

The MembershipListener will never be called concurrently and all MembershipListeners will receive the events in the same order.

Warning 1: If listener should do a time consuming operation, off-load the operation to another thread. otherwise it will slow down the system.

Warning 2: Do not make a call to hazelcast. It can cause deadlock.

See also
InitialMembershipListener
Cluster::addMembershipListener(MembershipListener*)

Member Function Documentation

◆ memberAdded()

virtual void hazelcast::client::MembershipListener::memberAdded ( const MembershipEvent membershipEvent)
pure virtual

Invoked when a new member is added to the cluster.

Parameters
membershipEventmembership event

Implemented in hazelcast::client::MembershipListenerDelegator, and hazelcast::client::InitialMembershipListenerDelegator.

◆ memberAttributeChanged()

virtual void hazelcast::client::MembershipListener::memberAttributeChanged ( const MemberAttributeEvent memberAttributeEvent)
pure virtual

Invoked when an attribute of a member was changed.

Parameters
memberAttributeEventmember attribute event

Implemented in hazelcast::client::MembershipListenerDelegator, and hazelcast::client::InitialMembershipListenerDelegator.

◆ memberRemoved()

virtual void hazelcast::client::MembershipListener::memberRemoved ( const MembershipEvent membershipEvent)
pure virtual

Invoked when an existing member leaves the cluster.

Parameters
membershipEventmembership event

Implemented in hazelcast::client::MembershipListenerDelegator, and hazelcast::client::InitialMembershipListenerDelegator.


The documentation for this class was generated from the following files: