-
public interface SavepointListener
Interface for a listener to be notified of the start and pre-commit, commit, or abort of savepoints. To receive such notifications, implement this interface, with the methods that will be called in the cases of interest, and pass an instance toSession.addSavepointListener(org.postgresql.pljava.SavepointListener)
. The default implementations of these methods do nothing.It is possible for a listener method to be called with savepoint null, or parent null, or both; that can happen if the application code has not kept a strong reference to the
Savepoint
object in question.SavepointListener
exposes a PostgreSQL-specific function that is more internal than the documented SPI.- Author:
- Thomas Hallgren
-
-
Method Summary
Modifier and Type Method Description default void
onAbort(Session session, Savepoint savepoint, Savepoint parent)
default void
onCommit(Session session, Savepoint savepoint, Savepoint parent)
default void
onPreCommit(Session session, Savepoint savepoint, Savepoint parent)
default void
onStart(Session session, Savepoint savepoint, Savepoint parent)
-
-
-
Method Detail
-
onAbort
default void onAbort(Session session, Savepoint savepoint, Savepoint parent) throws SQLException
- Throws:
SQLException
-
onCommit
default void onCommit(Session session, Savepoint savepoint, Savepoint parent) throws SQLException
- Throws:
SQLException
-
onStart
default void onStart(Session session, Savepoint savepoint, Savepoint parent) throws SQLException
- Throws:
SQLException
-
onPreCommit
default void onPreCommit(Session session, Savepoint savepoint, Savepoint parent) throws SQLException
- Throws:
SQLException
-
-