You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@atlas.apache.org by sa...@apache.org on 2020/01/21 16:35:03 UTC

[atlas] branch master updated: ATLAS-3568: Hive hook should set startTime and endTime for hive_process entities to System.currentTimeMillis()

This is an automated email from the ASF dual-hosted git repository.

sarath pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/atlas.git


The following commit(s) were added to refs/heads/master by this push:
     new 0ac9534  ATLAS-3568: Hive hook should set startTime and endTime for hive_process entities to System.currentTimeMillis()
0ac9534 is described below

commit 0ac9534915e55f21bb44e7a4da2439055d0620a8
Author: Sarath Subramanian <sa...@apache.org>
AuthorDate: Wed Jan 15 11:27:05 2020 -0800

    ATLAS-3568: Hive hook should set startTime and endTime for hive_process entities to System.currentTimeMillis()
---
 .../main/java/org/apache/atlas/hive/hook/events/BaseHiveEvent.java    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/addons/hive-bridge/src/main/java/org/apache/atlas/hive/hook/events/BaseHiveEvent.java b/addons/hive-bridge/src/main/java/org/apache/atlas/hive/hook/events/BaseHiveEvent.java
index 425be59..02e27d5 100644
--- a/addons/hive-bridge/src/main/java/org/apache/atlas/hive/hook/events/BaseHiveEvent.java
+++ b/addons/hive-bridge/src/main/java/org/apache/atlas/hive/hook/events/BaseHiveEvent.java
@@ -663,8 +663,8 @@ public abstract class BaseHiveEvent {
         // We are setting an empty value to these attributes, since now we have a new entity type called hive process
         // execution which captures these values. We have to set empty values here because these attributes are
         // mandatory attributes for hive process entity type.
-        ret.setAttribute(ATTRIBUTE_START_TIME, EMPTY_ATTRIBUTE_VALUE);
-        ret.setAttribute(ATTRIBUTE_END_TIME, EMPTY_ATTRIBUTE_VALUE);
+        ret.setAttribute(ATTRIBUTE_START_TIME, System.currentTimeMillis());
+        ret.setAttribute(ATTRIBUTE_END_TIME, System.currentTimeMillis());
         ret.setAttribute(ATTRIBUTE_USER_NAME, EMPTY_ATTRIBUTE_VALUE);
         ret.setAttribute(ATTRIBUTE_QUERY_TEXT, EMPTY_ATTRIBUTE_VALUE);
         ret.setAttribute(ATTRIBUTE_QUERY_ID, EMPTY_ATTRIBUTE_VALUE);