kenliao94 commented on code in PR #1275: URL: https://github.com/apache/activemq/pull/1275#discussion_r1865248949
########## activemq-jdbc-store/src/main/java/org/apache/activemq/store/jdbc/adapter/DefaultJDBCAdapter.java: ########## @@ -620,12 +618,12 @@ public void doRecoverNextMessages(TransactionContext c, ActiveMQDestination dest @Override public void doRecoverNextMessagesWithPriority(TransactionContext c, ActiveMQDestination destination, String clientId, - String subscriptionName, long seq, long priority, int maxReturned, JDBCMessageRecoveryListener listener) throws Exception { + String subscriptionName, long seq, long priority, int maxReturned, JDBCMessageRecoveryListener listener) throws Exception { PreparedStatement s = null; ResultSet rs = null; try { - s = c.getConnection().prepareStatement(this.statements.getFindDurableSubMessagesByPriorityStatement()); + s = c.getConnection().prepareStatement(this.limitQuery(this.statements.getFindDurableSubMessagesByPriorityStatement())); s.setMaxRows(Math.min(maxReturned * 2, maxRows)); Review Comment: Sorry, not following this logic here. Isn't this.limitQuery a no-ops? It just returns the original query (line 1188) -- 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