Repository: sqoop Updated Branches: refs/heads/sqoop2 051207da9 -> d82e9d302
SQOOP-2604. Sqoop2: Add "run" mode to sqoop2-server script (Jarcec via Hari) Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/d82e9d30 Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/d82e9d30 Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/d82e9d30 Branch: refs/heads/sqoop2 Commit: d82e9d30255dd9860ebe0c2aee1ec29b46c53bb1 Parents: 051207d Author: Hari Shreedharan <[email protected]> Authored: Thu Oct 8 15:37:23 2015 -0700 Committer: Hari Shreedharan <[email protected]> Committed: Thu Oct 8 15:37:23 2015 -0700 ---------------------------------------------------------------------- dist/src/main/bin/sqoop.sh | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/sqoop/blob/d82e9d30/dist/src/main/bin/sqoop.sh ---------------------------------------------------------------------- diff --git a/dist/src/main/bin/sqoop.sh b/dist/src/main/bin/sqoop.sh index 71994bd..3b2c6e1 100755 --- a/dist/src/main/bin/sqoop.sh +++ b/dist/src/main/bin/sqoop.sh @@ -18,9 +18,9 @@ function print_usage(){ echo "Usage: sqoop.sh COMMAND" echo " where COMMAND is one of:" - echo " server <start/stop> Start/stop the server" - echo " client [script] Start an interactive shell without a script" - echo " or run a script with a batch shell" + echo " server <start/stop/run> Start/stop the server (or run it in the foreground)" + echo " client [script] Start an interactive shell without a script" + echo " or run a script with a batch shell" echo "" } @@ -179,6 +179,12 @@ case $COMMAND in source ${BASEDIR}/bin/sqoop-sys.sh case $2 in + run) + # For running in the foreground, we're not doing any checks if we're running or not and simply start the server) + sqoop_server_classpath_set + echo "Starting the Sqoop2 server..." + exec ${EXEC_JAVA} $JAVA_OPTS -classpath ${CLASSPATH} org.apache.sqoop.server.SqoopJettyServer + ;; start) # check if the sqoop server started already. is_sqoop_server_running
