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-873) YARNClient.getApplicationReport(unknownAppId) returns a null report
Date Thu, 18 Jul 2013 17:28:50 GMT

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

Bikas Saha commented on YARN-873:
---------------------------------

Having a return statement in a catch/finally block is not recommended normally. We could print
the message and re-throw the exception or simply not catch the exception. Also, this way the
cmd line would exit with non-zero exit code.
{code}
+    } catch (ApplicationNotFoundException ex) {
+      sysout.println("Application with id '"
+          + applicationId + "' doesn't exist in RM.");
+      return;
+    }
{code}
                
> YARNClient.getApplicationReport(unknownAppId) returns a null report
> -------------------------------------------------------------------
>
>                 Key: YARN-873
>                 URL: https://issues.apache.org/jira/browse/YARN-873
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>    Affects Versions: 2.1.0-beta
>            Reporter: Bikas Saha
>            Assignee: Xuan Gong
>         Attachments: YARN-873.1.patch, YARN-873.2.patch, YARN-873.3.patch
>
>
> How can the client find out that app does not exist?

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message