de3123b6c3ae617d585b34e853823dffcf3ee6b7
[releng/builder.git] / jjb / netvirt / netvirt.yaml
1 # REMOVE THIS LINE IF YOU WANT TO CUSTOMIZE ANYTHING BELOW
2 # Otherwise this file will be automatically overwritten by the template
3 # autobuilder.
4
5 # ODL Releng build templates
6 - project:
7     name: netvirt
8     jobs:
9         - 'netvirt-verify-{stream}'
10         - 'netvirt-merge-{stream}'
11         - 'netvirt-periodic-{stream}'
12         - 'netvirt-distribution-{stream}'
13         - 'netvirt-distribution-check-{stream}'
14         - 'netvirt-integration-{stream}'
15         - 'netvirt-clm-{stream}'
16         - 'netvirt-validate-autorelease-{stream}'
17
18
19     # stream:    release stream (eg. stable-lithium or beryllium)
20     # branch:    git branch (eg. stable/lithium or master)
21     stream:
22         - boron:
23             branch: 'master'
24             jdk: openjdk8
25             jdks:
26                 - openjdk8
27             disable_autorelease: False
28             disable_distribution_check: False
29         - beryllium:
30             branch: 'stable/beryllium'
31             jdk: openjdk7
32             jdks:
33                 - openjdk7
34                 - openjdk8
35             disable_autorelease: False
36             disable_distribution_check: False
37
38     project: 'netvirt'
39
40 # For the Job templates below replace instances of:
41 # PROJECT_SHORTNAME with your project name (eg. circuitsw)
42 # PROJECT_PATH with your project name (eg. ofextensions/circuitsw)
43 # MAVEN_GOALS with your maven goals to build
44 # MAVEN_OPTS with your maven options to build
45
46 - job-template:
47     name: 'netvirt-verify-{stream}'
48
49     # Job template for ODL verify jobs
50     #
51     # The purpose of this job template is to setup a ODL verify job
52     #
53     # Required Variables:
54     #     stream:    release stream (eg. stable-lithium or beryllium)
55     #     branch:    git branch (eg. stable/lithium or master)
56
57     project-type: matrix
58     node: matrix_master
59     concurrent: true
60
61     axes:
62         - axis:
63             type: slave
64             name: nodes
65             values:
66                 - dynamic_verify
67         - axis:
68             type: jdk
69             values: '{obj:jdks}'
70
71     logrotate:
72         daysToKeep: '{build-days-to-keep}'
73         numToKeep: '{build-num-to-keep}'
74         artifactDaysToKeep: '{build-artifact-days-to-keep}'
75         artifactNumToKeep: '{build-artifact-num-to-keep}'
76
77     parameters:
78         - project-parameter:
79             project: '{project}'
80         - gerrit-parameters:
81             project: '{project}'
82             branch: '{branch}'
83             refspec: 'refs/heads/{branch}'
84
85     scm:
86         - gerrit-trigger-scm:
87             credentials-id: '{ssh-credentials}'
88             refspec: '$GERRIT_REFSPEC'
89             choosing-strategy: 'gerrit'
90
91     wrappers:
92         - build-timeout
93         - ssh-agent-credentials:
94             users:
95                 - '{ssh-credentials}'
96
97     triggers:
98         - gerrit-trigger-patch-submitted:
99             name: 'netvirt'
100             branch: '{branch}'
101
102     builders:
103         - wipe-org-opendaylight-repo
104         - jacoco-nojava-workaround
105         - provide-maven-settings:
106             global-settings-file: 'odl-global-settings'
107             settings-file: 'netvirt-settings'
108         - maven-target:
109             maven-version: '{mvn33}'
110             pom: 'pom.xml'
111             goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins -Dstream={stream}'
112             java-opts:
113                 - '-Xmx1024m -XX:MaxPermSize=256m'
114             settings: 'netvirt-settings'
115             settings-type: cfp
116             global-settings: 'odl-global-settings'
117             global-settings-type: cfp
118
119     publishers:
120         - archive-artifacts:
121             artifacts: '**/target/surefire-reports/*-output.txt, '
122         - findbugs
123         - email-notification:
124             email-prefix: '[netvirt]'
125         - jacoco-report
126         - archive-build:
127             maven-version: '{mvn33}'
128
129 - job-template:
130     name: 'netvirt-merge-{stream}'
131
132     # Job template for ODL merge jobs
133     #
134     # The purpose of this job template is to setup a ODL merge job
135     # and deploy artifacts to Nexus.
136     #
137     # Required Variables:
138     #     stream:    release stream (eg. stable-lithium or beryllium)
139     #     branch:    git branch (eg. stable/lithium or master)
140
141     project-type: maven
142     node: dynamic_merge
143     jdk: '{jdk}'
144
145     logrotate:
146         daysToKeep: '14'
147         numToKeep: '10'
148         artifactDaysToKeep: '{build-artifact-days-to-keep}'
149         artifactNumToKeep: '{build-artifact-num-to-keep}'
150
151     parameters:
152         - project-parameter:
153             project: '{project}'
154         - gerrit-parameters:
155             project: '{project}'
156             branch: '{branch}'
157             refspec: 'refs/heads/{branch}'
158
159     scm:
160         - gerrit-trigger-scm:
161             credentials-id: '{ssh-credentials}'
162             refspec: ''
163             choosing-strategy: 'default'
164
165     wrappers:
166         - build-timeout
167         - ssh-agent-credentials:
168             users:
169                 - '{ssh-credentials}'
170
171     triggers:
172         - timed: 'H H * * 0'
173         - gerrit-trigger-patch-merged:
174             name: 'netvirt'
175             branch: '{branch}'
176
177     prebuilders:
178         - wipe-org-opendaylight-repo
179         - jacoco-nojava-workaround
180         - provide-maven-settings:
181             global-settings-file: 'odl-global-settings'
182             settings-file: 'netvirt-settings'
183
184     maven:
185         maven-name: '{mvn33}'
186         root-pom: 'pom.xml'
187         goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins -Dmerge -Dstream={stream}'
188         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m'
189         settings: 'netvirt-settings'
190         settings-type: cfp
191         global-settings: 'odl-global-settings'
192         global-settings-type: cfp
193         post-step-run-condition: UNSTABLE
194
195     postbuilders:
196         - conditional-step:
197             condition-kind: file-exists
198             condition-filename: deploy-site.xml
199             condition-basedir: workspace
200
201             # The strategy here is intentional to run Maven site:deploy twice
202             # once using regular pom.xml to produce a staged-site which is
203             # then used by deploy-site.xml to push to Nexus. This is a
204             # workaround to Maven Site's default linking code which creates
205             # incorrect URLs for sites due to auto-detection assuming your
206             # project is configured in a certain way which ODL is not.
207             steps:
208             - maven-target:
209                 maven-version: '{mvn33}'
210                 pom: pom.xml
211                 goals: 'site:deploy -V -B -Dstream={stream}'
212                 java-opts:
213                     - '-Xmx2g'
214                 settings: 'netvirt-settings'
215                 settings-type: cfp
216                 global-settings: 'odl-global-settings'
217                 global-settings-type: cfp
218             - maven-target:
219                 maven-version: '{mvn33}'
220                 pom: deploy-site.xml
221                 goals: 'site:deploy -V -B -Dstream={stream}'
222                 java-opts:
223                     - '-Xmx2g'
224                 settings: 'netvirt-settings'
225                 settings-type: cfp
226                 global-settings: 'odl-global-settings'
227                 global-settings-type: cfp
228
229     reporters:
230         - findbugs
231
232     publishers:
233         - archive-artifacts:
234             artifacts: '**/target/surefire-reports/*-output.txt, '
235         - email-notification:
236             email-prefix: '[netvirt]'
237         - maven-deploy:
238             id: ''
239             unique-version: true
240             deploy-unstable: false
241         - jacoco-report
242         - archive-build:
243             maven-version: '{mvn33}'
244
245 - job-template:
246     name: 'netvirt-periodic-{stream}'
247     disabled: false
248
249     # Job template for periodic builders
250     #
251     # The purpose of this job template is to setup a periodic
252     # builder.
253     #
254     # Required Variables:
255     #     stream:    release stream (eg. stable-lithium or beryllium)
256     #     branch:    git branch (eg. stable/lithium or master)
257
258     project-type: maven
259     node: dynamic_verify
260     jdk: '{jdk}'
261
262     logrotate:
263         daysToKeep: '14'
264         numToKeep: '10'
265         artifactDaysToKeep: '{build-artifact-days-to-keep}'
266         artifactNumToKeep: '{build-artifact-num-to-keep}'
267
268     parameters:
269         - project-parameter:
270             project: '{project}'
271
272     scm:
273         - git-scm:
274             credentials-id: '{ssh-credentials}'
275             refspec: ''
276             branch: '{branch}'
277
278     wrappers:
279         - build-timeout
280         - ssh-agent-credentials:
281             users:
282                 - '{ssh-credentials}'
283
284     triggers:
285         - timed: '@daily'
286
287     prebuilders:
288         - wipe-org-opendaylight-repo
289         - jacoco-nojava-workaround
290         - provide-maven-settings:
291             global-settings-file: 'odl-global-settings'
292             settings-file: 'netvirt-settings'
293
294     maven:
295         maven-name: '{mvn33}'
296         root-pom: 'pom.xml'
297         goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins'
298         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m'
299         settings: 'netvirt-settings'
300         settings-type: cfp
301         global-settings: 'odl-global-settings'
302         global-settings-type: cfp
303
304     reporters:
305         - findbugs
306
307     publishers:
308         - email-notification:
309             email-prefix: '[netvirt]'
310         - jacoco-report
311         - archive-build:
312             maven-version: '{mvn33}'
313
314 - job-template:
315     name: 'netvirt-distribution-{stream}'
316
317     # Required variables:
318     #     stream:    release stream (eg. stable-lithium or beryllium)
319     #     branch:    git branch (eg. stable/lithium or master)
320
321     project-type: maven
322     node: dynamic_merge
323     jdk: '{jdk}'
324
325     logrotate:
326         daysToKeep: '{build-days-to-keep}'
327         numToKeep: '{build-num-to-keep}'
328         artifactDaysToKeep: '{build-artifact-days-to-keep}'
329         artifactNumToKeep: '{build-artifact-num-to-keep}'
330
331     parameters:
332         - project-parameter:
333             project: 'integration/distribution'
334
335     scm:
336         - git-scm:
337             credentials-id: '{ssh-credentials}'
338             refspec: ''
339             branch: '{branch}'
340
341     wrappers:
342         - build-timeout
343         - ssh-agent-credentials:
344             users:
345                 - '{ssh-credentials}'
346
347     triggers:
348         - reverse:
349             jobs: '{project}-merge-{stream}'
350             result: 'success'
351
352     prebuilders:
353         - wipe-org-opendaylight-repo
354         - provide-maven-settings:
355             global-settings-file: 'odl-global-settings'
356             settings-file: 'netvirt-settings'
357
358     maven:
359         maven-name: '{mvn33}'
360         root-pom: 'pom.xml'
361         goals: 'clean install -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
362         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
363         settings: 'integration-distribution-settings'
364         settings-type: cfp
365         global-settings: 'odl-global-settings'
366         global-settings-type: cfp
367
368     publishers:
369         - email-notification:
370             email-prefix: '[{project}]'
371         - maven-deploy:
372             id: ''
373             unique-version: true
374             deploy-unstable: false
375         - archive-build:
376             maven-version: '{mvn33}'
377
378 # Template: integration-patch-distribution-{stream}
379 # Goal: Build a patch and make sure the distribution can deploy with this change
380 # Operation: This job template builds a patch, creates a distribution containing
381 #            the patch, and triggers the distribution deploy test
382
383 - job-template:
384     name: 'netvirt-distribution-check-{stream}'
385     disabled: '{obj:disable_distribution_check}'
386
387     project-type: maven
388     node: dynamic_verify
389     concurrent: true
390     jdk: '{jdk}'
391
392     logrotate:
393         daysToKeep: '{build-days-to-keep}'
394         numToKeep: '{build-num-to-keep}'
395         artifactDaysToKeep: '{build-artifact-days-to-keep}'
396         artifactNumToKeep: '{build-artifact-num-to-keep}'
397
398     parameters:
399         - gerrit-parameters:
400             project: '{project}'
401             branch: '{branch}'
402             refspec: 'refs/heads/{branch}'
403         - project-parameter:
404             project: '{project}'
405         - integration-distribution-git-url
406
407     scm:
408         - integration-gerrit-scm:
409             credentials-id: '{ssh-credentials}'
410             basedir: '$GERRIT_PROJECT'
411             refspec: '$GERRIT_REFSPEC'
412             branch: '{branch}'
413         - integration-distribution-scm:
414             credentials-id: '{ssh-credentials}'
415             branch: '{branch}'
416
417     wrappers:
418         - build-timeout
419         - ssh-agent-credentials:
420             users:
421                 - '{ssh-credentials}'
422
423     triggers:
424         - gerrit:
425             server-name: 'OpenDaylight'
426             trigger-on:
427                 - patchset-created-event:
428                     exclude-drafts: 'true'
429                     exclude-trivial-rebase: 'false'
430                     exclude-no-code-change: 'true'
431                 - draft-published-event
432                 - comment-added-contains-event:
433                     comment-contains-value: 'test-distribution'
434                 - comment-added-contains-event:
435                     comment-contains-value: 'reverify'
436                 - comment-added-contains-event:
437                     comment-contains-value: 'recheck'
438             projects:
439               - project-compare-type: 'ANT'
440                 project-pattern: '{name}'
441                 branches:
442                   - branch-compare-type: 'ANT'
443                     branch-pattern: '**/{branch}'
444             skip-vote:
445                 successful: false
446                 failed: false
447                 unstable: false
448                 notbuilt: false
449
450     prebuilders:
451         - wipe-org-opendaylight-repo
452         - maven-target:
453             maven-version: '{mvn33}'
454             pom: '$GERRIT_PROJECT/pom.xml'
455             goals: 'clean install -V -B -Djenkins -DskipTests -Dcheckstyle.skip=true -Dmaven.javadoc.skip=true -Dmaven.site.skip=true -DgenerateReports=false -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dstream={stream}'
456             java-opts:
457                 - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
458             settings: 'netvirt-settings'
459             settings-type: cfp
460             global-settings: 'odl-global-settings'
461             global-settings-type: cfp
462
463     maven:
464         maven-name: '{mvn33}'
465         root-pom: 'distribution/pom.xml'
466         goals: 'clean install -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
467         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
468         settings: 'netvirt-settings'
469         settings-type: cfp
470         global-settings: 'odl-global-settings'
471         global-settings-type: cfp
472         ignore-upstream-changes: true
473         post-step-run-condition: 'SUCCESS'
474
475     postbuilders:
476         - integration-distribution-check
477
478     publishers:
479         - archive:
480             artifacts: 'karaf.log'
481         - archive:
482             artifacts: 'karaf_console.log'
483         - email-notification:
484             email-prefix: '[netvirt]'
485         - archive-build:
486             maven-version: '{mvn33}'
487
488 - job-template:
489     name: 'netvirt-integration-{stream}'
490     disabled: false
491
492     # Job template for ODL integration verify jobs
493     #
494     # This is similar to a normal verify job, but it runs
495     # when a project that's a dependency of your project
496     # is successfully built.
497     #
498     # Required Variables:
499     #     stream:    release stream (eg. stable-lithium or beryllium)
500     #     branch:    git branch (eg. stable/lithium or master)
501
502     project-type: maven
503     node: dynamic_merge
504     jdk: '{jdk}'
505
506     logrotate:
507         daysToKeep: '{build-days-to-keep}'
508         numToKeep: '{build-num-to-keep}'
509         artifactDaysToKeep: '{build-artifact-days-to-keep}'
510         artifactNumToKeep: '{build-artifact-num-to-keep}'
511
512     parameters:
513         - project-parameter:
514             project: '{project}'
515
516     scm:
517         - git-scm:
518             credentials-id: '{ssh-credentials}'
519             refspec: ''
520             branch: '{branch}'
521
522     wrappers:
523         - build-timeout
524         - ssh-agent-credentials:
525             users:
526                 - '{ssh-credentials}'
527
528     triggers:
529         - reverse:
530             jobs: 'controller-merge-{stream},neutron-merge-{stream},odlparent-merge-{stream},openflowjava-merge-{stream},openflowplugin-merge-{stream},ovsdb-merge-{stream},sfc-merge-{stream},yangtools-merge-{stream}'
531             result: 'success'
532
533     prebuilders:
534         - wipe-org-opendaylight-repo
535         - jacoco-nojava-workaround
536         - provide-maven-settings:
537             global-settings-file: 'odl-global-settings'
538             settings-file: 'netvirt-settings'
539
540     maven:
541         maven-name: '{mvn33}'
542         root-pom: 'pom.xml'
543         goals: 'clean install -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r  -V -B -Djenkins'
544         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m'
545         settings: 'netvirt-settings'
546         settings-type: cfp
547         global-settings: 'odl-global-settings'
548         global-settings-type: cfp
549
550     reporters:
551         - findbugs
552
553     publishers:
554         - email-notification:
555             email-prefix: '[netvirt] [controller] [neutron] [odlparent] [openflowjava] [openflowplugin] [ovsdb] [sfc] [yangtools]'
556         - jacoco-report
557         - archive-build:
558             maven-version: '{mvn33}'
559
560 - job-template:
561     name: 'netvirt-clm-{stream}'
562     disabled: false
563
564     project-type: maven
565     node: dynamic_verify
566     jdk: '{jdk}'
567
568     logrotate:
569         daysToKeep: '{build-days-to-keep}'
570         numToKeep: '{build-num-to-keep}'
571         artifactDaysToKeep: '{build-artifact-days-to-keep}'
572         artifactNumToKeep: '{build-artifact-num-to-keep}'
573
574     parameters:
575         - project-parameter:
576             project: '{project}'
577
578     scm:
579         - git-scm:
580             credentials-id: '{ssh-credentials}'
581             refspec: ''
582             branch: '{branch}'
583
584     wrappers:
585         - build-timeout
586         - ssh-agent-credentials:
587             users:
588                 - '{ssh-credentials}'
589
590     triggers:
591         - timed: 'H H * * 6'
592
593     prebuilders:
594         - wipe-org-opendaylight-repo
595         - provide-maven-settings:
596             global-settings-file: 'odl-global-settings'
597             settings-file: 'netvirt-settings'
598
599     maven:
600         maven-name: '{mvn33}'
601         root-pom: 'pom.xml'
602         goals: 'clean install com.sonatype.clm:clm-maven-plugin:index -V -B -Djenkins -DskipTests=true -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
603         maven-opts: '-Xmx4096m -XX:MaxPermSize=512m'
604         settings: 'netvirt-settings'
605         settings-type: cfp
606         global-settings: 'odl-global-settings'
607         global-settings-type: cfp
608
609     postbuilders:
610         - shell: 'find . -regex ".*karaf/target" | xargs rm -rf'
611         - check-clm:
612             application-name: netvirt
613
614     publishers:
615         - email-notification:
616             email-prefix: '[netvirt]'
617         - archive-build:
618             maven-version: '{mvn33}'
619
620 - job-template:
621     name: 'netvirt-validate-autorelease-{stream}'
622     disabled: '{obj:disable_autorelease}'
623
624     project-type: maven
625     node: dynamic_verify
626     concurrent: true
627     jdk: '{jdk}'
628
629     logrotate:
630         daysToKeep: '{build-days-to-keep}'
631         numToKeep: '{build-num-to-keep}'
632         artifactDaysToKeep: '{build-artifact-days-to-keep}'
633         artifactNumToKeep: '{build-artifact-num-to-keep}'
634
635     parameters:
636         - project-parameter:
637             project: '{project}'
638         - gerrit-parameters:
639             project: '{project}'
640             branch: '{branch}'
641             refspec: 'refs/heads/{branch}'
642         - autorelease-release-tag:
643             release-tag: 'validate'
644         - autorelease-release-branch:
645             release-branch: '{branch}'
646         - string:
647             name: CLONE_URL
648             default: 'ssh://jenkins-$SILO@git.opendaylight.org:29418/releng/autorelease'
649             description: "Autorelease clone URL"
650
651     scm:
652         - git:
653             url: '$CLONE_URL'
654             credentials-id: '{ssh-credentials}'
655             refspec: ''
656             branches:
657                 - 'origin/{branch}'
658             skip-tag: true
659             submodule:
660                 recursive: true
661                 timeout: 60
662
663     wrappers:
664         - autorelease-build-timeout
665         - ssh-agent-credentials:
666             users:
667                 - '{ssh-credentials}'
668
669     triggers:
670         - gerrit:
671             server-name: 'OpenDaylight'
672             trigger-on:
673                 - patchset-created-event:
674                     exclude-drafts: 'true'
675                     exclude-trivial-rebase: 'false'
676                     exclude-no-code-change: 'true'
677                 - draft-published-event
678                 - comment-added-contains-event:
679                     comment-contains-value: 'recheck'
680                 - comment-added-contains-event:
681                     comment-contains-value: 'reverify'
682                 - comment-added-contains-event:
683                     comment-contains-value: 'revalidate'
684             projects:
685               - project-compare-type: 'ANT'
686                 project-pattern: 'netvirt'
687                 branches:
688                   - branch-compare-type: 'ANT'
689                     branch-pattern: '**/{branch}'
690                 file-paths:
691                     - compare-type: ANT
692                       pattern: '**/*.xml'
693
694     prebuilders:
695         - wipe-org-opendaylight-repo
696         - jacoco-nojava-workaround
697         - autorelease-checkout-gerrit-patch
698         - autorelease-generate-release-patches
699         - maven-target:
700             maven-version: '{mvn33}'
701             pom: validate-pom.xml
702             goals: 'clean install -V -B -T1.5C -Djenkins -DskipTests -Dcheckstyle.skip=true -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
703             java-opts:
704             - '-Xmx8g'
705             settings: 'autorelease-settings'
706             settings-type: cfp
707             global-settings: 'odl-global-settings'
708             global-settings-type: cfp
709
710     maven:
711         maven-name: '{mvn33}'
712         root-pom: 'pom.xml'
713         goals: 'clean validate -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
714         maven-opts: '-Xmx8g -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
715         settings: 'autorelease-settings'
716         settings-type: cfp
717         global-settings: 'odl-global-settings'
718         global-settings-type: cfp
719         automatic-archiving: false
720         post-step-run-condition: UNSTABLE
721
722     postbuilders:
723         - autorelease-sys-stats
724
725     publishers:
726         - email-notification:
727             email-prefix: '[autorelease] [netvirt]'
728         - archive-build:
729             maven-version: '{mvn33}'
730