[ 
https://issues.apache.org/jira/browse/HIVE-3204?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kanna Karanam updated HIVE-3204:
--------------------------------

    Attachment: HIVE-3204.2.patch.txt

Thanks Ashutosh. Please find more info below.

1)If I understand correctly, the intent of this delete is to avoid the 
cascading failures. If one test fails before cleaning up the directory, then 
rest of the tests which are depending on this directory will fail automatically 
so we may want to keep this logic to avoid this cascading affect.
2)"ls"  with no optional arguments in Unix will display just file names. (these 
are  1, 2, 4). But when it comes to DFS -ls, it displays file names along with 
their attributes. (Permissions, Creation time, last modified time etc..) and 
these attributes are non-deterministic so we are masking them.
3)Removed the white space changes and uploaded the new patch.

Thnaks
                
> Windows: Fix the unit tests which contains “!<cmd>” commands (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, HIVE-3204.2.patch.txt
>
>
> Possible solution 1: (Preferred one)
> !<Unix cmd | Windows cmd> => Keeping the same syntax. Hive uses Java runtime 
> to launch the shell command  so any attempt to run windows commands on Unix 
> will fail and vice versa.
> To deal with unit tests. Unix commands in each .q file will be modified as 
> shown below. I will filter out the !commands which can’t be run on 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 independent 
> shell functionality
> Cons – 
> 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 administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to