kevinrr888 commented on PR #5073: URL: https://github.com/apache/accumulo/pull/5073#issuecomment-2486385101
I removed the new check and now check if an instance exists before the full set of checks runs in `CheckServerConfig`. The instance is checked with `VolumeManager.getInstanceIDFromHdfs(instanceIdPath, hadoopConfig)`. Coincidentally, the vars needed for this call perform all* the checks that can be performed without a running instance: `SiteConfiguration.auto()`, `VolumeManagerImpl.get(siteConfig, hadoopConfig)`, and `new ServerDirs(siteConfig, hadoopConfig)`. I wanted to avoid just surrounding the existing code: ``` try (var context = new ServerContext(SiteConfiguration.auto())) { context.getConfiguration(); } ``` with a `try-catch` as the exception that occurs is a few layers deep and may be changed in the future and it would not be clear that changing those exceptions would affect this command. Also, if we surrounded it with a `try-catch` we would have to identify what is an exception relating to no instance from many potential exceptions. Calling the method directly avoids these issues. *to the best of my knowledge -- 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