Repository navigation
Spring Boot + Thymeleaf + htmx: MaxUploadSizeExceededException(413) handling #8
Unanswered
knowledgefactory4u
asked this question in
Q&A
Replies: 3 comments 1 reply
|
I tried with response-targets.js as well to handle the 5**/4** error, but it is still not working. |
0 replies
|
Can you try what happens if you remove |
0 replies
|
I tried it and explored further, and found the response of two scenarios Case 1: (Successfull upload) Response Case 2: (File Size exceeds 12 MB) Response There is a mismatch for the header in success and failed scenario. Means, the connection is closed. |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
There is an endpoint to upload a file, and I am trying to handle the MaxUploadSizeExceededException(Global) and show the custom message on the UI.
But the application is not showing the error message on the UI.
Console error:

Here is the code that I have tried so far:
pom.xml
application.properties
FileUploadController.java
GlobalExceptionHandler .java
upload.html
message.html
Could you point me in the right direction or tell me what I am missing?
All reactions