doFilter « Filter « JSP-Servlet Q&A

1. Servlet Filter: Socket need to be referenced in doFilter()

Right now I have a filter that has the sockets opened in the init and for some reason when I open them in doFilter() it doesn't work with the server app ...

2. Is doFilter() executed before or after the Servlet's work is done?

The javax.servlet.Filter object can be used both for authentication (where the Filter needs to catch the request before any servlet work needs to be done) and for XSLT translation ...

3. What is doFilter doing in doFilter method in filters of java?

I wanna know that in our dofilter method i made this call chain.doFilter. What is doFilter doing inside a doFilter?Is it not gonna get recursive call?

4. in servlet Filter's method doFilter does not call

i have to create a program to login on facebook using example but when i run project then i get my doFilter method does not call after complete ...

5. doFilter not getting called

Could you help to check why doFilter not getting called web.xml:

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi=""    xmlns="" xmlns:web="" xsi:schemaLocation="" id="WebApp_ID" version="2.5">