Class JGroupsCluster
java.lang.Object
net.ontopia.persistence.proxy.jgroups.JGroupsCluster
- All Implemented Interfaces:
ClusterIF,InstrumentedClusterIF,org.jgroups.Receiver
INTERNAL: Class that represents a jgroups cluster of Ontopia instances.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.jgroups.JChannelprotected Stringprotected final Set<ClusterNodeListenerIF>protected ConcurrentLinkedQueue<JGroupsEvent>protected StorageIFFields inherited from interface net.ontopia.persistence.proxy.ClusterIF
DATA_CACHE_CLEAR, DATA_CACHE_FIELD_EVICT, DATA_CACHE_FIELDS_EVICT, DATA_CACHE_IDENTITY_EVICT, QUERY_CACHE_RT1_CLEAR, QUERY_CACHE_RT1_EVICT, QUERY_CACHE_RT2_CLEAR, QUERY_CACHE_RT2_EVICT, QUERY_CACHE_SRCLOC_CLEAR, QUERY_CACHE_SRCLOC_EVICT, QUERY_CACHE_SUBIND_CLEAR, QUERY_CACHE_SUBIND_EVICT, QUERY_CACHE_SUBLOC_CLEAR, QUERY_CACHE_SUBLOC_EVICT -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedJGroupsCluster(String clusterId, StorageIF storage) JGroupsCluster(String clusterId, org.jgroups.JChannel channel) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddClusterNodeListener(ClusterNodeListenerIF listener) voidclearCache(IdentityIF namespace, int cacheType) voidprotected org.jgroups.JChannelvoidevictCache(IdentityIF namespace, int cacheType, Object key) voidevictCache(IdentityIF namespace, int cacheType, Collection keys) voidevictField(IdentityIF identity, int field) voidevictFields(IdentityIF identity) voidevictIdentity(IdentityIF identity) voidflush()org.jgroups.JChannellonglonglonglonglongprotected longgetStat(ToLongFunction<org.jgroups.protocols.MsgStats> statMethod) voidjoin()voidleave()protected voidvoidreceive(org.jgroups.Message msg) voidvoidviewAccepted(org.jgroups.View view) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jgroups.Receiver
getState, receive, setState
-
Field Details
-
channel
protected org.jgroups.JChannel channel -
clusterId
-
storage
-
queue
-
listeners
-
-
Constructor Details
-
JGroupsCluster
-
JGroupsCluster
-
-
Method Details
-
join
public void join() -
createChannel
protected org.jgroups.JChannel createChannel() -
getChannel
public org.jgroups.JChannel getChannel() -
leave
public void leave() -
evictIdentity
- Specified by:
evictIdentityin interfaceClusterIF
-
evictFields
- Specified by:
evictFieldsin interfaceClusterIF
-
evictField
- Specified by:
evictFieldin interfaceClusterIF
-
clearDatacache
public void clearDatacache()- Specified by:
clearDatacachein interfaceClusterIF
-
evictCache
- Specified by:
evictCachein interfaceClusterIF
-
evictCache
- Specified by:
evictCachein interfaceClusterIF
-
clearCache
- Specified by:
clearCachein interfaceClusterIF
-
flush
public void flush() -
processEvent
-
receive
public void receive(org.jgroups.Message msg) - Specified by:
receivein interfaceorg.jgroups.Receiver
-
viewAccepted
public void viewAccepted(org.jgroups.View view) - Specified by:
viewAcceptedin interfaceorg.jgroups.Receiver
-
getClusterName
- Specified by:
getClusterNamein interfaceClusterIF
-
getClusterState
- Specified by:
getClusterStatein interfaceInstrumentedClusterIF
-
getStat
-
getClusterReceivedBytes
public long getClusterReceivedBytes()- Specified by:
getClusterReceivedBytesin interfaceInstrumentedClusterIF
-
getClusterReceivedMessages
public long getClusterReceivedMessages()- Specified by:
getClusterReceivedMessagesin interfaceInstrumentedClusterIF
-
getClusterSentBytes
public long getClusterSentBytes()- Specified by:
getClusterSentBytesin interfaceInstrumentedClusterIF
-
getClusterSentMessages
public long getClusterSentMessages()- Specified by:
getClusterSentMessagesin interfaceInstrumentedClusterIF
-
getClusterNodeCount
public long getClusterNodeCount()- Specified by:
getClusterNodeCountin interfaceClusterIF
-
getClusterNodes
- Specified by:
getClusterNodesin interfaceClusterIF
-
getClusterNode
- Specified by:
getClusterNodein interfaceClusterIF
-
addClusterNodeListener
- Specified by:
addClusterNodeListenerin interfaceClusterIF
-
removeClusterNodeListener
- Specified by:
removeClusterNodeListenerin interfaceClusterIF
-