background
Today, when I used springboot to develop my blog system, the following exception always appeared when I click Submit markdown file in the browser:
java.lang.IllegalArgumentException: Request header is too large
The web technology stack used is springboot, with Tomcat service embedded
Solution
After troubleshooting, it is because the server has a request length configuration. You can see from the source code of the server configuration class serverproperties that there are the following parameters:
/**
* Maximum size, in bytes, of the HTTP message header.
*/
private int maxHttpHeaderSize = 0; // bytes
There is a HTTP header maximum value setting, the unit is byte, as long as the application.properties The maximum value of file configuration is enough
#Request header length limit
server.max-http-header-size=10000000
Read More:
- [Solved] Browser Access Error: Request Header or Cookie too large
- [Solved] Nginx Error: 400 Request Header Or Cookie Too Large
- Grafana Error: 414 Request-URI Too Large [How to Solve]
- Solution to java.lang.IllegalArgumentException: Property’dataSource’ is required
- [Solved] nodejs Error: request entity too large
- How to Solve Nginx 413 Error (request entity too large)
- [Solved] ES Query SIZE too large Error: ENTITY CONTENT IS TOO LONG [105539255] FOR THE CONFIGURED BUFFER LIMIT [104857600]
- Hive ERROR Failed with exception java.io.IOException:java.lang.IllegalArgumentException
- .Net Core 5.0 Upload File limit via Swagger Api report error: error: request entity too large [Three Methods]
- [Solved] ELK Log System Error: “statusCode“:429,“error“:“Too Many Requests“,“message“ Data too large
- [Solved] Request processing failed; nested exception is java.lang.NullPointerException
- [Solved] .java.lang.IllegalArgumentException: requirement failed: Can only call getServletHandlers on a runn
- POI Export Excel Error: HTTP Status 500 – Request processing failed; nested exception is java.lang.NullPointerException
- [Solved] JMeter Server Command line pressure measurement: Error in NonGUIDriver java.lang.IllegalArgumentException
- [Solved] Hive tez due to: ROOT_INPUT_INIT_FAILURE java.lang.IllegalArgumentException: Illegal Capacity: -38297
- Tomcat Error parsing HTTP request header Note: further occurrences of HTTP header parsing errors
- [Solved] Response Export error on submit request on future invoke, java.lang.OutOfMemoryError: Java heap space
- Error (17) solves the problem of losing the request header of multithread asynchronous feign call
- Error in plot.new() : figure margins too large
- [Solved] sqoop Error: jSQLException in nextKeyValue Caused by: ORA-24920:column size too large for client