Wrox Home  
Search P2P Archive for: Go

  Return to Index  

j2ee thread: =?iso-8859-1?Q?RE=3A_=C4j2ee=C5_Instance_of_servlet_in_Servlet? =?iso-8859-1?Q?_Container?=


Message #1 by Juha.Kauhanen@t... on Thu, 16 May 2002 11:27:00 +0300
There's only one instance. The container creates new threads for 
concurrent
requests. If you wanted a new instance being created every time, use
SingleThreadModel. If a servlet implements this interface, you are
guaranteed that no two threads will execute concurrently in the 
servlet's
service method.

-----Original Message-----
From: KaipaSudhakaraReddy [mailto:kaipa_r@y...]
Sent: 15 May 2002 18:26
To: Java 2 Enterprise Edition
Subject: =C4j2ee=C5 Instance of servlet in Servlet Container

Iam getting a concurrency problem in servlets.Basicall I want to
know ,when the request comes to the container then it will send to a
servlet (one instance).If another request comes at thet same time what
will happen,Is the servlet container is going to create another 
instance
of the Servlet or it reuses the instance which already there.
to unsubscribe send a blank email to leave-j2ee-639981E=C9p2p.wrox.com.

  Return to Index