简体   繁体   中英

Conflicting method names in Jenkins

I am using Jenkins Templating Engine, and I created a few libraries that implement the build step, eg cmake library.

The problem is, that down the flow I want to call the Build a job step contributed by the Pipeline plugin suite, and once I try to call it:

build job: "Job_Name", parameters: "..."

I get an error from JTE because it tries to call my cmake::build step. Is there a way to call the Pipeline's build step explicitly?

I think this could help:

'org.jenkinsci.plugins.workflow.support.steps.build.BuildTriggerStep'(job: "job name")

What this does is calling directly the BuildTriggerStep , which is the class under the package org.jenkinsci.plugins.workflow.support.steps.build and will do exactly the same as the build step.

I got that from The source code of the build step plugin

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM