dlmarion commented on code in PR #4260:
URL: https://github.com/apache/accumulo/pull/4260#discussion_r1489624839
##########
test/src/main/java/org/apache/accumulo/test/functional/SplitRecoveryIT.java:
##########
@@ -189,12 +187,26 @@ private void runSplitRecoveryTest(ServerContext context,
int failPoint, String m
private static Map<Long,List<ReferencedTabletFile>>
getBulkFilesLoaded(ServerContext context,
KeyExtent extent) {
- Map<Long,List<ReferencedTabletFile>> bulkFiles = new HashMap<>();
- context.getAmple().readTablet(extent).getLoaded().forEach((path, txid) ->
bulkFiles
- .computeIfAbsent(txid, k -> new
ArrayList<>()).add(path.getTabletFile()));
+ // Ample is not used here because it does not recognize some of the old
columns that this
+ // upgrade code is dealing with.
+ try (Scanner scanner =
+ context.createScanner(AccumuloTable.METADATA.tableName(),
Authorizations.EMPTY)) {
+ scanner.setRange(extent.toMetaRange());
+
+ Map<Long,List<ReferencedTabletFile>> bulkFiles = new HashMap<>();
+ for (var entry : scanner) {
+ if
(entry.getKey().getColumnFamily().equals(BulkFileColumnFamily.NAME)) {
+ var path = new
StoredTabletFile(entry.getKey().getColumnQualifier().toString());
+ var txid = BulkFileColumnFamily.getBulkLoadTid(entry.getValue());
+ bulkFiles.computeIfAbsent(txid, k -> new
ArrayList<>()).add(path.getTabletFile());
+ }
+ }
Review Comment:
So, this looks like the real change here, the other changes are due to the
method moves. What is the old column here?
--
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]