hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bikas Saha (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-1559) Race between ServerRMProxy and ClientRMProxy setting RMProxy#INSTANCE
Date Mon, 06 Jan 2014 17:41:51 GMT

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

Bikas Saha commented on YARN-1559:
----------------------------------


bq. In the latest patch, I don't see any duplication. Am I missing something?
yeah. the latest patch does not have it. I was looking at the .2 patch from yesterday which
was the latest at that time.

bq. Not sure I understand what you are referring to.
{code}
-   * A RetryPolicy to allow failing over upto the specified maximum time.
-   */
-  private static class FailoverUptoMaximumTimePolicy implements RetryPolicy {
-    private long maxTime;
-
-    FailoverUptoMaximumTimePolicy(long maxTime) {
-      this.maxTime = maxTime;
-    }
-
-    @Override
-    public RetryAction shouldRetry(Exception e, int retries, int failovers,
-        boolean isIdempotentOrAtMostOnce) throws Exception {
-      return System.currentTimeMillis() < maxTime
-          ? RetryAction.FAILOVER_AND_RETRY
-          : RetryAction.FAIL;
-    }
-  }
{code}

> Race between ServerRMProxy and ClientRMProxy setting RMProxy#INSTANCE
> ---------------------------------------------------------------------
>
>                 Key: YARN-1559
>                 URL: https://issues.apache.org/jira/browse/YARN-1559
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: resourcemanager
>    Affects Versions: 2.4.0
>            Reporter: Karthik Kambatla
>            Assignee: Karthik Kambatla
>            Priority: Blocker
>         Attachments: YARN-1559-20140105.txt, yarn-1559-1.patch, yarn-1559-2.patch, yarn-1559-3.patch
>
>
> RMProxy#INSTANCE is a non-final static field and both ServerRMProxy and ClientRMProxy
set it. This leads to races as witnessed on - YARN-1482.
> Sample trace:
> {noformat}
> java.lang.IllegalArgumentException: RM does not support this client protocol
>         at com.google.common.base.Preconditions.checkArgument(Preconditions.java:88)
>         at org.apache.hadoop.yarn.client.ClientRMProxy.checkAllowedProtocols(ClientRMProxy.java:119)
>         at org.apache.hadoop.yarn.client.ConfiguredRMFailoverProxyProvider.init(ConfiguredRMFailoverProxyProvider.java:58)
>         at org.apache.hadoop.yarn.client.RMProxy.createRMFailoverProxyProvider(RMProxy.java:158)
>         at org.apache.hadoop.yarn.client.RMProxy.createRMProxy(RMProxy.java:88)
>         at org.apache.hadoop.yarn.server.api.ServerRMProxy.createRMProxy(ServerRMProxy.java:56)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message