You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@storm.apache.org by GitBox <gi...@apache.org> on 2020/08/07 16:50:49 UTC

[GitHub] [storm] Ethanlm commented on a change in pull request #3317: STORM-3682 Upgrade netty client metrics to use V2 API

Ethanlm commented on a change in pull request #3317:
URL: https://github.com/apache/storm/pull/3317#discussion_r467153995



##########
File path: storm-client/src/jvm/org/apache/storm/messaging/netty/Client.java
##########
@@ -420,15 +432,15 @@ public void close() {
 
     private void waitForPendingMessagesToBeSent() {
         LOG.info("waiting up to {} ms to send {} pending messages to {}",
-                 PENDING_MESSAGES_FLUSH_TIMEOUT_MS, pendingMessages.get(), dstAddressPrefixedName);
-        long totalPendingMsgs = pendingMessages.get();
+                 PENDING_MESSAGES_FLUSH_TIMEOUT_MS, pendingMessages.getCount(), dstAddressPrefixedName);
+        long totalPendingMsgs = pendingMessages.getCount();
         long startMs = System.currentTimeMillis();
-        while (pendingMessages.get() != 0) {
+        while (pendingMessages.getCount() != 0) {

Review comment:
       I am worried about performance since meter.getCount() doesn't seem trivial. Maybe we should keep those AtomIntegers and add meters separately. They are essentially different things

##########
File path: docs/Metrics.md
##########
@@ -273,7 +273,12 @@ Be aware that the `__system` bolt is an actual bolt so regular bolt metrics desc
 
 ##### Send (Netty Client)

Review comment:
       > The value is a map where ...
   
   We need to update the doc there too since the structure changed. 
   




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org