Return-Path: X-Original-To: apmail-hive-dev-archive@www.apache.org Delivered-To: apmail-hive-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 22CB7D7C8 for ; Wed, 11 Jul 2012 06:15:37 +0000 (UTC) Received: (qmail 46060 invoked by uid 500); 11 Jul 2012 06:15:36 -0000 Delivered-To: apmail-hive-dev-archive@hive.apache.org Received: (qmail 45853 invoked by uid 500); 11 Jul 2012 06:15:36 -0000 Mailing-List: contact dev-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list dev@hive.apache.org Received: (qmail 45819 invoked by uid 500); 11 Jul 2012 06:15:35 -0000 Delivered-To: apmail-hadoop-hive-dev@hadoop.apache.org Received: (qmail 45815 invoked by uid 99); 11 Jul 2012 06:15:35 -0000 Received: from issues-vm.apache.org (HELO issues-vm) (140.211.11.160) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 11 Jul 2012 06:15:35 +0000 Received: from isssues-vm.apache.org (localhost [127.0.0.1]) by issues-vm (Postfix) with ESMTP id CC8B3142850 for ; Wed, 11 Jul 2012 06:15:34 +0000 (UTC) Date: Wed, 11 Jul 2012 06:15:34 +0000 (UTC) From: "Ashutosh Chauhan (JIRA)" To: hive-dev@hadoop.apache.org Message-ID: <158718906.33845.1341987334839.JavaMail.jiratomcat@issues-vm> In-Reply-To: <673894483.63551.1340827364888.JavaMail.jiratomcat@issues-vm> Subject: =?utf-8?Q?[jira]_[Commented]_(HIVE-3204)_Windows:_Fix_the_unit_tes?= =?utf-8?Q?ts_which_contains_=E2=80=9C!=E2=80=9D_c?= =?utf-8?Q?ommands_(Unix_shell_commands)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HIVE-3204?page=3Dcom.atlassian.= jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D13411= 267#comment-13411267 ]=20 Ashutosh Chauhan commented on HIVE-3204: ---------------------------------------- [~kannakar@microsoft.com] : Few comments: * I see that you have added temp subdir in few places and then do rm immedi= ately. As you noted I believe this is the case when dir doesnt exist dfs -r= mr throws some exception while !rm -rf was not. If thats the case then I th= ink we should remove !rm -rf statement altogether since there is no point i= n removing non-existent dir. Also, its confusing to create a dir and then r= emove it immediately.=20 * In few .q.out files, output has changed from 1 2 4 to "Found 3 items" thi= s looks suspicious. Do you know why that has happened ? * Try to minimize white space changes in patch. There were quite bunch of t= hem in this patch.=20 =20 > Windows: Fix the unit tests which contains =E2=80=9C!=E2=80=9D comma= nds (Unix shell commands) > -------------------------------------------------------------------------= --------- > > Key: HIVE-3204 > URL: https://issues.apache.org/jira/browse/HIVE-3204 > Project: Hive > Issue Type: Sub-task > Components: Tests, Windows > Affects Versions: 0.10.0 > Reporter: Kanna Karanam > Assignee: Kanna Karanam > Fix For: 0.10.0 > > Attachments: HIVE-3204.1.patch.txt > > > Possible solution 1: (Preferred one) > ! =3D> Keeping the same syntax. Hive uses Java ru= ntime to launch the shell command so any attempt to run windows commands o= n Unix will fail and vice versa. > To deal with unit tests. Unix commands in each .q file will be modified a= s shown below. I will filter out the !commands which can=E2=80=99t be run o= n the current . > Original entry in.q file: > !rm -rf ../build/ql/test/data/exports/exim_department; > It will be replaced with the following entries. > UNIX::!rm -rf ../build/ql/test/data/exports/exim_department; > WINDOWS::!del ../build/ql/test/data/exports/exim_department > Possible solution 2: > Provide a Shell UDF library(JAVA Based code)to support platform independe= nt shell functionality > Cons =E2=80=93=20 > 1) Difficult to provide full shell functionality > 2) Takes long time > 3) Difficult to manage -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrato= rs: https://issues.apache.org/jira/secure/ContactAdministrators!default.jsp= a For more information on JIRA, see: http://www.atlassian.com/software/jira