Uploaded image for project: 'Hadoop YARN'
  1. Hadoop YARN
  2. YARN-5901

Fix race condition in TestGetGroups beforeclass setup()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.0.0-alpha1
    • 2.9.0, 3.0.0-alpha2
    • yarn

    Description

      In TestGetGroups, the class-level setup method spins up, in a child thread, a resource manager that Yarn clients can talk to. But it checks whether the resource manager is fully started by doing resourcemanager.getServiceState() == STATE.STARTED. This is not reliable since resourcemanager.start() will first trigger service state change in RM, and then starts up all the services added to RM. We need to wait for RM to fully start before YARN clients can send requests. Otherwise, the tests can fail due to "connection refused" exception when the main thread sends out client requests to RM and if the RPC server has not fired up in the child thread.

      Attachments

        1. YARN-5901-branch-2.03.patch
          3 kB
          Haibo Chen
        2. YARN-5901.03.patch
          3 kB
          Haibo Chen
        3. YARN-5901.02.patch
          3 kB
          Haibo Chen
        4. yarn5901.001.patch
          3 kB
          Haibo Chen

        Activity

          People

            haibochen Haibo Chen
            haibochen Haibo Chen
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: