Dealing with large diagram URLs - Bad Message 431 Error

0 votes
asked Oct 27 in Question / help by brettblue (180 points)

I'm running the Plantuml Jetty docker container to host Plantuml on my own server. All has been working well, but I have a diagram url with more than 8k worth of characters (which I think is the default request header limit), 8,027 characters to be exact, so I get the following error:

Bad Message 431

reason: Request Header Fields Too Large

I have spent hours trying to figure out how to increase the request header fields limit in the Jetty container configuration, and I've looked at the Jetty documentation, but between the *.ini, *.xml, and other configuration files, I could not seem to get the change to take effect (after trying to edit various files such as server.ini, while removing the comment mark from the setting and restarting the container). I'm sure it is something simple for someone who knows how to do it, so if someone could please take a moment and let me know how, it would be MUCH APPRECIATED!!

...or if I am mistaken as to what the problem is, that would be helpful as well, but the error seems pretty self-explanatory.

1 Answer

0 votes
answered Oct 28 by brettblue (180 points)

I read more carefully through the documentation and ended up editing the jetty.xml file which worked! In case it helps anyone else...

 <Set name="requestHeaderSize"><Property name="jetty.httpConfig.requestHeaderSize" deprecated="jetty.request.header.size" default="32768" /></Set>

commented Oct 28 by plantuml (207,620 points)
Thanks for your contribution!

It may indeed help others.
...