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 handle a singleton service locator. when multiple threads
are trying to get the singleton object in same time

Answer Posted / krishnapal

Using synchronized method we can using put requesting
threads into waiting queue.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Should you use singleton pattern?

932


When is the finalize() called?

1168


Can we use catch statement for checked exceptions when there is no chance of raising exception in our code?

1030


What is a treeset class?

1001


What about interrupt() method of thread class ?

1064


How can we make a class singleton?

1061


What are the five major types of reference sources?

1112


Write a program in java to find the maximum and minimum value node from a circular linked list.

1074


Which language is java?

971


Distinguish between a predicate and a function?

983


Can you write a java class that could be used both as an applet as well as an application?

951


Why is it called a string?

1000


Can we create an object of private class?

964


What is vector capacity in java?

1077


What are the advantages of user defined functions?

990