How could I solve this in my spring web application? It is working in JDK 1.7, Spring 4.1.3 RELEASE and WebLogic 10 but when we upgrade JDK 1.8 , Spring 4.1.3 RELEASE and Weblogic 12.2 it is failing.
can we increase header size in RestTemplate
. Please let me know
Please find below error
**<h1>Bad Message 431</h1><pre>reason: Request Header Fields Too Large</pre>"
2020-11-10 12:06:05.574 headers [DEBUG] http-outgoing-0 << HTTP/1.1 431 Request Header Fields Too Large
2020-11-10 12:06:05.574 headers [DEBUG] http-outgoing-0 << Content-Type: text/html;charset=iso-8859-1
2020-11-10 12:06:05.574 headers [DEBUG] http-outgoing-0 << Content-Length: 74
2020-11-10 12:06:05.590 headers [DEBUG] http-outgoing-0 << nnCoection: close
2020-11-10 12:06:05.590 MainClientExec [DEBUG] Connection can be kept alive indefinitely
2020-11-10 12:06:05.590 PoolingHttpClientConnectionManager [DEBUG] Connection [id: 0][route: {s}-> can be kept alive indefinitely
2020-11-10 12:06:05.590 DefaultManagedHttpClientConnection [DEBUG] http-outgoing-0: set socket timeout to 0
2020-11-10 12:06:05.590 PoolingHttpClientConnectionManager [DEBUG] Connection released: [id: 0][route: {s}->][total kept alive: 1; route allocated: 1 of 2; total allocated: 1 of 20]
2020-11-10 12:06:05.605 ServiceImpl [ERROR] ValidateToken Service failed with this exception: <h1>Bad Message 431</h1><pre>reason: Request Header Fields Too Large</pre>
2020-11-10 12:06:05.637 ExceptionControllerAdvice [ERROR] Unhandled exception.
java.lang.ClassCastException: java.lang.String cannot be cast to java.util.Map
at com.agreement.rest.domain.Exception.fromJsonToException(Exception.java:78)**