MateusLeviDev / devops-lyceum

0 stars 0 forks source link

L-23 @ API Implementation: Create Exception Handler #4

Closed MateusLeviDev closed 7 months ago

MateusLeviDev commented 7 months ago

the GlobalExceptionHandler class is annotated with @ControllerAdvice, which means it will be called whenever an exception is thrown in the application. https://nikhilsukhani.medium.com/mastering-exception-handling-in-spring-boot-using-controlleradvice-and-exceptionhandler-e676b5dd62ed

O GlobalExceptionHandler é um componente anotado com @ControllerAdvice, o que significa que ele atua globalmente em toda a aplicação Spring.