Interface CommitResult

All Known Subinterfaces:
CompletableCommitResult

public interface CommitResult
This interface represents results of potentially asynchronous commit action. When commit is successful the result will be always same, commit completed.

But when commit cannot be completed, has partial failures, an operator implementation should return which exactly data was affected so those can be handled, sent to DLQ or logged.

  • Field Details

  • Method Details

    • fromException

      static CommitResult fromException(Throwable e)
    • isDone

      boolean isDone()
      Returns:
      true when commit action has been done
    • isAsync

      boolean isAsync()
    • getCause

      Throwable getCause()
      Returns:
      null or real cause of failure
    • getAffectedMessages

      List<?> getAffectedMessages()
      Returns:
      data associated with failure
    • handleAsynchronously

      default void handleAsynchronously(CommitResult.AsynchronousResultHandler handler)