jeanouii commented on code in PR #1275:
URL: https://github.com/apache/activemq/pull/1275#discussion_r1691475604
##########
activemq-jdbc-store/src/main/java/org/apache/activemq/store/jdbc/adapter/DefaultJDBCAdapter.java:
##########
@@ -586,12 +584,12 @@ public void doRecoverSubscription(TransactionContext c,
ActiveMQDestination dest
@Override
public void doRecoverNextMessages(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.getFindDurableSubMessagesStatement());
+ s =
c.getConnection().prepareStatement(this.limitQuery(this.statements.getFindDurableSubMessagesStatement()));
s.setMaxRows(Math.min(maxReturned * 2, maxRows));
Review Comment:
I'm not sure why there is "* 2" for the setMaxRows
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact