You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pr@cassandra.apache.org by GitBox <gi...@apache.org> on 2020/09/22 15:34:32 UTC

[GitHub] [cassandra] clohfink commented on a change in pull request #750: CASSANDRA-15164 log unusual EstimatedHistogram serializations and deserializations

clohfink commented on a change in pull request #750:
URL: https://github.com/apache/cassandra/pull/750#discussion_r492825012



##########
File path: src/java/org/apache/cassandra/utils/EstimatedHistogram.java
##########
@@ -390,7 +407,15 @@ public EstimatedHistogram deserialize(DataInputPlus in) throws IOException
                 offsets[i == 0 ? 0 : i - 1] = in.readLong();
                 buckets[i] = in.readLong();
             }
-            return new EstimatedHistogram(offsets, buckets);
+            EstimatedHistogram histogram = new EstimatedHistogram(offsets, buckets);
+
+            if (histogram.isOverflowed())
+            {
+                logger.warn("Deserialized a histogram with {} values greater than the maximum of {}.",
+                            histogram.overflowCount(), histogram.getLargestBucketOffset());

Review comment:
       the thread name would give a decent amount of context, but you could dump whole stack trace with message too I suppose but I think its sufficient like this




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



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