SteNicholas commented on code in PR #3248:
URL: https://github.com/apache/celeborn/pull/3248#discussion_r2221235331


##########
common/src/main/java/org/apache/celeborn/common/write/InFlightRequestTracker.java:
##########
@@ -90,6 +113,12 @@ public Set<Integer> getBatchIdSetByAddressPair(String 
hostAndPort) {
         hostAndPort, pair -> ConcurrentHashMap.newKeySet());
   }
 
+  public long getBatchBytesSizeByAddressPair(String hostAndPort) {
+    return inflightBytesSizePerAddress
+        .computeIfAbsent(hostAndPort, pair -> new LongAdder())
+        .longValue();

Review Comment:
   @mridulm, this is designed to insert into `inflightBytesSizePerAddress` to 
guarantee consistency between multiple threads.



-- 
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]

Reply via email to