hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xg...@apache.org
Subject hadoop git commit: YARN-2859.addendum: fix the remaining issue from the previous patch
Date Thu, 19 Nov 2015 18:10:33 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2.7 bb6983e15 -> fe67c6f43


YARN-2859.addendum: fix the remaining issue from the previous patch

(cherry picked from commit f114e728da6e19f3d35ff0cfef9fceea26aa5d46)
(cherry picked from commit be65d319fae8f8644c46ee7c44108ce72dafc9c7)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/fe67c6f4
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/fe67c6f4
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/fe67c6f4

Branch: refs/heads/branch-2.7
Commit: fe67c6f43f80f32b15f362179ea2082967d861d1
Parents: bb6983e
Author: Xuan <xgong@apache.org>
Authored: Thu Nov 19 10:07:16 2015 -0800
Committer: Xuan <xgong@apache.org>
Committed: Thu Nov 19 10:10:22 2015 -0800

----------------------------------------------------------------------
 .../ApplicationHistoryServer.java                         | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/fe67c6f4/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-applicationhistoryservice/src/main/java/org/apache/hadoop/yarn/server/applicationhistoryservice/ApplicationHistoryServer.java
----------------------------------------------------------------------
diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-applicationhistoryservice/src/main/java/org/apache/hadoop/yarn/server/applicationhistoryservice/ApplicationHistoryServer.java
b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-applicationhistoryservice/src/main/java/org/apache/hadoop/yarn/server/applicationhistoryservice/ApplicationHistoryServer.java
index f915181..7fb900d 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-applicationhistoryservice/src/main/java/org/apache/hadoop/yarn/server/applicationhistoryservice/ApplicationHistoryServer.java
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-applicationhistoryservice/src/main/java/org/apache/hadoop/yarn/server/applicationhistoryservice/ApplicationHistoryServer.java
@@ -131,10 +131,14 @@ public class ApplicationHistoryServer extends CompositeService {
     return this.ahsClientService;
   }
 
+  private InetSocketAddress getListenerAddress() {
+    return this.webApp.httpServer().getConnectorAddress(0);
+  }
+
   @Private
   @VisibleForTesting
   public int getPort() {
-    return this.webApp.httpServer().getConnectorAddress(0).getPort();
+    return this.getListenerAddress().getPort();
   }
 
   /**
@@ -321,6 +325,10 @@ public class ApplicationHistoryServer extends CompositeService {
          httpServer.addContext(uiWebAppContext, true);
        }
        httpServer.start();
+       conf.updateConnectAddr(YarnConfiguration.TIMELINE_SERVICE_BIND_HOST,
+         YarnConfiguration.TIMELINE_SERVICE_WEBAPP_ADDRESS,
+         YarnConfiguration.DEFAULT_TIMELINE_SERVICE_WEBAPP_ADDRESS,
+         this.getListenerAddress());
        LOG.info("Instantiating AHSWebApp at " + getPort());
     } catch (Exception e) {
       String msg = "AHSWebApp failed to start.";


Mime
View raw message