Skip to content

[Spring Boot 3.x] 404 Not Found behavior #38826

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
BruceAn1978 opened this issue Dec 15, 2023 · 2 comments
Closed

[Spring Boot 3.x] 404 Not Found behavior #38826

BruceAn1978 opened this issue Dec 15, 2023 · 2 comments
Labels
for: stackoverflow A question that's better suited to stackoverflow.com status: invalid An issue that we don't feel is valid

Comments

@BruceAn1978
Copy link

A json responsed like below and no any exception was threw on server sider when I access a 404 url (springboot 3.1.5):

{
  "timestamp": "2023-12-15 09:11:15",
   "path": "/time",
   "status": 404,
   "error": "Not Found",
   "requestId": "8a3f3980-1"
}

I have not configure any global ExceptionHandler, It should throw a exception and can be caught by global ExceptionHandler, then the response can be adapted to some customized content.

@bclozel
Copy link
Member

bclozel commented Dec 15, 2023

I have asked for a small project that reproduces the problem. This seems more like a question to me - please reach out on StackOverflow and create a question there. You should add as much details as possible there. It's not clear here if you're asking how to handle such exceptions or if your exception handler is not working. I'm closing this issue as a result.

@bclozel bclozel closed this as not planned Won't fix, can't repro, duplicate, stale Dec 15, 2023
@bclozel bclozel added status: invalid An issue that we don't feel is valid for: stackoverflow A question that's better suited to stackoverflow.com and removed status: waiting-for-triage An issue we've not yet triaged labels Dec 15, 2023
@BruceAn1978
Copy link
Author

Just a simple issue, it will throw an exception on the server sider while accessing a 404 url without any global exception handler.
No any exceptions were threw on the server sider and a json response was returned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
for: stackoverflow A question that's better suited to stackoverflow.com status: invalid An issue that we don't feel is valid
Projects
None yet
Development

No branches or pull requests

3 participants