When defining a Jersey resource class as a Spring component, if you use JSR-330's @ Name
instead of Spring's @ Component
, Spring AOP using @ Transactional
or @ Aspect
will work. Absent.
According to Jersey's Official Reference, you need to use one of the following annotations for your resource class.
@Component
@Service
@Controller
@Repository
@Component // @AOP doesn't work with Named
public class SampleResource { ...
Recommended Posts