You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by GitBox <gi...@apache.org> on 2018/12/05 18:40:20 UTC

[GitHub] milleruntime commented on a change in pull request #797: Improved tablet metadata abstraction layer and used it more.

milleruntime commented on a change in pull request #797: Improved tablet metadata abstraction layer and used it more.
URL: https://github.com/apache/accumulo/pull/797#discussion_r239175392
 
 

 ##########
 File path: core/src/main/java/org/apache/accumulo/core/util/Merge.java
 ##########
 @@ -218,55 +212,23 @@ protected void merge(AccumuloClient client, String table, List<Size> sizes, int
   protected Iterator<Size> getSizeIterator(AccumuloClient client, String tablename, Text start,
       Text end) throws MergeException {
     // open up metadata, walk through the tablets.
+
     Table.ID tableId;
-    Scanner scanner;
+    TabletsMetadata tablets;
     try {
       ClientContext context = new ClientContext(client.info());
       tableId = Tables.getTableId(context, tablename);
-      scanner = client.createScanner(MetadataTable.NAME, Authorizations.EMPTY);
+      tablets = TabletsMetadata.builder().scanMetadataTable()
+          .overRange(new KeyExtent(tableId, end, start).toMetadataRange()).fetchFiles().fetchPrev()
+          .build(context);
 
 Review comment:
   This is great!

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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


With regards,
Apache Git Services