You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tez.apache.org by hi...@apache.org on 2014/11/13 20:14:21 UTC

[1/2] tez git commit: TEZ-1774. AppLaunched event for Timeline does not have start time set. (hitesh)

Repository: tez
Updated Branches:
  refs/heads/branch-0.5 4db332fc7 -> dcdf15125


TEZ-1774. AppLaunched event for Timeline does not have start time set. (hitesh)

(cherry picked from commit f152a7f3bcca82a343b759c2921dbc8d93aaf175)

Conflicts:
	CHANGES.txt


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

Branch: refs/heads/branch-0.5
Commit: 60116ce99b35c94e96296857ddebcaeb21e4a96f
Parents: 4db332f
Author: Hitesh Shah <hi...@apache.org>
Authored: Thu Nov 13 11:01:44 2014 -0800
Committer: Hitesh Shah <hi...@apache.org>
Committed: Thu Nov 13 11:12:17 2014 -0800

----------------------------------------------------------------------
 .../history/logging/ats/ATSHistoryLoggingService.java  | 13 +++++++++----
 .../logging/ats/HistoryEventTimelineConversion.java    |  4 ++++
 .../ats/TestHistoryEventTimelineConversion.java        |  4 ++++
 3 files changed, 17 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tez/blob/60116ce9/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/ATSHistoryLoggingService.java
----------------------------------------------------------------------
diff --git a/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/ATSHistoryLoggingService.java b/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/ATSHistoryLoggingService.java
index 0108c26..008334f 100644
--- a/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/ATSHistoryLoggingService.java
+++ b/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/ATSHistoryLoggingService.java
@@ -255,10 +255,15 @@ public class ATSHistoryLoggingService extends HistoryLoggingService {
           timelineClient.putEntities(entities);
       if (response != null
         && !response.getErrors().isEmpty()) {
-        TimelinePutError err = response.getErrors().get(0);
-        if (err.getErrorCode() != 0) {
-          LOG.warn("Could not post history events to ATS"
-              + ", atsPutError=" + err.getErrorCode());
+        int count = response.getErrors().size();
+        for (int i = 0; i < count; ++i) {
+          TimelinePutError err = response.getErrors().get(i);
+          if (err.getErrorCode() != 0) {
+            LOG.warn("Could not post history event to ATS"
+                + ", atsPutError=" + err.getErrorCode()
+                + ", entityId=" + entities[i].getEntityId()
+                + ", eventType=" + events.get(i).getHistoryEvent().getEventType());
+          }
         }
       }
       // Do nothing additional, ATS client library should handle throttling

http://git-wip-us.apache.org/repos/asf/tez/blob/60116ce9/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/HistoryEventTimelineConversion.java
----------------------------------------------------------------------
diff --git a/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/HistoryEventTimelineConversion.java b/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/HistoryEventTimelineConversion.java
index 865915e..4b6d648 100644
--- a/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/HistoryEventTimelineConversion.java
+++ b/tez-plugins/tez-yarn-timeline-history/src/main/java/org/apache/tez/dag/history/logging/ats/HistoryEventTimelineConversion.java
@@ -142,6 +142,8 @@ public class HistoryEventTimelineConversion {
     atsEntity.addOtherInfo(ATSConstants.CONFIG,
         DAGUtils.convertConfigurationToATSMap(event.getConf()));
 
+    atsEntity.setStartTime(event.getLaunchTime());
+
     return atsEntity;
   }
 
@@ -530,6 +532,8 @@ public class HistoryEventTimelineConversion {
     initEvt.setTimestamp(event.getInitedTime());
     atsEntity.addEvent(initEvt);
 
+    atsEntity.setStartTime(event.getInitedTime());
+
     atsEntity.addOtherInfo(ATSConstants.VERTEX_NAME, event.getVertexName());
     atsEntity.addOtherInfo(ATSConstants.INIT_REQUESTED_TIME, event.getInitRequestedTime());
     atsEntity.addOtherInfo(ATSConstants.INIT_TIME, event.getInitedTime());

http://git-wip-us.apache.org/repos/asf/tez/blob/60116ce9/tez-plugins/tez-yarn-timeline-history/src/test/java/org/apache/tez/dag/history/logging/ats/TestHistoryEventTimelineConversion.java
----------------------------------------------------------------------
diff --git a/tez-plugins/tez-yarn-timeline-history/src/test/java/org/apache/tez/dag/history/logging/ats/TestHistoryEventTimelineConversion.java b/tez-plugins/tez-yarn-timeline-history/src/test/java/org/apache/tez/dag/history/logging/ats/TestHistoryEventTimelineConversion.java
index a40aa74..ce47820 100644
--- a/tez-plugins/tez-yarn-timeline-history/src/test/java/org/apache/tez/dag/history/logging/ats/TestHistoryEventTimelineConversion.java
+++ b/tez-plugins/tez-yarn-timeline-history/src/test/java/org/apache/tez/dag/history/logging/ats/TestHistoryEventTimelineConversion.java
@@ -205,6 +205,8 @@ public class TestHistoryEventTimelineConversion {
 
     TimelineEntity timelineEntity = HistoryEventTimelineConversion.convertToTimelineEntity(event);
 
+    Assert.assertEquals(launchTime, timelineEntity.getStartTime().longValue());
+
     Assert.assertEquals(EntityTypes.TEZ_APPLICATION.name(), timelineEntity.getEntityType());
     Assert.assertEquals("tez_" + applicationId.toString(), timelineEntity.getEntityId());
 
@@ -405,6 +407,8 @@ public class TestHistoryEventTimelineConversion {
     Assert.assertEquals(EntityTypes.TEZ_VERTEX_ID.name(), timelineEntity.getEntityType());
     Assert.assertEquals(tezVertexID.toString(), timelineEntity.getEntityId());
 
+    Assert.assertEquals(initedTime, timelineEntity.getStartTime().longValue());
+
     Assert.assertEquals(1, timelineEntity.getRelatedEntities().size());
     Assert.assertTrue(
         timelineEntity.getRelatedEntities().get(EntityTypes.TEZ_DAG_ID.name()).contains(


[2/2] tez git commit: Update CHANGES.txt for TEZ-1774. (hitesh)

Posted by hi...@apache.org.
Update CHANGES.txt for TEZ-1774. (hitesh)

(cherry picked from commit f4c2112f647ce1aa7b7ab9febad2118bd9451cc6)

Conflicts:
	CHANGES.txt


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

Branch: refs/heads/branch-0.5
Commit: dcdf1512561d7c4bce2c32ab42d37c7435eb8b1e
Parents: 60116ce
Author: Hitesh Shah <hi...@apache.org>
Authored: Thu Nov 13 11:05:20 2014 -0800
Committer: Hitesh Shah <hi...@apache.org>
Committed: Thu Nov 13 11:12:50 2014 -0800

----------------------------------------------------------------------
 CHANGES.txt | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tez/blob/dcdf1512/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index a8a3b9f..a52b943 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -15,6 +15,7 @@ ALL CHANGES:
   TEZ-1687. Use logIdentifier of Vertex for logging.
   TEZ-1737. Should add taskNum in VertexFinishedEvent.
   TEZ-1770. Handle ConnectExceptions correctly when establishing connections to an NM which may be down.
+  TEZ-1774. AppLaunched event for Timeline does not have start time set.
 
 Release 0.5.2: 2014-11-07