Class GlobalTransaction

java.lang.Object
org.infinispan.transaction.xa.GlobalTransaction
All Implemented Interfaces:
Cloneable

@ProtoTypeId(1084) public class GlobalTransaction extends Object implements Cloneable
Uniquely identifies a transaction that spans all JVMs in a cluster. This is used when replicating all modifications in a transaction; the PREPARE and COMMIT (or ROLLBACK) messages have to have a unique identifier to associate the changes with
. GlobalTransaction should be instantiated thorough TransactionFactory class, as their type depends on the runtime configuration.
Since:
4.0
Author:
Bela Ban Apr 12, 2003, Manik Surtani (manik@jboss.org), Mircea.Markus@jboss.com
  • Constructor Details

    • GlobalTransaction

      public GlobalTransaction(Address addr, boolean remote)
    • GlobalTransaction

      public GlobalTransaction(Address addr, boolean remote, boolean clientTx)
  • Method Details

    • getAddress

      public Address getAddress()
    • getId

      public long getId()
    • getRequestUUID

      @ProtoField(1) public RequestUUID getRequestUUID()
    • getXid

      @ProtoField(2) public XidImpl getXid()
    • getInternalId

      @ProtoField(3) public long getInternalId()
    • isClientTransaction

      @ProtoField(4) public boolean isClientTransaction()
    • isRemote

      public boolean isRemote()
    • setRemote

      public void setRemote(boolean remote)
    • changeAddress

      public GlobalTransaction changeAddress(Address address)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object other)
      Overrides:
      equals in class Object
    • globalId

      public final String globalId()
      Returns a simplified representation of the transaction.
    • setXid

      public void setXid(Xid xid)
    • setInternalId

      public void setInternalId(long internalId)
    • clone

      public Object clone()
      Overrides:
      clone in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object