You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tez.apache.org by pr...@apache.org on 2015/04/17 04:25:24 UTC
tez git commit: TEZ-1969. Stop the DAGAppMaster when a local mode
client is stopped (pramachandran)
Repository: tez
Updated Branches:
refs/heads/master e1968681c -> 3e6fc355c
TEZ-1969. Stop the DAGAppMaster when a local mode client is stopped (pramachandran)
Project: http://git-wip-us.apache.org/repos/asf/tez/repo
Commit: http://git-wip-us.apache.org/repos/asf/tez/commit/3e6fc355
Tree: http://git-wip-us.apache.org/repos/asf/tez/tree/3e6fc355
Diff: http://git-wip-us.apache.org/repos/asf/tez/diff/3e6fc355
Branch: refs/heads/master
Commit: 3e6fc355c618b77531f7d29b6a1c9cbc3c39456a
Parents: e196868
Author: Prakash Ramachandran <pr...@hortonworks.com>
Authored: Fri Apr 17 07:54:43 2015 +0530
Committer: Prakash Ramachandran <pr...@hortonworks.com>
Committed: Fri Apr 17 07:54:43 2015 +0530
----------------------------------------------------------------------
CHANGES.txt | 1 +
.../src/main/java/org/apache/tez/client/LocalClient.java | 9 +++++++++
2 files changed, 10 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/tez/blob/3e6fc355/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index ce9bfe8..1a7609f 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -9,6 +9,7 @@ INCOMPATIBLE CHANGES
TEZ-1993. Implement a pluggable InputSizeEstimator for grouping fairly
ALL CHANGES:
+ TEZ-1969. Stop the DAGAppMaster when a local mode client is stopped
TEZ-714. OutputCommitters should not run in the main AM dispatcher thread
TEZ-2323. Fix TestOrderedWordcount to use MR memory configs.
TEZ-1482. Fix memory issues for Local Mode running concurrent tasks
http://git-wip-us.apache.org/repos/asf/tez/blob/3e6fc355/tez-dag/src/main/java/org/apache/tez/client/LocalClient.java
----------------------------------------------------------------------
diff --git a/tez-dag/src/main/java/org/apache/tez/client/LocalClient.java b/tez-dag/src/main/java/org/apache/tez/client/LocalClient.java
index b5889a9..6eb58bd 100644
--- a/tez-dag/src/main/java/org/apache/tez/client/LocalClient.java
+++ b/tez-dag/src/main/java/org/apache/tez/client/LocalClient.java
@@ -106,6 +106,14 @@ public class LocalClient extends FrameworkClient {
public void close() throws IOException {
// LocalClients are shared between TezClient and DAGClients, which can cause stop / start / close
// to be invoked multiple times. If modifying these methods - this should be factored in.
+
+ // Multiple DAGClient's can reuse the LocalClient (for ex session). However there is only a
+ // single instance of LocalClient for a TezClient, and dagAppMaster can be cleaned up when
+ // the TezClient is stopped, in order not to leak.
+ if (dagAppMaster != null) {
+ dagAppMaster.stop();
+ dagAppMaster = null;
+ }
}
@Override
@@ -309,6 +317,7 @@ public class LocalClient extends FrameworkClient {
LOG.error("Error starting DAGAppMaster", t);
if (dagAppMaster != null) {
dagAppMaster.stop();
+ dagAppMaster = null;
}
amFailException = t;
}