jenkinsci / jenkinsci/java-client-api

status code: 414, reason phrase: Request-URI Too Large

オープン
#462 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
Java
スター
913
フォーク
466
PR マージ指標
30日以内にマージされた PR はありません

説明

`org.apache.http.client.HttpResponseException: status code: 414, reason phrase: Request-URI Too Large
at com.offbytwo.jenkins.client.validator.HttpResponseValidator.validateResponse(HttpResponseValidator.java:11)
at com.offbytwo.jenkins.client.JenkinsHttpClient.post(JenkinsHttpClient.java:261)
at com.offbytwo.jenkins.model.Job.build(Job.java:151)
at com.offbytwo.jenkins.model.Job.build(Job.java:113)`

when build job with params, The parameter is a very long value, there will be the following error.In the source code, although the operation is a post request, he stitched the parameters on the url.

` public QueueReference build(Map params, Map fileParams, boolean crumbFlag) throws IOException {
String qs = join(Collections2.transform(params.entrySet(), new MapEntryToQueryStringPair()), "&");
ExtractHeader location = client.post(url + "buildWithParameters?" + qs,null, ExtractHeader.class, fileParams, crumbFlag);
return new QueueReference(location.getLocation());
}`

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

Start at Job.java in the build(Map params, ...) method and follow its call to JenkinsHttpClient.post. Reproduce the failure with a parameter value long enough to trigger HTTP 414, then verify that parameterized builds no longer place the full value in the request URI and complete successfully.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
java
領域
api
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
明確に書かれている
初心者へのやさしさ
45/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。