hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tao Jie (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-6000) Set modifier of interface Listener in AllocationFileLoaderService to public
Date Thu, 15 Dec 2016 00:58:58 GMT

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

Tao Jie commented on YARN-6000:
-------------------------------

[~templedf], [~kasha] would you mind taking a look at it?

> Set modifier of interface Listener in AllocationFileLoaderService to public
> ---------------------------------------------------------------------------
>
>                 Key: YARN-6000
>                 URL: https://issues.apache.org/jira/browse/YARN-6000
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: fairscheduler, yarn
>    Affects Versions: 3.0.0-alpha1
>            Reporter: Tao Jie
>            Assignee: Tao Jie
>         Attachments: YARN-6000.001.patch
>
>
> We removed public modifier of {{AllocationFileLoaderService.Listener}} in YARN-4997 since
it trigger a findbugs warning. However it breaks Hive code in {{FairSchedulerShim}}. 
> {code}
> AllocationFileLoaderService allocsLoader = new AllocationFileLoaderService();
>     allocsLoader.init(conf);
>     allocsLoader.setReloadListener(new AllocationFileLoaderService.Listener() {
>       @Override
>       public void onReload(AllocationConfiguration allocs) {
>         allocConf.set(allocs);
>       }
>     });
>     try {
>       allocsLoader.reloadAllocations();
>     } catch (Exception ex) {
>       throw new IOException("Failed to load queue allocations", ex);
>     }
>     if (allocConf.get() == null) {
>       allocConf.set(new AllocationConfiguration(conf));
>     }
>     QueuePlacementPolicy queuePolicy = allocConf.get().getPlacementPolicy();
>     if (queuePolicy != null) {
>       requestedQueue = queuePolicy.assignAppToQueue(requestedQueue, userName);
> {code}
> As a result we should set the modifier back to public.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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


Mime
View raw message