qpid::cluster::ClusterMap Class Reference

Map of established cluster members and newbies waiting for a brain dump. More...

#include <ClusterMap.h>

List of all members.

Public Types

typedef std::map< MemberId, UrlMap
typedef std::set< MemberIdSet

Public Member Functions

 ClusterMap (const MemberId &id, const Url &url, bool isReady)
 ClusterMap (const framing::FieldTable &urls, const framing::FieldTable &states)
bool configChange (cpg_address *current, int nCurrent, cpg_address *left, int nLeft, cpg_address *joined, int nJoined)
 Update from config change.
bool configChange (const std::string &addresses)
bool isNewbie (const MemberId &id) const
bool isMember (const MemberId &id) const
bool isAlive (const MemberId &id) const
Url getNewbieUrl (const MemberId &id)
Url getMemberUrl (const MemberId &id)
MemberId firstNewbie () const
 First newbie in the cluster in ID order, target for offers.
framing::ClusterConnectionMembershipBody asMethodBody () const
 Convert map contents to a cluster control body.
size_t aliveCount () const
size_t memberCount () const
std::vector< UrlmemberUrls () const
bool dumpRequest (const MemberId &id, const std::string &url)
boost::optional< UrldumpOffer (const MemberId &from, const MemberId &to)
 Return non-empty Url if accepted.
bool ready (const MemberId &id, const Url &)

Friends

std::ostream & operator<< (std::ostream &, const Map &)
std::ostream & operator<< (std::ostream &, const ClusterMap &)


Detailed Description

Map of established cluster members and newbies waiting for a brain dump.

Definition at line 44 of file ClusterMap.h.


Member Function Documentation

bool qpid::cluster::ClusterMap::configChange ( cpg_address *  current,
int  nCurrent,
cpg_address *  left,
int  nLeft,
cpg_address *  joined,
int  nJoined 
)

Update from config change.

Returns:
true if member set changed.

framing::ClusterConnectionMembershipBody qpid::cluster::ClusterMap::asMethodBody (  )  const

Convert map contents to a cluster control body.

bool qpid::cluster::ClusterMap::ready ( const MemberId id,
const Url  
)

Returns:
true If this is a new member


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

Generated on Thu Oct 16 13:38:25 2008 for Qpid by  doxygen 1.5.6