Interface RollbackCallable

  • All Superinterfaces:
    Function<List<com.google.common.util.concurrent.ListenableFuture<Void>>,​List<com.google.common.util.concurrent.ListenableFuture<Void>>>

    public interface RollbackCallable
    extends Function<List<com.google.common.util.concurrent.ListenableFuture<Void>>,​List<com.google.common.util.concurrent.ListenableFuture<Void>>>
    A callable which runs in case a job task fails. It consumes the futures that were returned by the last failing job, and returns the futures corresponding to the corrective transactions.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      List<com.google.common.util.concurrent.ListenableFuture<Void>> apply​(List<com.google.common.util.concurrent.ListenableFuture<Void>> failedFutures)
      Roll back the transaction which led to the provided failed futures (futures resulting from the failed operation — the futures themselves aren't necessarily failed).
    • Method Detail

      • apply

        List<com.google.common.util.concurrent.ListenableFuture<Void>> apply​(List<com.google.common.util.concurrent.ListenableFuture<Void>> failedFutures)
        Roll back the transaction which led to the provided failed futures (futures resulting from the failed operation — the futures themselves aren't necessarily failed).
        Specified by:
        apply in interface Function<List<com.google.common.util.concurrent.ListenableFuture<Void>>,​List<com.google.common.util.concurrent.ListenableFuture<Void>>>
        Parameters:
        failedFutures - The futures from the failed job.
        Returns:
        The corrective roll back's resulting futures.