svn commit: r1799852 - /ofbiz/ofbiz-framework/trunk/build.gradle

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r1799852 - /ofbiz/ofbiz-framework/trunk/build.gradle

jleroux@apache.org
Author: jleroux
Date: Mon Jun 26 06:03:35 2017
New Revision: 1799852

URL: http://svn.apache.org/viewvc?rev=1799852&view=rev
Log:
Reverts r1799736

Taher pointed out in dev ML that kill is not an atomic operation.
So the previous behaviour does not change. In most cases SIGKILL is still the
action which kills the process before SIGTERM has a chance to terminate it.

Modified:
    ofbiz/ofbiz-framework/trunk/build.gradle

Modified: ofbiz/ofbiz-framework/trunk/build.gradle
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/build.gradle?rev=1799852&r1=1799851&r2=1799852&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/build.gradle (original)
+++ ofbiz/ofbiz-framework/trunk/build.gradle Mon Jun 26 06:03:35 2017
@@ -332,13 +332,8 @@ task terminateOfbiz(group: ofbizServer,
                 standardOutput = processOutput
             }
             processOutput.toString().split(System.lineSeparator()).each { line ->
-                // Try to terminate cleanly
                 if (line ==~ /.*org\.apache\.ofbiz\.base\.start\.Start.*/) {
-                    exec { commandLine 'kill', '-TERM', line.tokenize().first() }
-                }
-                // Only kill if needed
-                if (line ==~ /.*org\.apache\.ofbiz\.base\.start\.Start.*/) {
-                    exec { commandLine 'kill', '-KILL', line.tokenize().first() }
+                    exec { commandLine 'kill', '-9', line.tokenize().first() }
                 }
             }
         }