-----------------------------
Please read the FAQ!
<http://java.apache.org/faq/>
-----------------------------

Thanks Jon, I believe you are right.  How about this question instead:  Is
it possible to do a synchronization on a particular session object so that
it sychronizes a block of code for a particular user only?  I have tried
something like:

HttpSession session = req.getSession(true);

synchronized (session) {
... code ...
}

And it causes every user to wait in line to use this code.  Am I not
understanding sychronization blocks perhaps?

-- Joshua Slack


> Is this probable, based on my description of the problem?  If so, can it
be
> fixed with synchronization?  Will that cause unwanted pauses from user to
> user, or can I set up synchronization to be on a per-user basis?

you don't give a lot of details about how your servlet is dealing with the
data...but servlets are multithreaded so that is the first consideration
that you need to take. if you are doing something that two threads could
screw up, then your servlet will definately not work properly.

-jon




--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html>
Problems?:           [EMAIL PROTECTED]

Reply via email to