public class TransactionMetricsAdapter extends Object implements TransactionMetrics
| Modifier and Type | Class and Description |
|---|---|
static class |
TransactionMetricsAdapter.TransactionMetricsSnapshot
Transaction metrics snapshot.
|
| Modifier and Type | Field and Description |
|---|---|
static String |
METRIC_SYSTEM_TIME_HISTOGRAM
Metric name for system time histogram on node.
|
static long[] |
METRIC_TIME_BUCKETS
Histogram buckets for metrics of system and user time.
|
static String |
METRIC_TOTAL_SYSTEM_TIME
Metric name for total system time on node.
|
static String |
METRIC_TOTAL_USER_TIME
Metric name for total user time on node.
|
static String |
METRIC_USER_TIME_HISTOGRAM
Metric name for user time histogram on node.
|
| Constructor and Description |
|---|
TransactionMetricsAdapter(GridKernalContext ctx) |
| Modifier and Type | Method and Description |
|---|---|
long |
commitTime()
Gets last time transaction was committed.
|
Map<String,String> |
getAllOwnerTransactions()
Gets a map of all transactions for which the local node is the originating node.
|
long |
getLockedKeysNumber()
The number of keys locked on the node.
|
Map<String,String> |
getLongRunningOwnerTransactions(int duration)
Gets a map of all transactions for which the local node is the originating node and which duration
exceeds the given duration.
|
long |
getOwnerTransactionsNumber()
The number of active transactions for which this node is the initiator.
|
long |
getTransactionsCommittedNumber()
The number of transactions which were committed on the local node.
|
long |
getTransactionsHoldingLockNumber()
The number of active transactions on the local node holding at least one key lock.
|
long |
getTransactionsRolledBackNumber()
The number of transactions which were rolled back on the local node.
|
void |
onNearTxComplete(long systemTime,
long userTime)
Callback for completion of near transaction.
|
void |
onTxCommit()
Transaction commit callback.
|
void |
onTxManagerStarted()
Callback invoked when
IgniteTxManager started. |
void |
onTxRollback()
Transaction rollback callback.
|
void |
reset()
Reset.
|
long |
rollbackTime()
Gets last time transaction was rollback.
|
TransactionMetrics |
snapshot() |
String |
toString() |
int |
txCommits()
Gets total number of transaction commits.
|
int |
txRollbacks()
Gets total number of transaction rollbacks.
|
public static final String METRIC_TOTAL_SYSTEM_TIME
public static final String METRIC_SYSTEM_TIME_HISTOGRAM
public static final String METRIC_TOTAL_USER_TIME
public static final String METRIC_USER_TIME_HISTOGRAM
public static final long[] METRIC_TIME_BUCKETS
public TransactionMetricsAdapter(GridKernalContext ctx)
ctx - Kernal context.public void onTxManagerStarted()
IgniteTxManager started.public long commitTime()
commitTime in interface TransactionMetricspublic long rollbackTime()
rollbackTime in interface TransactionMetricspublic int txCommits()
txCommits in interface TransactionMetricspublic int txRollbacks()
txRollbacks in interface TransactionMetricspublic Map<String,String> getAllOwnerTransactions()
getAllOwnerTransactions in interface TransactionMetricspublic Map<String,String> getLongRunningOwnerTransactions(int duration)
getLongRunningOwnerTransactions in interface TransactionMetricsduration.public long getTransactionsCommittedNumber()
getTransactionsCommittedNumber in interface TransactionMetricspublic long getTransactionsRolledBackNumber()
getTransactionsRolledBackNumber in interface TransactionMetricspublic long getTransactionsHoldingLockNumber()
getTransactionsHoldingLockNumber in interface TransactionMetricspublic long getLockedKeysNumber()
getLockedKeysNumber in interface TransactionMetricspublic long getOwnerTransactionsNumber()
getAllOwnerTransactions.size().getOwnerTransactionsNumber in interface TransactionMetricspublic void onTxCommit()
public void onTxRollback()
public void onNearTxComplete(long systemTime,
long userTime)
systemTime - Transaction system time.userTime - Transaction user time.public void reset()
public TransactionMetrics snapshot()
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.9.0 Release Date : October 15 2020