Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 7CDCC200B30 for ; Mon, 20 Jun 2016 06:00:45 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 7B77B160A64; Mon, 20 Jun 2016 04:00:45 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id C4EC0160A53 for ; Mon, 20 Jun 2016 06:00:44 +0200 (CEST) Received: (qmail 99219 invoked by uid 500); 20 Jun 2016 04:00:43 -0000 Mailing-List: contact dev-help@atlas.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@atlas.incubator.apache.org Delivered-To: mailing list dev@atlas.incubator.apache.org Received: (qmail 99188 invoked by uid 99); 20 Jun 2016 04:00:43 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Jun 2016 04:00:43 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 2F375C0D53 for ; Mon, 20 Jun 2016 04:00:43 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -2.244 X-Spam-Level: X-Spam-Status: No, score=-2.244 tagged_above=-999 required=6.31 tests=[DKIM_ADSP_CUSTOM_MED=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=2, KAM_LAZY_DOMAIN_SECURITY=1, NML_ADSP_CUSTOM_MED=1.2, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-1.426] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id KW1EoAtOHMzP for ; Mon, 20 Jun 2016 04:00:41 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with SMTP id 319475F4E8 for ; Mon, 20 Jun 2016 04:00:40 +0000 (UTC) Received: (qmail 99092 invoked by uid 99); 20 Jun 2016 04:00:40 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Jun 2016 04:00:40 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 3FBF12F19F9; Mon, 20 Jun 2016 04:00:39 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============1388493165642141654==" MIME-Version: 1.0 Subject: Re: Review Request 48939: ATLAS-904 Handle process qualified name per Hive Operation From: Suma Shivaprasad To: Hemanth Yamijala , Shwetha GS Cc: atlas Date: Mon, 20 Jun 2016 04:00:39 -0000 Message-ID: <20160620040039.14424.28566@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: Suma Shivaprasad X-ReviewGroup: atlas X-Auto-Response-Suppress: DR, RN, OOF, AutoReply X-ReviewRequest-URL: https://reviews.apache.org/r/48939/ X-Sender: Suma Shivaprasad References: <20160620040024.14425.90589@reviews.apache.org> In-Reply-To: <20160620040024.14425.90589@reviews.apache.org> Reply-To: Suma Shivaprasad X-ReviewRequest-Repository: atlas archived-at: Mon, 20 Jun 2016 04:00:45 -0000 --===============1388493165642141654== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/48939/ ----------------------------------------------------------- (Updated June 20, 2016, 4 a.m.) Review request for atlas, Shwetha GS and Hemanth Yamijala. Bugs: ATLAS-904 https://issues.apache.org/jira/browse/ATLAS-904 Repository: atlas Description ------- 1. Process qualified name = HiveOperation.name + sorted inputs + sorted outputs 2. HiveOperation.name doesnt provide identifiers for identiifying INSERT, INSERT_OVERWRITE, UPDATE, DELETE etc separately . Hence adding WriteEntity.WriteType as well which exhibits the following behaviour a. If there are multiple outputs, for each output, adds the query type(WriteType) b. if query being run if is type INSERT [into/overwrite] TABLE [PARTITION], WriteType is INSERT/INSERT_OVERWRITE b. If query is of type INSERT OVERWRITE hdfs_path, adds WriteType as PATH_WRITE c. If query is of type UPDATE/DELETE, adds type as UPDATE/DELETE [ Note - linage is not available for this since this is single table operation] 3.When input is of type local dir or hdfs path currently, it doesnt add it to qualified name. The reason is that partition based paths cause a lot of processes to be created in this case instead of updating the same process. Pending: Address Shwetha G S suggestion to add hdfs paths to process qualified name only in case of non-partition based queries. This needs to be done per HiveOperation type 1. if HiveOperation = LOAD, IMPORT, EXPORT - detect if the current query context is dealing with partitions and do not add if it is partition based. 2. If HiveOperation = INSERT OVERWRITE DFS_PATH/LOCAL_PATH , then detect if the query context is dealing with a partitioned table in inputs and decide if we need to add or not. Diffs (updated) ----- addons/hive-bridge/src/main/java/org/apache/atlas/hive/bridge/HiveMetaStoreBridge.java c956a32 addons/hive-bridge/src/main/java/org/apache/atlas/hive/hook/HiveHook.java 23c82df addons/hive-bridge/src/test/java/org/apache/atlas/hive/hook/HiveHookIT.java e7fbf71 webapp/src/main/java/org/apache/atlas/web/resources/EntityResource.java 0713d30 Diff: https://reviews.apache.org/r/48939/diff/ Testing ------- Existing tests modified to query with new qualified name. Need to add tests for INSERT INTO TABLE Thanks, Suma Shivaprasad --===============1388493165642141654==--