Forum

Number Of Page View:100,000+/Months
LOGIN |New User

Reply

Thread Priorities and Yield
now we are discussing about the thread properties .Threads always run with some priority , represented usually as a number between 1 The scheduler in most JVMs uses preemptive, priority based scheduling. This does not mean that all JVMs use time slicing. The JVM specification does not require a VM to implement a time-slicing
scheduler, where each thread is allocated a fair amount of time and then sent back to runnable to give another thread a chance. Although many JVMs do use time slicing, another may use a scheduler that lets one thread stay running until the thread completes its run() method.and 10.
           scheduler might do one of the following
> Pick a thread to run, and keep it there until it blocks or completes its run() method
> Time slice the threads in the pool to give everyone an equal opportunity to run.
Posted By: Name:Rajesh Kr URL: Thread Priorities and Yield