You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-dev@hadoop.apache.org by "Szilard Nemeth (Jira)" <ji...@apache.org> on 2020/01/20 08:42:00 UTC
[jira] [Resolved] (YARN-10081) Exception message from
ClientRMProxy#getRMAddress is misleading
[ https://issues.apache.org/jira/browse/YARN-10081?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Szilard Nemeth resolved YARN-10081.
-----------------------------------
Fix Version/s: 3.3.0
Hadoop Flags: Reviewed
Resolution: Fixed
> Exception message from ClientRMProxy#getRMAddress is misleading
> ---------------------------------------------------------------
>
> Key: YARN-10081
> URL: https://issues.apache.org/jira/browse/YARN-10081
> Project: Hadoop YARN
> Issue Type: Bug
> Components: yarn
> Affects Versions: 3.3.0
> Reporter: Adam Antal
> Assignee: Ravuri Sushma sree
> Priority: Trivial
> Fix For: 3.3.0
>
> Attachments: YARN-10081.001.patch
>
>
> In {{ClientRMProxy#getRMAddress}} in the else branch we have the following piece of code.
> {code:java}
> } else {
> String message = "Unsupported protocol found when creating the proxy " +
> "connection to ResourceManager: " +
> ((protocol != null) ? protocol.getClass().getName() : "null");
> LOG.error(message);
> throw new IllegalStateException(message);
> }
> {code}
> This is wrong, because the protocol variable is of type "Class<?>", so {{Class.getClass()}} will be always {{Object}}. It should be {{protocol.getName()}}.
> An example of the error message if {{RMProxy}} is misused, and this exception is thrown:
> {noformat}
> java.lang.IllegalStateException: Unsupported protocol found when creating the proxy connection to ResourceManager: java.lang.Class
> at org.apache.hadoop.yarn.client.ClientRMProxy.getRMAddress(ClientRMProxy.java:109)
> at org.apache.hadoop.yarn.client.RMProxy.newProxyInstance(RMProxy.java:133)
> ...
> {noformat}
> where obviously not a {{Object.class}} was provided to this function as protocol parameter.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-dev-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-dev-help@hadoop.apache.org