joshelser commented on a change in pull request #755: HBASE-23210 Backport
HBASE-15519 (Add per-user metrics) to branch-1
URL: https://github.com/apache/hbase/pull/755#discussion_r338823623
##########
File path:
hbase-server/src/main/java/org/apache/hadoop/hbase/util/LossyCounting.java
##########
@@ -119,16 +138,33 @@ public long getDataSize() {
return data.size();
}
- public boolean contains(String key) {
+ public boolean contains(T key) {
return data.containsKey(key);
}
- public Set<String> getElements(){
+ public Set<T> getElements(){
return data.keySet();
}
public long getCurrentTerm() {
return currentTerm;
}
+
+ class SweepRunnable implements Runnable {
+ @Override public void run() {
+ if (LOG.isTraceEnabled()) {
+ LOG.trace("Starting sweep of lossyCounting-" + name);
Review comment:
nit, could use the `{}` markers and drop the `isTraceEnabled()`
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services