Replies: 5 comments 28 replies
|
Thanks for bringing this up. Does what you describe (or something similar) really work in Spring Boot? Can you show me an example? When that is triggered, where is the value returned to? |
0 replies
|
hi @geoand! |
8 replies
4 replies
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.
Hi,
We're investigating whether Quarkus supports — or could support — a global, annotation-driven exception handling mechanism that is not tied to the HTTP response pipeline, but works across the entire application layer.
The core problem
JAX-RS ExceptionMapper is HTTP-centric by design — its sole purpose is to convert exceptions into Response objects. We're looking for something more general: a cross-cutting exception handler that can intercept exceptions regardless of where they are thrown (service layer, repository layer, background jobs, etc.), execute arbitrary logic, and optionally produce a result — without being constrained to return a Response or any specific type.
In Spring,
@ControllerAdvice+@ExceptionHandleris HTTP-scoped, but CDI interceptors and AOP (@Aroundadvice) can handle this more general case. We're looking for the Quarkus equivalent.What we'd like to achieve
Something like:
@GlobalExceptionHandler// custom annotation we'd defineKey requirements:
Questions
We're aware of related HTTP-scoped issues #5392, #4042, and #11557 but those are all constrained to the HTTP pipeline, which is not our primary goal here.
Thanks for any guidance!
All reactions