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 2020/10/08 19:00:19 UTC

[GitHub] [accumulo] EdColeman commented on a change in pull request #1728: Closes #1718. Fail if no Accumulo Instance on Standalone setup

EdColeman commented on a change in pull request #1728:
URL: https://github.com/apache/accumulo/pull/1728#discussion_r501946691



##########
File path: test/src/main/java/org/apache/accumulo/harness/AccumuloClusterHarness.java
##########
@@ -217,6 +219,17 @@ public void setupCluster() throws Exception {
     }
   }
 
+  public void checkConnection() {
+    try (AccumuloClient client = Accumulo.newClient().from(getClientProps()).build()) {
+      // Use prefix so cleanupTables deletes it
+      String tablePrefix = this.getClass().getSimpleName() + "_";
+      client.tableOperations().create(tablePrefix);

Review comment:
       Why is just getting the client not sufficient?  
   
   Other options could be InstanceOperations.getSystemConfiguration or getSiteConfiguration()
   
   Another possibility would be to see if you can scan either the root or the metadata table, and if you restricted the colFam to file or ~tab:~pr - that's only going to be a few entries - and that's a fairly robust way of know that a lot is up and ready for operations.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org