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

FairScheduler handles "invalid" queue names inconsistently

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.8.0, 3.0.0-alpha1
    • Component/s: fairscheduler
    • Labels:
      None
    • Hadoop Flags:
      Incompatible change
    • Release Note:
      FairScheduler does not allow queue names with leading or tailing spaces or empty sub-queue names anymore.

      Description

      Leading space, trailing space and empty sub queue name may cause MetricsException(Metrics source XXX already exists! ) when add application to FairScheduler.
      The reason is because QueueMetrics parse the queue name different from the QueueManager.
      QueueMetrics use Q_SPLITTER to parse queue name, it will remove Leading space and trailing space in the sub queue name, It will also remove empty sub queue name.

        static final Splitter Q_SPLITTER =
            Splitter.on('.').omitEmptyStrings().trimResults(); 
      

      But QueueManager won't remove Leading space, trailing space and empty sub queue name.
      This will cause out of sync between FSQueue and FSQueueMetrics.
      QueueManager will think two queue names are different so it will try to create a new queue.
      But FSQueueMetrics will treat these two queue names as same queue which will create "Metrics source XXX already exists!" MetricsException.

        Attachments

        1. YARN-3241.000.patch
          8 kB
          zhihai xu
        2. YARN-3241.001.patch
          15 kB
          zhihai xu
        3. YARN-3241.002.patch
          15 kB
          zhihai xu

          Issue Links

            Activity

              People

              • Assignee:
                zxu zhihai xu
                Reporter:
                zxu zhihai xu
              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: