jjb: lttng-tools: Add process cleaner plugin
authorMichael Jeanson <mjeanson@efficios.com>
Thu, 8 Jun 2023 20:19:01 +0000 (16:19 -0400)
committerMichael Jeanson <mjeanson@efficios.com>
Thu, 8 Jun 2023 20:20:37 +0000 (16:20 -0400)
Use the process cleaner plugin before and after jobs to clean possible
leftover processes that could interfere with the test suite.

Change-Id: I13af079244cbafde65f9c85f7c66d604fbfa2669
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
jobs/lttng-tools.yaml

index 3022fb698a06a824db064ba48c8f9df4d5a74e58..fbc4622b924f9635bc8760e96d2e76cc8dc57d0e 100644 (file)
           write-description: "<h1 style=\"color:red\">This build failed due to timeout.</h1>"
       - timestamps
       - workspace-cleanup
+      - raw: &lttng-tools_wrapper_proc-cleaner_defaults
+          xml: |
+            <org.jenkinsci.plugins.proccleaner.PreBuildCleanup plugin="proc-cleaner-plugin">
+              <cleaner class="org.jenkinsci.plugins.proccleaner.PsCleaner">
+                <killerType>org.jenkinsci.plugins.proccleaner.PsAllKiller</killerType>
+                <killer class="org.jenkinsci.plugins.proccleaner.PsAllKiller"/>
+                <switchedOff>false</switchedOff>
+                <systemProcessesFilterOff>false</systemProcessesFilterOff>
+              </cleaner>
+            </org.jenkinsci.plugins.proccleaner.PreBuildCleanup>
 
     scm:
       - git: &lttng-tools_scm_git_default
           clean-if:
             - failure: false
 
+      - raw: &lttng-tools_publisher_proc-cleaner_defaults
+          xml: |
+            <org.jenkinsci.plugins.proccleaner.PostBuildCleanup plugin="proc-cleaner-plugin">
+              <cleaner class="org.jenkinsci.plugins.proccleaner.PsCleaner">
+                <killerType>org.jenkinsci.plugins.proccleaner.PsAllKiller</killerType>
+                <killer class="org.jenkinsci.plugins.proccleaner.PsAllKiller"/>
+                <switchedOff>false</switchedOff>
+                <systemProcessesFilterOff>false</systemProcessesFilterOff>
+              </cleaner>
+            </org.jenkinsci.plugins.proccleaner.PostBuildCleanup>
+
       - ircbot: &lttng-tools_publisher_ircbot_defaults
           strategy: statechange-only
           message-type: summary
     publishers:
       - tap: *lttng-tools_publisher_tap_defaults
       - raw: *lttng-tools_publisher_warnings-ng_defaults
-      - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
       - archive: *lttng-tools_publisher_archive_defaults
+      - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
+      - raw: *lttng-tools_publisher_proc-cleaner_defaults
       - ircbot: *lttng-tools_publisher_ircbot_defaults
       - email-ext: *lttng-tools_publisher_email-ext_defaults
 
           timeout: 45
       - timestamps
       - workspace-cleanup
+      - raw: *lttng-tools_wrapper_proc-cleaner_defaults
 
     <<: *lttng-tools_matrix_axes_defaults
     <<: *lttng-tools_builders_defaults
       - raw: *lttng-tools_publisher_warnings-ng_defaults
       - archive: *lttng-tools_publisher_archive_defaults
       - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
+      - raw: *lttng-tools_publisher_proc-cleaner_defaults
 
 - job-template:
     name: dev_review_lttng-tools_{version}_smokebuild
     publishers:
       - raw: *lttng-tools_publisher_warnings-ng_defaults
       - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
+      - raw: *lttng-tools_publisher_proc-cleaner_defaults
 
 - job-template:
     name: dev_review_lttng-tools_{version}_clang-tidy
           artifacts: 'clang-tidy-fixes.diff'
           allow-empty: true
       - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
+      - raw: *lttng-tools_publisher_proc-cleaner_defaults
 
 - job-template:
     name: dev_review_lttng-tools_{version}_rootbuild
       - raw: *lttng-tools_publisher_warnings-ng_defaults
       - archive: *lttng-tools_publisher_archive_defaults
       - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
+      - raw: *lttng-tools_publisher_proc-cleaner_defaults
 
 - job-template:
     name: 'dev_review_lttng-tools_{version}_check-format'
           allow-empty: false
           fingerprint: true
       - workspace-cleanup: *lttng-tools_publisher_workspace-cleanup_defaults
+      - raw: *lttng-tools_publisher_proc-cleaner_defaults
       - ircbot: *lttng-tools_publisher_ircbot_defaults
 
 - job-template:
This page took 0.025061 seconds and 4 git commands to generate.