Explain Life cycle of Servlet Filter.
Answer Posted / surajkumar.java
A java class which implements javax.servlet.Filter is
configured as filter in web.xml file.
The web container calls the init method to initialize filter
by passing javax.servlet.FilterConfig object to retrieve the
filter’s init parameters.
The doFilter method of Filter class performs the actual
processing like authentication, data format conversion and
page redirect to other page and catching etc. The doFilter
method passes the request and response object of the current
request and the filter chain object to invoke next filter in
the chain.
Web container calls the destroy() method to take the filter
out of service.
Is This Answer Correct ? | 29 Yes | 7 No |
Post New Answer View All Answers
what are memory considerations of jsp compares to other web components?
What are the different class loaders used by jvm?
What is the form of storage space in java?
How messaging services are done, before release of JMS?
What happens when a thread cannot acquire a lock on an object?
How can I scroll through list of pages like the search results in google?
Can I map more than one table in a cmp?
Explain about local interfaces.
Define the remote object implementation?
When a thread blocks on i/o, what state does it enter?
Can I run seam outside of jboss as?
What is threadfactory?
What is the difference between the session.get() method and the session.load() method?
What is abstract schema?
What is an abstract method?