dlmarion commented on code in PR #2792:
URL: https://github.com/apache/accumulo/pull/2792#discussion_r973227199
##########
server/gc/src/main/java/org/apache/accumulo/gc/GCRun.java:
##########
@@ -172,7 +177,19 @@ public Stream<Reference> getReferences() {
@Override
public Set<TableId> getTableIDs() {
- return context.getTableIdToNameMap().keySet();
+ final String tablesPath = context.getZooKeeperRoot() + Constants.ZTABLES;
+ final ZooReader zr = context.getZooReader();
+ final Set<TableId> tids = new HashSet<>();
+ while (true) {
+ try {
+ zr.sync(tablesPath);
+ zr.getChildren(tablesPath).forEach(t -> tids.add(TableId.of(t)));
+ return tids;
+ } catch (KeeperException | InterruptedException e) {
+ log.error("Error getting tables from ZooKeeper, retrying", e);
+ UtilWaitThread.sleepUninterruptibly(1, TimeUnit.SECONDS);
+ }
Review Comment:
Addressed in 1f8d37305789fa1540158e32b54da86a7af3ae87
--
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]