阅读背景:

如何通过等待JVM处理的对象锁来导致线程处于阻塞状态

来源:互联网 

I have seen there are different ways a thread could get to blocked state. Im interested to know what exactly happens after a thread is in blocked state. How does it get back to running state. If its blocked by sleep(time) then it moves to the runnable queue after time milli secs. If its blocked on a I/O operation it gets into the runnable queue once that is done. how does it get to the runnable queue when it is waiting on an objects lock. how does it know that the lock on the ocject its waiting for is now available. Can some one also explain the internals of how the blocked thread on I/O works. Please correct me if my understanding on any of the above topics isn't right..I have seen there are different ways a thread c




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: