1

When field in my plugin is filled with about 5000 characters it gives error:

Bad Message 414
reason: URI Too Long

When I make it less a bit, it gives:

Bad Message 431
reason: Request Header Fields Too Large

config.jelly:

<f:entry field="field" title="Example">
   <f:textarea value="${it.getField()}"/>
</f:entry>

java:

private String field;
...
public FormValidation doCheckField(@QueryParameter String value)
            throws IOException, ServletException {
    if (value.length() == 0) {
        return FormValidation.error("Please set an input");
    } else {
        return FormValidation.ok();
    }
}
A_Rybin
  • 121
  • 1
  • 8

1 Answers1

6

It was fixed by adding to Jenkins config

  • /etc/sysconfig/jenkins for default SLES installation
  • C:\Program Files (x86)\Jenkins\jenkins.xml in Windows

JENKINS_ARGS="--requestHeaderSize=32768"
fusion27
  • 2,396
  • 1
  • 25
  • 25
A_Rybin
  • 121
  • 1
  • 8