The starting point is the BranchSource object, so configurations always start with branchSource: .
|
For more information on how to configure various options related to Multibranch Pipelines via YAML syntax, see Mutibranch Pipeline Template yaml syntax guide. |
-
$class: 'DefaultBranchPropertyStrategy'
All branches get the same properties
Table 1. DefaultBranchPropertyStrategy
parametersParameter Type Description props
List of Nested Choice of BranchProperty objects
-
$class: 'NamedExceptionsBranchPropertyStrategy'
Named branches get different properties
Table 2. NamedExceptionsBranchPropertyStrategy
parametersParameter Type Description defaultProperties
List of Nested Choice of BranchProperty objects
namedExceptions
List of Nested Named object
BranchProperty objects
-
$class: 'DurabilityHintBranchProperty'
This setting allows users to change the default durability mode for running Pipelines. In most cases this is a trade-off between performance and the ability for running pipelines to resume after unplanned Jenkins outages.
What does this do?
Previously, running pipelines wrote data constantly, so that they could resume even if Jenkins fails. This setting gives the user the ability to adjust this write behavior. Higher-performance/lower-durability modes write data to disk much less often for running pipelines. Writing data less often can massively reduce build times for Pipelines with many steps or complex logic. For pipelines which spend most of their time waiting for a shell/batch script to run, the difference will be less visible.
Running pipelines with lower durability settings may lose data if they do not finish and Jenkins is not shut down gracefully. A "graceful" shutdown is where Jenkins goes through a full shutdown process, such as visiting
http://[jenkins-server]/exit
. A "dirty" shutdown, such as using kill -9 to terminate the Jenkins process, may prevent incomplete pipelines from persisting data. Pipelines that cannot persist data may not be able to resume or displayed in Blue Ocean/Stage View/etc.Pipelines will generally write log data regardless of durability settings. Some modes use an "atomic write" option - this helps ensure that pipeline build files aren’t overwritten or left partially written if something fails. Atomic writes may place more stress on filesystems, so especially with networked storage it may be faster not to use them.
Defaults may be set globally under Manage Jenkins > Configure System. Table 3. DurabilityHintBranchProperty
parametersParameter Type Description hint
Values:
PERFORMANCE_OPTIMIZED
,SURVIVABLE_NONATOMIC
,MAX_SURVIVABILITY
-
$class: 'NoTriggerBranchProperty'
This setting suppresses the build trigger coming from branch indexing or normal SCM commit events.
Table 4. NoTriggerBranchProperty
parametersParameter Type Description suppressAutomaticTriggering
Values:
EVENTS
,INDEXING
,NONE
Named object
Named exception
Parameter | Type | Description |
---|---|---|
|
String |
The name of the branch that this exception applies to. Name matching is case insensitive. This name can be a comma separated list of names. The name can include Ant style wildcards. Prefixing a name with Some examples:
|
|
List of Nested Choice of BranchProperty objects |