Policy.Eviction#getMaximum() might cause noticeable stalls (original) (raw)
See https://issues.apache.org/jira/browse/CASSANDRA-19429
Javadoc for getMaximum() does not warn the users the API is delicate, so developers might use it without realizing they might get unexpected degradations.
It might be great if the method could be improved:
a) Avoid stalls on getMaximum()
b) Add an alternative lightweight method that would skip draining the queue and return and approximate results
c) Add a clear notice to javadoc so the users know the method is not safe for hot paths