PDA

View Full Version : How to access Beans from servlet filter


VJJ
Oct 11th, 2007, 07:36 PM
I would like to access the spring beans from a servlet filter class. How can I do it?

Mike Bingham
Oct 11th, 2007, 07:58 PM
You could use the DelegatingFilterProxy class provided by Spring:

http://www.springframework.org/docs/api/org/springframework/web/filter/DelegatingFilterProxy.html

See the following for an example:

http://forum.springframework.org/showthread.php?p=42415