Record Class MetricsCollector.Snapshot
java.lang.Object
java.lang.Record
com.pyranid.MetricsCollector.Snapshot
- Record Components:
connectionsAcquiredStatementScope- statement-scoped connection acquisitions that completed normallyconnectionsAcquiredTransactionScope- transaction-scoped connection acquisitions that completed normallyconnectionsFailedStatementScope- statement-scoped connection acquisitions that failedconnectionsFailedTransactionScope- transaction-scoped connection acquisitions that failedconnectionReleaseFailuresStatementScope- statement-scoped connection releases that failedconnectionReleaseFailuresTransactionScope- transaction-scoped connection releases that failedtransactionClosuresEntered- closure-based transactions enteredtransactionClosuresExited- closure-based transactions exitedtransactionClosuresCommitted- closure-based transactions that committedtransactionClosuresRolledBack- closure-based transactions that rolled backtransactionClosuresNoPhysical- closure-based transactions that exited without a physical JDBC transactiontransactionClosuresFailed- closure-based transactions that failed before a normal commit or rollback outcomephysicalTransactionsBegun- physical JDBC transactions begunphysicalTransactionsBeginFailed- physical JDBC transactions that failed while beginningphysicalTransactionsCommitted- physical JDBC transactions committedphysicalTransactionsCommitFailed- physical JDBC transactions whose commit failedphysicalTransactionsRolledBack- physical JDBC transactions rolled backphysicalTransactionsRollbackFailed- physical JDBC transactions whose rollback failedsavepointsCreated- transaction savepoints createdsavepointsRolledBack- transaction savepoints rolled back tosavepointsReleased- transaction savepoints releasedstatementsExecuted- statements that executed successfullystatementsFailed- statements that failed during executionstreamsOpened- streams that opened successfullystreamsOpenFailures- streams that failed before openingstreamsClosedNormally- opened streams that reached the end of the result setstreamsEarlyClosed- opened streams that closed before all rows were consumedstreamsCallbackFailed- opened streams whose caller-provided callback failedstreamsIterationFailed- opened streams whose result-set iteration failedpostTransactionOperationsRun- post-transaction operations that ranpostTransactionOperationsFailed- post-transaction operations that failed
- Enclosing interface:
MetricsCollector
@ThreadSafe
public static record MetricsCollector.Snapshot(@NonNull Long connectionsAcquiredStatementScope, @NonNull Long connectionsAcquiredTransactionScope, @NonNull Long connectionsFailedStatementScope, @NonNull Long connectionsFailedTransactionScope, @NonNull Long connectionReleaseFailuresStatementScope, @NonNull Long connectionReleaseFailuresTransactionScope, @NonNull Long transactionClosuresEntered, @NonNull Long transactionClosuresExited, @NonNull Long transactionClosuresCommitted, @NonNull Long transactionClosuresRolledBack, @NonNull Long transactionClosuresNoPhysical, @NonNull Long transactionClosuresFailed, @NonNull Long physicalTransactionsBegun, @NonNull Long physicalTransactionsBeginFailed, @NonNull Long physicalTransactionsCommitted, @NonNull Long physicalTransactionsCommitFailed, @NonNull Long physicalTransactionsRolledBack, @NonNull Long physicalTransactionsRollbackFailed, @NonNull Long savepointsCreated, @NonNull Long savepointsRolledBack, @NonNull Long savepointsReleased, @NonNull Long statementsExecuted, @NonNull Long statementsFailed, @NonNull Long streamsOpened, @NonNull Long streamsOpenFailures, @NonNull Long streamsClosedNormally, @NonNull Long streamsEarlyClosed, @NonNull Long streamsCallbackFailed, @NonNull Long streamsIterationFailed, @NonNull Long postTransactionOperationsRun, @NonNull Long postTransactionOperationsFailed)
extends Record
Counter snapshot for collectors that support in-process inspection.
Implementations may read counters independently without cross-counter atomicity. Callers that need invariant-consistent snapshots should drain in-flight work before reading.
- Since:
- 4.2.0
- Author:
- Mark Allen
-
Constructor Summary
ConstructorsConstructorDescriptionSnapshot(@NonNull Long connectionsAcquiredStatementScope, @NonNull Long connectionsAcquiredTransactionScope, @NonNull Long connectionsFailedStatementScope, @NonNull Long connectionsFailedTransactionScope, @NonNull Long connectionReleaseFailuresStatementScope, @NonNull Long connectionReleaseFailuresTransactionScope, @NonNull Long transactionClosuresEntered, @NonNull Long transactionClosuresExited, @NonNull Long transactionClosuresCommitted, @NonNull Long transactionClosuresRolledBack, @NonNull Long transactionClosuresNoPhysical, @NonNull Long transactionClosuresFailed, @NonNull Long physicalTransactionsBegun, @NonNull Long physicalTransactionsBeginFailed, @NonNull Long physicalTransactionsCommitted, @NonNull Long physicalTransactionsCommitFailed, @NonNull Long physicalTransactionsRolledBack, @NonNull Long physicalTransactionsRollbackFailed, @NonNull Long savepointsCreated, @NonNull Long savepointsRolledBack, @NonNull Long savepointsReleased, @NonNull Long statementsExecuted, @NonNull Long statementsFailed, @NonNull Long streamsOpened, @NonNull Long streamsOpenFailures, @NonNull Long streamsClosedNormally, @NonNull Long streamsEarlyClosed, @NonNull Long streamsCallbackFailed, @NonNull Long streamsIterationFailed, @NonNull Long postTransactionOperationsRun, @NonNull Long postTransactionOperationsFailed) Creates an instance of aSnapshotrecord class. -
Method Summary
Modifier and TypeMethodDescription@NonNull LongReturns the value of theconnectionReleaseFailuresStatementScoperecord component.@NonNull LongReturns the value of theconnectionReleaseFailuresTransactionScoperecord component.@NonNull LongReturns the value of theconnectionsAcquiredStatementScoperecord component.@NonNull LongReturns the value of theconnectionsAcquiredTransactionScoperecord component.@NonNull LongReturns the value of theconnectionsFailedStatementScoperecord component.@NonNull LongReturns the value of theconnectionsFailedTransactionScoperecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@NonNull LongReturns the value of thephysicalTransactionsBeginFailedrecord component.@NonNull LongReturns the value of thephysicalTransactionsBegunrecord component.@NonNull LongReturns the value of thephysicalTransactionsCommitFailedrecord component.@NonNull LongReturns the value of thephysicalTransactionsCommittedrecord component.@NonNull LongReturns the value of thephysicalTransactionsRollbackFailedrecord component.@NonNull LongReturns the value of thephysicalTransactionsRolledBackrecord component.@NonNull LongReturns the value of thepostTransactionOperationsFailedrecord component.@NonNull LongReturns the value of thepostTransactionOperationsRunrecord component.@NonNull LongReturns the value of thesavepointsCreatedrecord component.@NonNull LongReturns the value of thesavepointsReleasedrecord component.@NonNull LongReturns the value of thesavepointsRolledBackrecord component.@NonNull LongReturns the value of thestatementsExecutedrecord component.@NonNull LongReturns the value of thestatementsFailedrecord component.@NonNull LongReturns the value of thestreamsCallbackFailedrecord component.@NonNull LongReturns the value of thestreamsClosedNormallyrecord component.@NonNull LongReturns the value of thestreamsEarlyClosedrecord component.@NonNull LongReturns the value of thestreamsIterationFailedrecord component.@NonNull LongReturns the value of thestreamsOpenedrecord component.@NonNull LongReturns the value of thestreamsOpenFailuresrecord component.final StringtoString()Returns a string representation of this record class.@NonNull LongReturns the value of thetransactionClosuresCommittedrecord component.@NonNull LongReturns the value of thetransactionClosuresEnteredrecord component.@NonNull LongReturns the value of thetransactionClosuresExitedrecord component.@NonNull LongReturns the value of thetransactionClosuresFailedrecord component.@NonNull LongReturns the value of thetransactionClosuresNoPhysicalrecord component.@NonNull LongReturns the value of thetransactionClosuresRolledBackrecord component.
-
Constructor Details
-
Snapshot
public Snapshot(@NonNull Long connectionsAcquiredStatementScope, @NonNull Long connectionsAcquiredTransactionScope, @NonNull Long connectionsFailedStatementScope, @NonNull Long connectionsFailedTransactionScope, @NonNull Long connectionReleaseFailuresStatementScope, @NonNull Long connectionReleaseFailuresTransactionScope, @NonNull Long transactionClosuresEntered, @NonNull Long transactionClosuresExited, @NonNull Long transactionClosuresCommitted, @NonNull Long transactionClosuresRolledBack, @NonNull Long transactionClosuresNoPhysical, @NonNull Long transactionClosuresFailed, @NonNull Long physicalTransactionsBegun, @NonNull Long physicalTransactionsBeginFailed, @NonNull Long physicalTransactionsCommitted, @NonNull Long physicalTransactionsCommitFailed, @NonNull Long physicalTransactionsRolledBack, @NonNull Long physicalTransactionsRollbackFailed, @NonNull Long savepointsCreated, @NonNull Long savepointsRolledBack, @NonNull Long savepointsReleased, @NonNull Long statementsExecuted, @NonNull Long statementsFailed, @NonNull Long streamsOpened, @NonNull Long streamsOpenFailures, @NonNull Long streamsClosedNormally, @NonNull Long streamsEarlyClosed, @NonNull Long streamsCallbackFailed, @NonNull Long streamsIterationFailed, @NonNull Long postTransactionOperationsRun, @NonNull Long postTransactionOperationsFailed) Creates an instance of aSnapshotrecord class.- Parameters:
connectionsAcquiredStatementScope- the value for theconnectionsAcquiredStatementScoperecord componentconnectionsAcquiredTransactionScope- the value for theconnectionsAcquiredTransactionScoperecord componentconnectionsFailedStatementScope- the value for theconnectionsFailedStatementScoperecord componentconnectionsFailedTransactionScope- the value for theconnectionsFailedTransactionScoperecord componentconnectionReleaseFailuresStatementScope- the value for theconnectionReleaseFailuresStatementScoperecord componentconnectionReleaseFailuresTransactionScope- the value for theconnectionReleaseFailuresTransactionScoperecord componenttransactionClosuresEntered- the value for thetransactionClosuresEnteredrecord componenttransactionClosuresExited- the value for thetransactionClosuresExitedrecord componenttransactionClosuresCommitted- the value for thetransactionClosuresCommittedrecord componenttransactionClosuresRolledBack- the value for thetransactionClosuresRolledBackrecord componenttransactionClosuresNoPhysical- the value for thetransactionClosuresNoPhysicalrecord componenttransactionClosuresFailed- the value for thetransactionClosuresFailedrecord componentphysicalTransactionsBegun- the value for thephysicalTransactionsBegunrecord componentphysicalTransactionsBeginFailed- the value for thephysicalTransactionsBeginFailedrecord componentphysicalTransactionsCommitted- the value for thephysicalTransactionsCommittedrecord componentphysicalTransactionsCommitFailed- the value for thephysicalTransactionsCommitFailedrecord componentphysicalTransactionsRolledBack- the value for thephysicalTransactionsRolledBackrecord componentphysicalTransactionsRollbackFailed- the value for thephysicalTransactionsRollbackFailedrecord componentsavepointsCreated- the value for thesavepointsCreatedrecord componentsavepointsRolledBack- the value for thesavepointsRolledBackrecord componentsavepointsReleased- the value for thesavepointsReleasedrecord componentstatementsExecuted- the value for thestatementsExecutedrecord componentstatementsFailed- the value for thestatementsFailedrecord componentstreamsOpened- the value for thestreamsOpenedrecord componentstreamsOpenFailures- the value for thestreamsOpenFailuresrecord componentstreamsClosedNormally- the value for thestreamsClosedNormallyrecord componentstreamsEarlyClosed- the value for thestreamsEarlyClosedrecord componentstreamsCallbackFailed- the value for thestreamsCallbackFailedrecord componentstreamsIterationFailed- the value for thestreamsIterationFailedrecord componentpostTransactionOperationsRun- the value for thepostTransactionOperationsRunrecord componentpostTransactionOperationsFailed- the value for thepostTransactionOperationsFailedrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
connectionsAcquiredStatementScope
Returns the value of theconnectionsAcquiredStatementScoperecord component.- Returns:
- the value of the
connectionsAcquiredStatementScoperecord component
-
connectionsAcquiredTransactionScope
Returns the value of theconnectionsAcquiredTransactionScoperecord component.- Returns:
- the value of the
connectionsAcquiredTransactionScoperecord component
-
connectionsFailedStatementScope
Returns the value of theconnectionsFailedStatementScoperecord component.- Returns:
- the value of the
connectionsFailedStatementScoperecord component
-
connectionsFailedTransactionScope
Returns the value of theconnectionsFailedTransactionScoperecord component.- Returns:
- the value of the
connectionsFailedTransactionScoperecord component
-
connectionReleaseFailuresStatementScope
Returns the value of theconnectionReleaseFailuresStatementScoperecord component.- Returns:
- the value of the
connectionReleaseFailuresStatementScoperecord component
-
connectionReleaseFailuresTransactionScope
Returns the value of theconnectionReleaseFailuresTransactionScoperecord component.- Returns:
- the value of the
connectionReleaseFailuresTransactionScoperecord component
-
transactionClosuresEntered
Returns the value of thetransactionClosuresEnteredrecord component.- Returns:
- the value of the
transactionClosuresEnteredrecord component
-
transactionClosuresExited
Returns the value of thetransactionClosuresExitedrecord component.- Returns:
- the value of the
transactionClosuresExitedrecord component
-
transactionClosuresCommitted
Returns the value of thetransactionClosuresCommittedrecord component.- Returns:
- the value of the
transactionClosuresCommittedrecord component
-
transactionClosuresRolledBack
Returns the value of thetransactionClosuresRolledBackrecord component.- Returns:
- the value of the
transactionClosuresRolledBackrecord component
-
transactionClosuresNoPhysical
Returns the value of thetransactionClosuresNoPhysicalrecord component.- Returns:
- the value of the
transactionClosuresNoPhysicalrecord component
-
transactionClosuresFailed
Returns the value of thetransactionClosuresFailedrecord component.- Returns:
- the value of the
transactionClosuresFailedrecord component
-
physicalTransactionsBegun
Returns the value of thephysicalTransactionsBegunrecord component.- Returns:
- the value of the
physicalTransactionsBegunrecord component
-
physicalTransactionsBeginFailed
Returns the value of thephysicalTransactionsBeginFailedrecord component.- Returns:
- the value of the
physicalTransactionsBeginFailedrecord component
-
physicalTransactionsCommitted
Returns the value of thephysicalTransactionsCommittedrecord component.- Returns:
- the value of the
physicalTransactionsCommittedrecord component
-
physicalTransactionsCommitFailed
Returns the value of thephysicalTransactionsCommitFailedrecord component.- Returns:
- the value of the
physicalTransactionsCommitFailedrecord component
-
physicalTransactionsRolledBack
Returns the value of thephysicalTransactionsRolledBackrecord component.- Returns:
- the value of the
physicalTransactionsRolledBackrecord component
-
physicalTransactionsRollbackFailed
Returns the value of thephysicalTransactionsRollbackFailedrecord component.- Returns:
- the value of the
physicalTransactionsRollbackFailedrecord component
-
savepointsCreated
Returns the value of thesavepointsCreatedrecord component.- Returns:
- the value of the
savepointsCreatedrecord component
-
savepointsRolledBack
Returns the value of thesavepointsRolledBackrecord component.- Returns:
- the value of the
savepointsRolledBackrecord component
-
savepointsReleased
Returns the value of thesavepointsReleasedrecord component.- Returns:
- the value of the
savepointsReleasedrecord component
-
statementsExecuted
Returns the value of thestatementsExecutedrecord component.- Returns:
- the value of the
statementsExecutedrecord component
-
statementsFailed
Returns the value of thestatementsFailedrecord component.- Returns:
- the value of the
statementsFailedrecord component
-
streamsOpened
Returns the value of thestreamsOpenedrecord component.- Returns:
- the value of the
streamsOpenedrecord component
-
streamsOpenFailures
Returns the value of thestreamsOpenFailuresrecord component.- Returns:
- the value of the
streamsOpenFailuresrecord component
-
streamsClosedNormally
Returns the value of thestreamsClosedNormallyrecord component.- Returns:
- the value of the
streamsClosedNormallyrecord component
-
streamsEarlyClosed
Returns the value of thestreamsEarlyClosedrecord component.- Returns:
- the value of the
streamsEarlyClosedrecord component
-
streamsCallbackFailed
Returns the value of thestreamsCallbackFailedrecord component.- Returns:
- the value of the
streamsCallbackFailedrecord component
-
streamsIterationFailed
Returns the value of thestreamsIterationFailedrecord component.- Returns:
- the value of the
streamsIterationFailedrecord component
-
postTransactionOperationsRun
Returns the value of thepostTransactionOperationsRunrecord component.- Returns:
- the value of the
postTransactionOperationsRunrecord component
-
postTransactionOperationsFailed
Returns the value of thepostTransactionOperationsFailedrecord component.- Returns:
- the value of the
postTransactionOperationsFailedrecord component
-