Class NoOpJGroupsMetricManager
java.lang.Object
org.infinispan.remoting.transport.jgroups.NoOpJGroupsMetricManager
- All Implemented Interfaces:
JGroupsMetricsManager
An empty implementation of
JGroupsMetricsManager
.
All methods are no-op except for trackRequest(Address)
which return an instance of
NoOpRequestTracker
.
- See Also:
-
NoOpRequestTracker
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onChannelConnected
(org.jgroups.JChannel channel, boolean isMainChannel) Registers metrics for aJChannel
.void
onChannelDisconnected
(org.jgroups.JChannel channel) Unregisters metrics for aJChannel
.void
recordMessageSent
(Address destination, int bytesSent, boolean async) Records a message sent to adestination
.trackRequest
(Address destination) Track the latency for a synchronous request.
-
Field Details
-
INSTANCE
-
-
Method Details
-
trackRequest
Description copied from interface:JGroupsMetricsManager
Track the latency for a synchronous request.- Specified by:
trackRequest
in interfaceJGroupsMetricsManager
- Parameters:
destination
- The destination address. Cannot be null.- Returns:
- A
RequestTracker
implementation with the send time already set.
-
recordMessageSent
Description copied from interface:JGroupsMetricsManager
Records a message sent to adestination
.Updates the bytes sent and, if it is an async message, the async counter.
- Specified by:
recordMessageSent
in interfaceJGroupsMetricsManager
- Parameters:
destination
- The destination address. Cannot be null.bytesSent
- The number of bytes sent in the message.async
- Set totrue
if the message is asynchronous.
-
onChannelConnected
public void onChannelConnected(org.jgroups.JChannel channel, boolean isMainChannel) Description copied from interface:JGroupsMetricsManager
Registers metrics for aJChannel
.- Specified by:
onChannelConnected
in interfaceJGroupsMetricsManager
- Parameters:
channel
- TheJChannel
instance.isMainChannel
- Set totrue
if this is the main channel (the cluster channel, not cross-site).
-
onChannelDisconnected
public void onChannelDisconnected(org.jgroups.JChannel channel) Description copied from interface:JGroupsMetricsManager
Unregisters metrics for aJChannel
.- Specified by:
onChannelDisconnected
in interfaceJGroupsMetricsManager
- Parameters:
channel
- TheJChannel
instance.
-