Fix: JaCoCo exclude patterns format
[releng/builder.git] / jjb / integration / distribution / distribution-templates.yaml
1 ---
2 - job-template:
3     name: "{project-name}-distribution-check-{stream}"
4
5     ######################
6     # Default parameters #
7     ######################
8
9     mvn-version: mvn38
10     csit-gate-list: ""
11     block_on_csit: false
12     # Unless block_on_csit is true, the failure-threshold will be ignored. For project jobs that
13     # want to fail distribution check on csit jobs, they will only need a list of jobs to run
14     # plus the change of block_on_csit to true, and this failure-threshold: 'UNSTABLE' will take
15     # effect
16     failure-threshold: "UNSTABLE"
17     disable-job: false
18
19     #####################
20     # Job Configuration #
21     #####################
22
23     # Operation: This job template builds a patch, creates a distribution containing
24     #            the patch (making sure dependencies are specified),
25     #            and performs the distribution deploy test.
26     disabled: "{disable-job}"
27
28     project-type: freestyle
29     node: "centos8-builder-8c-8g"
30     concurrent: true
31
32     properties:
33       - opendaylight-infra-properties:
34           build-days-to-keep: "{build-days-to-keep}"
35
36     parameters:
37       - opendaylight-infra-parameters:
38           os-cloud: "{os-cloud}"
39           project: "{project}"
40           branch: "{branch}"
41           refspec: "refs/heads/{branch}"
42           artifacts: "{archive-artifacts}"
43       - integration-distribution-stream:
44           stream: "{stream}"
45       - integration-distribution-git-url:
46           git-url: "{git-url}"
47       - distribution-karaf-version:
48           karaf-version: "{karaf-version}"
49       - maven-exec:
50           maven-version: "{mvn-version}"
51
52     scm:
53       - integration-gerrit-scm:
54           basedir: "$GERRIT_PROJECT"
55           refspec: "$GERRIT_REFSPEC"
56           branch: "{branch}"
57       - integration-distribution-scm:
58           branch: "{distribution_branch}"
59
60     wrappers:
61       - opendaylight-infra-wrappers:
62           # Distro-check jobs typically run within 10 - 30 minutes
63           # with 45 minutes being the occassional edge case.
64           # enforce a 60 minute limit to ensure stuck jobs get
65           # cleared up sooner.
66           # Double that as Karaf 3+4 may take longer.
67           build-timeout: "120"
68
69     triggers:
70       - gerrit-trigger-patch-submitted:
71           gerrit-server-name: "{gerrit-server-name}"
72           project: "{project}"
73           branch: "{branch}"
74           files: "**"
75           forbidden-files: ""
76
77     builders:
78       - distribution-check-wipe
79       - lf-update-java-alternatives:
80           java-version: "{java-version}"
81       - inject:
82           properties-file: "allowed_projects.txt"
83       - distribution-check-build-project:
84           pom: "$GERRIT_PROJECT/pom.xml"
85           mvn-opts: "{opendaylight-infra-mvn-opts}"
86           mvn-version: "{mvn-version}"
87           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
88       - distribution-check-verify-groupid:
89           gerrit-project: "$GERRIT_PROJECT"
90       - distribution-check-download-deps:
91           dist-pom: "distribution/pom.xml"
92           mvn-opts: "{opendaylight-infra-mvn-opts}"
93           mvn-version: "{mvn-version}"
94           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
95       - distribution-check-delete-snapshots
96       - distribution-check-configure-remotes
97       - distribution-check-repeat-project-build:
98           pom: "$GERRIT_PROJECT/pom.xml"
99           mvn-opts: "{opendaylight-infra-mvn-opts}"
100           mvn-version: "{mvn-version}"
101           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
102       - distribution-check-repeat-distro-build:
103           dist-pom: "distribution/pom.xml"
104           mvn-opts: "{opendaylight-infra-mvn-opts}"
105           mvn-version: "{mvn-version}"
106           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
107       - integration-set-variables
108       - distribution-check-warn-9191
109       - distribution-check-warn-9192
110       - integration-upload-distribution:
111           dist-pom: distribution/pom.xml
112           settings-project: integration
113       - distribution-check-bootup
114
115       - trigger-builds:
116           - project: "{csit-gate-list}"
117             block: "{obj:block_on_csit}"
118             block-thresholds:
119               failure-threshold: "{failure-threshold}"
120             predefined-parameters: |
121               BUNDLE_URL=$BUNDLE_URL
122               KARAF_VERSION=$KARAF_VERSION
123
124     publishers:
125       - email-notification:
126           email-recipients: "{email-recipients}"
127           email-prefix: "[{project-name}]"
128       - integration-csit-archive-build
129       - lf-infra-publish
130
131 - job-template:
132     name: "distribution-verify-{type}-{stream}"
133
134     disable-job: "false"
135     jacoco-exclude-pattern: >
136       **/gen/**
137       **/generated-sources/**
138       **/yang-gen**
139       **/pax/**
140
141     project-type: freestyle
142     node: centos8-builder-8c-8g
143     concurrent: true
144     disabled: "{disable-job}"
145
146     properties:
147       - opendaylight-infra-properties:
148           build-days-to-keep: "{build-days-to-keep}"
149
150     parameters:
151       - opendaylight-infra-parameters:
152           os-cloud: "{os-cloud}"
153           project: "{project}"
154           branch: "{branch}"
155           refspec: "refs/heads/{branch}"
156           artifacts: "{archive-artifacts}"
157
158     scm:
159       - gerrit-trigger-scm:
160           refspec: "$GERRIT_REFSPEC"
161           choosing-strategy: "gerrit"
162
163     wrappers:
164       - opendaylight-infra-wrappers:
165           build-timeout: "{build-timeout}"
166
167     triggers:
168       - gerrit-trigger-patch-submitted:
169           gerrit-server-name: "{gerrit-server-name}"
170           project: "{project}"
171           branch: "{branch}"
172           files: "{files}"
173           forbidden-files: "{forbidden-files}"
174
175     builders:
176       - wipe-org-opendaylight-repo
177       - lf-provide-maven-settings:
178           global-settings-file: "global-settings"
179           settings-file: "integration-settings"
180       - lf-update-java-alternatives:
181           java-version: "{java-version}"
182       - maven-target:
183           maven-version: "{mvn-version}"
184           pom: pom.xml
185           goals: |
186             clean install dependency:tree -DoutputFile=dependency_tree.txt
187             -Dstream={stream}
188             -Dsft.heap.max=4g
189             {opendaylight-infra-mvn-opts}
190             {profile}
191           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
192           java-opts:
193             - "-Xmx1024m"
194           settings: integration-settings
195           settings-type: cfp
196           global-settings: global-settings
197           global-settings-type: cfp
198
199     publishers:
200       - findbugs
201       - lf-jacoco-report:
202           exclude-pattern: "{jacoco-exclude-pattern}"
203       - lf-infra-publish
204       - email-notification:
205           email-recipients: "{email-recipients}"
206           email-prefix: "[{project-name}]"
207
208 - job-template:
209     name: "distribution-merge-{type}-{stream}"
210
211     # Need to keep jobs that deploy to Nexus at end of build as Maven
212     # projects. Maybe reconsider this once upstream moves deploy to a
213     # separate lifecycle:
214     #     https://issues.apache.org/jira/browse/MNG-5666
215
216     disable-job: false
217     jacoco-exclude-pattern: >
218       **/gen/**
219       **/generated-sources/**
220       **/yang-gen**
221       **/pax/**
222
223     project-type: maven
224     node: "centos8-builder-8c-8g"
225     disabled: "{disable-job}"
226
227     properties:
228       - opendaylight-infra-properties:
229           build-days-to-keep: "{build-days-to-keep}"
230
231     parameters:
232       - opendaylight-infra-parameters:
233           os-cloud: "{os-cloud}"
234           project: "{project}"
235           branch: "{branch}"
236           refspec: "refs/heads/{branch}"
237           artifacts: "{archive-artifacts}"
238       - distribution-karaf-version:
239           karaf-version: "{karaf-version}"
240
241     scm:
242       - gerrit-trigger-scm:
243           refspec: ""
244           choosing-strategy: "default"
245
246     wrappers:
247       - opendaylight-infra-wrappers:
248           build-timeout: "{build-timeout}"
249
250     triggers:
251       - gerrit-trigger-patch-merged:
252           gerrit-server-name: "{gerrit-server-name}"
253           name: "{project}"
254           branch: "{branch}"
255           files: "{files}"
256           forbidden-files: "{forbidden-files}"
257       - reverse:
258           jobs: "{dependencies}"
259
260     prebuilders:
261       - wipe-org-opendaylight-repo
262       - lf-jacoco-nojava-workaround
263       - lf-provide-maven-settings:
264           global-settings-file: "global-settings"
265           settings-file: "integration-settings"
266       - lf-update-java-alternatives:
267           java-version: "{java-version}"
268       - integration-set-variables
269       - distribute-build-url:
270           path: "$KARAF_ARTIFACT/src/main/assembly"
271
272     maven:
273       maven-name: "mvn38"
274       root-pom: "pom.xml"
275       goals: >
276         clean install dependency:tree -DoutputFile=dependency_tree.txt -V -B
277         -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r
278         -Dsft.heap.max=4g
279         -Djenkins -Dmerge -Dstream={stream}
280         {profile}
281       maven-opts: "-Xmx1024m"
282       settings: integration-settings
283       settings-type: cfp
284       global-settings: global-settings
285       global-settings-type: cfp
286
287     postbuilders:
288       - integration-compare-distributions
289     # TODO: the output of the above command is not *friendly* for the reader because the most important info
290     # is listed last. This is fine/best for command line output, but for keeping in a file it would be better
291     # to put the summary at the beginning of the file. Some bash magic can be done here to make that happen.
292
293     reporters:
294       - findbugs
295
296     publishers:
297       - maven-deploy:
298           id: ""
299           unique-version: true
300           deploy-unstable: false
301       - lf-jacoco-report:
302           exclude-pattern: "{jacoco-exclude-pattern}"
303       - lf-infra-publish
304       - email-notification:
305           email-recipients: "{email-recipients}"
306           email-prefix: "[{project-name}]"
307
308 - job-template:
309     name: "distribution-check-{type}-{stream}"
310
311     ######################
312     # Default parameters #
313     ######################
314     disable-job: false
315     mvn-version: mvn38
316
317     #####################
318     # Job Configuration #
319     #####################
320
321     # Like a {project}-distribution-check, but few steps less as there is no upstream project involved.
322     disabled: "{disable-job}"
323
324     project-type: freestyle
325     node: "centos8-builder-8c-8g"
326     concurrent: true
327
328     properties:
329       - opendaylight-infra-properties:
330           build-days-to-keep: "{build-days-to-keep}"
331
332     parameters:
333       - opendaylight-infra-parameters:
334           os-cloud: "{os-cloud}"
335           project: "{project}"
336           branch: "{branch}"
337           refspec: "refs/heads/{branch}"
338           artifacts: "{archive-artifacts}"
339       - integration-distribution-stream:
340           stream: "{stream}"
341       - distribution-karaf-version:
342           karaf-version: "{karaf-version}"
343       - maven-exec:
344           maven-version: "{mvn-version}"
345
346     scm:
347       - integration-gerrit-scm:
348           basedir: "distribution"
349           refspec: "$GERRIT_REFSPEC"
350           branch: "{branch}"
351
352     wrappers:
353       - opendaylight-infra-wrappers:
354           # Distro-check jobs typically run within 10 - 30 minutes
355           # with 45 minutes being the occassional edge case.
356           # enforce a 60 minute limit to ensure stuck jobs get
357           # cleared up sooner.
358           # Double that as Karaf 3+4 may take longer.
359           build-timeout: "120"
360
361     triggers:
362       - gerrit-trigger-patch-submitted:
363           gerrit-server-name: "{gerrit-server-name}"
364           project: "{project}"
365           branch: "{branch}"
366           files: "{files}"
367           forbidden-files: "{forbidden-files}"
368
369     builders:
370       - distribution-check-wipe
371       - lf-update-java-alternatives:
372           java-version: "{java-version}"
373       - inject:
374           properties-file: "allowed_projects.txt"
375       - distribution-check-build-project:
376           pom: "distribution/pom.xml"
377           mvn-opts: |
378             {opendaylight-infra-mvn-opts}
379             {profile}
380           mvn-version: "{mvn-version}"
381           # '{opendaylight-infra-parallel-mvn-opts}' is bad when there are multiple big features in SFT.
382       - distribution-check-verify-groupid:
383           gerrit-project: "integration"
384       - distribution-check-delete-snapshots
385       - distribution-check-configure-remotes
386       - distribution-check-repeat-project-build:
387           pom: "distribution/pom.xml"
388           mvn-opts: |
389             {opendaylight-infra-mvn-opts}
390             {profile}
391           mvn-version: "{mvn-version}"
392           # '{opendaylight-infra-parallel-mvn-opts}' is bad when there are multiple big features in SFT.
393       - integration-set-variables
394       - distribution-check-warn-9191
395       - distribution-check-warn-9192
396       - integration-upload-distribution:
397           dist-pom: "{dist-pom}"
398           settings-project: integration
399       - distribution-check-bootup
400
401     publishers:
402       - email-notification:
403           email-recipients: "{email-recipients}"
404           email-prefix: "[{project-name}]"
405       - integration-csit-archive-build
406       - lf-infra-publish
407
408 - job-template:
409     name: "distribution-sanity-{stream}"
410     # Goal: Verify distribution starts with no issues when all features are loaded.
411     # Operation: This job deploys odl-integration-all + list of UM features.
412     # This job works for both managed & self-managed distro.
413
414     project-type: freestyle
415     node: centos8-builder-2c-8g
416     concurrent: false
417
418     properties:
419       - opendaylight-infra-properties:
420           build-days-to-keep: "{build-days-to-keep}"
421
422     parameters:
423       - opendaylight-infra-parameters:
424           os-cloud: "{os-cloud}"
425           project: "{project}"
426           branch: "{branch}"
427           refspec: "refs/heads/{branch}"
428           artifacts: "{archive-artifacts}"
429       - integration-distribution-stream:
430           stream: "{stream}"
431       - integration-distribution-branch:
432           branch: "{branch}"
433       - integration-bundle-url:
434           bundle-url: "{bundle-url}"
435       - integration-repo-url:
436           repo-url: "{sm-repos}"
437       - integration-controller-parameters:
438           controller-features: "{sm-features}"
439           # Parameters below are unused in this job so set them all to blank
440           controller-max-mem: ""
441           controller-debug-map: ""
442           controller-scope: ""
443           controller-use-features-boot: ""
444           feature-elasticsearch-attribute: "{elasticsearch-attribute}"
445       - distribution-karaf-version:
446           karaf-version: "{karaf-version}"
447
448     wrappers:
449       - opendaylight-infra-wrappers:
450           build-timeout: "{build-timeout}"
451
452     builders:
453       - integration-detect-variables
454       - lf-update-java-alternatives:
455           java-version: "{java-version}"
456       - distribution-check-bootup
457
458     publishers:
459       - email-notification:
460           email-recipients: "{email-recipients}"
461           email-prefix: "[{project-name}]"
462       - integration-csit-archive-build
463       - lf-infra-publish
464
465 - job-template:
466     name: "distribution-csit-managed-{stream}"
467     # Goal: Verify distribution starts with no issues when all features are loaded.
468     # Operation: This job deploys odl-integration-all.
469     # This job works for just managed distro.
470
471     disable-job: false
472
473     project-type: freestyle
474     node: centos8-builder-4c-4g
475     concurrent: false
476     disabled: "{disable-job}"
477
478     properties:
479       - opendaylight-infra-properties:
480           build-days-to-keep: "{build-days-to-keep}"
481
482     parameters:
483       - opendaylight-infra-parameters:
484           os-cloud: "{os-cloud}"
485           project: "{project}"
486           branch: "{branch}"
487           refspec: "refs/heads/{branch}"
488           artifacts: "{archive-artifacts}"
489       - integration-distribution-stream:
490           stream: "{stream}"
491       - integration-distribution-branch:
492           branch: "{branch}"
493       - integration-bundle-url:
494           bundle-url: "{bundle-url}"
495       - distribution-karaf-version:
496           karaf-version: "karaf4"
497
498     wrappers:
499       - opendaylight-infra-wrappers:
500           build-timeout: "{build-timeout}"
501
502     builders:
503       - integration-detect-variables
504       - lf-update-java-alternatives:
505           java-version: "{java-version}"
506       - distribution-check-bootup
507
508     publishers:
509       - email-notification:
510           email-recipients: "{email-recipients}"
511           email-prefix: "[{project-name}]"
512       - integration-csit-archive-build
513       - lf-infra-publish