Update list of csit jobs for distribution test
[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       - 'integration-update-csit-tests-{stream}'
17
18     # CSIT Lists in releng-defaults.yaml
19     stream:
20       - oxygen:
21           branch: 'master'
22           jdk: 'openjdk8'
23           csit-blacklist: longevity gate sanity capwap centinel coe didm iotdm jsonrpc lacp netide tsdr
24           csit-list: !include: csit-jobs-oxygen.lst
25           csit-sanity-list: '{csit-sanity-list-oxygen}'
26           csit-weekly-list: '{csit-weekly-list-oxygen}'
27           schedule-weekly: 'H 23 * * 6'
28           csit-high-frequency-list: '{csit-high-frequency-list-oxygen}'
29           schedule-high-frequency: ''
30
31       - nitrogen:
32           branch: 'stable/nitrogen'
33           jre: 'openjdk8'
34           csit-blacklist: longevity gate sanity capwap centinel coe didm iotdm jsonrpc lacp netide tsdr
35           csit-list: !include: csit-jobs-nitrogen.lst
36           csit-sanity-list: '{csit-sanity-list-nitrogen}'
37           csit-weekly-list: '{csit-weekly-list-nitrogen}'
38           schedule-weekly: 'H 23 * * 6'
39           csit-high-frequency-list: '{csit-high-frequency-list-nitrogen}'
40           schedule-high-frequency: ''
41
42       - carbon:
43           branch: 'stable/carbon'
44           karaf-version: karaf3
45           jdk: 'openjdk8'
46           jre: 'openjdk8'
47           csit-blacklist: longevity gate sanity capwap centinel coe jsonrpc
48           csit-list: !include: csit-jobs-carbon.lst
49           csit-sanity-list: '{csit-sanity-list-carbon}'
50           csit-weekly-list: '{csit-weekly-list-carbon}'
51           schedule-weekly: 'H 23 * * 6'
52           csit-high-frequency-list: '{csit-high-frequency-list-carbon}'
53           schedule-high-frequency: 'H H/4 * * *'
54
55       - boron:
56           branch: 'stable/boron'
57           karaf-version: karaf3
58           jdk: 'openjdk8'
59           jre: 'openjdk8'
60           csit-blacklist: longevity gate sanity jsonrpc
61           csit-list: !include: csit-jobs-boron.lst
62           csit-sanity-list: '{csit-sanity-list-boron}'
63           csit-weekly-list: '{csit-weekly-list-boron}'
64           schedule-weekly: 'H 23 * * 6'
65           csit-high-frequency-list: ''
66           schedule-high-frequency: ''
67
68     # tools system image
69     tools_system_image: Ubuntu 16.04 - mininet-ovs-25 - 20170808-0158
70
71 # Template: integration-csit-verify-1node-library
72 # Goal: Verify changes in csit folder not covered by projects suite verify jobs (e.g. libraries or variables)
73 # Operation: This job template performs a base openflow test when there is a change in the libraries folder
74
75 - job-template:
76     name: 'integration-csit-verify-1node-library'
77
78     project-type: freestyle
79     node: centos7-robot-2c-2g
80
81     # {stream} is already defined as a composite object, it cannot be overriden.
82     dist-stream: boron
83     # This is not a template, so define branch, scope and jre for distribution to test with.
84     branch: stable/boron
85     scope: only
86     jre: openjdk8
87
88     properties:
89       - opendaylight-infra-properties:
90           build-days-to-keep: '{build-days-to-keep}'
91
92     parameters:
93       - opendaylight-infra-parameters:
94           os-cloud: '{os-cloud}'
95           project: '{project}'
96           branch: '{test-branch}'
97           refspec: 'refs/heads/{test-branch}'
98           artifacts: '{archive-artifacts}'
99       - integration-distribution-branch:
100           branch: '{verify-branch}'
101       - integration-distribution-stream:
102           stream: '{verify-stream}'
103       - integration-bundle-url:
104           bundle-url: '{bundle-url}'
105       - integration-controller-scope:
106           controller-scope: '{scope}'
107       - integration-controller-features:
108           controller-features: >
109               odl-clustering-test-app,
110               odl-openflowplugin-flow-services-ui,
111               odl-openflowplugin-app-table-miss-enforcer,
112               odl-bgpcep-pcep,
113               odl-bgpcep-bgp,
114               odl-netconf-connector-all
115       # when upgrading to carbon you should replace odl-netconf-connector-all with odl-netconf-topology
116       # and change USE_NETCONF_CONNECTOR to False in test-options
117       - integration-test-options:
118           test-options: '-v TIMEOUT_BUG_4220:10s -v USE_NETCONF_CONNECTOR:True'
119       - integration-stream-test-plan:
120           stream-test-plan: 'test-libraries-{verify-stream}.txt'
121       - integration-test-plan:
122           test-plan: 'test-libraries.txt'
123       - integration-patch-refspec:
124           branch: '$GERRIT_REFSPEC'
125       - integration-jdk-version:
126           jdkversion: '{jre}'
127       - distribution-karaf-version:
128           karaf-version: '{verify-karaf-version}'
129
130     scm:
131       - integration-gerrit-scm:
132           basedir: 'test'
133           refspec: '$PATCHREFSPEC'
134           branch: '{test-branch}'
135
136     wrappers:
137       - opendaylight-infra-wrappers:
138           build-timeout: '{build-timeout}'
139
140     triggers:
141       - integration-trigger-patch-submitted:
142           server: '{server-name}'
143           project: '{project}'
144           branch: '{test-branch}'
145           files: 'csit/libraries/*'
146
147     builders:
148       - integration-infra-stack:
149           stack-template: '{stack-template}'
150           vm_0_count: '1'
151           vm_0_flavor: '{odl_system_flavor}'
152           vm_0_image: '{odl_system_image}'
153           vm_1_count: '{tools_system_count}'
154           vm_1_flavor: '{tools_system_flavor}'
155           vm_1_image: '{tools_system_image}'
156       - integration-install-robotframework
157       - inject:
158           properties-file: 'env.properties'
159       - integration-get-slave-addresses
160       - inject:
161           properties-file: 'slave_addresses.txt'
162       - integration-detect-variables
163       - integration-deploy-controller-run-test
164       - integration-cleanup-tmp
165
166     publishers:
167       - integration-robot:
168           unstable-if: 0.0
169           pass-if: 100.0
170       - email-notification:
171           email-recipients: '{email-recipients}'
172           email-prefix: '[integration]'
173       - integration-csit-archive-build
174       - lf-infra-publish
175
176 # Template: integration-distribution-test-{stream}
177 # Goal: Verify a distribution through all system test available
178 # Operation: This template takes a distribution and passes all available system test
179
180 - job-template:
181     name: 'integration-distribution-test-{stream}'
182
183     project-type: freestyle
184     node: centos7-robot-2c-2g
185
186     properties:
187       - opendaylight-infra-properties:
188           build-days-to-keep: '{build-days-to-keep}'
189
190     parameters:
191       - integration-bundle-url:
192           bundle-url: '{bundle-url}'
193       - distribution-karaf-version:
194           karaf-version: '{karaf-version}'
195
196     builders:
197       - trigger-builds:
198           - project: '{csit-list}'
199             block: true
200             predefined-parameters: |
201               BUNDLE_URL=$BUNDLE_URL
202               KARAF_VERSION=$KARAF_VERSION
203
204     publishers:
205       - email-notification:
206           email-recipients: '{email-recipients}'
207           email-prefix: '[integration]'
208
209 # Template: integration-sanity-test-{stream}
210 # Goal: Verify a distribution through sanity test
211 # Operation: This template takes a distribution and passes sanity test
212
213 - job-template:
214     name: 'integration-sanity-test-{stream}'
215
216     project-type: freestyle
217     node: centos7-robot-2c-2g
218
219     properties:
220       - opendaylight-infra-properties:
221           build-days-to-keep: '{build-days-to-keep}'
222
223     parameters:
224       - integration-bundle-url:
225           bundle-url: '{bundle-url}'
226       - distribution-karaf-version:
227           karaf-version: '{karaf-version}'
228
229     builders:
230       - trigger-builds:
231           - project: '{csit-sanity-list}'
232             block: true
233             predefined-parameters: |
234               BUNDLE_URL=$BUNDLE_URL
235               KARAF_VERSION=$KARAF_VERSION
236
237     publishers:
238       - email-notification:
239           email-recipients: '{email-recipients}'
240           email-prefix: '[integration]'
241
242 # Template: integration-patch-test-{stream}
243 # Goal: Build a patch and run all available system test on a distribution containing the change
244 # Operation: This job template builds a patch, creates a distribution containing the patch, and
245 # triggers the distribution test when test-integration is used in gerrit comments
246
247 - job-template:
248     name: 'integration-patch-test-{stream}'
249
250     project-type: freestyle
251     node: centos7-java-builder-2c-8g
252
253     properties:
254       - opendaylight-infra-properties:
255           build-days-to-keep: '{build-days-to-keep}'
256
257     parameters:
258       - opendaylight-infra-parameters:
259           os-cloud: '{os-cloud}'
260           project: '$GERRIT_PROJECT'
261           branch: '{branch}'
262           refspec: '$GERRIT_REFSPEC'
263           artifacts: '{archive-artifacts}'
264       - integration-distribution-branch:
265           branch: '{branch}'
266       - distribution-karaf-version:
267           karaf-version: '{karaf-version}'
268       - integration-distribution-git-url:
269           git-url: '{git-url}'
270       - maven-exec:
271           maven-version: mvn33
272
273     scm:
274       - integration-gerrit-scm:
275           basedir: '$GERRIT_PROJECT'
276           refspec: '$GERRIT_REFSPEC'
277           branch: '{branch}'
278       - integration-distribution-scm:
279           branch: '{branch}'
280
281     wrappers:
282       - opendaylight-infra-wrappers:
283           build-timeout: '720'
284
285     triggers:
286       - gerrit:
287           server-name: '{server-name}'
288           trigger-on:
289             - comment-added-contains-event:
290                 comment-contains-value: 'test-integration'
291           projects:
292             - project-compare-type: 'ANT'
293               project-pattern: '**'
294               branches:
295                 - branch-compare-type: 'ANT'
296                   branch-pattern: '**/{branch}'
297           skip-vote:
298             successful: true
299             failed: true
300             unstable: true
301             notbuilt: true
302
303     builders:
304       - integration-rebase-gerrit-patch
305       - wipe-org-opendaylight-repo
306       - provide-maven-settings:
307           global-settings-file: 'global-settings'
308           settings-file: 'integration-settings'
309       - maven-target:
310           maven-version: 'mvn33'
311           pom: '$GERRIT_PROJECT/pom.xml'
312           goals: |
313               clean install dependency:tree -DoutputFile=dependency_tree.txt
314               -Pq
315               -Dstream={stream}
316               {opendaylight-infra-mvn-opts}
317           java-opts:
318             - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
319           settings: integration-settings
320           settings-type: cfp
321           global-settings: global-settings
322           global-settings-type: cfp
323       - maven-target:
324           maven-version: mvn33
325           pom: distribution/pom.xml
326           goals: |
327               clean install dependency:tree -DoutputFile=dependency_tree.txt
328               {opendaylight-infra-mvn-opts}
329           java-opts:
330             - '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
331           settings: integration-settings
332           settings-type: cfp
333           global-settings: global-settings
334           global-settings-type: cfp
335       - integration-upload-distribution:
336           dist-pom: distribution/pom.xml
337       - trigger-builds:
338           - project: '{csit-list}'
339             block: true
340             predefined-parameters: |
341               BUNDLE_URL=$BUNDLE_URL
342               KARAF_VERSION=$KARAF_VERSION
343
344     publishers:
345       - lf-infra-publish
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}'
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: '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               -Dsft.heap.max=4g
421               {opendaylight-infra-mvn-opts}
422           java-opts:
423             - '-Xmx3072m -Dmaven.compile.fork=true'
424           settings: integration-settings
425           settings-type: cfp
426           global-settings: global-settings
427           global-settings-type: cfp
428       - integration-upload-distribution:
429           dist-pom: patch_tester/distribution/pom.xml
430       - conditional-step:
431           condition-kind: boolean-expression
432           condition-expression: $RUNTEST
433           steps:
434             - trigger-builds:
435                 - project: '{csit-list}'
436                   block: true
437                   predefined-parameters: |
438                     BUNDLE_URL=$BUNDLE_URL
439                     KARAF_VERSION=$KARAF_VERSION
440
441     publishers:
442       - lf-infra-publish
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]'
510
511 - job-template:
512     name: 'integration-update-csit-tests-{stream}'
513
514     # This job's purpose is to update csit
515     # tests to run in integration-distribution-test-{stream}
516     # by updating integration files: csit-list-carbon.inc,
517     # csit-list-boron.inc, csit-list-beryllium.inc
518     # These files can be used as !include in int-dist-test-{stream}
519
520     ######################
521     # Default parameters #
522     ######################
523
524     git-url: '$GIT_URL/$PROJECT'
525     submodule-recursive: true
526
527     #####################
528     # Job Configuration #
529     #####################
530
531     project-type: freestyle
532     node: centos7-java-builder-2c-4g
533
534     properties:
535       - lf-infra-properties:
536           build-days-to-keep: 7
537
538     parameters:
539       - lf-infra-parameters:
540           project: releng/builder  # Hardcode as this job needs to pull releng/builder
541           stream: '{stream}'
542           branch: master  # Hardcode as releng/builder only has master
543           lftools-version: '{lftools-version}'
544       - string:
545           name: CSIT_BLACKLIST
546           default: '{csit-blacklist}'
547           description: Space separated list of jobs strings to blacklist.
548
549     scm:
550       - lf-infra-gerrit-scm:
551           jenkins-ssh-credential: '{jenkins-ssh-credential}'
552           git-url: '{git-url}'
553           refspec: '$GERRIT_REFSPEC'
554           branch: '$GERRIT_BRANCH'
555           submodule-recursive: '{submodule-recursive}'
556           choosing-strategy: default
557
558     wrappers:
559       - lf-infra-wrappers:
560           build-timeout: 10
561           jenkins-ssh-credential: '{jenkins-ssh-credential}'
562
563     triggers:
564       - reverse:
565           jobs: builder-jjb-merge
566
567     builders:
568       - shell: !include-raw-escape: update-csit-tests.sh
569       - shell: |
570           git status
571           git add jjb/integration/*.lst
572       - opendaylight-infra-push-gerrit-patch:
573           project: "releng/builder"
574           gerrit-topic: "auto-update-csit-jobs-{stream}"
575           gerrit-commit-message: "Auto Update CSIT Jobs to run for {stream}"
576
577     publishers:
578       - lf-infra-publish