Skip to content

Commit a8405dd

Browse files
DSP-5892-2: Make kill process tree executable
DSE will start spark-submit from within another script to we only end up reporting the process number of the spawning script. To fix this we can kill the entire process group.
1 parent c6b2262 commit a8405dd

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

bin/kill-process-tree.sh

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ parent=$2
1616
signal=$1
1717

1818
# A string which will be populated with descendant processes ids
19-
pids=""
19+
pids="$parent"
2020

2121
# Kills the given process if it is running. It also checks whether the given parameter contains process ID
2222
function kill_if_running() {

bin/server_stop.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ if [ ! -f "$pidFilePath" ] || ! kill -0 "$(cat "$pidFilePath")"; then
2424
else
2525
echo 'Stopping job server...'
2626
PID="$(cat "$pidFilePath")"
27-
"$(dirname "$0")"/kill-process-tree.sh -2 $PID
27+
"$(dirname "$0")"/kill-process-tree.sh 15 $PID && rm "$pidFilePath"
2828
echo '...job server stopped'
2929
fi
3030

version.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
version in ThisBuild := "0.5.2.DSP-5892-2-SNAPSHOT"
1+
version in ThisBuild := "0.5.1.155"

0 commit comments

Comments
 (0)