You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@accumulo.apache.org by mm...@apache.org on 2019/06/24 14:35:41 UTC

[accumulo] branch master updated: Add exceptions to standalone IT property file loading. Closes #1168. (#1189)

This is an automated email from the ASF dual-hosted git repository.

mmiller pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/accumulo.git


The following commit(s) were added to refs/heads/master by this push:
     new 49767b4  Add exceptions to standalone IT property file loading. Closes #1168. (#1189)
49767b4 is described below

commit 49767b4fdd25f85c3c2148d77906b0ae6712708d
Author: Don Resnik <do...@vistronix.com>
AuthorDate: Mon Jun 24 10:35:36 2019 -0400

    Add exceptions to standalone IT property file loading. Closes #1168. (#1189)
    
    * This update changes logs to RuntimeExceptions so that bad standalone IT properties do not automatically convert to a mini cluster
---
 .../harness/conf/AccumuloClusterPropertyConfiguration.java     | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/test/src/main/java/org/apache/accumulo/harness/conf/AccumuloClusterPropertyConfiguration.java b/test/src/main/java/org/apache/accumulo/harness/conf/AccumuloClusterPropertyConfiguration.java
index 326430d..98bb45a 100644
--- a/test/src/main/java/org/apache/accumulo/harness/conf/AccumuloClusterPropertyConfiguration.java
+++ b/test/src/main/java/org/apache/accumulo/harness/conf/AccumuloClusterPropertyConfiguration.java
@@ -63,19 +63,19 @@ public abstract class AccumuloClusterPropertyConfiguration implements AccumuloCl
         try {
           reader = new FileReader(f);
         } catch (FileNotFoundException e) {
-          log.warn("Could not read properties from specified file: {}", propertyFile, e);
+          throw new RuntimeException("Could not read properties from specified file: " + propertyFile, e);
         }
 
         if (reader != null) {
           try {
             fileProperties.load(reader);
           } catch (IOException e) {
-            log.warn("Could not load properties from specified file: {}", propertyFile, e);
+            throw new RuntimeException("Could not load properties from specified file: " + propertyFile, e);
           } finally {
             try {
               reader.close();
             } catch (IOException e) {
-              log.warn("Could not close reader", e);
+              throw new RuntimeException("Could not close reader", e);
             }
           }
 
@@ -83,10 +83,10 @@ public abstract class AccumuloClusterPropertyConfiguration implements AccumuloCl
           clientConf = fileProperties.getProperty(ACCUMULO_CLUSTER_CLIENT_CONF_KEY);
         }
       } else {
-        log.debug("Property file ({}) is not a readable file", propertyFile);
+        throw new RuntimeException("Property file (" + propertyFile + ") is not a readable file");
       }
     } else {
-      log.debug("No properties file found in {}", ACCUMULO_IT_PROPERTIES_FILE);
+      throw new RuntimeException("No properties file found in " + ACCUMULO_IT_PROPERTIES_FILE);
     }
 
     if (clusterTypeValue == null) {