sodonnel commented on code in PR #3909:
URL: https://github.com/apache/ozone/pull/3909#discussion_r1010733984
##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/replication/ContainerReplicaPendingOps.java:
##########
@@ -163,6 +176,9 @@ public void removeExpiredEntries(long expiryMilliSeconds) {
if (op.getScheduledEpochMillis() + expiryMilliSeconds
< clock.millis()) {
iterator.remove();
+ pendingOpCount.put(op.getOpType(),
+ pendingOpCount.get(op.getOpType()) - 1);
+ updateMetrics(op.getOpType());
Review Comment:
Maybe rename this to updateTimeoutMetrics.
Also, is it worth passing the full Op in so we get the replica index in the
updateMetrics and can apply the same `if replicaIndex > 0` logic as it other
places?
--
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]