[ 
https://issues.apache.org/jira/browse/YARN-7139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16328760#comment-16328760
 ] 

Szilard Nemeth commented on YARN-7139:
--------------------------------------

Checked your changes, I think everything is fine except in this code block I 
wouldn't mention that the null check is here only because of the tests are "not 
good enough".

I guess you spent a considerable amount of time to check how easy would have 
been to correct the tests and that's why you decided with the null check in the 
production code is safer. 
{code:java}
// During tests we do not always have an application object, handle
        // it here but we probably should fix the tests
        if (rmApp != null && rmApp.getApplicationSubmissionContext() != null) {
          // Before we send out the event that the app is accepted is
          // to set the queue in the submissionContext (needed on restore etc)
          rmApp.getApplicationSubmissionContext().setQueue(queue.getName());
        }
{code}

> FairScheduler: finished applications are always restored to default queue
> -------------------------------------------------------------------------
>
>                 Key: YARN-7139
>                 URL: https://issues.apache.org/jira/browse/YARN-7139
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: fairscheduler
>    Affects Versions: 2.8.1
>            Reporter: Wilfred Spiegelenburg
>            Assignee: Wilfred Spiegelenburg
>            Priority: Major
>         Attachments: YARN-7139.01.patch, YARN-7139.02.patch, 
> YARN-7139.03.patch, YARN-7139.04.patch
>
>
> The queue an application gets submitted to is defined by the placement policy 
> in the FS. The placement policy returns the queue and the application object 
> is updated. When an application is stored in the state store the application 
> submission context is used which has not been updated after the placement 
> rules have run. 
> This means that the original queue from the submission is still stored which 
> is the incorrect queue. On restore we then read back the wrong queue and 
> display the wrong queue in the RM web UI.
> We should update the submission context after we have run the placement 
> policies to make sure that we store the correct queue for the application.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to