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-yarn.git
The following commit(s) were added to refs/heads/master by this push:
new 2e0266d Fixes #3 Check if application is running before starting (#5)
2e0266d is described below
commit 2e0266de99000e827286a81f2c39576a68de5b39
Author: Mike Walch <[email protected]>
AuthorDate: Mon Aug 28 10:43:23 2017 -0400
Fixes #3 Check if application is running before starting (#5)
* Also improved README.md
---
README.md | 15 +++++++++------
distribution/bin/fluo-yarn | 5 +++++
2 files changed, 14 insertions(+), 6 deletions(-)
diff --git a/README.md b/README.md
index 6d9604b..2080c7a 100644
--- a/README.md
+++ b/README.md
@@ -34,7 +34,7 @@ See the [related projects page][related] for external
projects that may help in
## Set up your Fluo application
-Before you can launch a Fluo application in YARN, you should follow Fluo's
[install instructions][install]
+Before you can launch a Fluo application in YARN, you should follow Fluo's
[install] and [application] instructions
to install Fluo and initialize a Fluo application. After your application has
been initialized, follow
the insructions below to install the Fluo YARN launcher and run your
application in YARN. Avoid using the
`fluo` command to start local oracle and worker processes if you are running
in YARN.
@@ -82,7 +82,8 @@ After you obtain a Fluo YARN distribution tarball, follow
these steps to install
## Start Fluo application in YARN
-Follow the instructions below to start a Fluo application which contain an
oracle and multiple workers.
+Follow the instructions below to start your application in YARN. If you have
not done so already, you should [initialize
+your Fluo application][application] before following these instructions.
1. Configure [fluo-yarn-env.sh] and [fluo-yarn.properties] if you have not
already.
@@ -90,13 +91,14 @@ Follow the instructions below to start a Fluo application
which contain an oracl
fluo-yarn start myapp conf/fluo-yarn.properties
- The commands will retrieve your application configuration and observer jars
(using your
- application name) before starting the application in YARN.
+ The commands will retrieve your application configuration and observer jars
(using your application name) before
+ starting the application in YARN. The command will output a YARN
application ID that can be used to find your
+ application in the YARN resource manager and view its logs.
## Manage Fluo application in YARN
Except for stopping your application in YARN, the `fluo` script can be used to
manage your application using the
-`scan` and `wait` commands. See Fluo's [install instruction][install] for
more information.
+`scan` and `wait` commands. See [Fluo's application
instructions][application] for more information.
When you want you stop your Fluo application, use the the YARN resource
manager or the
`yarn application -kill <App ID>` to stop the application in YARN.
@@ -105,7 +107,8 @@ When you want you stop your Fluo application, use the the
YARN resource manager
[YARN]: http://hadoop.apache.org/
[related]: https://fluo.apache.org/related-projects/
[related]: https://fluo.apache.org/related-projects/
-[install]: https://github.com/apache/incubator-fluo/blob/master/docs/install.md
+[install]: https://github.com/apache/fluo/blob/master/docs/install.md
+[application]: https://github.com/apache/fluo/blob/master/docs/applications.md
[release]: https://fluo.apache.org/download/
[fluo-yarn-env.sh]: distribution/conf/fluo-yarn-env.sh
[fluo-yarn.properties]: distribution/conf/fluo-yarn.properties
diff --git a/distribution/bin/fluo-yarn b/distribution/bin/fluo-yarn
index 367dec4..5c78307 100755
--- a/distribution/bin/fluo-yarn
+++ b/distribution/bin/fluo-yarn
@@ -88,6 +88,11 @@ start)
print_usage
exit 1
fi
+ app_status=$($FLUO_HOME/bin/fluo status $app)
+ if [[ "$app_status" == "RUNNING" ]]; then
+ echo "Fluo appplication '$app' is already running!"
+ exit 1
+ fi
build_bundled_jar
java org.apache.fluo.yarn.core.FluoYarnLauncher "$FLUO_CONN_PROPS" "$3"
"$conf/log4j.properties" "$app" "$app_dir/$bundled_jar"
;;
--
To stop receiving notification emails like this one, please contact
['"[email protected]" <[email protected]>'].