cassandra-pr mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aweisberg <...@git.apache.org>
Subject [GitHub] cassandra pull request #283: CASSANDRA-14459: DynamicEndpointSnitch should n...
Date Mon, 10 Dec 2018 17:58:48 GMT
Github user aweisberg commented on a diff in the pull request:

    https://github.com/apache/cassandra/pull/283#discussion_r239884211
  
    --- Diff: src/java/org/apache/cassandra/net/MessagingService.java ---
    @@ -729,20 +730,26 @@ void markTimeout(InetAddressAndPort addr)
         /**
          * Track latency information for the dynamic snitch
          *
    -     * @param cb      the callback associated with this message -- this lets us know
if it's a message type we're interested in
    -     * @param address the host that replied to the message
    -     * @param latency
    +     * @param cb            the callback associated with this message -- this lets us
know if it's a message type we're interested in
    +     * @param address       the host that replied to the message
    +     * @param latencyMicros the number of microseconds to record for this host
          */
    -    public void maybeAddLatency(IAsyncCallback cb, InetAddressAndPort address, long latency)
    +    public void maybeAddLatency(IAsyncCallback cb, InetAddressAndPort address, long latencyMicros)
         {
    -        if (cb.isLatencyForSnitch())
    -            addLatency(address, latency);
    +        if (cb.latencyMeasurementType() != LatencyMeasurementType.IGNORE)
    +            addLatency(address, latencyMicros, cb.latencyMeasurementType());
         }
     
    -    public void addLatency(InetAddressAndPort address, long latency)
    +    // Used on the local read path
    +    public void addLatency(InetAddressAndPort address, long latencyMicros)
    --- End diff --
    
    It's a bit implicit that this is exclusively for adding read latency?


---

---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@cassandra.apache.org
For additional commands, e-mail: pr-help@cassandra.apache.org


Mime
View raw message