Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-789

build-timeout — ver.1.3: should kill the all process tree.

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Critical Critical
    • build-timeout-plugin
    • None
    • Platform: All, OS: Linux

      Hi,

      At the moment it only kills the main process but some children can keep running
      and then the following builds won't run correctly.
      It would be great if Hudson was killing all the processes linked to the process
      killed.

      Regards,
      Fred

          [JENKINS-789] build-timeout — ver.1.3: should kill the all process tree.

          oehl added a comment -

          corrected the component and summary.

          oehl added a comment - corrected the component and summary.

          Unfortunately this is highly platform dependent and therefore difficult to do
          from Java.

          Kohsuke Kawaguchi added a comment - Unfortunately this is highly platform dependent and therefore difficult to do from Java.

          huybrechts added a comment -

          I just had a quick look at the code. ProcessTreeKiller is used in two places
          during a build, but neither of them is reached when the build is cancelled
          (manually, or through build-timeout). I think the launcher.kill() in
          AbstractBuild needs to go into a finally block so it survives an
          InterruptedException.

          huybrechts added a comment - I just had a quick look at the code. ProcessTreeKiller is used in two places during a build, but neither of them is reached when the build is cancelled (manually, or through build-timeout). I think the launcher.kill() in AbstractBuild needs to go into a finally block so it survives an InterruptedException.

          Martin Ba added a comment -

          Platform: All, OS: Linux

          Note that this works correctly on Windows. All child processes are correctly killed.

          (I add this comment because this issue, although clearly marked as OS: Linux, had me double-check the behavior of the build-timeout plugin.)

          Martin Ba added a comment - Platform: All, OS: Linux Note that this works correctly on Windows. All child processes are correctly killed. (I add this comment because this issue, although clearly marked as OS: Linux , had me double-check the behavior of the build-timeout plugin.)

          Roi Rosenthal added a comment -

          still having this issue, mainly with unit & integration testing (cargo, failsafe, surefire maven plugins using forked process).
          the issue occurs on windows

          Roi Rosenthal added a comment - still having this issue, mainly with unit & integration testing (cargo, failsafe, surefire maven plugins using forked process). the issue occurs on windows

          I have the same problem and it occurs on a CentOS.

          Giacomo Boccardo added a comment - I have the same problem and it occurs on a CentOS.

          Rick Oosterholt added a comment - - edited

          Problem for us too since we use ant to run our unit tests "forked". OS is Linux.

             <junit fork="true" ... />
          

          Rick Oosterholt added a comment - - edited Problem for us too since we use ant to run our unit tests "forked". OS is Linux. <junit fork= "true" ... />

            Unassigned Unassigned
            oehl oehl
            Votes:
            8 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated: