yaml file for bundle-based-reconciliaion script
[releng/builder.git] / jjb / integration / integration-test-jobs.yaml
1 ---
2 - project:
3     name: integration-test
4     project: integration/test
5     project-name: integration-test
6     test-branch: master
7     jobs:
8       - 'integration-distribution-test-{stream}'
9       - 'integration-sanity-test-{stream}'
10       - 'integration-patch-test-{stream}'
11       - 'integration-multipatch-test-{stream}'
12       - 'integration-distribution-weekly-test-trigger-{stream}'
13       - 'integration-distribution-high-frequency-test-trigger-{stream}'
14       - 'integration-update-csit-tests-{stream}'
15       - '{project-name}-rtd-jobs':
16           build-node: centos7-builder-2c-2g
17           project-pattern: integration/test
18           rtd-project: odl-integrationtest
19       - gerrit-tox-verify:
20           branch: master
21           stream: master
22
23     # CSIT Lists in releng-defaults.yaml
24     stream:
25       - fluorine:
26           branch: 'master'
27           csit-blacklist: >
28               alto bier capwap centinel coe didm dluxapps groupbasedpolicy iotdm jsonrpc lacp
29               l2switch messaging4transport nemo netide nic ocpplugin of-config p4plugin packetcable
30               sdninterfaceapp sxp tsdr unimgr usc usecplugin vtn gate longevity sanity tdd wip
31           csit-list: !include: csit-jobs-fluorine.lst
32           csit-sanity-list: '{csit-sanity-list-fluorine}'
33           csit-weekly-list: '{csit-weekly-list-fluorine}'
34           csit-high-frequency-list: '{csit-high-frequency-list-fluorine}'
35           mvn-version: 'mvn33'
36       - oxygen:
37           branch: 'stable/oxygen'
38           csit-blacklist: >
39               capwap centinel coe didm iotdm jsonrpc lacp messaging4transport netide nic
40               ocpplugin sdninterfaceapp unimgr usecplugin gate longevity sanity tdd wip
41           csit-list: !include: csit-jobs-oxygen.lst
42           csit-sanity-list: '{csit-sanity-list-oxygen}'
43           csit-weekly-list: '{csit-weekly-list-oxygen}'
44           csit-high-frequency-list: '{csit-high-frequency-list-oxygen}'
45           mvn-version: 'mvn33'
46
47       - nitrogen:
48           branch: 'stable/nitrogen'
49           csit-blacklist: capwap centinel coe didm iotdm jsonrpc lacp netide tsdr gate longevity sanity tdd wip
50           csit-list: !include: csit-jobs-nitrogen.lst
51           csit-sanity-list: '{csit-sanity-list-nitrogen}'
52           csit-weekly-list: '{csit-weekly-list-nitrogen}'
53           csit-high-frequency-list: '{csit-high-frequency-list-nitrogen}'
54           mvn-version: 'mvn33'
55
56       - carbon:
57           branch: 'stable/carbon'
58           karaf-version: karaf3
59           csit-blacklist: capwap centinel coe jsonrpc gate longevity sanity tdd wip
60           csit-list: !include: csit-jobs-carbon.lst
61           csit-sanity-list: '{csit-sanity-list-carbon}'
62           csit-weekly-list: '{csit-weekly-list-carbon}'
63           csit-high-frequency-list: '{csit-high-frequency-list-carbon}'
64           mvn-version: 'mvn33'
65
66     # tools system image
67     tools_system_image: ZZCI - Ubuntu 16.04 - mininet-ovs-25 - 20171208-1847
68
69 # Template: integration-distribution-test-{stream}
70 # Goal: Verify a distribution through all system test available
71 # Operation: This template takes a distribution and passes all available system test
72
73 - job-template:
74     name: 'integration-distribution-test-{stream}'
75
76     project-type: freestyle
77     node: centos7-robot-2c-8g
78
79     properties:
80       - opendaylight-infra-properties:
81           build-days-to-keep: '{build-days-to-keep}'
82
83     parameters:
84       - integration-bundle-url:
85           bundle-url: '{bundle-url}'
86       - distribution-karaf-version:
87           karaf-version: '{karaf-version}'
88
89     builders:
90       - trigger-builds:
91           - project: '{csit-list}'
92             block: true
93             predefined-parameters: |
94               BUNDLE_URL=$BUNDLE_URL
95               KARAF_VERSION=$KARAF_VERSION
96
97     publishers:
98       - opendaylight-infra-generate-csit-status-report
99       - email-notification:
100           email-recipients: '{email-recipients}'
101           email-prefix: '[integration]'
102       - lf-infra-publish
103
104 # Template: integration-sanity-test-{stream}
105 # Goal: Verify a distribution through sanity test
106 # Operation: This template takes a distribution and passes sanity test
107
108 - job-template:
109     name: 'integration-sanity-test-{stream}'
110
111     project-type: freestyle
112     node: centos7-robot-2c-8g
113
114     properties:
115       - opendaylight-infra-properties:
116           build-days-to-keep: '{build-days-to-keep}'
117
118     parameters:
119       - integration-bundle-url:
120           bundle-url: '{bundle-url}'
121       - distribution-karaf-version:
122           karaf-version: '{karaf-version}'
123
124     builders:
125       - trigger-builds:
126           - project: '{csit-sanity-list}'
127             block: true
128             predefined-parameters: |
129               BUNDLE_URL=$BUNDLE_URL
130               KARAF_VERSION=$KARAF_VERSION
131
132     publishers:
133       - email-notification:
134           email-recipients: '{email-recipients}'
135           email-prefix: '[integration]'
136
137 # Template: integration-patch-test-{stream}
138 # Goal: Build a patch and run all available system test on a distribution containing the change
139 # Operation: This job template builds a patch, creates a distribution containing the patch, and
140 # triggers the distribution test when test-integration is used in gerrit comments
141
142 - job-template:
143     name: 'integration-patch-test-{stream}'
144
145     project-type: freestyle
146     node: centos7-builder-2c-8g
147
148     properties:
149       - opendaylight-infra-properties:
150           build-days-to-keep: '{build-days-to-keep}'
151
152     parameters:
153       - opendaylight-infra-parameters:
154           os-cloud: '{os-cloud}'
155           project: '$GERRIT_PROJECT'
156           branch: '{branch}'
157           refspec: '$GERRIT_REFSPEC'
158           artifacts: '{archive-artifacts}'
159       - integration-distribution-branch:
160           branch: '{branch}'
161       - distribution-karaf-version:
162           karaf-version: '{karaf-version}'
163       - integration-distribution-git-url:
164           git-url: '{git-url}'
165       - maven-exec:
166           maven-version: mvn33
167
168     scm:
169       - integration-gerrit-scm:
170           basedir: '$GERRIT_PROJECT'
171           refspec: '$GERRIT_REFSPEC'
172           branch: '{branch}'
173       - integration-distribution-scm:
174           branch: '{branch}'
175
176     wrappers:
177       - opendaylight-infra-wrappers:
178           build-timeout: '720'
179
180     triggers:
181       - gerrit:
182           server-name: '{gerrit-server-name}'
183           trigger-on:
184             - comment-added-contains-event:
185                 comment-contains-value: 'test-integration'
186           projects:
187             - project-compare-type: 'ANT'
188               project-pattern: '**'
189               branches:
190                 - branch-compare-type: 'ANT'
191                   branch-pattern: '**/{branch}'
192           skip-vote:
193             successful: true
194             failed: true
195             unstable: true
196             notbuilt: true
197
198     builders:
199       - integration-rebase-gerrit-patch
200       - wipe-org-opendaylight-repo
201       - provide-maven-settings:
202           global-settings-file: 'global-settings'
203           settings-file: 'integration-settings'
204       - maven-target:
205           maven-version: 'mvn33'
206           pom: '$GERRIT_PROJECT/pom.xml'
207           goals: |
208               clean install dependency:tree -DoutputFile=dependency_tree.txt
209               -Pq
210               -Dstream={stream}
211               {opendaylight-infra-mvn-opts}
212           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
213           java-opts:
214             - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
215           settings: integration-settings
216           settings-type: cfp
217           global-settings: global-settings
218           global-settings-type: cfp
219       - maven-target:
220           maven-version: mvn33
221           pom: distribution/pom.xml
222           goals: |
223               clean install dependency:tree -DoutputFile=dependency_tree.txt
224               {opendaylight-infra-mvn-opts}
225           # {opendaylight-infra-parallel-mvn-opts} is bad when there are multiple big features in SFT.
226           java-opts:
227             - '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
228           settings: integration-settings
229           settings-type: cfp
230           global-settings: global-settings
231           global-settings-type: cfp
232       - integration-upload-distribution:
233           dist-pom: distribution/pom.xml
234       - trigger-builds:
235           - project: '{csit-list}'
236             block: true
237             predefined-parameters: |
238               BUNDLE_URL=$BUNDLE_URL
239               KARAF_VERSION=$KARAF_VERSION
240
241     publishers:
242       - lf-infra-publish
243       - email-notification:
244           email-recipients: '{email-recipients}'
245           email-prefix: '[$GERRIT_PROJECT]'
246
247
248 - job-template:
249     name: 'integration-multipatch-test-{stream}'
250     # Goal: Build one or more patches and run all available system test on a distribution containing the change.
251     # Operation: This job template checks out and builds in order each patch provided in job parameters, finally
252     # it creates a distribution containing all patches and triggers the distribution test job which includes most
253     # (if not all) available CSIT jobs.
254
255     project-type: freestyle
256     node: centos7-builder-4c-4g
257     jdk: '{java-version}'
258
259     properties:
260       - opendaylight-infra-properties:
261           build-days-to-keep: '{build-days-to-keep}'
262
263     parameters:
264       - patches-to-build-parameter:
265           patches_to_build: '$PATCHES_TO_BUILD'
266       - run-test-parameter:
267           run-test: 'false'
268       - integration-distribution-branch:
269           branch: '{branch}'
270       - integration-distribution-stream:
271           stream: '{stream}'
272       - distribution-karaf-version:
273           karaf-version: '{karaf-version}'
274       - opendaylight-infra-parameters:
275           os-cloud: '{os-cloud}'
276           project: 'integration/distribution'
277           branch: '{branch}'
278           refspec: 'refs/heads/{branch}'
279           artifacts: '{archive-artifacts}'
280       - maven-exec:
281           maven-version: mvn33
282
283     wrappers:
284       - opendaylight-infra-wrappers:
285           build-timeout: '1200'
286
287     triggers:
288       - gerrit:
289           server-name: '{gerrit-server-name}'
290           trigger-on:
291             - comment-added-contains-event:
292                 comment-contains-value: 'multipatch-build:'
293           projects:
294             - project-compare-type: ANT
295               project-pattern: '**'
296               branches:
297                 - branch-compare-type: ANT
298                   branch-pattern: '**/{branch}'
299
300     builders:
301       - wipe-org-opendaylight-repo
302       - lf-maven-install:
303           mvn-version: '{mvn-version}'
304       - provide-maven-settings:
305           global-settings-file: 'global-settings'
306           settings-file: 'integration-distribution-settings'
307       - integration-multipatch-builder
308       - integration-upload-distribution:
309           dist-pom: patch_tester/distribution/pom.xml
310       - conditional-step:
311           condition-kind: boolean-expression
312           condition-expression: $RUNTEST
313           steps:
314             - trigger-builds:
315                 - project: '{csit-list}'
316                   block: true
317                   predefined-parameters: |
318                     BUNDLE_URL=$BUNDLE_URL
319                     KARAF_VERSION=$KARAF_VERSION
320
321     publishers:
322       - lf-infra-publish
323       - email-notification:
324           email-recipients: '{email-recipients}'
325           email-prefix: '[int/dist]'
326
327 - job-template:
328     name: 'integration-distribution-weekly-test-trigger-{stream}'
329
330     project-type: freestyle
331     node: centos7-robot-2c-8g
332
333     properties:
334       - opendaylight-infra-properties:
335           build-days-to-keep: '{build-days-to-keep}'
336
337     parameters:
338       - integration-bundle-url:
339           bundle-url: '{bundle-url}'
340       - distribution-karaf-version:
341           karaf-version: '{karaf-version}'
342
343     triggers:
344       - timed: '{schedule-weekly}'
345
346     builders:
347       - trigger-builds:
348           - project: '{csit-weekly-list}'
349             block: true
350             predefined-parameters: |
351               BUNDLE_URL=$BUNDLE_URL
352               KARAF_VERSION=$KARAF_VERSION
353
354     publishers:
355       - email-notification:
356           email-recipients: '{email-recipients}'
357           email-prefix: '[integration]'
358
359 - job-template:
360     name: 'integration-distribution-high-frequency-test-trigger-{stream}'
361
362     project-type: freestyle
363     node: centos7-robot-2c-8g
364
365     properties:
366       - opendaylight-infra-properties:
367           build-days-to-keep: '{build-days-to-keep}'
368
369     parameters:
370       - integration-bundle-url:
371           bundle-url: '{bundle-url}'
372       - distribution-karaf-version:
373           karaf-version: '{karaf-version}'
374
375     triggers:
376       - timed: '{schedule-high-frequency}'
377
378     builders:
379       - trigger-builds:
380           - project: '{csit-high-frequency-list}'
381             block: true
382             predefined-parameters: |
383               BUNDLE_URL=$BUNDLE_URL
384               KARAF_VERSION=$KARAF_VERSION
385
386     publishers:
387       - email-notification:
388           email-recipients: '{email-recipients}'
389           email-prefix: '[integration]'
390
391 - job-template:
392     name: 'integration-update-csit-tests-{stream}'
393
394     # This job's purpose is to update csit
395     # tests to run in integration-distribution-test-{stream}
396     # by updating integration files: csit-list-{stream}.inc
397     # These files can be used as !include in int-dist-test-{stream}
398
399     ######################
400     # Default parameters #
401     ######################
402
403     git-url: '$GIT_URL/$PROJECT'
404     submodule-recursive: true
405
406     #####################
407     # Job Configuration #
408     #####################
409
410     project-type: freestyle
411     node: centos7-builder-2c-8g
412
413     properties:
414       - lf-infra-properties:
415           build-days-to-keep: 7
416
417     parameters:
418       - lf-infra-parameters:
419           project: releng/builder  # Hardcode as this job needs to pull releng/builder
420           stream: '{stream}'
421           branch: master  # Hardcode as releng/builder only has master
422           lftools-version: '{lftools-version}'
423       - string:
424           name: CSIT_BLACKLIST
425           default: '{csit-blacklist}'
426           description: Space separated list of jobs strings to blacklist.
427
428     scm:
429       - lf-infra-gerrit-scm:
430           jenkins-ssh-credential: '{jenkins-ssh-credential}'
431           git-url: '{git-url}'
432           refspec: '$GERRIT_REFSPEC'
433           branch: '$GERRIT_BRANCH'
434           submodule-recursive: '{submodule-recursive}'
435           choosing-strategy: default
436
437     wrappers:
438       - lf-infra-wrappers:
439           build-timeout: 10
440           jenkins-ssh-credential: '{jenkins-ssh-credential}'
441
442     triggers:
443       - reverse:
444           jobs: builder-jjb-merge
445
446     builders:
447       - shell: !include-raw-escape: update-csit-tests.sh
448       - shell: |
449           git status
450           git add jjb/integration/*.lst
451       - opendaylight-infra-push-gerrit-patch:
452           project: "releng/builder"
453           gerrit-topic: "auto-update-csit-jobs-{stream}"
454           gerrit-commit-message: "Auto Update CSIT Jobs to run for {stream}"
455
456     publishers:
457       - lf-infra-publish