Nitrogen distribution test runs on Karaf3
[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       - '{project-name}-verify-tox-master'
9       - 'integration-csit-verify-1node-library'
10       - 'integration-distribution-test-{stream}'
11       - 'integration-sanity-test-{stream}'
12       - 'integration-patch-test-{stream}'
13       - 'integration-multipatch-test-{stream}'
14       - 'integration-distribution-weekly-test-trigger-{stream}'
15       - 'integration-distribution-high-frequency-test-trigger-{stream}'
16
17     # CSIT Lists in releng-defaults.yaml
18     stream:
19       - nitrogen:
20           branch: 'master'
21           karaf-version: karaf3
22           jre: 'openjdk8'
23           csit-list: '{csit-list-nitrogen}'
24           csit-sanity-list: '{csit-sanity-list-nitrogen}'
25           csit-weekly-list: '{csit-weekly-list-nitrogen}'
26           schedule-weekly: 'H 12 * * 0'
27           csit-high-frequency-list: ''
28           schedule-high-frequency: ''
29
30       - carbon:
31           branch: 'stable/carbon'
32           karaf-version: karaf3
33           jdk: 'openjdk8'
34           jre: 'openjdk8'
35           csit-list: '{csit-list-carbon}'
36           csit-sanity-list: '{csit-sanity-list-carbon}'
37           csit-weekly-list: '{csit-weekly-list-carbon}'
38           schedule-weekly: 'H 12 * * 0'
39           csit-high-frequency-list: '{csit-high-frequency-list-carbon}'
40           schedule-high-frequency: 'H H/4 * * *'
41
42       - boron:
43           branch: 'stable/boron'
44           karaf-version: karaf3
45           jdk: 'openjdk8'
46           jre: 'openjdk8'
47           csit-list: '{csit-list-boron}'
48           csit-sanity-list: '{csit-sanity-list-boron}'
49           csit-weekly-list: '{csit-weekly-list-boron}'
50           schedule-weekly: 'H 12 * * 0'
51           csit-high-frequency-list: ''
52           schedule-high-frequency: ''
53
54       - beryllium:
55           branch: 'stable/beryllium'
56           karaf-version: karaf3
57           jdk: 'openjdk7'
58           jre: 'openjdk7'
59           csit-list: '{csit-list-beryllium}'
60           csit-sanity-list: ''
61           csit-weekly-list: ''
62           schedule-weekly: 'H 12 * * 0'
63           csit-high-frequency-list: ''
64           schedule-high-frequency: ''
65
66     # tools system image
67     tools_system_image: Ubuntu 14.04 - mininet-ovs-25 - 20170210-0300
68
69 # Template: integration-csit-verify-1node-library
70 # Goal: Verify changes in csit folder not covered by projects suite verify jobs (e.g. libraries or variables)
71 # Operation: This job template performs a base openflow test when there is a change in the libraries folder
72
73 - job-template:
74     name: 'integration-csit-verify-1node-library'
75
76     project-type: freestyle
77     node: centos7-robot-2c-2g
78
79     # {stream} is already defined as a composite object, it cannot be overriden.
80     dist-stream: boron
81     # This is not a template, so define branch, scope and jre for distribution to test with.
82     branch: stable/boron
83     scope: only
84     jre: openjdk8
85
86     properties:
87       - opendaylight-infra-properties:
88           build-days-to-keep: '{build-days-to-keep}'
89
90     parameters:
91       - opendaylight-infra-parameters:
92           os-cloud: '{os-cloud}'
93           project: '{project}'
94           branch: '{test-branch}'
95           refspec: 'refs/heads/{test-branch}'
96           artifacts: '{archive-artifacts}'
97       - integration-distribution-branch:
98           branch: '{verify-branch}'
99       - integration-distribution-stream:
100           stream: '{verify-stream}'
101       - integration-bundle-url:
102           bundle-url: '{bundle-url}'
103       - integration-controller-scope:
104           controller-scope: '{scope}'
105       - integration-controller-features:
106           controller-features: >
107               odl-clustering-test-app,
108               odl-openflowplugin-flow-services-ui,
109               odl-openflowplugin-app-table-miss-enforcer,
110               odl-bgpcep-pcep,
111               odl-bgpcep-bgp,
112               odl-netconf-connector-all
113       # when upgrading to carbon you should replace odl-netconf-connector-all with odl-netconf-topology
114       # and change USE_NETCONF_CONNECTOR to False in test-options
115       - integration-test-options:
116           test-options: '-v TIMEOUT_BUG_4220:10s -v USE_NETCONF_CONNECTOR:True'
117       - integration-stream-test-plan:
118           stream-test-plan: 'test-libraries-{verify-stream}.txt'
119       - integration-test-plan:
120           test-plan: 'test-libraries.txt'
121       - integration-patch-refspec:
122           branch: '$GERRIT_REFSPEC'
123       - integration-jdk-version:
124           jdkversion: '{jre}'
125       - distribution-karaf-version:
126           karaf-version: '{verify-karaf-version}'
127
128     scm:
129       - integration-gerrit-scm:
130           basedir: 'test'
131           refspec: '$PATCHREFSPEC'
132           branch: '{test-branch}'
133
134     wrappers:
135       - opendaylight-infra-wrappers:
136           build-timeout: '{build-timeout}'
137
138     triggers:
139       - integration-trigger-patch-submitted:
140           server: '{server-name}'
141           project: '{project}'
142           branch: '{test-branch}'
143           files: 'csit/libraries/*'
144
145     builders:
146       - integration-infra-stack:
147           stack-template: '{stack-template}'
148           vm_0_count: '1'
149           vm_0_flavor: '{odl_system_flavor}'
150           vm_0_image: '{odl_system_image}'
151           vm_1_count: '{tools_system_count}'
152           vm_1_flavor: '{tools_system_flavor}'
153           vm_1_image: '{tools_system_image}'
154       - integration-install-robotframework
155       - inject:
156           properties-file: 'env.properties'
157       - integration-get-slave-addresses
158       - inject:
159           properties-file: 'slave_addresses.txt'
160       - integration-detect-variables
161       - integration-deploy-controller-run-test
162       - integration-cleanup-tmp
163
164     publishers:
165       - integration-robot:
166           unstable-if: 0.0
167           pass-if: 100.0
168       - email-notification:
169           email-recipients: '{email-recipients}'
170           email-prefix: '[integration]'
171       - integration-csit-archive-build
172       - opendaylight-infra-shiplogs:
173           maven-version: 'mvn33'
174
175 # Template: integration-distribution-test-{stream}
176 # Goal: Verify a distribution through all system test available
177 # Operation: This template takes a distribution and passes all available system test
178
179 - job-template:
180     name: 'integration-distribution-test-{stream}'
181
182     project-type: freestyle
183     node: centos7-robot-2c-2g
184
185     properties:
186       - opendaylight-infra-properties:
187           build-days-to-keep: '{build-days-to-keep}'
188
189     parameters:
190       - integration-bundle-url:
191           bundle-url: '{bundle-url}'
192       - distribution-karaf-version:
193           karaf-version: '{karaf-version}'
194
195     builders:
196       - trigger-builds:
197           - project: '{csit-list}'
198             block: true
199             predefined-parameters: |
200               BUNDLE_URL=$BUNDLE_URL
201               KARAF_VERSION=$KARAF_VERSION
202
203     publishers:
204       - email-notification:
205           email-recipients: '{email-recipients}'
206           email-prefix: '[integration]'
207
208 # Template: integration-sanity-test-{stream}
209 # Goal: Verify a distribution through sanity test
210 # Operation: This template takes a distribution and passes sanity test
211
212 - job-template:
213     name: 'integration-sanity-test-{stream}'
214
215     project-type: freestyle
216     node: centos7-robot-2c-2g
217
218     properties:
219       - opendaylight-infra-properties:
220           build-days-to-keep: '{build-days-to-keep}'
221
222     parameters:
223       - integration-bundle-url:
224           bundle-url: '{bundle-url}'
225       - distribution-karaf-version:
226           karaf-version: '{karaf-version}'
227
228     builders:
229       - trigger-builds:
230           - project: '{csit-sanity-list}'
231             block: true
232             predefined-parameters: |
233               BUNDLE_URL=$BUNDLE_URL
234               KARAF_VERSION=$KARAF_VERSION
235
236     publishers:
237       - email-notification:
238           email-recipients: '{email-recipients}'
239           email-prefix: '[integration]'
240
241 # Template: integration-patch-test-{stream}
242 # Goal: Build a patch and run all available system test on a distribution containing the change
243 # Operation: This job template builds a patch, creates a distribution containing the patch, and
244 # triggers the distribution test when test-integration is used in gerrit comments
245
246 - job-template:
247     name: 'integration-patch-test-{stream}'
248
249     project-type: freestyle
250     node: centos7-java-builder-2c-8g
251
252     properties:
253       - opendaylight-infra-properties:
254           build-days-to-keep: '{build-days-to-keep}'
255
256     parameters:
257       - opendaylight-infra-parameters:
258           os-cloud: '{os-cloud}'
259           project: '$GERRIT_PROJECT'
260           branch: '{branch}'
261           refspec: '$GERRIT_REFSPEC'
262           artifacts: '{archive-artifacts} **/dependency_tree.txt'
263       - integration-distribution-branch:
264           branch: '{branch}'
265       - distribution-karaf-version:
266           karaf-version: '{karaf-version}'
267       - integration-distribution-git-url:
268           git-url: '{git-url}'
269       - maven-exec:
270           maven-version: mvn33
271
272     scm:
273       - integration-gerrit-scm:
274           basedir: '$GERRIT_PROJECT'
275           refspec: '$GERRIT_REFSPEC'
276           branch: '{branch}'
277       - integration-distribution-scm:
278           branch: '{branch}'
279
280     wrappers:
281       - opendaylight-infra-wrappers:
282           build-timeout: '720'
283
284     triggers:
285       - gerrit:
286           server-name: '{server-name}'
287           trigger-on:
288             - comment-added-contains-event:
289                 comment-contains-value: 'test-integration'
290           projects:
291             - project-compare-type: 'ANT'
292               project-pattern: '**'
293               branches:
294                 - branch-compare-type: 'ANT'
295                   branch-pattern: '**/{branch}'
296           skip-vote:
297             successful: true
298             failed: true
299             unstable: true
300             notbuilt: true
301
302     builders:
303       - integration-rebase-gerrit-patch
304       - wipe-org-opendaylight-repo
305       - provide-maven-settings:
306           global-settings-file: 'odl-global-settings'
307           settings-file: 'integration-settings'
308       - maven-target:
309           maven-version: 'mvn33'
310           pom: '$GERRIT_PROJECT/pom.xml'
311           goals: |
312               clean install dependency:tree -DoutputFile=dependency_tree.txt
313               -Pq
314               -Dstream={stream}
315               {opendaylight-infra-mvn-opts}
316           java-opts:
317             - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
318           settings: integration-settings
319           settings-type: cfp
320           global-settings: odl-global-settings
321           global-settings-type: cfp
322       - maven-target:
323           maven-version: mvn33
324           pom: distribution/pom.xml
325           goals: |
326               clean install dependency:tree -DoutputFile=dependency_tree.txt
327               {opendaylight-infra-mvn-opts}
328           java-opts:
329             - '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
330           settings: integration-settings
331           settings-type: cfp
332           global-settings: odl-global-settings
333           global-settings-type: cfp
334       - integration-upload-distribution:
335           dist-pom: distribution/pom.xml
336       - trigger-builds:
337           - project: '{csit-list}'
338             block: true
339             predefined-parameters: |
340               BUNDLE_URL=$BUNDLE_URL
341               KARAF_VERSION=$KARAF_VERSION
342
343     publishers:
344       - opendaylight-infra-shiplogs:
345           maven-version: 'mvn33'
346       - email-notification:
347           email-recipients: '{email-recipients}'
348           email-prefix: '[$GERRIT_PROJECT]'
349
350
351 - job-template:
352     name: 'integration-multipatch-test-{stream}'
353     # Goal: Build one or more patches and run all available system test on a distribution containing the change.
354     # Operation: This job template checks out and builds each patch provided in job parameters, creates a distribution
355     # containing these patches, and triggers the distribution test job which includes most (if not all) available
356     # CSIT jobs
357     # TODO: Move the following to appropriate readthedocs document.
358     # Recommended Sandbox usage:
359     # 0. Create this job and a CSIT job you want to run on the new .zip in Sandbox (disable timed triggers).
360     # 1. Copy the csit job name to clipboard.
361     # 2. Navigate to Sandbox page of this job.
362     # 3. Click "Configure".
363     # 4. Locate "Trigger/call builds on other projects" (under "Post Steps" tab).
364     # 5. Delete the long value of "Projects to build" field and paste the job name from clipboard (ctrl+a, ctrl+v).
365     # 6. Click "Save" button.
366     # 7. Click "Build with Parameters".
367     # yamllint disable-line rule:line-length
368     # 8. Start the job with your parameters, see https://wiki.opendaylight.org/view/Integration/Test/Running_System_Tests#Running_System_Tests_Using_Custom_Distribution_Built_From_Multiple_Patches
369     # 9. The multipatch job waits for the csit job to finish, so abort csit if you see something went wrong.
370     # 10. Navigate to Sandbox page of the csit job, click the run triggered from multipatch.
371     # 11. Click Parameters and copy the long value of BUNDLE_URL field to clipboard.
372     # 12. Run the same csit job woth different patchset or test options, or other csit jobs, with this BUNDLE_URL value
373     #     so you do not have to wait for multipatch build. Repeat step 12.
374     # 13. Currently, the .zip lasts 24 hours (?) so you may need to jump to step 2 (or 0) after some time.
375
376     project-type: freestyle
377     node: centos7-java-builder-8c-8g
378     jdk: '{jdk}'
379
380     properties:
381       - opendaylight-infra-properties:
382           build-days-to-keep: '{build-days-to-keep}'
383
384     parameters:
385       - patches-to-build-parameter:
386           patches_to_build: '$PATCHES_TO_BUILD'
387       - run-test-parameter:
388           run-test: 'false'
389       - integration-distribution-branch:
390           branch: '{branch}'
391       - distribution-karaf-version:
392           karaf-version: '{karaf-version}'
393       - opendaylight-infra-parameters:
394           os-cloud: '{os-cloud}'
395           project: 'integration/distribution'
396           branch: '{branch}'
397           refspec: 'refs/heads/{branch}'
398           artifacts: '{archive-artifacts} **/dependency_tree.txt'
399       - maven-exec:
400           maven-version: mvn33
401
402     wrappers:
403       - opendaylight-infra-wrappers:
404           build-timeout: '1200'
405
406     builders:
407       - wipe-org-opendaylight-repo
408       - integration-multipatch-builder
409       - provide-maven-settings:
410           global-settings-file: 'odl-global-settings'
411           settings-file: 'yangtools-settings'
412       - maven-target:
413           maven-version: mvn33
414           pom: patch_tester/pom.xml
415           # TODO: Make Maven options configurable. Currently tests are not skipped, everything else is.
416           goals: |
417               clean install dependency:tree -DoutputFile=dependency_tree.txt
418               -Pq
419               -Dstream={stream}
420               {opendaylight-infra-mvn-opts}
421           java-opts:
422             - '-Xmx7168m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
423           settings: integration-settings
424           settings-type: cfp
425           global-settings: odl-global-settings
426           global-settings-type: cfp
427       - integration-upload-distribution:
428           dist-pom: patch_tester/distribution/pom.xml
429       - conditional-step:
430           condition-kind: boolean-expression
431           condition-expression: $RUNTEST
432           steps:
433             - trigger-builds:
434                 - project: '{csit-list}'
435                   block: true
436                   predefined-parameters: |
437                     BUNDLE_URL=$BUNDLE_URL
438                     KARAF_VERSION=$KARAF_VERSION
439
440     publishers:
441       - opendaylight-infra-shiplogs:
442           maven-version: 'mvn33'
443       - email-notification:
444           email-recipients: '{email-recipients}'
445           email-prefix: '[int/dist]'
446
447 - job-template:
448     name: 'integration-distribution-weekly-test-trigger-{stream}'
449
450     project-type: freestyle
451     node: centos7-robot-2c-2g
452
453     properties:
454       - opendaylight-infra-properties:
455           build-days-to-keep: '{build-days-to-keep}'
456
457     parameters:
458       - integration-bundle-url:
459           bundle-url: '{bundle-url}'
460       - distribution-karaf-version:
461           karaf-version: '{karaf-version}'
462
463     triggers:
464       - timed: '{schedule-weekly}'
465
466     builders:
467       - trigger-builds:
468           - project: '{csit-weekly-list}'
469             block: true
470             predefined-parameters: |
471               BUNDLE_URL=$BUNDLE_URL
472               KARAF_VERSION=$KARAF_VERSION
473
474     publishers:
475       - email-notification:
476           email-recipients: '{email-recipients}'
477           email-prefix: '[integration]'
478
479 - job-template:
480     name: 'integration-distribution-high-frequency-test-trigger-{stream}'
481
482     project-type: freestyle
483     node: centos7-robot-2c-2g
484
485     properties:
486       - opendaylight-infra-properties:
487           build-days-to-keep: '{build-days-to-keep}'
488
489     parameters:
490       - integration-bundle-url:
491           bundle-url: '{bundle-url}'
492       - distribution-karaf-version:
493           karaf-version: '{karaf-version}'
494
495     triggers:
496       - timed: '{schedule-high-frequency}'
497
498     builders:
499       - trigger-builds:
500           - project: '{csit-high-frequency-list}'
501             block: true
502             predefined-parameters: |
503               BUNDLE_URL=$BUNDLE_URL
504               KARAF_VERSION=$KARAF_VERSION
505
506     publishers:
507       - email-notification:
508           email-recipients: '{email-recipients}'
509           email-prefix: '[integration]'