Hi there,

Here is another question how to design functions for a servlet.
IMHO for every request made to a servlet the service function is called again.
But what happens, when a critical function  is called by two or more service functions 
at the same time?
For instance a function which handles a database connection and the belonging queries.
What happens, when a second service function call this method while it handle's a 
database querie for the first one?
The first one will have no chance to complete the request, right?
Should the database function synchronized or is it better to implement the 
SingleThreadModel?
I think it is easier to implement the SingleThreadModel, because i've a lot of 
functions the must be synchronized and
then i'am afraid to have a deadlock in the system.
Any comments or suggestions?

                Mirko

___________________________________________________________________________
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