mattrpav commented on code in PR #1377:
URL: https://github.com/apache/activemq/pull/1377#discussion_r1931182555


##########
activemq-console/src/main/java/org/apache/activemq/console/command/store/StoreBackup.java:
##########
@@ -178,7 +194,19 @@ public boolean recoverMessage(Message message) throws 
IOException {
                         return true;
                     }
                 };
-                if(offset != null) {
+                if(startMsgId != null || endMsgId != null) {
+                    System.out.println("Backing up from startMsgId: " + 
startMsgId + " to endMsgId: " + endMsgId);
+                    queue.recoverNextMessages(startMsgId, endMsgId, (count != 
null ? count : Integer.MAX_VALUE), queueRecoveryListener, true);
+                } else if(indexesList != null) {
+                    System.out.println("Backing up using indexes count: " + 
indexesList.size());
+                    for(int idx : indexesList) {
+                        if(idx < 0) {

Review Comment:
   The cause would be bad user input. I'm good with making the change to throw 
exception.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscr...@activemq.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@activemq.apache.org
For additional commands, e-mail: gitbox-h...@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact


Reply via email to