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

Wangda Tan commented on YARN-2113:
----------------------------------

[~sunilg], thanks for update the patch. 

Checked the patch and also offline discussed with Sunil, I can understand that 
this patch handles an edge case which allows a lower priority app preempt 
higher priority app if the user of higher priority app beyond its user limit. 

However I think it is debatable: as of now, YARN doesn't calculate UL for 
different priorities, but that doesn't mean we should allow lower priority app 
to preempt higher priority app. [~eepayne], could you share your thoughts here?

And also, this patch added a compound comparator which sort application in 
following way (essentially): {{(priority > demand) > (fifo > demand)}}

I'm a little worried about this complex comparator. If we could decide no lower 
priority app can preempt higher priority app. We should be able to simply 
compare logic to:
{code}
compare(a, b)
    if (a.priority != b.priority) {
        return a.priority.compare(b.priority)
    }
    return a.toBePreemptFromOther.compare(b.toBePreemptFromOther)
{code}

Above logic makes sure that when priority is same, app with 
toBePreemptFromOther always goes first. Is it possible that one app's 
toBePreemptFromOther > 0 and actuallyToBePreempted > 0 at the same time? If it 
is possible, could you add some examples?

> Add cross-user preemption within CapacityScheduler's leaf-queue
> ---------------------------------------------------------------
>
>                 Key: YARN-2113
>                 URL: https://issues.apache.org/jira/browse/YARN-2113
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: scheduler
>            Reporter: Vinod Kumar Vavilapalli
>            Assignee: Sunil G
>         Attachments: YARN-2113.0001.patch, YARN-2113.0002.patch, 
> YARN-2113.0003.patch, YARN-2113.v0.patch
>
>
> Preemption today only works across queues and moves around resources across 
> queues per demand and usage. We should also have user-level preemption within 
> a queue, to balance capacity across users in a predictable manner.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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

Reply via email to