Add systemmetrics jobs to Jenkins
[releng/builder.git] / jjb / releng-templates-java.yaml
index 9904fa7b79fea124b0608c69afe17803bb41917c..8612c19bb579bbd4662ec0abd5936e445470071a 100644 (file)
@@ -12,9 +12,9 @@
     node: '{build-node}'
     jdk: '{jdk}'
 
-    logrotate:
-        daysToKeep: '{build-days-to-keep}'
-        numToKeep: '{build-num-to-keep}'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: '{build-days-to-keep}'
 
     parameters:
         - opendaylight-infra-parameters:
     node: '{build-node}'
     jdk: '{jdk}'
 
-    logrotate:
-        daysToKeep: '{build-days-to-keep}'
-        numToKeep: '{build-num-to-keep}'
-        artifactDaysToKeep: '{build-artifact-days-to-keep}'
-        artifactNumToKeep: '{build-artifact-num-to-keep}'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: '{build-days-to-keep}'
 
     parameters:
         - opendaylight-infra-parameters:
     #            the patch, and triggers the distribution deploy test
 
     name: '{project-name}-distribution-check-{stream}'
-    disabled: '{obj:disable_distribution_check}'
+    disabled: false
 
     project-type: freestyle
     node: '{build-node}'
     concurrent: true
     jdk: '{jdk}'
 
-    logrotate:
-        daysToKeep: '{build-days-to-keep}'
-        numToKeep: '{build-num-to-keep}'
-        artifactDaysToKeep: '{build-artifact-days-to-keep}'
-        artifactNumToKeep: '{build-artifact-num-to-keep}'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: '{build-days-to-keep}'
 
     parameters:
         - opendaylight-infra-parameters:
             branch: '{branch}'
             refspec: 'refs/heads/{branch}'
             artifacts: '{archive-artifacts} **/dependency_tree.txt **/target/surefire-reports/*-output.txt'
-        - integration-distribution-git-url
+        - integration-distribution-git-url:
+            git-url: '{git-url}'
 
     scm:
         - integration-gerrit-scm:
             build-timeout: '60'
 
     triggers:
-        - gerrit:
-            server-name: 'OpenDaylight'
-            trigger-on:
-                - patchset-created-event:
-                    exclude-drafts: 'true'
-                    exclude-trivial-rebase: 'false'
-                    exclude-no-code-change: 'true'
-                - draft-published-event
-                - comment-added-contains-event:
-                    comment-contains-value: 'redistcheck'
-                - comment-added-contains-event:
-                    comment-contains-value: 'recheck'
-            projects:
-              - project-compare-type: 'ANT'
-                project-pattern: '{project}'
-                branches:
-                  - branch-compare-type: 'ANT'
-                    branch-pattern: '**/{branch}'
-            skip-vote:
-                successful: false
-                failed: false
-                unstable: false
-                notbuilt: false
+        - gerrit-trigger-patch-submitted:
+            server: '{server-name}'
+            project: '{project}'
+            branch: '{branch}'
+            files: '**'
 
     builders:
         - maven-target:
     node: '{build-node}'
     jdk: '{jdk}'
 
-    logrotate:
-        daysToKeep: '{build-days-to-keep}'
-        numToKeep: '{build-num-to-keep}'
-        artifactDaysToKeep: '{build-artifact-days-to-keep}'
-        artifactNumToKeep: '{build-artifact-num-to-keep}'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: '{build-days-to-keep}'
 
     parameters:
         - opendaylight-infra-parameters:
     node: '{build-node}'
     jdk: '{jdk}'
 
-    logrotate:
-        daysToKeep: '14'
-        numToKeep: '10'
-        artifactDaysToKeep: '{build-artifact-days-to-keep}'
-        artifactNumToKeep: '{build-artifact-num-to-keep}'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: 14
 
     parameters:
         - opendaylight-infra-parameters:
     triggers:
         - timed: 'H H * * 0'
         - gerrit-trigger-patch-merged:
+            server-name: '{server-name}'
             name: '{project}'
             branch: '{branch}'
 
         - opendaylight-infra-shiplogs:
             maven-version: 'mvn33'
 
-- job-template:
-    name: '{project-name}-periodic-{stream}'
-
-    # Job template for periodic builders
-    #
-    # The purpose of this job template is to setup a periodic
-    # builder.
-    #
-    # Required Variables:
-    #     stream:    release stream (eg. boron or carbon)
-    #     branch:    git branch (eg. stable/boron or master)
-
-    project-type: freestyle
-    node: '{build-node}'
-    jdk: '{jdk}'
-
-    logrotate:
-        daysToKeep: '14'
-
-    parameters:
-        - opendaylight-infra-parameters:
-            project: '{project}'
-            branch: '{branch}'
-            refspec: 'refs/heads/{branch}'
-            artifacts: '{archive-artifacts}'
-
-    scm:
-        - git-scm:
-            refspec: ''
-            branch: '{branch}'
-
-    wrappers:
-        - opendaylight-infra-wrappers:
-            build-timeout: '{build-timeout}'
-
-    triggers:
-        - timed: '@daily'
-
-    builders:
-        - jacoco-nojava-workaround
-        - provide-maven-settings:
-            global-settings-file: 'odl-global-settings'
-            settings-file: '{mvn-settings}'
-        - maven-target:
-            maven-version: 'mvn33'
-            goals: '{mvn-goals} -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
-            java-opts:
-              - '{mvn-opts}'
-            settings: '{mvn-settings}'
-            settings-type: cfp
-            global-settings: 'odl-global-settings'
-            global-settings-type: cfp
-
-    publishers:
-        - email-notification:
-            email-recipients: '{email-recipients}'
-            email-prefix: '[{project-name}]'
-        - jacoco-report
-        - findbugs
-        - opendaylight-infra-shiplogs:
-            maven-version: 'mvn33'
-
 - job-template:
     name: '{project-name}-sonar'
     disabled: false
     node: '{build-node}'
     jdk: 'openjdk8'
 
-    logrotate:
-        daysToKeep: '7'
-        numToKeep: '10'
-        artifactDaysToKeep: '1'
-        artifactNumToKeep: '1'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: 7
 
     parameters:
         - opendaylight-infra-parameters:
     triggers:
         - timed: 'H H * * 6'
         - gerrit-trigger-patch-sonar:
+            server-name: '{server-name}'
             name: '{project}'
+            # FIXME: Make sure this does not alter Gerrit votes, then update docs.
 
     builders:
         - jacoco-nojava-workaround
 
 - job-template:
     name: '{project-name}-validate-autorelease-{stream}'
-    disabled: '{obj:disable_autorelease}'
+    disabled: false
 
     project-type: freestyle
     node: '{build-node}'
     concurrent: true
     jdk: '{jdk}'
 
-    logrotate:
-        daysToKeep: '7'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: 7
 
     parameters:
         - opendaylight-infra-parameters:
             release-branch: '{branch}'
         - string:
             name: CLONE_URL
-            default: 'ssh://jenkins-$SILO@git.opendaylight.org:29418/releng/autorelease'
+            default: '{git-url}/releng/autorelease'
             description: "Autorelease clone URL"
 
     scm:
             build-timeout: '{build-timeout}'
 
     triggers:
-        - gerrit:
-            server-name: 'OpenDaylight'
-            trigger-on:
-                - patchset-created-event:
-                    exclude-drafts: 'true'
-                    exclude-trivial-rebase: 'false'
-                    exclude-no-code-change: 'true'
-                - draft-published-event
-                - comment-added-contains-event:
-                    comment-contains-value: 'recheck'
-                - comment-added-contains-event:
-                    comment-contains-value: 'revalidate'
-            projects:
-              - project-compare-type: 'ANT'
-                project-pattern: '{project}'
-                branches:
-                  - branch-compare-type: 'ANT'
-                    branch-pattern: '**/{branch}'
-                file-paths:
-                    - compare-type: ANT
-                      pattern: '**/*.xml'
+        - gerrit-trigger-patch-submitted:
+            server: '{server-name}'
+            project: '{project}'
+            branch: '{branch}'
+            files: '**/*.xml'
 
     builders:
         - jacoco-nojava-workaround
     concurrent: true
     jdk: '{jdks}'
 
-    logrotate:
-        daysToKeep: '7'
+    properties:
+        - opendaylight-infra-properties:
+            build-days-to-keep: 7
 
     parameters:
         - opendaylight-infra-parameters:
 
     triggers:
         - gerrit-trigger-patch-submitted:
-            name: '{project}'
+            server: '{server-name}'
+            project: '{project}'
             branch: '{branch}'
+            files: '**'
 
     builders:
         - jacoco-nojava-workaround