-
1. Re: Need suggestion to use Interceptor for logging
jaikiran Jul 19, 2012 2:57 AM (in response to aanshu_2302)1 of 1 people found this helpfulKeeping aside performance considerations, what kind of logging do you expect from the interceptor? All it can do is perhaps log certain generic log messages like "entering method" kind of stuff. If you want real/detailed logging from the beans, then directly using the logger within the bean implementation is a better way to do it.
-
2. Re: Need suggestion to use Interceptor for logging
aanshu_2302 Jul 19, 2012 3:03 AM (in response to jaikiran)Yes. I was thinking of implementing so that I get proper logs before each EJB call that doSoemthing() called and then I could figure out the from the logs where some problem occured.
This was my scenario.
For detailed, logging of exception, I think loggers are better. I just wanted to seek opinion if anybody came across some benefits with Interceptors.
When should be use Interceptors?
1. For logging, business critical methods.?
2. Security authentication?
Any other use cases that you can suggest?
-
3. Re: Need suggestion to use Interceptor for logging
sfcoy Jul 19, 2012 3:15 AM (in response to aanshu_2302)Anshu Gupta wrote:
...
Any other use cases that you can suggest?
I've worked on projects that use the org.springframework.ejb.interceptor.SpringBeanAutowiringInterceptor to set up @Autowired annotations on EJBs.