aspose file tools*
The moose likes Servlets and the fly likes servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "servlets" Watch "servlets" New topic
Author

servlets

kesavareddy evuri
Greenhorn

Joined: Mar 22, 2006
Posts: 4
if impliment single thread model is depriciated in servlets what is the alternate to that


kesav
Mani Ram
Ranch Hand

Joined: Mar 11, 2002
Posts: 1140
The alternate is obviously the Multi-threaded model. Unfortunately, the Servlet container can't help you in this model as it did in case of Single threaded model. You need to make your application thread safe, by the traditional way - protect the shared resources (if any) yourself.


Mani
Quaerendo Invenietis
Vicky Pandya
Ranch Hand

Joined: Dec 16, 2004
Posts: 148
Originally posted by kesavareddy evuri:
if impliment single thread model is depriciated in servlets what is the alternate to that


use synchronized blocks only for the resources, code you wish you to protect.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61652
    
  67

Please read this with regards to naming your topics.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
wood burning stoves
 
subject: servlets