File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Can this be a case of deadlock ?And how to determine it output ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Can this be a case of deadlock ?And how to determine it output ?" Watch "Can this be a case of deadlock ?And how to determine it output ?" New topic
Author

Can this be a case of deadlock ?And how to determine it output ?

A Agr
Ranch Hand

Joined: Feb 10, 2009
Posts: 32
Himalay Majumdar
Ranch Hand

Joined: Sep 28, 2008
Posts: 324
Yes it is ...try the following code



Getting a deadlock is very unlikely to happen so usually..you will get an output under normal condition. Here by putting sleep method in .I am making it more probable for a deadlock to happen. I many situations..even without a sleep() method..the thread scheduler can behave in such way..that creates deadlock situation.


SCJP 1.6, SCWCD 5.0, SCBCD 5.0 [loading..]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can this be a case of deadlock ?And how to determine it output ?