How to use @Transactional annotation in a spring boot application

The @Transactional annotation in Spring Boot is a powerful mechanism that provides declarative transaction management for applications.