boglesby commented on a change in pull request #6663:
URL: https://github.com/apache/geode/pull/6663#discussion_r687265396
##########
File path:
geode-core/src/main/java/org/apache/geode/internal/cache/wan/parallel/ParallelGatewaySenderQueue.java
##########
@@ -1404,13 +1404,19 @@ void
peekEventsFromIncompleteTransactions(List<GatewaySenderEventImpl> batch,
}
}
if (incompleteTransactionIdsInBatch.size() == 0 ||
- retries++ == GET_TRANSACTION_EVENTS_FROM_QUEUE_RETRIES) {
+ retries >= sender.getRetriesToGetTransactionEventsFromQueue()) {
break;
}
+ retries++;
Review comment:
GET_TRANSACTION_EVENTS_FROM_QUEUE_WAIT_TIME_MS is 1ms by default.
GET_TRANSACTION_EVENTS_FROM_QUEUE_RETRIES is 3 by default.
So, thats 3 ms of retries by default. As Gester said, I'm not sure thats
going to be enough.
##########
File path:
geode-core/src/main/java/org/apache/geode/internal/cache/wan/serial/SerialGatewaySenderQueue.java
##########
@@ -496,13 +489,19 @@ void
peekEventsFromIncompleteTransactions(List<AsyncEvent<?, ?>> batch, long las
}
}
if (incompleteTransactionIdsInBatch.size() == 0 ||
- retries++ == GET_TRANSACTION_EVENTS_FROM_QUEUE_RETRIES) {
+ retries >= sender.getRetriesToGetTransactionEventsFromQueue()) {
break;
}
+ retries++;
+ try {
+ Thread.sleep(GET_TRANSACTION_EVENTS_FROM_QUEUE_WAIT_TIME_MS);
+ } catch (InterruptedException e) {
+ Thread.currentThread().interrupt();
+ }
Review comment:
Same comment here.
GET_TRANSACTION_EVENTS_FROM_QUEUE_WAIT_TIME_MS is 1ms by default.
GET_TRANSACTION_EVENTS_FROM_QUEUE_RETRIES is 3 by default.
So, thats 3 ms of retries by default. I'm not sure thats going to be enough.
##########
File path:
geode-core/src/main/java/org/apache/geode/cache/wan/GatewaySender.java
##########
@@ -500,4 +516,12 @@
*/
void setGatewayEventFilters(List<GatewayEventFilter> filters);
+ /**
+ * Set the number of retries to get transaction events
+ * for this GatewaySender when GroupTransactionEvents
+ * is set.
+ *
+ */
+ void setRetriesToGetTransactionEventsFromQueue(int retries);
+
}
Review comment:
This method currently is not invoked by anything.
Other setters in this class are invoked by AlterGatewaySenderFunction.
Should this property be alterable?
Also, I don't see any tests that test this property.
--
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]