what is the advantage of using Servlets over CGI programming?

Answer Posted / janet

Servlets are only instantiated when the client first
accesses the program. All subsequent accesses are done to
that instance.This keeps the response time of servlets lower
than that of CGI programs, which must be run once per
hit.also because servlet is instantiated only once,all
accesses are put through that one object. This helps in
maintaining objects like internal connection,pooling or user
session tracking and lots of other features.

Is This Answer Correct ?    11 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the different methods involved in the process of session management in servlets?

671


What do you mean by the servlet chaining?

549


Why servlet is used as controller ? Not JSP? I want complete explation?

660


Write a program to show the functionality of servlets.

557


Why the concept of single thread model interface is used?

556






What is new in ServletRequest interface ? (Servlet 2.4)

577


How to get the actual path of servlet in server?

739


Difference between java beans & servlets?

591


What is the purpose of inter-servlet communication?

595


What is the directory structure of web application?

530


What are the differences between the servletconfig interface and the servletcontext interface?

586


Can you create a deadlock condition on a servlet?

589


What are all the advantages of servlet over cgi?

608


Explain the concept of ssi ?

595


What is the need of session tracking in web application?

585