Class TransactionSaver


  • public class TransactionSaver
    extends Object
    Transaction cache Huge command are not cached, cache is limited to configuration transactionReplaySize commands
    • Constructor Detail

      • TransactionSaver

        public TransactionSaver​(int transactionReplaySize)
        Constructor
        Parameters:
        transactionReplaySize - maximum number of command cached
    • Method Detail

      • add

        public void add​(RedoableClientMessage clientMessage)
        Add a command to cache.
        Parameters:
        clientMessage - client message
      • clear

        public void clear()
        Transaction finished, clearing cache
      • getIdx

        public int getIdx()
        Current transaction cache length
        Returns:
        cache length
      • isDirty

        public boolean isDirty()
        Is cache not valid (some commands have not been cached)
        Returns:
        is dirty