Interface TxnHandler

All Known Implementing Classes:
TxnHandlerImpl

public interface TxnHandler
Callbacks for reacting to events during the life cycle management of transactions. The most relevant callback is beforeUnlock(Path, boolean): At this point resources have been written and are in their final location but the lock is still held. This allows one to e.g. safely read the last modified timestamp of a just committed file before another transaction can modify it again.
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    afterPreCommit(org.aksw.commons.path.core.Path<String> resKey)
     
    default void
    beforePreCommit(org.aksw.commons.path.core.Path<String> resKey)
     
    default void
    beforeUnlock(org.aksw.commons.path.core.Path<String> resKey, boolean isCommit)
     
    default void
    end()
     
  • Method Details

    • beforePreCommit

      default void beforePreCommit(org.aksw.commons.path.core.Path<String> resKey) throws Exception
      Throws:
      Exception
    • afterPreCommit

      default void afterPreCommit(org.aksw.commons.path.core.Path<String> resKey) throws Exception
      Throws:
      Exception
    • beforeUnlock

      default void beforeUnlock(org.aksw.commons.path.core.Path<String> resKey, boolean isCommit) throws Exception
      Throws:
      Exception
    • end

      default void end()