kevinrr888 commented on code in PR #5416: URL: https://github.com/apache/accumulo/pull/5416#discussion_r2007968694
########## server/manager/src/main/java/org/apache/accumulo/manager/Manager.java: ########## @@ -568,10 +573,13 @@ private class MigrationCleanupThread implements Runnable { @Override public void run() { while (stillManager()) { - if (!migrations.isEmpty()) { + // migrations are stored in the metadata tables which cannot be read until the + // TabletGroupWatchers are started + if (watchersStarted.get() && numMigrations() > 0) { Review Comment: There is probably something specific that needs to be executed in the TabletGroupWatcher.run before this should be executed, but I'm not sure what... When `watchersStarted` is set to true will probably have to be changed. Currently is set after calling `start()` on all the watchers. ########## server/manager/src/main/java/org/apache/accumulo/manager/Manager.java: ########## @@ -568,10 +573,13 @@ private class MigrationCleanupThread implements Runnable { @Override public void run() { while (stillManager()) { - if (!migrations.isEmpty()) { + // migrations are stored in the metadata tables which cannot be read until the + // TabletGroupWatchers are started + if (watchersStarted.get() && numMigrations() > 0) { try { cleanupOfflineMigrations(); cleanupNonexistentMigrations(getContext()); + cleanupDeletedMigrations(); Review Comment: Previously, when TServers were deleted, the migrations to these TServers were deleted every call to `Manager.update()` which is called every 5 seconds (see `LiveTServerSet.scanServers()`). Now this is done every 5 minutes (see the `sleepUninterruptibly(CLEANUP_INTERVAL_MINUTES, MINUTES);` below). Not sure if the extra delay matters or not, so making note in case it does. ########## core/src/test/java/org/apache/accumulo/core/metadata/schema/TabletMetadataTest.java: ########## @@ -203,6 +207,7 @@ public void testAllColumns() { assertEquals(unsplittableMeta, tm.getUnSplittable()); assertEquals(ecMeta.toJson(), tm.getExternalCompactions().get(ecid).toJson()); assertEquals(10, tm.getFlushNonce().getAsLong()); + assertEquals(tsi, tm.getMigration()); Review Comment: Would be nice if tests like this and `AmpleConditionalWriterIT` failed when new columns are added to the the metadata tables but are not tested. This could be a follow on. Would also have to ensure all existing columns are tested. -- 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: notifications-unsubscr...@accumulo.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org