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

Robert Kanter commented on YARN-6625:
-------------------------------------

Two last minor things and then we're good to go:
# The {{isValidUrl}} method can be more simpler/compact - something like this:
{code:java}
private boolean isValidUrl(String url) {
  boolean isValid = false;
  try {
    HttpURLConnection conn =
      (HttpURLConnection) new URL(url).openConnection();
    conn.connect();
    isValid = (conn.getResponseCode() == HttpURLConnection.HTTP_OK);
  } catch (Exception e) {
    LOG.debug("Failed to connect to " + url + ": " + e.toString());
  }
  return isValid;
}
{code}
# Remove the * imports from TestAmFilter

> yarn application -list returns a tracking URL for AM that doesn't work in 
> secured and HA environment
> ----------------------------------------------------------------------------------------------------
>
>                 Key: YARN-6625
>                 URL: https://issues.apache.org/jira/browse/YARN-6625
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: amrmproxy
>    Affects Versions: 3.0.0-alpha2
>            Reporter: Yufei Gu
>            Assignee: Yufei Gu
>         Attachments: YARN-6625.001.patch, YARN-6625.002.patch, 
> YARN-6625.003.patch
>
>
> The tracking URL given at the command line should work secured or not. The 
> tracking URLs are like http://node-2.abc.com:47014 and AM web server supposed 
> to redirect it to a RM address like this 
> http://node-1.abc.com:8088/proxy/application_1494544954891_0002/, but it 
> fails to do that because the connection is rejected when AM is talking to RM 
> admin service to get HA status.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

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

Reply via email to