aspose file tools*
The moose likes Servlets and the fly likes how many servlet instances will be created Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "how many servlet instances will be created " Watch "how many servlet instances will be created " New topic
Author

how many servlet instances will be created

samdeep aarzoo
Ranch Hand

Joined: Jun 09, 2005
Posts: 160

hi
please help me in understanding:
if there are 10 clients (10 threads) do request
over some servlet , than how many instances of servlet
will be created .
whether it is 1 or 10

please tell also in comparison to single thread model
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

There will be one servlet instance which will handle each request in a new and separate thread.

Read section SRV.2.2 of the details.Servlet Spec for more details.
[ September 25, 2005: Message edited by: Ben Souther ]

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
jQuery in Action, 2nd edition
 
subject: how many servlet instances will be created
 
Similar Threads
How many instances of EJB(business logic)
Some Clarification about servlet ??
singlethread model
Servlet init()
init()