Database Reference
In-Depth Information
public Set<String> getUnreachableNodes()
{
return stringify(Gossiper.instance.getUnreachableMembers());
}
The
Gossiper
class is a Singleton that maintains lists of IP addresses of the nodes it has sent
and received heartbeat messages from, so when you call the
getUnreachableNodes
operation
in the JMX agent, it calls the MBean method in
StorageService
, which delegates the call to
the
Gossiper
, which returns the set of unreachable IP addresses, wrapped in a new set so it can't
be modified directly by the caller:
/* unreachable member set */
private Set<InetAddress> unreachableEndpoints_ =
new ConcurrentSkipListSet<InetAddress>(inetcomparator);
//...
public Set<InetAddress> getUnreachableMembers()
{
return new HashSet<InetAddress>(unreachableEndpoints_);
}
So when we open it up in the JMX agent JConsole, we see, happily, that we have no unreachable
nodes because the set is empty. If there were unreachable nodes, their IP addresses would appear