thread scheduling mechanism in SUN's VM
I've the problem, that n threads share a resource
(sharedObject).
The synchronization is done in an synchronized
Block:
synchronized( sharedObject )
{
// do something with sharedIbject
}
I would like to know in which order the thread scheduler
of SUN Solaris VM of the JDK 1.3 or in general,
gives the lock of the sharedObject to one of the thread, which
are waiting for the lock of the sharedObject.
Is there something like FIFO, so that it's safe, that all waiting
threads will get the sharedObject in the right order,
or do i have to implement a queueing mechanism with wait and
notify.
thanks

