milleruntime commented on code in PR #2638:
URL: https://github.com/apache/accumulo/pull/2638#discussion_r852882774


##########
test/src/main/java/org/apache/accumulo/test/compaction/ExternalCompactionMetricsIT.java:
##########
@@ -166,7 +166,7 @@ public void testMetrics() throws Exception {
         UtilWaitThread.sleep(100);
         try (TabletsMetadata tm = 
getCluster().getServerContext().getAmple().readTablets()
             .forLevel(DataLevel.USER).fetch(ColumnType.ECOMP).build()) {
-          count = tm.stream().flatMap(t -> 
t.getExternalCompactions().keySet().stream()).count();
+          count = tm.stream().mapToLong(t -> 
t.getExternalCompactions().keySet().size()).sum();

Review Comment:
   I will have to look this data structure up again but I thought there was 
something unique about `flatMap`... Do you know if this translates to the same 
data structure?



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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to