-
Notifications
You must be signed in to change notification settings - Fork 620
Description
What feature do you want to see added?
Currently, when defining Jenkins pipeline jobs using Job DSL, the GitLab plugin requires the deprecated syntax:
triggers {
gitlabPush {
buildOnMergeRequestEvents(true)
buildOnPushEvents(true)
enableCiSkip(true)
}
}
This generates deprecation warnings in Job DSL seed jobs:
Warning: triggers is deprecated
Problem:
Job DSL now prefers properties { pipelineTriggers { ... } } for defining triggers.
The GitLab plugin (v1.9.9) does not currently support this API.
Users are forced to continue using the deprecated syntax, creating warnings and reducing clarity.
Impact:
Seed job logs are noisy due to warnings.
Encourages continued use of deprecated DSL constructs.
Reduces maintainability and clarity of pipeline definitions.
Proposed Solution / Feature Request:
Add support for defining GitLab triggers using the modern pipelineTriggers block.
Example of the desired syntax:
properties {
pipelineTriggers {
triggers {
gitlabPush {
buildOnMergeRequestEvents(true)
buildOnPushEvents(true)
enableCiSkip(true)
}
}
}
}
Benefits:
Eliminates deprecation warnings in Job DSL scripts.
Aligns the GitLab plugin with modern Job DSL best practices.
Improves maintainability and readability of Jenkins pipelines.
Environment:
Jenkins version: 2.516.3
GitLab plugin version: 1.9.9
Job DSL plugin version: 1.93
Upstream changes
No response
Are you interested in contributing this feature?
No response