Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-3353

DataNode.run() join() and shutdown() ought to have synchronized access to dataNodeThread

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Invalid
    • None
    • None
    • None
    • None

    Description

      Looking at the DataNode.run() and join() methods, they are manipulating the state of the dataNodeThread:

      void join() {
      if (dataNodeThread != null) {
      try

      { dataNodeThread.join(); }

      catch (InterruptedException e) {}
      }
      }

      There's something similar in shutdown()

      This could lead to race conditions on shutdown, where the check passes and then the reference is null when the next method is invoked.
      Marking major as race conditions are always trouble, and hard to test.

      Attachments

        Activity

          People

            Unassigned Unassigned
            stevel@apache.org Steve Loughran
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: