Invoked BuildJob but raised "Don't have key Location in response of header"
ShenSteve opened this issue · 2 comments
ShenSteve commented
using release v1.0.1,
API response status code is 200 or 201, but no location in response header, the build hasn't been triggered on Jenkins.
errors.New("Don't have key "Location" in response of header")
What kind of cause leads to this error? I mean, the response code is 200/201, but the build hasn't been triggered in fact.
lcsoft2009 commented
Hi @ShenSteve
I got the same issue and solved by corrected my job name with the folder path(multibranch job).
wrong job name: testJob
correct job name: testJob/job/develop/
shreshth0707 commented
For a multibranch job , the name of the job should include the branch name as well
Ex: Jobname : testJob
Branch Name : master
jenkins.BuildJob(ctx,"testJob/job/master", nil)