This is an automated email from the ASF dual-hosted git repository.
wenjun 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 51e7c022 [Fix][Spark] fixed first start shell can't run. (#1746)
51e7c022 is described below
commit 51e7c022ba606cf3d327a31e75dac3016d8c09ce
Author: TrickyZerg <[email protected]>
AuthorDate: Wed Apr 27 11:44:08 2022 +0800
[Fix][Spark] fixed first start shell can't run. (#1746)
* split return string to get command
---
.../src/main/java/org/apache/seatunnel/utils/CompressionUtils.java | 2 +-
.../seatunnel-core-spark/src/main/bin/start-seatunnel-spark.sh | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git
a/seatunnel-core/seatunnel-core-base/src/main/java/org/apache/seatunnel/utils/CompressionUtils.java
b/seatunnel-core/seatunnel-core-base/src/main/java/org/apache/seatunnel/utils/CompressionUtils.java
index bd8f4074..4007a971 100644
---
a/seatunnel-core/seatunnel-core-base/src/main/java/org/apache/seatunnel/utils/CompressionUtils.java
+++
b/seatunnel-core/seatunnel-core-base/src/main/java/org/apache/seatunnel/utils/CompressionUtils.java
@@ -97,7 +97,7 @@ public final class CompressionUtils {
* @throws FileNotFoundException file not found exception
* @throws ArchiveException archive exception
*/
- public static void unTar(final File inputFile, final File outputDir)
throws IOException, ArchiveException {
+ public static void unTar(final File inputFile, final File outputDir)
throws IOException, ArchiveException {
LOGGER.info("Untaring {} to dir {}.", inputFile.getAbsolutePath(),
outputDir.getAbsolutePath());
diff --git
a/seatunnel-core/seatunnel-core-spark/src/main/bin/start-seatunnel-spark.sh
b/seatunnel-core/seatunnel-core-spark/src/main/bin/start-seatunnel-spark.sh
index b7a1a09d..4528a68b 100755
--- a/seatunnel-core/seatunnel-core-spark/src/main/bin/start-seatunnel-spark.sh
+++ b/seatunnel-core/seatunnel-core-spark/src/main/bin/start-seatunnel-spark.sh
@@ -24,12 +24,13 @@ if [ -f "${CONF_DIR}/seatunnel-env.sh" ]; then
. "${CONF_DIR}/seatunnel-env.sh"
fi
-CMD=$(java -cp ${APP_JAR} org.apache.seatunnel.SparkStarter ${@}) &&
EXIT_CODE=$? || EXIT_CODE=$?
+CMD=$(java -cp ${APP_JAR} org.apache.seatunnel.SparkStarter ${@} | tail -n 1)
&& EXIT_CODE=$? || EXIT_CODE=$?
if [ ${EXIT_CODE} -eq 234 ]; then
# print usage
echo ${CMD}
exit 0
elif [ ${EXIT_CODE} -eq 0 ]; then
+ echo "Execute SeaTunnel Spark Job: ${CMD}"
eval ${CMD}
else
echo ${CMD}