Interface Transaction


  • @Public
    @Evolving
    public interface Transaction
    The class represents a transaction within Pulsar.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.util.concurrent.CompletableFuture<java.lang.Void> abort()
      Abort the transaction.
      java.util.concurrent.CompletableFuture<java.lang.Void> commit()
      Commit the transaction.
      TxnID getTxnID()
      Get TxnID of the transaction.
    • Method Detail

      • commit

        java.util.concurrent.CompletableFuture<java.lang.Void> commit()
        Commit the transaction.
        Returns:
        the future represents the commit result.
      • abort

        java.util.concurrent.CompletableFuture<java.lang.Void> abort()
        Abort the transaction.
        Returns:
        the future represents the abort result.
      • getTxnID

        TxnID getTxnID()
        Get TxnID of the transaction.
        Returns:
        TxnID the txnID.