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

mwalch pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/fluo-uno.git


The following commit(s) were added to refs/heads/master by this push:
     new b8fb6bd  Organized Accumulo & Hadoop config by version (#203)
b8fb6bd is described below

commit b8fb6bde18c6e0001031d26743ee17e109c8de2e
Author: Mike Walch <[email protected]>
AuthorDate: Thu Oct 4 16:18:06 2018 -0400

    Organized Accumulo & Hadoop config by version (#203)
---
 bin/impl/setup-accumulo.sh                                   |  6 +++---
 bin/impl/setup-hadoop.sh                                     | 12 +++---------
 conf/accumulo/{accumulo-site-1.0.xml => 1/accumulo-site.xml} |  0
 .../{accumulo-2.0.properties => 2/accumulo.properties}       |  0
 conf/accumulo/{ => common}/accumulo-it.properties            |  0
 conf/hadoop/{mapred-site-2.xml => 2/mapred-site.xml}         |  0
 conf/hadoop/{workers => 2/slaves}                            |  0
 conf/hadoop/{ => 3}/mapred-site.xml                          |  0
 conf/hadoop/{ => 3}/workers                                  |  0
 conf/hadoop/{ => common}/capacity-scheduler.xml              |  0
 conf/hadoop/{ => common}/core-site.xml                       |  0
 conf/hadoop/{ => common}/hdfs-site.xml                       |  0
 conf/hadoop/{ => common}/masters                             |  0
 conf/hadoop/{ => common}/yarn-site.xml                       |  0
 14 files changed, 6 insertions(+), 12 deletions(-)

diff --git a/bin/impl/setup-accumulo.sh b/bin/impl/setup-accumulo.sh
index 2911ff2..e7ccd80 100755
--- a/bin/impl/setup-accumulo.sh
+++ b/bin/impl/setup-accumulo.sh
@@ -42,17 +42,18 @@ tar xzf "$DOWNLOADS/$ACCUMULO_TARBALL" -C "$INSTALL"
 
 conf=$ACCUMULO_HOME/conf
 
+cp "$UNO_HOME"/conf/accumulo/common/* "$conf"
 if [[ $ACCUMULO_VERSION =~ ^1\..*$ ]]; then
   accumulo_conf=$conf/accumulo-site.xml
   cp "$conf"/examples/2GB/standalone/* "$conf"/
   $SED "s#localhost#$UNO_HOST#" "$conf/slaves"
-  cp "$UNO_HOME"/conf/accumulo/accumulo-site-1.0.xml "$accumulo_conf"
+  cp "$UNO_HOME"/conf/accumulo/1/* "$conf"
   $SED "s#export HADOOP_PREFIX=[^ ]*#export HADOOP_PREFIX=$HADOOP_HOME#" 
"$conf"/accumulo-env.sh
 else
   accumulo_conf=$conf/accumulo.properties
+  cp "$UNO_HOME"/conf/accumulo/2/* "$conf"
   "$ACCUMULO_HOME"/bin/accumulo-cluster create-config
   $SED "s#localhost#$UNO_HOST#" "$conf/tservers"
-  cp "$UNO_HOME"/conf/accumulo/accumulo-2.0.properties "$accumulo_conf"
   $SED "s#export HADOOP_HOME=[^ ]*#export HADOOP_HOME=$HADOOP_HOME#" 
"$conf"/accumulo-env.sh
   $SED "s#instance[.]name=#instance.name=$ACCUMULO_INSTANCE#" 
"$conf"/accumulo-client.properties
   $SED 
"s#instance[.]zookeepers=localhost:2181#instance.zookeepers=$UNO_HOST:2181#" 
"$conf"/accumulo-client.properties
@@ -80,7 +81,6 @@ $SED "s#ACCUMULO_IMAP_SIZE#$ACCUMULO_IMAP_SIZE#" 
"$accumulo_conf"
 $SED "s#ACCUMULO_USE_NATIVE_MAP#$ACCUMULO_USE_NATIVE_MAP#" "$accumulo_conf"
 $SED "s#UNO_HOST#$UNO_HOST#" "$accumulo_conf"
 
-cp "$UNO_HOME/conf/accumulo/accumulo-it.properties" "$conf"
 it_props="$conf/accumulo-it.properties"
 $SED "s#ACCUMULO_USER#$ACCUMULO_USER#" "$it_props"
 $SED "s#ACCUMULO_PASSWORD#$ACCUMULO_PASSWORD#" "$it_props"
diff --git a/bin/impl/setup-hadoop.sh b/bin/impl/setup-hadoop.sh
index 5614fc2..bd5a7fa 100755
--- a/bin/impl/setup-hadoop.sh
+++ b/bin/impl/setup-hadoop.sh
@@ -43,17 +43,11 @@ mkdir -p "$HADOOP_LOG_DIR"
 tar xzf "$DOWNLOADS/$HADOOP_TARBALL" -C "$INSTALL"
 
 hadoop_conf="$HADOOP_HOME"/etc/hadoop
-cp "$UNO_HOME"/conf/hadoop/core-site.xml "$hadoop_conf/"
-cp "$UNO_HOME"/conf/hadoop/hdfs-site.xml "$hadoop_conf/"
-cp "$UNO_HOME"/conf/hadoop/yarn-site.xml "$hadoop_conf/"
-cp "$UNO_HOME"/conf/hadoop/capacity-scheduler.xml "$hadoop_conf/"
-cp "$UNO_HOME"/conf/hadoop/masters "$hadoop_conf/"
+cp "$UNO_HOME"/conf/hadoop/common/* "$hadoop_conf/"
 if [[ $HADOOP_VERSION =~ ^2\..*$ ]]; then
-  cp "$UNO_HOME"/conf/hadoop/workers "$hadoop_conf/slaves"
-  cp "$UNO_HOME"/conf/hadoop/mapred-site-2.xml "$hadoop_conf/mapred-site.xml"
+  cp "$UNO_HOME"/conf/hadoop/2/* "$hadoop_conf/"
 else
-  cp "$UNO_HOME"/conf/hadoop/workers "$hadoop_conf/"
-  cp "$UNO_HOME"/conf/hadoop/mapred-site.xml "$hadoop_conf/"
+  cp "$UNO_HOME"/conf/hadoop/3/* "$hadoop_conf/"
 fi
 
 $SED "s#UNO_HOST#$UNO_HOST#g" "$hadoop_conf/core-site.xml" 
"$hadoop_conf/hdfs-site.xml" "$hadoop_conf/yarn-site.xml"
diff --git a/conf/accumulo/accumulo-site-1.0.xml 
b/conf/accumulo/1/accumulo-site.xml
similarity index 100%
rename from conf/accumulo/accumulo-site-1.0.xml
rename to conf/accumulo/1/accumulo-site.xml
diff --git a/conf/accumulo/accumulo-2.0.properties 
b/conf/accumulo/2/accumulo.properties
similarity index 100%
rename from conf/accumulo/accumulo-2.0.properties
rename to conf/accumulo/2/accumulo.properties
diff --git a/conf/accumulo/accumulo-it.properties 
b/conf/accumulo/common/accumulo-it.properties
similarity index 100%
rename from conf/accumulo/accumulo-it.properties
rename to conf/accumulo/common/accumulo-it.properties
diff --git a/conf/hadoop/mapred-site-2.xml b/conf/hadoop/2/mapred-site.xml
similarity index 100%
rename from conf/hadoop/mapred-site-2.xml
rename to conf/hadoop/2/mapred-site.xml
diff --git a/conf/hadoop/workers b/conf/hadoop/2/slaves
similarity index 100%
copy from conf/hadoop/workers
copy to conf/hadoop/2/slaves
diff --git a/conf/hadoop/mapred-site.xml b/conf/hadoop/3/mapred-site.xml
similarity index 100%
rename from conf/hadoop/mapred-site.xml
rename to conf/hadoop/3/mapred-site.xml
diff --git a/conf/hadoop/workers b/conf/hadoop/3/workers
similarity index 100%
rename from conf/hadoop/workers
rename to conf/hadoop/3/workers
diff --git a/conf/hadoop/capacity-scheduler.xml 
b/conf/hadoop/common/capacity-scheduler.xml
similarity index 100%
rename from conf/hadoop/capacity-scheduler.xml
rename to conf/hadoop/common/capacity-scheduler.xml
diff --git a/conf/hadoop/core-site.xml b/conf/hadoop/common/core-site.xml
similarity index 100%
rename from conf/hadoop/core-site.xml
rename to conf/hadoop/common/core-site.xml
diff --git a/conf/hadoop/hdfs-site.xml b/conf/hadoop/common/hdfs-site.xml
similarity index 100%
rename from conf/hadoop/hdfs-site.xml
rename to conf/hadoop/common/hdfs-site.xml
diff --git a/conf/hadoop/masters b/conf/hadoop/common/masters
similarity index 100%
rename from conf/hadoop/masters
rename to conf/hadoop/common/masters
diff --git a/conf/hadoop/yarn-site.xml b/conf/hadoop/common/yarn-site.xml
similarity index 100%
rename from conf/hadoop/yarn-site.xml
rename to conf/hadoop/common/yarn-site.xml

Reply via email to