public class BinaryLogClientStatistics extends Object implements BinaryLogClientStatisticsMXBean, BinaryLogClient.EventListener, BinaryLogClient.LifecycleListener
| Constructor and Description |
|---|
BinaryLogClientStatistics() |
BinaryLogClientStatistics(BinaryLogClient binaryLogClient) |
| Modifier and Type | Method and Description |
|---|---|
protected long |
getCurrentTimeMillis() |
String |
getLastEvent() |
long |
getNumberOfDisconnects() |
long |
getNumberOfSkippedEvents() |
long |
getSecondsBehindMaster() |
long |
getSecondsSinceLastEvent() |
long |
getTotalBytesReceived() |
long |
getTotalNumberOfEventsSeen() |
void |
onCommunicationFailure(BinaryLogClient client,
Exception ex)
It's guarantied to be called before
BinaryLogClient.LifecycleListener.onDisconnect(BinaryLogClient)) in case of
communication failure. |
void |
onConnect(BinaryLogClient client)
Called once client has successfully logged in but before started to receive binlog events.
|
void |
onDisconnect(BinaryLogClient client)
Called upon disconnect (regardless of the reason).
|
void |
onEvent(Event event) |
void |
onEventDeserializationFailure(BinaryLogClient client,
Exception ex)
Called in case of failed event deserialization.
|
void |
reset() |
public BinaryLogClientStatistics()
public BinaryLogClientStatistics(BinaryLogClient binaryLogClient)
public String getLastEvent()
getLastEvent in interface BinaryLogClientStatisticsMXBeanpublic long getSecondsSinceLastEvent()
getSecondsSinceLastEvent in interface BinaryLogClientStatisticsMXBeanpublic long getSecondsBehindMaster()
getSecondsBehindMaster in interface BinaryLogClientStatisticsMXBeanpublic long getTotalNumberOfEventsSeen()
getTotalNumberOfEventsSeen in interface BinaryLogClientStatisticsMXBeanpublic long getTotalBytesReceived()
getTotalBytesReceived in interface BinaryLogClientStatisticsMXBeanpublic long getNumberOfSkippedEvents()
getNumberOfSkippedEvents in interface BinaryLogClientStatisticsMXBeanpublic long getNumberOfDisconnects()
getNumberOfDisconnects in interface BinaryLogClientStatisticsMXBeanpublic void reset()
reset in interface BinaryLogClientStatisticsMXBeanpublic void onEvent(Event event)
onEvent in interface BinaryLogClient.EventListenerpublic void onEventDeserializationFailure(BinaryLogClient client, Exception ex)
BinaryLogClient.LifecycleListeneronEventDeserializationFailure in interface BinaryLogClient.LifecycleListenerpublic void onDisconnect(BinaryLogClient client)
BinaryLogClient.LifecycleListeneronDisconnect in interface BinaryLogClient.LifecycleListenerpublic void onConnect(BinaryLogClient client)
BinaryLogClient.LifecycleListeneronConnect in interface BinaryLogClient.LifecycleListenerpublic void onCommunicationFailure(BinaryLogClient client, Exception ex)
BinaryLogClient.LifecycleListenerBinaryLogClient.LifecycleListener.onDisconnect(BinaryLogClient)) in case of
communication failure.onCommunicationFailure in interface BinaryLogClient.LifecycleListenerprotected long getCurrentTimeMillis()
Copyright © 2019. All rights reserved.