You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by ki...@apache.org on 2022/01/17 08:00:53 UTC

[incubator-seatunnel] branch dev updated: [Seatunnel #1080][seatunnel-core] Remove unnecessary flink-sql scripts (#1081)

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

kirs pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-seatunnel.git


The following commit(s) were added to refs/heads/dev by this push:
     new 99ad5d6  [Seatunnel #1080][seatunnel-core] Remove unnecessary flink-sql scripts (#1081)
99ad5d6 is described below

commit 99ad5d65de77b3df7aa7ff94f2546ecf3511a637
Author: wuchunfu <31...@qq.com>
AuthorDate: Mon Jan 17 16:00:45 2022 +0800

    [Seatunnel #1080][seatunnel-core] Remove unnecessary flink-sql scripts (#1081)
---
 bin/start-seatunnel-sql.sh                         |  2 -
 bin/utils/app.sh                                   | 50 --------------
 bin/utils/file.sh                                  | 76 ----------------------
 .../src/main/bin/start-seatunnel-flink.sh          |  2 -
 4 files changed, 130 deletions(-)

diff --git a/bin/start-seatunnel-sql.sh b/bin/start-seatunnel-sql.sh
index 6e9a6f4..7d1dd58 100755
--- a/bin/start-seatunnel-sql.sh
+++ b/bin/start-seatunnel-sql.sh
@@ -65,14 +65,12 @@ fi
 eval set -- "$PARAMS"
 
 BIN_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-UTILS_DIR=${BIN_DIR}/utils
 APP_DIR=$(dirname ${BIN_DIR})
 CONF_DIR=${APP_DIR}/config
 PLUGINS_DIR=${APP_DIR}/lib
 DEFAULT_CONFIG=${CONF_DIR}/application.conf
 CONFIG_FILE=${CONFIG_FILE:-$DEFAULT_CONFIG}
 
-
 assemblyJarName=$(find ${PLUGINS_DIR} -name seatunnel-core-sql*.jar)
 
 source ${CONF_DIR}/seatunnel-env.sh
diff --git a/bin/utils/app.sh b/bin/utils/app.sh
deleted file mode 100644
index c8d386b..0000000
--- a/bin/utils/app.sh
+++ /dev/null
@@ -1,50 +0,0 @@
-#!/usr/bin/env bash
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#    http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# Get App Name of SeaTunnel
-function getAppName {
-
-    if [ "$#" -ne 1 ]; then
-        echo "Illegal number of parameters"
-        exit -1
-    fi
-
-    config_file_path=$1
-
-    app_name_config=$(grep -i "spark.app.name" ${config_file_path})
-    # remove all leading and trailing  whitespace
-    app_name_config=$(echo ${app_name_config} | tr -d '[:space:]')
-
-    DEFAULT_APP_NAME="SeaTunnel"
-    APP_NAME=${DEFAULT_APP_NAME}
-
-    if [[ ${app_name_config} == \#* ]]; then
-        # spark.app.name is commented, we should ignore
-        :
-    else
-
-        if [ "${app_name_config}" != "" ];then
-            # split app_name from config
-            APP_NAME=${app_name_config##*=}
-            # remove quotes if exists
-            APP_NAME=$(echo ${APP_NAME} | tr -d '"' | tr -d "'")
-        fi
-    fi
-
-    echo ${APP_NAME}
-}
\ No newline at end of file
diff --git a/bin/utils/file.sh b/bin/utils/file.sh
deleted file mode 100644
index 75e20a5..0000000
--- a/bin/utils/file.sh
+++ /dev/null
@@ -1,76 +0,0 @@
-#!/usr/bin/env bash
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#    http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-# List all files in specific dir and concat full path of files by specific delimeter.
-function listFiles {
-
-    dir=$1
-    delimeter=$2
-    ignore_file_regex=${3:-""} # if $3 not set, set default value: empty string("")
-
-    jar_list=""
-    for file in $(ls $dir); do
-
-        if [ "x$ignore_file_regex" != "x" ]; then
-
-            if [[ $file =~ $ignore_file_regex ]]; then
-                # if file match ignore file regex,
-                # then don't include this file.
-                continue
-            fi
-        fi
-
-        jar_file=$dir/$file
-        if [ "x$jar_list" == "x" ]; then
-            jar_list=$jar_file
-        else
-            jar_list="${jar_list}${delimeter}${jar_file}"
-        fi
-    done
-
-    echo $jar_list
-}
-
-function listJars {
-    dir=$1
-    echo $(listFiles $dir ",")
-}
-
-## list jars dependencies of plugins
-function listJarDependenciesOfPlugins {
-    dir=$1
-    allJars=""
-    for plugin_dir in $(ls $dir); do
-        abs_plugin_dir=$dir/$plugin_dir
-        for subdir in $(ls $abs_plugin_dir); do
-            abs_subdir=$abs_plugin_dir/$subdir
-            jars=""
-            if [ "$subdir" == "lib" ]; then
-                jars=$(listJars $abs_subdir)
-
-                if [ "x$allJars" == "x" ]; then
-                    allJars=$jars
-                else
-                    allJars="${allJars},${jars}"
-                fi
-            fi
-        done
-    done
-
-    echo $allJars
-}
diff --git a/seatunnel-core/seatunnel-core-flink/src/main/bin/start-seatunnel-flink.sh b/seatunnel-core/seatunnel-core-flink/src/main/bin/start-seatunnel-flink.sh
index fd9fb17..7af0d8a 100755
--- a/seatunnel-core/seatunnel-core-flink/src/main/bin/start-seatunnel-flink.sh
+++ b/seatunnel-core/seatunnel-core-flink/src/main/bin/start-seatunnel-flink.sh
@@ -65,14 +65,12 @@ fi
 eval set -- "$PARAMS"
 
 BIN_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-UTILS_DIR=${BIN_DIR}/utils
 APP_DIR=$(dirname ${BIN_DIR})
 CONF_DIR=${APP_DIR}/config
 PLUGINS_DIR=${APP_DIR}/lib
 DEFAULT_CONFIG=${CONF_DIR}/application.conf
 CONFIG_FILE=${CONFIG_FILE:-$DEFAULT_CONFIG}
 
-
 assemblyJarName=$(find ${PLUGINS_DIR} -name seatunnel-core-flink*.jar)
 
 if [ -f "${CONF_DIR}/seatunnel-env.sh" ]; then