Wangda Tan commented on YARN-3142:


bq. But we wont be using this till we set current attempt in scheduler which is 
after this. Also, this is a reference assignment which is atomic. Thoughts ?

Yeah it should not required.

bq. You mean remove the request from the resource request map ? Well the part 
about fetching from resource request map i.e. call to getResourceRequest is 
within locks. After that we just access ResourceRequest instance. And 
capability which we are returning here wont be changed even by another thread. 
However this is is not immutable field so we can probably guard it with a read 
lock just to be safe. Thoughts ?

Agree we can add a readlock here just to be safe.

> Improve locks in AppSchedulingInfo
> ----------------------------------
>                 Key: YARN-3142
>                 URL: https://issues.apache.org/jira/browse/YARN-3142
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: resourcemanager, scheduler
>            Reporter: Wangda Tan
>            Assignee: Varun Saxena
>         Attachments: YARN-3142.01.patch

This message was sent by Atlassian JIRA

To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org

Reply via email to