jenkinsci / jenkinsci/java-client-api

DisableJob function have a problem with Jobs inside folders

Open
#430 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
Java
Stars
913
Forks
466
PR merge metrics
No merged PRs in 30d

Description

Hello,

If we have a Job inside a folder, EncodingUtils.encode(jobName) will transform backslash "/" character into "%2F" and thus job will not be found.

public void disableJob(String jobName, boolean crumbFlag) throws IOException {
client.post("/job/" + EncodingUtils.encode(jobName) + "/disable", crumbFlag);
}

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.