You are viewing a plain text version of this content. The canonical link for it is here.
Posted to yarn-issues@hadoop.apache.org by "Szilard Nemeth (Jira)" <ji...@apache.org> on 2020/02/12 13:55:00 UTC
[jira] [Comment Edited] (YARN-10029) Add option to UIv2 to get
container logs from the new JHS API
[ https://issues.apache.org/jira/browse/YARN-10029?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17035366#comment-17035366 ]
Szilard Nemeth edited comment on YARN-10029 at 2/12/20 1:54 PM:
----------------------------------------------------------------
Thanks [~adam.antal] for this patch.
Some comments:
1. In serializers/yarn-jhs-log.js:
Maybe I don't get something but the variable name 'paylog' seems odd in this code block:
{code:java}
if (payload && payload[0] && payload[0].containerLogInfo) {
normalizedArrayResponse.data = payload[0].containerLogInfo.map((paylog) => {
return this.internalNormalizeSingleResponse(store, primaryModelClass, paylog,
payload[0].containerId, payload[0].nodeId);
});
}
{code}
2. In serializers/yarn-jhs-log.js, in function normalizeArrayResponse:
Can you add two comments above both if statements? For me it's not clear which is doing what. Maybe because of my limited knowledge with EmberJS, though.
3. In adapters/yarn-app-jhs-log.js, in function urlForFindRecord:
Variable cluserId seems unused so it's unnecessary
{code:java}
if (splits[2]) {
clusterId = splits[2];
}
{code}
4. In loader.js, function getConfigFromYarn:
I would modify this statement:
{code:java}
Ember.Logger.log("The URL is: " + httpUrl);
{code}
to
{code:java}
Ember.Logger.log("The RM URL is: " + httpUrl);
{code}
, or a simiar log message that elaborates more and contains reference to RM.
5. In loader.js, function transformURL: Could you please add a comment explaining what this function does (specifically with the regex)?
6. In controllers/logs.js, in action 'showContainersForAttemptId':
You set the provider and fieldname with:
{code}
let historyProvider = this.fallbackToJHS ? hash.jhsContainers : hash.tsContainers;
let fieldName = this.fallbackToJHS ? "containerId" : "id";
{code}
but the comment a little below says: "Getting aggregated containers from the JHS"
Isn't the service being called depends on the historyProvider ? I would clarify this in the comment.
was (Author: snemeth):
Thanks [~adam.antal] for this patch.
Some comments:
1. In serializers/yarn-jhs-log.js:
Maybe I don't get something but the variable name 'paylog' seems odd in this code block:
{code}
if (payload && payload[0] && payload[0].containerLogInfo) {
normalizedArrayResponse.data = payload[0].containerLogInfo.map((paylog) => {
return this.internalNormalizeSingleResponse(store, primaryModelClass, paylog,
payload[0].containerId, payload[0].nodeId);
});
}
{code}
2. In serializers/yarn-jhs-log.js, in function normalizeArrayResponse:
Can you add two comments above both if statements? For me it's not clear which is doing what. Maybe because of my limited knowledge with EmberJS, though.
3. In adapters/yarn-app-jhs-log.js, in function urlForFindRecord:
Variable cluserId seems unused so it's unnecessary
{code}
if (splits[2]) {
clusterId = splits[2];
}
{code}
4. In loader.js, function getConfigFromYarn:
I would modify this statement:
{code}
Ember.Logger.log("The URL is: " + httpUrl);
{code}
to
{code}
Ember.Logger.log("The RM URL is: " + httpUrl);
{code}, or a simiar log message that elaborates more and contains reference to RM.
5. In loader.js, function transformURL: Could you please add a comment explaining what this function does (specifically with the regex)?
> Add option to UIv2 to get container logs from the new JHS API
> -------------------------------------------------------------
>
> Key: YARN-10029
> URL: https://issues.apache.org/jira/browse/YARN-10029
> Project: Hadoop YARN
> Issue Type: Sub-task
> Components: yarn
> Affects Versions: 3.2.1
> Reporter: Adam Antal
> Assignee: Adam Antal
> Priority: Major
> Attachments: YARN-10029.001.patch, YARN-10029.002.patch, YARN-10029.003.patch
>
>
> Provided the new API is ready to use (also integrated into JHS in YARN-10028), we can add a new config option to UIv2 that would make the UIv2 to request logs from the JHS API similarly as the ATSv2.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: yarn-issues-help@hadoop.apache.org