You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bigtop.apache.org by yw...@apache.org on 2016/02/26 02:18:32 UTC

bigtop git commit: BIGTOP-2220 : flume-agent.init incorrectly handles flume.conf

Repository: bigtop
Updated Branches:
  refs/heads/master 1e9784144 -> 03a3f3494


BIGTOP-2220 : flume-agent.init incorrectly handles flume.conf

Signed-off-by: Youngwoo Kim <yw...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/bigtop/repo
Commit: http://git-wip-us.apache.org/repos/asf/bigtop/commit/03a3f349
Tree: http://git-wip-us.apache.org/repos/asf/bigtop/tree/03a3f349
Diff: http://git-wip-us.apache.org/repos/asf/bigtop/diff/03a3f349

Branch: refs/heads/master
Commit: 03a3f34942cd419f0332e93b376feaf576db42f7
Parents: 1e97841
Author: zenmyo <tz...@gmail.com>
Authored: Thu Jan 7 14:21:11 2016 +0900
Committer: Youngwoo Kim <yw...@apache.org>
Committed: Fri Feb 26 10:21:37 2016 +0900

----------------------------------------------------------------------
 bigtop-packages/src/common/flume/flume-agent.init | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/bigtop/blob/03a3f349/bigtop-packages/src/common/flume/flume-agent.init
----------------------------------------------------------------------
diff --git a/bigtop-packages/src/common/flume/flume-agent.init b/bigtop-packages/src/common/flume/flume-agent.init
index 1d041a2..ec179c0 100644
--- a/bigtop-packages/src/common/flume/flume-agent.init
+++ b/bigtop-packages/src/common/flume/flume-agent.init
@@ -197,10 +197,14 @@ checkallstatus() {
 # Common function to perform user action on all flume conf files
 #
 run_functions_on_conf() {
+  if [ -f ${FLUME_CONF_DIR}/flume.conf ]; then
+    echo $FLUME_AGENT_NAME
+    $1
+  fi
+  agent_conf_pattern="${FLUME_CONF_DIR}/flume-.*\.conf"
   for f in ${FLUME_CONF_DIR}/*
   do
-    file_ext=${f##*.}
-    if [ "$file_ext" = "conf" ]; then
+    if [ $(echo $f | grep -e ${agent_conf_pattern}) ]; then
       conf_file=${f%.*}
       file_name=${conf_file##*/}
       agent_name=${file_name#*-}