zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jtuple <...@git.apache.org>
Subject [GitHub] zookeeper pull request #580: ZOOKEEPER-3098: Add additional server metrics
Date Fri, 03 Aug 2018 18:40:28 GMT
Github user jtuple commented on a diff in the pull request:

    https://github.com/apache/zookeeper/pull/580#discussion_r207633573
  
    --- Diff: src/java/main/org/apache/zookeeper/server/NettyServerCnxn.java ---
    @@ -271,7 +271,7 @@ private boolean checkFourLetterWord(final Channel channel,
             String cmd = FourLetterCommands.getCommandString(len);
     
             channel.setInterestOps(0).awaitUninterruptibly();
    -        packetReceived();
    +        packetReceived(4);
    --- End diff --
    
    `packetReceived()` now takes in the packet-size as an argument to update the packets received
metric. The total packet size consists of packet header (4 bytes) + packet size. For "four
letter words", there is no packet size -- just the 4-byte packet header.


---

Mime
View raw message