Revert "Add method to not trigger downstream ar-jobs"
[releng/builder.git] / jjb / autorelease / autorelease-templates.yaml
index d46ff5d96e084e47e6a24a4b35269856ac908533..42acb0f0d57fa239a6bde7b800741938554cec17 100644 (file)
@@ -12,8 +12,8 @@
     extra-mvn-opts: ''
 
     properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '30'
+      - lf-infra-properties:
+          build-days-to-keep: 7
 
     parameters:
       - maven-exec:
@@ -69,7 +69,7 @@
           goals: '-version'
           settings: 'autorelease-settings'
           settings-type: cfp
-          global-settings: 'odl-global-settings'
+          global-settings: 'global-settings'
           global-settings-type: cfp
       - wipe-local-maven-repo
       - jacoco-nojava-workaround
@@ -77,7 +77,7 @@
       - autorelease-determine-merge-order
       - autorelease-cfp:
           autorelease-settings: 'autorelease-settings'
-          odl-global-settings: 'odl-global-settings'
+          global-settings: 'odl-global-settings'
       - autorelease-generate-taglist
       - autorelease-distribute-taglist
       - distribute-build-url:
             - '-Xmx10g -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
           settings: 'autorelease-settings'
           settings-type: cfp
-          global-settings: 'odl-global-settings'
+          global-settings: 'global-settings'
           global-settings-type: cfp
       - autorelease-maven-deploy
       - autorelease-get-integration-test-variables
           opendaylight-infra-mvn-opts: '{opendaylight-infra-mvn-opts}'
           maven-version: 'mvn33'
           settings: 'autorelease-settings'
-          global-settings: 'odl-global-settings'
+          global-settings: 'global-settings'
       - autorelease-maven-sources-post-process
       - shell: |
           mkdir -p archives/
 
     publishers:
       - opendaylight-infra-notify-status
-      - opendaylight-infra-sysstats
-      - archive:
-          # Need to archive dependencies.log in Jenkins to provide a simple
-          # way for downstream jobs to pull the latest version of this file
-          # in their builds.
-          artifacts: 'dependencies.log'
       - trigger-parameterized-builds:
-          - project: 'autorelease-generate-release-notes-{stream}'
-            condition: UNSTABLE_OR_BETTER
-            property-file: variables.jenkins-trigger
-            fail-on-missing: true
           - project: 'integration-distribution-test-{integration-test}'
             condition: UNSTABLE_OR_BETTER
             property-file: variables.jenkins-trigger
           - project: 'integration-sanity-test-{integration-test}'
             condition: FAILED
             trigger-with-no-params: true
-          - project: 'packaging-build-rpm-master'
+          - project: 'packaging-build-rpm-{stream}'
+            condition: UNSTABLE_OR_BETTER
+            predefined-parameters: DOWNLOAD_URL=$BUNDLE_URL
+            property-file: variables.jenkins-trigger
+            fail-on-missing: true
+          - project: 'packaging-build-deb-{stream}'
             condition: UNSTABLE_OR_BETTER
             predefined-parameters: DOWNLOAD_URL=$BUNDLE_URL
             property-file: variables.jenkins-trigger
             fail-on-missing: true
       - lf-infra-publish
 
+- job-template:
+    name: autorelease-update-validate-jobs-{stream}
+    project-type: freestyle
+    node: centos7-java-builder-2c-4g
+
+    properties:
+      - lf-infra-properties:
+          build-days-to-keep: 7
+
+    parameters:
+      - lf-infra-parameters:
+          project: releng/builder
+          branch: '{branch}'
+          stream: '{stream}'
+
+    scm:
+      - lf-infra-gerrit-scm:
+          git-url: '$GIT_URL/releng/builder'
+          branch: master
+          refspec: 'refs/heads/master'
+          jenkins-ssh-credential: opendaylight-jenkins-ssh
+          submodule-recursive: true
+          choosing-strategy: default
+
+    triggers:
+      - gerrit:
+          server-name: '{gerrit-server-name}'
+          trigger-on:
+            - change-merged-event
+            - comment-added-contains-event:
+                comment-contains-value: remerge$
+          projects:
+            - project-compare-type: ANT
+              project-pattern: '{project}'
+              branches:
+                - branch-compare-type: ANT
+                  branch-pattern: '**/{branch}'
+              file-paths:
+                - compare-type: ANT
+                  pattern: pom.xml
+
+    wrappers:
+      - lf-infra-wrappers:
+          build-timeout: 10
+          jenkins-ssh-credential: opendaylight-jenkins-ssh
+
+    builders:
+      - shell: !include-raw-escape:
+          - update-validate-autorelease-projects.sh
+      - opendaylight-infra-push-gerrit-patch:
+          project: 'releng/builder'
+          gerrit-topic: 'autorelease-update-validate-jobs-{stream}'
+          gerrit-commit-message: |
+              Update validate autorelease projects for {stream}
+
+    publishers:
+      - lf-infra-publish
+
 - job-template:
     name: autorelease-version-bump-{stream}
     project-type: freestyle
       - lf-infra-parameters:
           project: releng/autorelease
           branch: '{branch}'
+          stream: '{stream}'
           refspec: 'refs/heads/{branch}'
       - string:
           name: RELEASE_TAG
 
     scm:
       - lf-infra-gerrit-scm:
+          git-url: '$GIT_URL/$GERRIT_PROJECT'
           branch: '{branch}'
           refspec: 'refs/heads/{branch}'
           jenkins-ssh-credential: opendaylight-jenkins-ssh
           goals: '-version'
           settings: autorelease-settings
           settings-type: cfp
-          global-settings: odl-global-settings
+          global-settings: global-settings
           global-settings-type: cfp
       - autorelease-cfp
       - shell: !include-raw-escape:
           - version-bump.sh
 
     publishers:
+      - trigger-parameterized-builds:
+          - project: 'autorelease-generate-release-notes-{stream}'
+            condition: UNSTABLE_OR_BETTER
+            trigger-with-no-params: true
       - lf-infra-publish
 
 - job-template:
     name: 'autorelease-generate-release-notes-{stream}'
 
     project-type: freestyle
-    node: centos7-java-builder-2c-8g
+    node: centos7-java-builder-2c-4g
 
     properties:
-      - opendaylight-infra-properties:
-          build-days-to-keep: '{build-days-to-keep}'
+      - lf-infra-properties:
+          build-days-to-keep: 7
 
     parameters:
-      - opendaylight-infra-parameters:
-          os-cloud: '{os-cloud}'
+      - lf-infra-parameters:
           project: '{project}'
           branch: '{branch}'
-          refspec: 'refs/heads/{branch}'
-          artifacts: '{archive-artifacts}'
+          stream: '{stream}'
 
     scm:
-      - git:
-          credentials-id: 'opendaylight-jenkins-ssh'
-          url: '$GIT_BASE'
-          refspec: '$GERRIT_REFSPEC'
-          branches:
-            - '$GERRIT_BRANCH'
-          choosing-strategy: 'gerrit'
-          skip-tag: true
-          submodule:
-            recursive: true
+      - lf-infra-gerrit-scm:
+          git-url: '$GIT_URL/$GERRIT_PROJECT'
+          branch: '{branch}'
+          refspec: 'refs/heads/{branch}'
+          jenkins-ssh-credential: opendaylight-jenkins-ssh
+          submodule-recursive: true
+          choosing-strategy: default
 
     wrappers:
-      - opendaylight-infra-wrappers:
-          build-timeout: '30'
+      - lf-infra-wrappers:
+          build-timeout: 10
+          jenkins-ssh-credential: opendaylight-jenkins-ssh
 
     triggers:
       - timed: '0 0 * * 0'
 
     builders:
-      # force jenkins install of maven version before any shell scripts use it
-      - maven-target:
-          maven-version: 'mvn33'
-          goals: '-version'
-          settings: 'autorelease-settings'
-          settings-type: cfp
-          global-settings: 'odl-global-settings'
-          global-settings-type: cfp
+      - lf-maven-install:
+          mvn-version: mvn33
       - maven-target:
-          maven-version: 'mvn33'
+          maven-version: mvn33
           pom: '$WORKSPACE/scripts/release_notes_management/pom.xml'
           goals: |
               clean package
-              -Dcheckstyle.skip=true
-              -DaltDeploymentRepository=staging::default::file:hide/from/pom/files/stage
               {opendaylight-infra-mvn-opts}
-          java-opts:
-            - '-Xmx10g -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
-          settings: 'autorelease-settings'
+          settings: autorelease-settings
           settings-type: cfp
-          global-settings: 'odl-global-settings'
+          global-settings: global-settings
           global-settings-type: cfp
       - autorelease-generate-release-notes
 
     publishers:
-      - opendaylight-infra-sysstats
       - lf-infra-publish