3 Replies Latest reply on Oct 25, 2006 4:02 PM by 807607

    Deadlock

    807607
      How could one detect a deadlock?
        • 1. Re: Deadlock
          807607
          You can't. If there would be a precise definition what a deadlock looks like, java could prevent or solve it itself. But it can't.

          This is the nasty part of multithreading: errors don't have to be deterministic. You have to make sure that no deadlock can happen, BEFORE it happens!
          • 2. Re: Deadlock
            807607
            Depends on what you mean by "deadlock" (database transaction, "synchronized" keyword, general deadlock detection) and "detect" (static, dynamic).

            http://en.wikipedia.org/wiki/Deadlock
            http://www.google.com/search?q=%22deadlock+detection%22
            • 3. Re: Deadlock
              807607
              thanks