Class BackupSenderImpl

  • All Implemented Interfaces:
    BackupSender

    public class BackupSenderImpl
    extends java.lang.Object
    implements BackupSender
    Since:
    5.2
    Author:
    Mircea Markus
    • Constructor Detail

      • BackupSenderImpl

        public BackupSenderImpl​(java.lang.String localSiteName)
    • Method Detail

      • start

        public void start()
      • backupPrepare

        public BackupResponse backupPrepare​(org.infinispan.commands.tx.PrepareCommand command,
                                            org.infinispan.transaction.impl.AbstractCacheTransaction cacheTransaction)
                                     throws java.lang.Exception
        Description copied from interface: BackupSender
        Prepares a transaction on the remote site.
        Specified by:
        backupPrepare in interface BackupSender
        Throws:
        java.lang.Exception
      • processResponses

        public void processResponses​(BackupResponse backupResponse,
                                     org.infinispan.commands.VisitableCommand command)
                              throws java.lang.Throwable
        Description copied from interface: BackupSender
        Processes the responses of a backup command. It might throw an exception in the case the replication to the remote site fail, based on the configured CustomFailurePolicy.
        Specified by:
        processResponses in interface BackupSender
        Throws:
        java.lang.Throwable
      • processResponses

        public void processResponses​(BackupResponse backupResponse,
                                     org.infinispan.commands.VisitableCommand command,
                                     javax.transaction.Transaction transaction)
                              throws java.lang.Throwable
        Specified by:
        processResponses in interface BackupSender
        Throws:
        java.lang.Throwable
      • backupWrite

        public BackupResponse backupWrite​(org.infinispan.commands.write.WriteCommand command)
                                   throws java.lang.Exception
        Specified by:
        backupWrite in interface BackupSender
        Throws:
        java.lang.Exception
      • backupCommit

        public BackupResponse backupCommit​(org.infinispan.commands.tx.CommitCommand command)
                                    throws java.lang.Exception
        Specified by:
        backupCommit in interface BackupSender
        Throws:
        java.lang.Exception
      • backupRollback

        public BackupResponse backupRollback​(org.infinispan.commands.tx.RollbackCommand command)
                                      throws java.lang.Exception
        Specified by:
        backupRollback in interface BackupSender
        Throws:
        java.lang.Exception
      • status

        public java.util.Map<java.lang.String,​java.lang.Boolean> status()
        Description copied from interface: BackupSender
        Returns a Map having as entries the site names and as value Boolean.TRUE if the site is online and Boolean.FALSE if it is offline.
        Specified by:
        status in interface BackupSender