- Controller based - Define exception handler methods in the controller class. Annotate these methods using @ExceptionHandler.
- Global Exception handler - @ControllerAdvice annotation that can be used with any class to define our global exception handler.
- HandlerExceptionResolver - This interface can be used to create global exception handler.
No comments:
Post a Comment