Uploaded image for project: 'Activation'
  1. Activation
  2. MGNLACTIVATION-82

ActivationCommand handling of version RepositoryException is not complete

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 5.2.4
    • 5.2.2

      Line 100-107:

       if (StringUtils.isNotEmpty(getVersion())) {
                  try {
                      thisState = thisState.getVersionedContent(getVersion());
                  } catch (RepositoryException re) {
                      // TODO: is this correct? should not we fail completely rather then silently ignore versions?
                      log.error("Failed to get version " + getVersion() + " for " + thisState.getHandle() + ". Activating current content instead.", re);
                  }
              }
      

      ActivationCommand.activateUpdate has a todo in it:

      // TODO: is this correct? should not we fail completely rather then silently ignore versions?

      The RepositoryException is logged but ultimately ignored and the previous version activated, without any notification to the end users.

      The method should, at least, return a false for the success of the action.

        Acceptance criteria

              jsimak Jaroslav Simak
              dean.pullen Dean Pullen
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Bug DoR
                  Task DoD