Created
November 2, 2018 07:56
-
-
Save isopropylcyanide/4024141c623163fefd57b72008bc5a80 to your computer and use it in GitHub Desktop.
This bash script cancels all the Flink jobs that are submitted to the cluster sequentially.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
#Cancels all the flink jobs. Run in the $FLINK_DIR/bin | |
#@Author: Aman Garg | |
echo -e "Cancelling all flink jobs" | |
echo -e "*************************" | |
JOB_LIST=`./flink list | awk {'print $4'} | egrep '^\w+$'` | |
for i in $JOB_LIST | |
do | |
echo -e Cancelling $i | |
./flink cancel $i | |
done | |
echo -e "*************************" | |
echo -e "All jobs cancelled successfully" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment