Hi,
I would say DO NOT implement it. It will slow down your servlet very
much.
The only thing you have to do is be sure that your (multi threaded) servlet
to
be thread save. I can't understand 100% what means thread safe but you will
have to take care about accesing global variables.
If you acces (or modify) a global variable than you have to syncronize
that block
of code. Aslo you can syncronize a method.
You can modify any object created in the service (doGet or doPost)
because
this will be thread safe.
My advice is don't use STM and search the archives (i have seen on this
list
much better explanations about thread safe issues) or in books how to make
your servlet thread safe.
Best wishes,
Andras.
----- Original Message -----
From: "G S Sundar" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, November 02, 2000 7:52 AM
Subject: Single Thread Model..
> Hello All,
> I would like to make my servlet application to be thread safe,
> so, i'm trying to implement the SingleThreadMethod interface.
> Can some one throw some light on it how to implement exactly
> and sample code will be appriciated..
>
> SingleThreadModel:
> As per the document, no two threads can call the service method at a time.
> Or the servlet container maintain the pool of servlet instances(what is
this
> pool instances) and it will pass the request to the free instance..
>
> Thanx in advance
>
> Regards
> G S Sundaram
>
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html