keith-turner commented on a change in pull request #1366: Fix #1365 2.1 Upgrade 
processing for #1043 ~del
URL: https://github.com/apache/accumulo/pull/1366#discussion_r326727299
 
 

 ##########
 File path: 
server/base/src/main/java/org/apache/accumulo/server/metadata/ServerAmpleImpl.java
 ##########
 @@ -170,8 +169,10 @@ public void deleteGcCandidates(DataLevel level, 
Collection<String> paths) {
       }
       scanner.setRange(range);
 
-      return Iterators.transform(scanner.iterator(),
-          entry -> 
MetadataSchema.DeletesSection.decodeRow(entry.getKey().getRow().toString()));
+      return Iterators.transform(
 
 Review comment:
   Instead of using more Guava code here, this could use Java streams. I wan't 
sure how to get the stream for a scanner so I experimented locally.   I ended 
up with the following that at least compiles.
   
   ```java
     return StreamSupport.stream(scanner.spliterator(), false)
       .filter(entry -> 
entry.getValue().equals(DeletesSection.SkewedKeyValue.NAME))
       .map(entry -> 
DeletesSection.decodeRow(entry.getKey().getRow().toString())).iterator();
   ```

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to