Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-4909

(7.0.z) max-saved-replicated-journal-size is ignored

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • 7.0.2.CR1, 7.0.2.GA
    • 7.0.1.CR1
    • ActiveMQ
    • None
    • EAP 7.0.2

      Scenario:

      1. Configure two EAP servers in replicated HA topology
      2. On backup set max-saved-replicated-journal-size=2, allow-failback=true and restart-backup=true
      3. Do sequence: kill live, start live, kill live, start live...

      Expectation: When number of saved replicated journals exceeds 2, the backup should not be restarted but stopped.

      Actual state: max-saved-replicated-journal-size is ignored and backup is not stopped. Number of journals grows ad infinitum.

      I think that root cause is in SharedNothingLiveActivation. In the condition [1] there should be OR between !isRestartBackup and check if the number of journals was exceeded.

      [1]

      //if we have to many backups kept or are not configured to restart just stop, otherwise restart as a backup
      if (!replicatedPolicy.getReplicaPolicy().isRestartBackup() && activeMQServer.countNumberOfCopiedJournals() >= replicatedPolicy.getReplicaPolicy().getMaxSavedReplicatedJournalsSize() && replicatedPolicy.getReplicaPolicy().getMaxSavedReplicatedJournalsSize() >= 0) {
          activeMQServer.stop(true);
          ActiveMQServerLogger.LOGGER.stopReplicatedBackupAfterFailback();
      }
      else {
          activeMQServer.stop(true);
          ActiveMQServerLogger.LOGGER.restartingReplicatedBackupAfterFailback();
          activeMQServer.setHAPolicy(replicatedPolicy.getReplicaPolicy());
          activeMQServer.start();
      }
      

              csuconic@redhat.com Clebert Suconic
              eduda_jira Erich Duda (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Created:
                Updated:
                Resolved: