How can you maintain servlet chaining?



How can you maintain servlet chaining?..

Answer / bikash khuntia

you can maintain servlet chaining by using:

1. RequestDispatcher
2. include

Step 1: Set the request

request.setAttribute(key,value);

Step 2: Implimanting of RequestDispatcher

RequestDispatcher rsd = getServletContext().
getRequestDispatcher("Servletname");

Step 3: Forward or include the request and response by

rsd.forward(request,response);

rsd.include(request,response);

Is This Answer Correct ?    2 Yes 3 No

Post New Answer

More Servlets Interview Questions

What is the difference between CGI and Servlet?

0 Answers  


What is the difference between RequestDispatcher and sendRedirect?-

5 Answers   CTS,


Explain is servlet mapping?

0 Answers  


List some life cycle methods of a servlet.

0 Answers  


What are different types of SessionTracking?

2 Answers  






Explain the difference between GET and POST methods?

6 Answers  


Name the webserver that is used to run Servlets?

5 Answers  


How to get the server information in a servlet?

0 Answers  


Can we get PrintWriter and ServletOutputStream both in a servlet?

0 Answers  


what is SSL?

3 Answers  


Why is Servlet so popular?

0 Answers  


How to notify an object in session when session is invalidated or timed-out?

0 Answers  


Categories