IntelliJ Java IDE
The moose likes Spring and the fly likes Difference between AOP and Interceptor Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Application Frameworks » Spring
Reply Bookmark "Difference between AOP and Interceptor" Watch "Difference between AOP and Interceptor" New topic
Author

Difference between AOP and Interceptor

Naresh Shanmugam
Ranch Hand

Joined: Jul 16, 2010
Posts: 76
If a project is designed using Spring and Struts2, can somebody tell when to use Interceptor in Struts2 and When to use AOP in Spring. This is always confusing us.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12612
Use S2 interceptors when it's something related only to the normal S2 flow and/or need access to S2 infrastructure. Use AOP for everything else.
Naresh Shanmugam
Ranch Hand

Joined: Jul 16, 2010
Posts: 76
need access to S2 infrastructure


David could you please give me an example for this.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12612
Something on the value stack, like the action.
Naresh Shanmugam
Ranch Hand

Joined: Jul 16, 2010
Posts: 76
Got the point. Thanks for your valuable time David
 
 
subject: Difference between AOP and Interceptor
 
Threads others viewed
AOP
struts2 problem
struts2 + interceptor
Struts2 with Spring AOP
How to Configure interface Preparable in Struts2..
developer file tools

cast iron skillet 49er

more from paul wheaton's glorious empire of web junk: cast iron skillet diatomaceous earth rocket mass heater sepp holzer raised garden beds raising chickens lawn care CFL flea control missoula heat permaculture