Package org.hibernate.stat.internal
Class StatisticsImpl
java.lang.Object
org.hibernate.stat.internal.StatisticsImpl
- All Implemented Interfaces:
Serializable,Service,StatisticsImplementor,Statistics
Implementation of
Statistics based on the java.util.concurrent package.- See Also:
-
Field Summary
Fields inherited from interface org.hibernate.stat.Statistics
DEFAULT_QUERY_STATISTICS_MAX_SIZE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()reset all statisticsvoidCallback about a session being closed.voidCallback about a statement being closed.voidcollectionCacheHit(NavigableRole collectionRole, String regionName) Callback indicating a get from second level cache resulted in a hit.voidcollectionCacheMiss(NavigableRole collectionRole, String regionName) Callback indicating a get from second level cache resulted in a miss.voidcollectionCachePut(NavigableRole collectionRole, String regionName) Callback indicating a put into second level cache.voidconnect()Callback about a connection being obtained fromConnectionProvidervoiddeleteEntity(String entityName) Callback about an entity being deleted.voidendTransaction(boolean success) Callback about a transaction completing.voidentityCacheHit(NavigableRole entityName, String regionName) Callback indicating a get from second level cache resulted in a hit.voidentityCacheMiss(NavigableRole entityName, String regionName) Callback indicating a get from second level cache resulted in a miss.voidentityCachePut(NavigableRole entityName, String regionName) Callback indicating a put into second level cache.voidentityCacheRemove(NavigableRole entityName, String regionName) Callback indicating a removal from second level cache.voidfetchCollection(String role) Callback to indicate a collection being fetched.voidfetchEntity(String entityName) Callback about an entity being fetched.voidflush()Callback about a flush occurring@Nullable CacheRegionStatisticsImplgetCacheRegionStatistics(String regionName) Obtain the statistics for either a domain data or query result cache region.longThe number of prepared statements that were released.longThe global number of collections fetched.longThe global number of collections loaded.longThe global number of collections recreatedlongThe global number of collections removed.String[]The names of all collection roles.Obtain the statistics for the collection with the given role.longThe global number of collections updated.longThe global number of connections requested by sessions.getDomainDataRegionStatistics(String regionName) Obtain the second-level cache statistics for the given cache region.longThe global number of entity deletes.longThe global number of entity fetches.longThe global number of entity inserts.longThe global number of entity loads.String[]The names of all entities.getEntityStatistics(String entityName) Obtain the statistics for the entity with the given name.longThe global number of entity updates.longThe global number of entity upserts.longThe global number of flush operations executed, including automatic (either manual or automatic).longThe global number of cached natural id lookups successfully retrieved from the cache.longThe global number of cached natural id lookups not found in the cache.longThe global number of cacheable natural id lookups put in cache.longThe global number of natural id queries executed against the database.longThe global maximum query time for natural id queries executed against the database.@Nullable StringThe entity name for the maximum natural id query time.@Nullable StringThe region for the maximum natural id query time.getNaturalIdStatistics(String rootEntityName) Obtain the natural id resolution statistics for the entity type with the given name.longThe number of HibernateStaleObjectStateExceptions or JPAOptimisticLockExceptions that have occurred.longThe number of prepared statements that were acquired.String[]All executed query strings.longThe global number of cached queries successfully retrieved from the cache.longThe global number of cached queries notnot found in the cache.longThe global number of cacheable queries put in cache.longThe global number of executed queries.longThe time in milliseconds of the slowest query.@Nullable StringThe query string for the slowest query.longThe global number of query plans successfully retrieved from cache.longThe global number of query plans lookups not found in cache.@Nullable CacheRegionStatisticsImplgetQueryRegionStatistics(String regionName) Obtain the second-level cache statistics for the given query cache region.getQueryStatistics(String queryString) Obtain the query statistics for the given query string.longThe global number of cacheable entities and collections successfully retrieved from the cache.longThe global number of cacheable entities collections not found in the cache and loaded from the database.longThe global number of cacheable entities and collections put in the cache.String[]All second-level cache region names.longThe global number of sessions closed.longThe global number of sessions opened.If "hibernate.log_slow_query" is enabled, a map from the SQL query to the maximum execution time in milliseconds.getStart()TheInstantat which this instance ofStatisticswas created, or since the last timeStatistics.clear()was called.longThe Instant.toEpochMilli() milliseconds since the initial creation of this instance, or since the last timeStatistics.clear()was called.longThe number of transactions we know to have been successful.longThe number of transactions we know to have completed.longThe global number of timestamps successfully retrieved from cache.longThe global number of timestamp requests that were not found in the cache.longThe global number of timestamps put in cache.voidinsertEntity(String entityName) Callback about an entity being insertedbooleanIs collection of statistics enabled?voidloadCollection(String role) Callback about a collection loading.voidloadEntity(String entityName) Callback about an entity being loaded.voidLog the main statistics at levelINFO.voidnaturalIdCacheHit(NavigableRole rootEntityName, String regionName) Callback indicating a get from natural id cache resulted in a hit.voidnaturalIdCacheMiss(NavigableRole rootEntityName, String regionName) Callback indicating a get from natural id cache resulted in a miss.voidnaturalIdCachePut(NavigableRole rootEntityName, String regionName) Callback indicating a put into natural id cache.voidnaturalIdQueryExecuted(String rootEntityName, long time) Callback indicating execution of a natural id queryvoidCallback about a session being opened.voidoptimisticFailure(String entityName) Callback about an optimistic lock failure on an entityvoidCallback about a statement being prepared.voidqueryCacheHit(String hql, String regionName) Callback indicating a get from the query cache resulted in a hit.voidqueryCacheMiss(String hql, String regionName) Callback indicating a get from the query cache resulted in a miss.voidqueryCachePut(String hql, String regionName) Callback indicating a put into the query cache.voidqueryCompiled(String hql, long microseconds) Callback indicating compilation of a sql/hql queryvoidqueryExecuted(String hql, int rows, long time) Callback indicating execution of a sql/hql queryvoidqueryPlanCacheHit(String query) Callback indicating a get from the query plan cache resulted in a hit.voidqueryPlanCacheMiss(String query) Callback indicating a get from the query plan cache resulted in a miss.voidrecreateCollection(String role) Callback indicating a collection recreation (full deletion + full (re-)insertion).voidremoveCollection(String role) Callback indicating a collection removal.voidsetStatisticsEnabled(boolean enabled) Enable or disable statistics collection.voidRegister the execution of a slow SQL query.toString()voidupdateCollection(String role) Callback indicating a collection was updated.voidupdateEntity(String entityName) Callback about an entity being updated.voidCallback indicating a hit to the timestamp cachevoidCallback indicating a miss to the timestamp cachevoidCallback indicating a put to the timestamp cachevoidupsertEntity(String entityName) Callback about an entity being upserted.
-
Constructor Details
-
StatisticsImpl
-
-
Method Details
-
clear
public void clear()reset all statistics- Specified by:
clearin interfaceStatistics
-
getStart
Description copied from interface:StatisticsTheInstantat which this instance ofStatisticswas created, or since the last timeStatistics.clear()was called.- Specified by:
getStartin interfaceStatistics
-
getStartTime
public long getStartTime()Description copied from interface:StatisticsThe Instant.toEpochMilli() milliseconds since the initial creation of this instance, or since the last timeStatistics.clear()was called.- Specified by:
getStartTimein interfaceStatistics
-
isStatisticsEnabled
public boolean isStatisticsEnabled()Description copied from interface:StatisticsIs collection of statistics enabled?- Specified by:
isStatisticsEnabledin interfaceStatistics
-
setStatisticsEnabled
public void setStatisticsEnabled(boolean enabled) Description copied from interface:StatisticsEnable or disable statistics collection.- Specified by:
setStatisticsEnabledin interfaceStatistics
-
getEntityNames
Description copied from interface:StatisticsThe names of all entities.- Specified by:
getEntityNamesin interfaceStatistics
-
getEntityStatistics
Description copied from interface:StatisticsObtain the statistics for the entity with the given name.- Specified by:
getEntityStatisticsin interfaceStatistics- Parameters:
entityName- the entity name
-
getEntityLoadCount
public long getEntityLoadCount()Description copied from interface:StatisticsThe global number of entity loads.- Specified by:
getEntityLoadCountin interfaceStatistics
-
getEntityFetchCount
public long getEntityFetchCount()Description copied from interface:StatisticsThe global number of entity fetches.- Specified by:
getEntityFetchCountin interfaceStatistics
-
getEntityDeleteCount
public long getEntityDeleteCount()Description copied from interface:StatisticsThe global number of entity deletes.- Specified by:
getEntityDeleteCountin interfaceStatistics
-
getEntityInsertCount
public long getEntityInsertCount()Description copied from interface:StatisticsThe global number of entity inserts.- Specified by:
getEntityInsertCountin interfaceStatistics
-
getEntityUpdateCount
public long getEntityUpdateCount()Description copied from interface:StatisticsThe global number of entity updates.- Specified by:
getEntityUpdateCountin interfaceStatistics
-
getEntityUpsertCount
public long getEntityUpsertCount()Description copied from interface:StatisticsThe global number of entity upserts.- Specified by:
getEntityUpsertCountin interfaceStatistics
-
getOptimisticFailureCount
public long getOptimisticFailureCount()Description copied from interface:StatisticsThe number of HibernateStaleObjectStateExceptions or JPAOptimisticLockExceptions that have occurred.- Specified by:
getOptimisticFailureCountin interfaceStatistics
-
loadEntity
Description copied from interface:StatisticsImplementorCallback about an entity being loaded. This might indicate a proxy or a fully initialized entity, but in either case it means without a separate SQL query being needed.- Specified by:
loadEntityin interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity loaded.
-
fetchEntity
Description copied from interface:StatisticsImplementorCallback about an entity being fetched. UnlikeStatisticsImplementor.loadEntity(java.lang.String)this indicates a separate query being performed.- Specified by:
fetchEntityin interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity fetched.
-
updateEntity
Description copied from interface:StatisticsImplementorCallback about an entity being updated.- Specified by:
updateEntityin interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity updated.
-
upsertEntity
Description copied from interface:StatisticsImplementorCallback about an entity being upserted.- Specified by:
upsertEntityin interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity upserted.
-
insertEntity
Description copied from interface:StatisticsImplementorCallback about an entity being inserted- Specified by:
insertEntityin interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity inserted
-
deleteEntity
Description copied from interface:StatisticsImplementorCallback about an entity being deleted.- Specified by:
deleteEntityin interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity deleted.
-
optimisticFailure
Description copied from interface:StatisticsImplementorCallback about an optimistic lock failure on an entity- Specified by:
optimisticFailurein interfaceStatisticsImplementor- Parameters:
entityName- The name of the entity.
-
getCollectionRoleNames
Description copied from interface:StatisticsThe names of all collection roles.- Specified by:
getCollectionRoleNamesin interfaceStatistics
-
getCollectionStatistics
Description copied from interface:StatisticsObtain the statistics for the collection with the given role.- Specified by:
getCollectionStatisticsin interfaceStatistics- Parameters:
role- the collection role
-
getCollectionLoadCount
public long getCollectionLoadCount()Description copied from interface:StatisticsThe global number of collections loaded.- Specified by:
getCollectionLoadCountin interfaceStatistics
-
getCollectionFetchCount
public long getCollectionFetchCount()Description copied from interface:StatisticsThe global number of collections fetched.- Specified by:
getCollectionFetchCountin interfaceStatistics
-
getCollectionUpdateCount
public long getCollectionUpdateCount()Description copied from interface:StatisticsThe global number of collections updated.- Specified by:
getCollectionUpdateCountin interfaceStatistics
-
getCollectionRemoveCount
public long getCollectionRemoveCount()Description copied from interface:StatisticsThe global number of collections removed.- Specified by:
getCollectionRemoveCountin interfaceStatistics
-
getCollectionRecreateCount
public long getCollectionRecreateCount()Description copied from interface:StatisticsThe global number of collections recreated- Specified by:
getCollectionRecreateCountin interfaceStatistics
-
loadCollection
Description copied from interface:StatisticsImplementorCallback about a collection loading. This might indicate a lazy collection or an initialized collection being created, but in either case it means without a separate SQL query being needed.- Specified by:
loadCollectionin interfaceStatisticsImplementor- Parameters:
role- The collection role.
-
fetchCollection
Description copied from interface:StatisticsImplementorCallback to indicate a collection being fetched. UnlikeStatisticsImplementor.loadCollection(java.lang.String), this indicates a separate query was needed.- Specified by:
fetchCollectionin interfaceStatisticsImplementor- Parameters:
role- The collection role.
-
updateCollection
Description copied from interface:StatisticsImplementorCallback indicating a collection was updated.- Specified by:
updateCollectionin interfaceStatisticsImplementor- Parameters:
role- The collection role.
-
recreateCollection
Description copied from interface:StatisticsImplementorCallback indicating a collection recreation (full deletion + full (re-)insertion).- Specified by:
recreateCollectionin interfaceStatisticsImplementor- Parameters:
role- The collection role.
-
removeCollection
Description copied from interface:StatisticsImplementorCallback indicating a collection removal.- Specified by:
removeCollectionin interfaceStatisticsImplementor- Parameters:
role- The collection role.
-
getNaturalIdStatistics
Description copied from interface:StatisticsObtain the natural id resolution statistics for the entity type with the given name.- Specified by:
getNaturalIdStatisticsin interfaceStatistics- Parameters:
rootEntityName- The entity name that is the root of the hierarchy containing the natural id
-
getNaturalIdQueryExecutionCount
public long getNaturalIdQueryExecutionCount()Description copied from interface:StatisticsThe global number of natural id queries executed against the database.- Specified by:
getNaturalIdQueryExecutionCountin interfaceStatistics
-
getNaturalIdQueryExecutionMaxTime
public long getNaturalIdQueryExecutionMaxTime()Description copied from interface:StatisticsThe global maximum query time for natural id queries executed against the database.- Specified by:
getNaturalIdQueryExecutionMaxTimein interfaceStatistics
-
getNaturalIdQueryExecutionMaxTimeRegion
Description copied from interface:StatisticsThe region for the maximum natural id query time.- Specified by:
getNaturalIdQueryExecutionMaxTimeRegionin interfaceStatistics
-
getNaturalIdQueryExecutionMaxTimeEntity
Description copied from interface:StatisticsThe entity name for the maximum natural id query time.- Specified by:
getNaturalIdQueryExecutionMaxTimeEntityin interfaceStatistics
-
getNaturalIdCacheHitCount
public long getNaturalIdCacheHitCount()Description copied from interface:StatisticsThe global number of cached natural id lookups successfully retrieved from the cache.- Specified by:
getNaturalIdCacheHitCountin interfaceStatistics
-
getNaturalIdCacheMissCount
public long getNaturalIdCacheMissCount()Description copied from interface:StatisticsThe global number of cached natural id lookups not found in the cache.- Specified by:
getNaturalIdCacheMissCountin interfaceStatistics
-
getNaturalIdCachePutCount
public long getNaturalIdCachePutCount()Description copied from interface:StatisticsThe global number of cacheable natural id lookups put in cache.- Specified by:
getNaturalIdCachePutCountin interfaceStatistics
-
naturalIdQueryExecuted
Description copied from interface:StatisticsImplementorCallback indicating execution of a natural id query- Specified by:
naturalIdQueryExecutedin interfaceStatisticsImplementor
-
getSecondLevelCacheRegionNames
Description copied from interface:StatisticsAll second-level cache region names. For backwards compatibility, this method returns just the names of regions storing domain data, not query result cache regions.- Specified by:
getSecondLevelCacheRegionNamesin interfaceStatistics
-
getDomainDataRegionStatistics
Description copied from interface:StatisticsObtain the second-level cache statistics for the given cache region.- Specified by:
getDomainDataRegionStatisticsin interfaceStatistics- Parameters:
regionName- The unqualified region name- Returns:
- the statistics for the named region, or
nullif the second-level cache is not enabled
-
getQueryRegionStatistics
Description copied from interface:StatisticsObtain the second-level cache statistics for the given query cache region.- Specified by:
getQueryRegionStatisticsin interfaceStatistics- Parameters:
regionName- The unqualified region name- Returns:
- the statistics for the named region, or
nullif either query result caching is not enabled, or no query cache region exists with the given name
-
getCacheRegionStatistics
Description copied from interface:StatisticsObtain the statistics for either a domain data or query result cache region.This method checks both, preferring the domain data region if there is one. Think of it as a cascading check to:
Note that null is returned instead of throwing an exception when no region exists with the given name.- Specified by:
getCacheRegionStatisticsin interfaceStatistics- Parameters:
regionName- The unqualified region name- Returns:
- the statistics for the named region, or
nullif there is no region with the given name
-
getSecondLevelCacheHitCount
public long getSecondLevelCacheHitCount()Description copied from interface:StatisticsThe global number of cacheable entities and collections successfully retrieved from the cache.- Specified by:
getSecondLevelCacheHitCountin interfaceStatistics
-
getSecondLevelCacheMissCount
public long getSecondLevelCacheMissCount()Description copied from interface:StatisticsThe global number of cacheable entities collections not found in the cache and loaded from the database.- Specified by:
getSecondLevelCacheMissCountin interfaceStatistics
-
getSecondLevelCachePutCount
public long getSecondLevelCachePutCount()Description copied from interface:StatisticsThe global number of cacheable entities and collections put in the cache.- Specified by:
getSecondLevelCachePutCountin interfaceStatistics
-
getUpdateTimestampsCacheHitCount
public long getUpdateTimestampsCacheHitCount()Description copied from interface:StatisticsThe global number of timestamps successfully retrieved from cache.- Specified by:
getUpdateTimestampsCacheHitCountin interfaceStatistics
-
getUpdateTimestampsCacheMissCount
public long getUpdateTimestampsCacheMissCount()Description copied from interface:StatisticsThe global number of timestamp requests that were not found in the cache.- Specified by:
getUpdateTimestampsCacheMissCountin interfaceStatistics
-
getUpdateTimestampsCachePutCount
public long getUpdateTimestampsCachePutCount()Description copied from interface:StatisticsThe global number of timestamps put in cache.- Specified by:
getUpdateTimestampsCachePutCountin interfaceStatistics
-
updateTimestampsCacheHit
public void updateTimestampsCacheHit()Description copied from interface:StatisticsImplementorCallback indicating a hit to the timestamp cache- Specified by:
updateTimestampsCacheHitin interfaceStatisticsImplementor
-
updateTimestampsCacheMiss
public void updateTimestampsCacheMiss()Description copied from interface:StatisticsImplementorCallback indicating a miss to the timestamp cache- Specified by:
updateTimestampsCacheMissin interfaceStatisticsImplementor
-
updateTimestampsCachePut
public void updateTimestampsCachePut()Description copied from interface:StatisticsImplementorCallback indicating a put to the timestamp cache- Specified by:
updateTimestampsCachePutin interfaceStatisticsImplementor
-
getQueries
Description copied from interface:StatisticsAll executed query strings.The maximum number of queries tracked by the Hibernate statistics is determined by the configuration property "hibernate.statistics.query_max_size".
- Specified by:
getQueriesin interfaceStatistics- See Also:
-
getQueryStatistics
Description copied from interface:StatisticsObtain the query statistics for the given query string.- Specified by:
getQueryStatisticsin interfaceStatistics- Parameters:
queryString- the query string, written in HQL or SQL
-
getQueryExecutionCount
public long getQueryExecutionCount()Description copied from interface:StatisticsThe global number of executed queries.- Specified by:
getQueryExecutionCountin interfaceStatistics
-
getQueryCacheHitCount
public long getQueryCacheHitCount()Description copied from interface:StatisticsThe global number of cached queries successfully retrieved from the cache.- Specified by:
getQueryCacheHitCountin interfaceStatistics
-
getQueryCacheMissCount
public long getQueryCacheMissCount()Description copied from interface:StatisticsThe global number of cached queries notnot found in the cache.- Specified by:
getQueryCacheMissCountin interfaceStatistics
-
getQueryCachePutCount
public long getQueryCachePutCount()Description copied from interface:StatisticsThe global number of cacheable queries put in cache.- Specified by:
getQueryCachePutCountin interfaceStatistics
-
getQueryExecutionMaxTimeQueryString
Description copied from interface:StatisticsThe query string for the slowest query.- Specified by:
getQueryExecutionMaxTimeQueryStringin interfaceStatistics
-
getQueryExecutionMaxTime
public long getQueryExecutionMaxTime()Description copied from interface:StatisticsThe time in milliseconds of the slowest query.- Specified by:
getQueryExecutionMaxTimein interfaceStatistics
-
queryExecuted
Description copied from interface:StatisticsImplementorCallback indicating execution of a sql/hql query- Specified by:
queryExecutedin interfaceStatisticsImplementor- Parameters:
hql- The queryrows- Number of rows returnedtime- execution time
-
queryCacheHit
Description copied from interface:StatisticsImplementorCallback indicating a get from the query cache resulted in a hit.- Specified by:
queryCacheHitin interfaceStatisticsImplementor- Parameters:
hql- The queryregionName- The name of the cache region
-
queryCacheMiss
Description copied from interface:StatisticsImplementorCallback indicating a get from the query cache resulted in a miss.- Specified by:
queryCacheMissin interfaceStatisticsImplementor- Parameters:
hql- The queryregionName- The name of the cache region
-
queryCachePut
Description copied from interface:StatisticsImplementorCallback indicating a put into the query cache.- Specified by:
queryCachePutin interfaceStatisticsImplementor- Parameters:
hql- The queryregionName- The cache region
-
getQueryPlanCacheHitCount
public long getQueryPlanCacheHitCount()Description copied from interface:StatisticsThe global number of query plans successfully retrieved from cache.- Specified by:
getQueryPlanCacheHitCountin interfaceStatistics
-
getQueryPlanCacheMissCount
public long getQueryPlanCacheMissCount()Description copied from interface:StatisticsThe global number of query plans lookups not found in cache.- Specified by:
getQueryPlanCacheMissCountin interfaceStatistics
-
queryCompiled
Description copied from interface:StatisticsImplementorCallback indicating compilation of a sql/hql query- Specified by:
queryCompiledin interfaceStatisticsImplementor- Parameters:
hql- The querymicroseconds- execution time
-
queryPlanCacheHit
Description copied from interface:StatisticsImplementorCallback indicating a get from the query plan cache resulted in a hit.- Specified by:
queryPlanCacheHitin interfaceStatisticsImplementor- Parameters:
query- The query
-
queryPlanCacheMiss
Description copied from interface:StatisticsImplementorCallback indicating a get from the query plan cache resulted in a miss.- Specified by:
queryPlanCacheMissin interfaceStatisticsImplementor- Parameters:
query- The query
-
getSessionOpenCount
public long getSessionOpenCount()Description copied from interface:StatisticsThe global number of sessions opened.- Specified by:
getSessionOpenCountin interfaceStatistics
-
getSessionCloseCount
public long getSessionCloseCount()Description copied from interface:StatisticsThe global number of sessions closed.- Specified by:
getSessionCloseCountin interfaceStatistics
-
getFlushCount
public long getFlushCount()Description copied from interface:StatisticsThe global number of flush operations executed, including automatic (either manual or automatic).- Specified by:
getFlushCountin interfaceStatistics
-
getConnectCount
public long getConnectCount()Description copied from interface:StatisticsThe global number of connections requested by sessions.The actual number of connections used may be much smaller, assuming that a connection pool is in use.
- Specified by:
getConnectCountin interfaceStatistics
-
getSuccessfulTransactionCount
public long getSuccessfulTransactionCount()Description copied from interface:StatisticsThe number of transactions we know to have been successful.- Specified by:
getSuccessfulTransactionCountin interfaceStatistics
-
getTransactionCount
public long getTransactionCount()Description copied from interface:StatisticsThe number of transactions we know to have completed.- Specified by:
getTransactionCountin interfaceStatistics
-
getCloseStatementCount
public long getCloseStatementCount()Description copied from interface:StatisticsThe number of prepared statements that were released.- Specified by:
getCloseStatementCountin interfaceStatistics
-
getPrepareStatementCount
public long getPrepareStatementCount()Description copied from interface:StatisticsThe number of prepared statements that were acquired.- Specified by:
getPrepareStatementCountin interfaceStatistics
-
openSession
public void openSession()Description copied from interface:StatisticsImplementorCallback about a session being opened.- Specified by:
openSessionin interfaceStatisticsImplementor
-
closeSession
public void closeSession()Description copied from interface:StatisticsImplementorCallback about a session being closed.- Specified by:
closeSessionin interfaceStatisticsImplementor
-
flush
public void flush()Description copied from interface:StatisticsImplementorCallback about a flush occurring- Specified by:
flushin interfaceStatisticsImplementor
-
connect
public void connect()Description copied from interface:StatisticsImplementorCallback about a connection being obtained fromConnectionProvider- Specified by:
connectin interfaceStatisticsImplementor
-
prepareStatement
public void prepareStatement()Description copied from interface:StatisticsImplementorCallback about a statement being prepared.- Specified by:
prepareStatementin interfaceStatisticsImplementor
-
closeStatement
public void closeStatement()Description copied from interface:StatisticsImplementorCallback about a statement being closed.- Specified by:
closeStatementin interfaceStatisticsImplementor
-
endTransaction
public void endTransaction(boolean success) Description copied from interface:StatisticsImplementorCallback about a transaction completing.- Specified by:
endTransactionin interfaceStatisticsImplementor- Parameters:
success- Was the transaction successful?
-
logSummary
public void logSummary()Description copied from interface:StatisticsLog the main statistics at levelINFO.- Specified by:
logSummaryin interfaceStatistics
-
toString
-
getSlowQueries
Description copied from interface:StatisticsIf "hibernate.log_slow_query" is enabled, a map from the SQL query to the maximum execution time in milliseconds.- Specified by:
getSlowQueriesin interfaceStatistics- Specified by:
getSlowQueriesin interfaceStatisticsImplementor- See Also:
-
slowQuery
Description copied from interface:StatisticsImplementorRegister the execution of a slow SQL query.- Specified by:
slowQueryin interfaceStatisticsImplementor
-