Feat: Add wait flag for SonarCloud quality gates
[releng/global-jjb.git] / docs / jjb / lf-maven-jobs.rst
1 ##########
2 Maven Jobs
3 ##########
4
5 Job Groups
6 ==========
7
8 .. include:: ../job-groups.rst
9
10 Below is a list of Maven job groups:
11
12 .. literalinclude:: ../../jjb/lf-maven-job-groups.yaml
13    :language: yaml
14
15
16 Macros
17 ======
18
19 lf-infra-maven-sonar
20 --------------------
21
22 Runs Sonar against a Maven project.
23
24 :Required Parameters:
25
26     :java-version: Version of Java to execute Sonar with. (default: openjdk11)
27     :mvn-version: Version of Maven to execute Sonar with.
28     :mvn-settings: Maven settings.xml file containing credentials to use.
29
30 lf-infra-maven-sonarcloud
31 -------------------------
32
33 Runs Sonar against a Maven project and pushes results to SonarCloud.
34
35 :Required Parameters:
36
37     :java-version: Version of Java to execute Maven build. (default: openjdk11)
38     :mvn-version: Version of Maven to execute Sonar with.
39     :mvn-settings: Maven settings.xml file containing credentials to use.
40     :sonarcloud-project-key: SonarCloud project key.
41     :sonarcloud-project-organization: SonarCloud project organization.
42     :sonarcloud-api-token: SonarCloud API Token.
43     :sonarcloud-java-version: Version of Java to run the Sonar scan. (default: openjdk11)
44     :sonarcloud-qualitygate-wait: SonarCloud flag that forces the analysis step to
45         wait for the quality gate result. (default: false)
46
47 lf-maven-build
48 --------------
49
50 Calls the maven build script to perform a maven build.
51
52 :Required parameters:
53
54     :mvn-goals: The maven goals to perform for the build.
55         (default: clean deploy)
56
57 lf-maven-common
58 ---------------
59
60 Common Jenkins configuration for Maven jobs.
61
62 lf-maven-deploy
63 ---------------
64
65 Calls the maven deploy script to push artifacts to Nexus.
66
67 lf-maven-versions-plugin
68 ------------------------
69
70 Conditionally calls Maven versions plugin to set, update and commit the maven `versions:set`.
71
72 :Required Parameters:
73
74     :maven-versions-plugin: Whether to call Maven versions plugin or not. (default: false)
75     :version-properties-file: Name and path of the version properties file.
76         (default: version.properties)
77     :mvn-version: Version of Maven to execute Sonar with.
78     :mvn-pom: Location of pom.xml.
79     :mvn-settings: Maven settings.xml file containing credentials to use.
80
81 lf-maven-stage
82 --------------
83
84 Calls the maven stage script to push artifacts to a Nexus staging repository.
85
86 :Required Parameters:
87
88     :mvn-global-settings: The name of the Maven global settings to use for
89         Maven configuration.
90     :mvn-settings: The name of settings file containing credentials for the project.
91
92 lf-update-java-alternatives
93 ---------------------------
94
95 Setup Java alternatives for the Distro.
96
97 :Required Parameters:
98
99     :java-version: Version of Java to set as the default Java.
100         Eg. openjdk11
101
102 lf-infra-sonatype-clm
103 ---------------------
104
105 Runs a Sonatype CLM scan against a Maven project and pushes results to
106 Nexus IQ server.
107
108 :Optional parameters:
109     :mvn-goals: The maven goals to perform for the build.
110         (default: clean install)
111
112 Job Templates
113 =============
114
115 Maven CLM
116 ---------
117
118 Produces a CLM scan of the code into Nexus IQ Server.
119
120 :Template Names:
121
122     - {project-name}-maven-clm-{stream}
123     - gerrit-maven-clm
124     - github-maven-clm
125
126 :Comment Trigger: run-clm
127
128 :Required parameters:
129
130     :build-node:    The node to run build on.
131     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
132     :mvn-settings: The name of settings file containing credentials for the project.
133
134 :Optional parameters:
135
136     :branch: The branch to build against. (default: master)
137     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
138     :build-timeout: Timeout in minutes before aborting build. (default: 60)
139     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
140     :java-version: Version of Java to use for the build. (default: openjdk11)
141     :mvn-global-settings: The name of the Maven global settings to use for
142         Maven configuration. (default: global-settings)
143     :mvn-goals: The maven goals to perform for the build.
144         (default: clean install)
145     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
146     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
147     :mvn-version: Version of maven to use. (default: mvn35)
148     :nexus-iq-namespace: Insert a namespace to project AppID for projects that
149         share a Nexus IQ system to avoid project name collision. We recommend
150         inserting a trailing - dash if using this parameter.
151         For example 'odl-'. (default: '')
152     :nexus-iq-stage: Sets the **stage** which the policy evaluation will run
153         against on the Nexus IQ Server. (default: 'build')
154     :stream: Keyword that represents a release code-name.
155         Often the same as the branch. (default: master)
156     :submodule-recursive: Whether to checkout submodules recursively.
157         (default: true)
158     :submodule-timeout: Timeout (in minutes) for checkout operation.
159         (default: 10)
160     :submodule-disable: Disable submodule checkout operation.
161         (default: false)
162
163     :gerrit_merge_triggers: Override Gerrit Triggers.
164
165 Maven JavaDoc Publish
166 ---------------------
167
168 Produces and publishes javadocs for a Maven project.
169
170 Expects javadocs to be available in ``$WORKSPACE/target/site/apidocs``, but
171 overrideable with the ``mvn-dir`` parameter. If set, will search for javadocs
172 in ``$WORKSPACE/{mvn-dir}/target/site/apidocs``.
173
174 :Template Names:
175
176     - {project-name}-maven-javadoc-publish-{stream}-{java-version}
177     - gerrit-maven-javadoc-publish
178     - github-maven-javadoc-publish
179
180 :Comment Trigger: remerge
181
182 :Required parameters:
183
184     :build-node: The node to run build on.
185     :javadoc-path: The path in Nexus to deploy javadoc to.
186     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
187     :mvn-settings: The name of settings file containing credentials for the project.
188     :mvn-site-id: Maven Server ID from settings.xml to pull credentials from.
189         (Note: This setting is generally configured in ``defaults.yaml``.)
190
191 :Optional parameters:
192
193     :branch: The branch to build against. (default: master)
194     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
195     :build-timeout: Timeout in minutes before aborting build. (default: 60)
196     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
197     :java-version: Version of Java to use for the build. (default: openjdk11)
198     :mvn-dir: Directory supplied as argument to -f option (default: '.')
199     :mvn-global-settings: The name of the Maven global settings to use for
200         Maven configuration. (default: global-settings)
201     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
202     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
203         Must not include a "-f" option; see parameter mvn-dir.
204     :mvn-version: Version of maven to use. (default: mvn35)
205     :stream: Keyword that represents a release code-name.
206         Often the same as the branch. (default: master)
207     :submodule-recursive: Whether to checkout submodules recursively.
208         (default: true)
209     :submodule-timeout: Timeout (in minutes) for checkout operation.
210         (default: 10)
211     :submodule-disable: Disable submodule checkout operation.
212         (default: false)
213
214     :gerrit_merge_triggers: Override Gerrit Triggers.
215
216 Maven JavaDoc Verify
217 --------------------
218
219 Produces javadocs for a Maven project.
220
221 Expects javadocs to be available in ``$WORKSPACE/target/site/apidocs``, but
222 overrideable with the ``mvn-dir`` parameter. If set, will search for javadocs
223 in ``$WORKSPACE/{mvn-dir}/target/site/apidocs``.
224
225 :Template Names:
226
227     - {project-name}-maven-javadoc-verify-{stream}-{java-version}
228     - gerrit-maven-javadoc-verify
229     - github-maven-javadoc-verify
230
231 :Comment Trigger: recheck|reverify
232
233 :Required parameters:
234     :build-node:    The node to run build on.
235     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
236     :mvn-settings: The name of settings file containing credentials for the project.
237
238 :Optional parameters:
239
240     :branch: The branch to build against. (default: master)
241     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
242     :build-timeout: Timeout in minutes before aborting build. (default: 60)
243     :deploy-path:    The path in Nexus to deploy javadoc to. (default: $PROJECT/$STREAM)
244     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
245     :java-version: Version of Java to use for the build. (default: openjdk11)
246     :mvn-dir: Directory supplied as argument to -f option (default: '.')
247     :mvn-global-settings: The name of the Maven global settings to use for
248         Maven configuration. (default: global-settings)
249     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
250     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
251         Must not include a "-f" option; see parameter mvn-dir.
252     :mvn-version: Version of maven to use. (default: mvn35)
253     :stream: Keyword that represents a release code-name.
254         Often the same as the branch. (default: master)
255     :submodule-recursive: Whether to checkout submodules recursively.
256         (default: true)
257     :submodule-timeout: Timeout (in minutes) for checkout operation.
258         (default: 10)
259     :submodule-disable: Disable submodule checkout operation.
260         (default: false)
261
262     :gerrit_verify_triggers: Override Gerrit Triggers.
263
264 Maven Merge
265 -----------
266
267 Merge job which runs `mvn clean deploy` to build a project.
268
269 This job pushes files to Nexus using cURL instead of allowing the Maven deploy
270 goal to push the upload. This is to get around the issue that Maven deploy does
271 not properly support uploading files at the end of the build and instead pushes
272 as it goes. There exists a ``-Ddeploy-at-end`` feature but it does not work
273 with extensions.
274
275 This job uses the following strategy to deploy jobs to Nexus:
276
277 1. ``wget -r`` to fetch maven-metadata.xml from Nexus
278 2. ``mvn deploy -DaltDeploymentRepository`` to prepare files for upload
279 3. Removes untouched maven-metadata.xml files before upload
280 4. Use lftools (cURL) upload script to push artifacts to Nexus
281
282 :Template Names:
283
284     - {project-name}-maven-merge-{stream}
285     - gerrit-maven-merge
286     - github-maven-merge
287
288 :Comment Trigger: remerge
289
290 :Required parameters:
291
292     :build-node: The node to run build on.
293     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
294     :mvn-settings: The name of settings file containing credentials for the project.
295     :mvn-snapshot-id: Maven Server ID from settings.xml to pull credentials from.
296         (Note: This setting is generally configured in ``defaults.yaml``.)
297     :nexus-snapshot-repo: The repository id of the Nexus snapshot repo to deploy to.
298
299 :Optional parameters:
300
301     :branch: Git branch to fetch for the build. (default: master)
302     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
303     :build-timeout: Timeout in minutes before aborting build. (default: 60)
304     :cron: Cron schedule when to trigger the job. This parameter also
305         supports multiline input via YAML pipe | character in cases where
306         one may want to provide more than 1 cron timer. (default: 'H H * * 0'
307         to run weekly)
308     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
309     :java-version: Version of Java to use for the build. (default: openjdk11)
310     :mvn-global-settings: The name of the Maven global settings to use for
311         Maven configuration. (default: global-settings)
312     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
313     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
314     :mvn-version: Version of maven to use. (default: mvn35)
315     :nexus-cut-dirs: Number of directories to cut from file path for `wget -r`.
316     :stream: Keyword that represents a release code-name.
317         Often the same as the branch. (default: master)
318     :submodule-recursive: Whether to checkout submodules recursively.
319         (default: true)
320     :submodule-timeout: Timeout (in minutes) for checkout operation.
321         (default: 10)
322     :submodule-disable: Disable submodule checkout operation.
323         (default: false)
324
325     :gerrit_merge_triggers: Override Gerrit Triggers.
326     :gerrit_trigger_file_paths: Override file paths to filter which file
327         modifications will trigger a build.
328
329 Maven Merge for Docker
330 ----------------------
331
332 Produces a snapshot docker image in a Nexus registry. Appropriate for
333 Java projects that do not need to deploy any POM or JAR files.
334
335 Like the Maven Merge job as described above but logs in to Docker
336 registries first and skips the lf-maven-deploy builder. The project
337 POM file should invoke a plugin to build and push a Docker image.
338 This pulls the base image from the registry in the environment
339 variable ``CONTAINER_PULL_REGISTRY`` and pushes new image into the
340 registry in the environment variable ``CONTAINER_PUSH_REGISTRY``.
341
342 :Template Names:
343
344     - {project-name}-maven-docker-merge-{stream}
345     - gerrit-maven-docker-merge
346     - github-maven-docker-merge
347
348 :Required parameters:
349
350     :container-public-registry: Docker registry source with base images.
351     :container-snapshot-registry: Docker registry target for the deploy action.
352
353 All other required and optional parameters are identical to the Maven Merge job
354 described above.
355
356 Maven Stage
357 -----------
358
359 Produces a release candidate by creating a staging repo in Nexus.
360
361 The staging repo name is in the format PROJECT-NUMBER for example "aaa-1234",
362 "autorelease-2000", "odlparent-1201", etc...
363
364 This job runs a Maven build and deploys to $WORKSPACE/m2repo directory. This
365 directory is then used later to deploy to Nexus.
366
367 :Template Names:
368
369     - {project-name}-maven-stage-{stream}
370     - gerrit-maven-stage
371     - github-maven-stage
372
373 :Comment Trigger: "stage-release" or "stage-maven-release"
374
375 :Required parameters:
376
377     :build-node: The node to run build on.
378     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
379     :mvn-settings: The name of settings file containing credentials for the project.
380     :mvn-staging-id: Maven Server ID from settings.xml to pull credentials from.
381         (Note: This setting is generally configured in ``defaults.yaml``.)
382     :staging-profile-id: Profile ID of the project's Nexus staging profile.
383
384 :Optional parameters:
385
386     :archive-artifacts: Artifacts to archive to the logs server (default: '').
387     :branch: The branch to build against. (default: master)
388     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
389     :build-timeout: Timeout in minutes before aborting build. (default: 60)
390     :cron: Cron schedule when to trigger the job. This parameter also
391         supports multiline input via YAML pipe | character in cases where
392         one may want to provide more than 1 cron timer. (default: '')
393     :deploy-path:    The path in Nexus to deploy javadoc to. (default: $PROJECT/$STREAM)
394     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
395     :java-version: Version of Java to use for the build. (default: openjdk11)
396     :mvn-central: Set to ``true`` to also stage to **OSSRH**. This is for projects
397         that want to release to Maven Central. If set, then also set the parameter
398         ``ossrh-profile-id``. (default: false)
399     :maven-versions-plugin: Whether to call Maven versions plugin or not. (default: false)
400     :mvn-global-settings: The name of the Maven global settings to use for
401         Maven configuration. (default: global-settings)
402     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
403     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
404     :mvn-version: Version of maven to use. (default: mvn35)
405     :ossrh-profile-id: Profile ID for project as provided by OSSRH.
406         (default: '')
407     :sign-artifacts: Sign artifacts with Sigul. (default: false)
408     :stream: Keyword that represents a release code-name.
409         Often the same as the branch. (default: master)
410     :submodule-recursive: Whether to checkout submodules recursively.
411         (default: true)
412     :submodule-timeout: Timeout (in minutes) for checkout operation.
413         (default: 10)
414     :submodule-disable: Disable submodule checkout operation.
415         (default: false)
416     :version-properties-file: Name and path of the version properties file.
417         (default: version.properties)
418
419     :gerrit_release_triggers: Override Gerrit Triggers.
420     :gerrit_trigger_file_paths: Override file paths to filter which file
421         modifications will trigger a build.
422
423 Maven Stage for Docker
424 ----------------------
425
426 Produces a release candidate docker image in a Nexus registry.
427 Appropriate for Java projects that do not need to deploy any POM or
428 JAR files.
429
430 Like the Maven Stage job as described above but logs in to Docker
431 registries first and skips the lf-maven-deploy builder. The project
432 POM file should invoke a plugin to build and push a Docker image.
433 This pulls the base image from the registry in the environment
434 variable ``CONTAINER_PULL_REGISTRY`` and pushes new image into the
435 registry in the environment variable ``CONTAINER_PUSH_REGISTRY``.
436
437 :Template Names:
438
439     - {project-name}-maven-docker-stage-{stream}
440     - gerrit-maven-docker-stage
441     - github-maven-docker-stage
442
443 :Comment Trigger: "stage-release" or "stage-docker-release"
444
445 :Required parameters:
446
447     :container-public-registry: Docker registry source with base images.
448     :container-staging-registry: Docker registry target for the deploy action.
449
450 :Optional parameters:
451
452     :gerrit_release_docker_triggers: Override Gerrit Triggers.
453
454 All other required and optional parameters are identical to the Maven Stage job
455 described above.
456
457 .. _maven-sonar:
458
459 Maven Sonar
460 -----------
461
462 Sonar job which runs mvn clean install then publishes to Sonar.
463
464 This job purposely runs on the ``master`` branch and does not support
465 multi-branch configuration.
466
467 :Template Names:
468
469     - {project-name}-sonar
470     - gerrit-maven-sonar
471     - github-maven-sonar
472     - {project-name}-sonar-prescan-script
473     - gerrit-maven-sonar-prescan-script
474     - github-maven-sonar-prescan-script
475
476 :Comment Trigger: run-sonar
477
478 :Required parameters:
479
480     :build-node: The node to run build on.
481     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
482     :mvn-settings: The name of settings file containing credentials for the project.
483     :sonar-prescan-script: (maven-sonar-prescan-script jobs) A shell script to run before
484         sonar scans.
485
486 :Optional parameters:
487
488     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
489     :build-timeout: Timeout in minutes before aborting build. (default: 60)
490     :cron: Cron schedule when to trigger the job. This parameter also
491         supports multiline input via YAML pipe | character in cases where
492         one may want to provide more than 1 cron timer.  (default: 'H H * * 6'
493         to run weekly)
494     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
495     :java-version: Version of Java to use for the Maven build. (default: openjdk11)
496     :mvn-global-settings: The name of the Maven global settings to use for
497         Maven configuration. (default: global-settings)
498     :mvn-goals: The maven goals to perform for the build.
499         (default: clean install)
500     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
501     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
502     :mvn-version: Version of maven to use. (default: mvn35)
503     :sonar-mvn-goals: Maven goals to run for sonar analysis.
504         (default: sonar:sonar)
505     :sonarcloud: Set to ``true`` to use SonarCloud ``true|false``.
506         (default: false)
507     :sonarcloud-project-key: SonarCloud project key. (default: '')
508     :sonarcloud-project-organization: SonarCloud project organization.
509         (default: '')
510     :sonarcloud-api-token: SonarCloud API Token. (default: '')
511     :sonarcloud-java-version: Version of Java to use for the Sonar scan. (default: openjdk11)
512     :stream: Keyword that represents a release code-name.
513         Often the same as the branch. (default: master)
514     :submodule-recursive: Whether to checkout submodules recursively.
515         (default: true)
516     :submodule-timeout: Timeout (in minutes) for checkout operation.
517         (default: 10)
518     :submodule-disable: Disable submodule checkout operation.
519         (default: false)
520     :scan-dev-branch: Run the scan on a developer branch.
521         (default: false)
522
523     :gerrit_sonar_triggers: Override Gerrit Triggers.
524
525
526 SonarCloud Example:
527
528 .. literalinclude:: ../../.jjb-test/lf-maven-jobs/maven-sonarcloud.yaml
529    :language: yaml
530
531 Maven Sonar Verify
532 ------------------
533
534 Sonar job which runs mvn clean install then publishes to Sonar.
535
536 This job runs on dev branches and its triggered on new patchsets.
537
538 :Template Names:
539
540     - {project-name}-sonar-verify
541     - gerrit-maven-sonar-verify
542
543 :Comment Trigger: recheck|reverify
544
545 :Required parameters:
546
547     :build-node: The node to run build on.
548     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
549     :mvn-settings: The name of settings file containing credentials for the project.
550
551 :Optional parameters:
552
553     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
554     :build-timeout: Timeout in minutes before aborting build. (default: 60)
555     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
556     :java-version: Version of Java to use for the Maven build. (default: openjdk11)
557     :mvn-global-settings: The name of the Maven global settings to use for
558         Maven configuration. (default: global-settings)
559     :mvn-goals: The maven goals to perform for the build.
560         (default: clean install)
561     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
562     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
563     :mvn-version: Version of maven to use. (default: mvn35)
564     :sonar-mvn-goal: Maven goals to run for sonar analysis.
565         (default: sonar:sonar)
566     :sonarcloud: Set to ``true`` to use SonarCloud ``true|false``.
567         (default: true)
568     :sonarcloud-project-key: SonarCloud project key. (default: '')
569     :sonarcloud-project-organization: SonarCloud project organization.
570         (default: '')
571     :sonarcloud-api-token: SonarCloud API Token. (default: '')
572     :sonarcloud-java-version: Version of Java to use for the Sonar scan. (default: openjdk11)
573     :sonarcloud-qualitygate-wait: SonarCloud flag that forces the analysis step to
574         wait for the quality gate result. (default: false)
575     :stream: Keyword that represents a release code-name.
576         Often the same as the branch. (default: master)
577     :submodule-recursive: Whether to checkout submodules recursively.
578         (default: true)
579     :submodule-timeout: Timeout (in minutes) for checkout operation.
580         (default: 10)
581     :submodule-disable: Disable submodule checkout operation.
582         (default: false)
583     :scan-dev-branch: Run the scan on a developer branch.
584         (default: true)
585
586     :gerrit_sonar_triggers: Override Gerrit Triggers.
587
588
589 SonarCloud Example:
590
591 .. literalinclude:: ../../.jjb-test/lf-maven-jobs/maven-sonarcloud.yaml
592    :language: yaml
593
594 Maven Verify
595 ------------
596
597 Verify job which runs mvn clean install to test a project build..
598
599 :Template Names:
600
601     - {project-name}-maven-verify-{stream}-{mvn-version}-{java-version}
602     - gerrit-maven-verify
603     - github-maven-verify
604
605 :Comment Trigger: recheck|reverify
606
607 :Required parameters:
608
609     :build-node: The node to run build on.
610     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
611     :mvn-settings: The name of settings file containing credentials for the project.
612
613 :Optional parameters:
614
615     :branch: Git branch to fetch for the build. (default: master)
616     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
617     :build-timeout: Timeout in minutes before aborting build. (default: 60)
618     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
619     :java-version: Version of Java to use for the build. (default: openjdk11)
620     :mvn-global-settings: The name of the Maven global settings to use for
621         Maven configuration. (default: global-settings)
622     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
623     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
624     :mvn-version: Version of maven to use. (default: mvn35)
625     :stream: Keyword that represents a release code-name.
626         Often the same as the branch. (default: master)
627     :submodule-recursive: Whether to checkout submodules recursively.
628         (default: true)
629     :submodule-timeout: Timeout (in minutes) for checkout operation.
630         (default: 10)
631     :submodule-disable: Disable submodule checkout operation.
632         (default: false)
633
634     :gerrit_verify_triggers: Override Gerrit Triggers.
635     :gerrit_trigger_file_paths: Override file paths to filter which file
636         modifications will trigger a build.
637
638 Maven Verify for Docker
639 -----------------------
640
641 Like the Maven Verify job as described above but logs in to Docker
642 registries first. The project POM file should invoke a plugin to build
643 a Docker image. This pulls the base image from the registry in the environment
644 variable ``CONTAINER_PULL_REGISTRY``.
645
646 :Template Names:
647
648     - {project-name}-maven-docker-verify-{stream}-{mvn-version}-{java-version}
649     - gerrit-maven-docker-verify
650     - github-maven-docker-verify
651
652 :Required parameters:
653
654     :container-public-registry: Docker registry source with base images.
655
656 All other required and optional parameters are identical to the Maven Verify job
657 described above.
658
659 Maven Verify w/ Dependencies
660 ----------------------------
661
662 Verify job which runs mvn clean install to test a project build /w deps
663
664 This job's purpose is to verify a patch in conjunction to a list of upstream
665 patches it depends on. The user of this job can provide a list of patches via
666 comment trigger.
667
668 :Template Names:
669
670     - {project-name}-maven-verify-deps-{stream}-{mvn-version}-{java-version}
671     - gerrit-maven-verify-dependencies
672
673 :Comment Trigger: recheck: SPACE_SEPARATED_LIST_OF_PATCHES
674
675 :Required parameters:
676
677     :build-node: The node to run build on.
678     :jenkins-ssh-credential: Credential to use for SSH. (Generally configured in defaults.yaml)
679     :mvn-settings: The name of settings file containing credentials for the project.
680
681 :Optional parameters:
682
683     :branch: Git branch to fetch for the build. (default: master)
684     :build-days-to-keep: Days to keep build logs in Jenkins. (default: 7)
685     :build-timeout: Timeout in minutes before aborting build. (default: 60)
686     :git-url: URL clone project from. (default: $GIT_URL/$PROJECT)
687     :java-version: Version of Java to use for the build. (default: openjdk11)
688     :mvn-global-settings: The name of the Maven global settings to use for
689         Maven configuration. (default: global-settings)
690     :mvn-opts: Sets MAVEN_OPTS to start up the JVM running Maven. (default: '')
691     :mvn-params: Parameters to pass to the mvn CLI. (default: '')
692     :mvn-version: Version of maven to use. (default: mvn35)
693     :stream: Keyword that represents a release code-name.
694         Often the same as the branch. (default: master)
695     :submodule-recursive: Whether to checkout submodules recursively.
696         (default: true)
697     :submodule-timeout: Timeout (in minutes) for checkout operation.
698         (default: 10)
699     :submodule-disable: Disable submodule checkout operation.
700         (default: false)
701
702     :gerrit_verify_triggers: Override Gerrit Triggers.
703     :gerrit_trigger_file_paths: Override file paths to filter which file
704         modifications will trigger a build.