Developer community
0 votes
asked by Guru (27.1k points) 35 52 112 | 575 views

3 Answers

0 votes
Deadlock is a situation when two threads are waiting on each other to release a resource. Each thread is waiting for a resource which is held by the other waiting thread.
answered by Guru (39.1k points) 10 23 38
0 votes
Suppose a process request resources; if the resources are not available at that time the process enters into a wait state. A waiting process may never again change state, because the resources they have requested are held by some other waiting processes. This situation is called deadlock.
answered by Guru (24.6k points) 31 57 92
0 votes
When a thread holds a resource and waits for another resource to be realized by second thread, the second thread holding a resource and waiting for realized by first thread. Both the threads will be waiting in defiantly and they never execute this switching is called as “Deadlock”.

In java there is no mechanism to avoid deadlock situation, it is the responsibility of the programmer to write proper logic to avoid deadlock situation.
answered by Sr Member (4.8k points) 10 26 32

Related questions

0 votes
1 answer
asked by sara Guru (24.6k points) 31 57 92 | 33 views
0 votes
1 answer
asked by steve Sr Member (1.5k points) 8 24 40 | 3.9k views
0 votes
1 answer
asked by sunny Expert (11.4k points) 16 23 32 | 116 views
0 votes
1 answer
asked by rock Expert (15k points) 15 23 32 | 90 views
0 votes
1 answer
asked by sunny Expert (11.4k points) 16 23 32 | 136 views
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true


C Books Guide and List
C++ Books Guide and List
Best Java Books

3.8k questions

4k answers


10.7k users

3,754 questions
4,046 answers
10,709 users