public class SessionFlushTimeoutEvent extends SessionEvent implements DurationAwareEvent
SessionFlushTimeoutEvent indicates that the current Persistence Context (EntityManager or Session)
has been flushed for more than the maximum allowed time threshold, which is given by the Config.Property.Session.FLUSH_TIMEOUT_MILLIS property value.
The more entities the current Persistence Context is managing, the longer it takes to process the dirty checking mechanism and synchronize the entity state changes with the database.
The flush execution time impacts the overall transaction response time,
so you need to make sure that the current JPA EntityManager or Hibernate Session
doesn't contain a very large number of entities.
Event.Priority| Constructor and Description |
|---|
SessionFlushTimeoutEvent(long flushTimeNanos)
Instantiate the event using the provided parameters.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getDescription()
|
long |
getDurationMillis()
Get the duration, in milliseconds, associated with this
Event. |
long |
getFlushTimeMillis()
Get the Hibernate
Session flush execution time in milliseconds. |
long |
getFlushTimeNanos()
Get the Hibernate
Session flush execution time in nanoseconds. |
Event.Priority |
getPriority()
Get the
Event.Priority of this Event |
getInfoUrlclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetInfoUrlpublic SessionFlushTimeoutEvent(long flushTimeNanos)
flushTimeNanos - session flush execution timepublic long getFlushTimeNanos()
Session flush execution time in nanoseconds.Session flush execution time in nanosecondspublic long getFlushTimeMillis()
Session flush execution time in milliseconds.Session flush execution time in millisecondspublic long getDurationMillis()
Event.getDurationMillis in interface DurationAwareEventEventpublic Event.Priority getPriority()
Event.Priority of this EventgetPriority in interface EventEvent.Priority of this Eventpublic String getDescription()
getDescription in interface EventString description of this EventCopyright © 2026. All rights reserved.