[
https://issues.apache.org/jira/browse/YARN-987?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13815080#comment-13815080
]
Zhijie Shen commented on YARN-987:
----------------------------------
1. Would you please fix the capitalization?
{code}
+ /** AHS STORAGE CLASS */
{code}
{code}
+ <description> Store Class Name for History Store, defaulting to file
+ system store </description>
{code}
2. It seems not necessary that convertToXXXXReport is public as well.
3. It's better to use the constant in YarnConfiguration and
config.getClass/getClassByName.
{code}
+ config
+ .set(
+ "yarn.ahs.store.class",
+
"org.apache.hadoop.yarn.server.applicationhistoryservice.MemoryApplicationHistoryStore");
{code}
4. No need to convert to string to assert equivalence. You can do that directly
with the ID instances. In addition, please assert some fields from the
application attempt, such as "host"
{code}
+ Assert.assertEquals("application_0_0001", appReport.getApplicationId()
+ .toString());
+ Assert.assertEquals("appattempt_0_0001_000001", appReport
+ .getCurrentApplicationAttemptId().toString());
{code}
5. You can refer to RMAppImpl#createAndGetApplicationReport to decide what the
fields should be when the attempt is null.
{code}
+ if (lastAttempt == null) {
+ return ApplicationReport.newInstance(appHistory.getApplicationId(), null,
+ appHistory.getUser(), appHistory.getQueue(), appHistory
+ .getApplicationName(), "", 0, null, null, "", "", appHistory
+ .getStartTime(), appHistory.getFinishTime(), appHistory
+ .getFinalApplicationStatus(), null, "", 100, appHistory
+ .getApplicationType(), null);
+ }
{code}
> Adding History Service to use Store and converting Historydata to Report
> ------------------------------------------------------------------------
>
> Key: YARN-987
> URL: https://issues.apache.org/jira/browse/YARN-987
> Project: Hadoop YARN
> Issue Type: Sub-task
> Reporter: Mayank Bansal
> Assignee: Mayank Bansal
> Attachments: YARN-987-1.patch, YARN-987-2.patch, YARN-987-3.patch,
> YARN-987-4.patch, YARN-987-5.patch, YARN-987-6.patch
>
>
--
This message was sent by Atlassian JIRA
(v6.1#6144)