Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to make servlet thread safe?

Answer Posted / tulasi vani

There are two different ways of making a servlet thread
safe namely

1.By implementing SingleThreadModel.

By implementing a SingleThreadModel it will be possible to
create a Thread safe servlet.There can only be one user at
a given point of time.

2.Synchornize the part of sensitive code.

We can allow a single user at a given point of time by
making that part of the code which is sensitive as
synchronized.

Is This Answer Correct ?    127 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When Servlet is unloaded?

1056


What exactly is a servlet?

949


What are the steps that are required to handle the multi-threading?

1056


What are the difference between RMI and Servlets?

1524


What is servlet configuration?

1013


What is the difference between servlet and jsp?

1063


What are the phases of servlet life cycle?

1066


What are the functions of the servlet container?

1566


How to notify an object in session when session is invalidated or timed-out?

1037


What is the difference between the http servlet and generic servlet?

1098


What are the types of servlet?

1228


What is the workflow of a servlet?

1132


Can we override destroy method in servlet?

946


What is a generic servlet?

909


What are the various ways of session supervision in servlets?

956