Actually it could be either.  In the case of servlets, you normally only
have to really worry about class variables since the Servlet Engine will be
running multiple threads through your servlets.  But if there's the
possibility of more than one thread modifying the instance variables of a
single instance, it should be synchronized as well.
    (*Chris*)

----- Original Message -----
From: Michael Sierchio <[EMAIL PROTECTED]>
To: Chris Pratt <[EMAIL PROTECTED]>
Sent: Thursday, April 22, 1999 6:29 PM
Subject: Re: Thread-Safe.


> Chris Pratt wrote:
> >
> > That seems way over the top.  You only need to synchronize methods that
> > change global resources like files or member variables.  Most routines
will
> > run in multiple threads without any problem and synchronizing them will
> > really slow your system down.
>
> By "member" variable, do you mean a class variable rather than an
> instance variable?
>

___________________________________________________________________________
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

Reply via email to