[
https://issues.apache.org/jira/browse/MAPREDUCE-7266?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17079197#comment-17079197
]
Hudson commented on MAPREDUCE-7266:
-----------------------------------
SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #18130 (See
[https://builds.apache.org/job/Hadoop-trunk-Commit/18130/])
MAPREDUCE-7266. historyContext doesn't need to be a class attribute (snemeth:
rev e2c87b79170f18b316957cb935fbc254d448cd08)
* (edit)
hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/security/TestJHSSecurity.java
* (edit)
hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/JobHistoryServer.java
> historyContext doesn't need to be a class attribute inside JobHistoryServer
> ---------------------------------------------------------------------------
>
> Key: MAPREDUCE-7266
> URL: https://issues.apache.org/jira/browse/MAPREDUCE-7266
> Project: Hadoop Map/Reduce
> Issue Type: Improvement
> Components: jobhistoryserver
> Reporter: Siddharth Ahuja
> Assignee: Siddharth Ahuja
> Priority: Minor
> Fix For: 3.3.0, 3.2.2, 3.4.0
>
> Attachments: MAPREDUCE-7266.002.patch, YARN-10075.001.patch
>
>
> "historyContext" class attribute at
> https://github.com/apache/hadoop/blob/trunk/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/JobHistoryServer.java#L67
> is assigned a cast of another class attribute - "jobHistoryService" -
> https://github.com/apache/hadoop/blob/trunk/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/JobHistoryServer.java#L131,
> however it does not need to be stored separately because it is only ever
> used once in the clas, and that too as an argument while instantiating the
> HistoryClientService class at
> https://github.com/apache/hadoop/blob/trunk/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/JobHistoryServer.java#L155.
> Therefore, we could just delete the lines at
> https://github.com/apache/hadoop/blob/trunk/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/JobHistoryServer.java#L67
> and
> https://github.com/apache/hadoop/blob/trunk/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/JobHistoryServer.java#L131
> completely and instantiate the HistoryClientService as follows:
> {code}
> @VisibleForTesting
> protected HistoryClientService createHistoryClientService() {
> return new HistoryClientService((HistoryContext)jobHistoryService,
> this.jhsDTSecretManager);
> }
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]