Package oracle.jdbc.replay
Interface ReplayableConnection
public interface ReplayableConnection
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumStatistics report type. -
Method Summary
Modifier and TypeMethodDescriptionvoidDeclares that a request to the server is starting on this connection.voidClears replay statistics accumulated so far.voidAllows disabling replay at runtime on a per-connection basis.voidDeclares that the request that was in progress on this connection has completed.Obtains replay statistics accumulated so far.
-
Method Details
-
beginRequest
Declares that a request to the server is starting on this connection. When called after another beginRequest() but before an endRequest(), this call is a no-op and does not throw any exception. Therefore, application is allowed to call beginRequest after a connection pool checkout, which implicitly calls beginRequest.- Throws:
SQLException- When called with an open transaction on this connection.
-
endRequest
Declares that the request that was in progress on this connection has completed. Existing connection labels and state on the connection are not affected by this call. Calling endRequest() multiple times without beginRequest() in-between is allowed.- Throws:
SQLException- When called with an open transaction on this connection.
-
disableReplay
Allows disabling replay at runtime on a per-connection basis. This does not affect replay that is already in-progress.- Throws:
SQLException
-
getReplayStatistics
Obtains replay statistics accumulated so far. These reflect either replay actions on the current connection, or across all the connections created by the underlying data source. When the argument value is false, it is recommended that the call be made when there are few new connections opened.- Parameters:
reportType- The type of statistics report.- Returns:
- A replay statistics object containing all the metrics.
- See Also:
-
ReplayStatistics#StatisticsReportTypeOracleDataSource.getReplayStatistics()
-
clearReplayStatistics
Clears replay statistics accumulated so far. This can be done on a per-connection basis, or applied to all connections. Future statistics reporting only reflects statistics updates accumulated after the latest clearing.- Parameters:
reportType- The type of statistics report.- See Also:
-
ReplayStatistics#StatisticsReportTypeReplayStatistics#getReplayStatistics()
-