hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From br...@apache.org
Subject svn commit: r1649897 - in /hive/branches/HIVE-8065: itests/src/test/resources/ ql/src/test/queries/clientpositive/ ql/src/test/results/clientpositive/encrypted/
Date Tue, 06 Jan 2015 18:35:53 GMT
Author: brock
Date: Tue Jan  6 18:35:52 2015
New Revision: 1649897

URL: http://svn.apache.org/r1649897
Log:
HIVE-8819 - Create unit test where we read from an read only encrypted table (Ferdinand Xu
via Brock)

Added:
    hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_select_read_only_encrypted_tbl.q
    hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_select_read_only_encrypted_tbl.q.out
Modified:
    hive/branches/HIVE-8065/itests/src/test/resources/testconfiguration.properties

Modified: hive/branches/HIVE-8065/itests/src/test/resources/testconfiguration.properties
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-8065/itests/src/test/resources/testconfiguration.properties?rev=1649897&r1=1649896&r2=1649897&view=diff
==============================================================================
--- hive/branches/HIVE-8065/itests/src/test/resources/testconfiguration.properties (original)
+++ hive/branches/HIVE-8065/itests/src/test/resources/testconfiguration.properties Tue Jan
 6 18:35:52 2015
@@ -298,7 +298,8 @@ minitez.query.files=bucket_map_join_tez1
 encrypted.query.files.shared=encryption_join_unencrypted_tbl.q,\
   encryption_insert_partition_static.q,\
   encryption_insert_partition_dynamic.q,\
-  encryption_join_with_different_encryption_keys.q
+  encryption_join_with_different_encryption_keys.q\
+  encryption_select_read_only_encrypted_tbl.q
 
 beeline.positive.exclude=add_part_exist.q,\
   alter1.q,\

Added: hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_select_read_only_encrypted_tbl.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_select_read_only_encrypted_tbl.q?rev=1649897&view=auto
==============================================================================
--- hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_select_read_only_encrypted_tbl.q
(added)
+++ hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_select_read_only_encrypted_tbl.q
Tue Jan  6 18:35:52 2015
@@ -0,0 +1,13 @@
+-- SORT_QUERY_RESULTS
+
+DROP TABLE IF EXISTS encrypted_table;
+CREATE TABLE encrypted_table (key INT, value STRING) LOCATION '/user/hive/warehouse/default/encrypted_table';
+
+CRYPTO CREATE_KEY --keyName key_128 --bitLength 128;
+CRYPTO CREATE_ZONE --keyName key_128 --path /user/hive/warehouse/default/encrypted_table;
+
+LOAD DATA LOCAL INPATH '../../data/files/kv1.txt' INTO TABLE encrypted_table;
+
+dfs -chmod -R 555 /user/hive/warehouse/default/encrypted_table;
+
+SELECT count(*) FROM encrypted_table;

Added: hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_select_read_only_encrypted_tbl.q.out
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_select_read_only_encrypted_tbl.q.out?rev=1649897&view=auto
==============================================================================
--- hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_select_read_only_encrypted_tbl.q.out
(added)
+++ hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_select_read_only_encrypted_tbl.q.out
Tue Jan  6 18:35:52 2015
@@ -0,0 +1,37 @@
+PREHOOK: query: -- SORT_QUERY_RESULTS
+
+DROP TABLE IF EXISTS encrypted_table
+PREHOOK: type: DROPTABLE
+POSTHOOK: query: -- SORT_QUERY_RESULTS
+
+DROP TABLE IF EXISTS encrypted_table
+POSTHOOK: type: DROPTABLE
+#### A masked pattern was here ####
+PREHOOK: type: CREATETABLE
+#### A masked pattern was here ####
+PREHOOK: Output: database:default
+PREHOOK: Output: default@encrypted_table
+#### A masked pattern was here ####
+POSTHOOK: type: CREATETABLE
+#### A masked pattern was here ####
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@encrypted_table
+Encryption key created: 'key_128'
+Encryption zone created: '/user/hive/warehouse/default/encrypted_table' using key: 'key_128'
+PREHOOK: query: LOAD DATA LOCAL INPATH '../../data/files/kv1.txt' INTO TABLE encrypted_table
+PREHOOK: type: LOAD
+#### A masked pattern was here ####
+PREHOOK: Output: default@encrypted_table
+POSTHOOK: query: LOAD DATA LOCAL INPATH '../../data/files/kv1.txt' INTO TABLE encrypted_table
+POSTHOOK: type: LOAD
+#### A masked pattern was here ####
+POSTHOOK: Output: default@encrypted_table
+PREHOOK: query: SELECT count(*) FROM encrypted_table
+PREHOOK: type: QUERY
+PREHOOK: Input: default@encrypted_table
+#### A masked pattern was here ####
+POSTHOOK: query: SELECT count(*) FROM encrypted_table
+POSTHOOK: type: QUERY
+POSTHOOK: Input: default@encrypted_table
+#### A masked pattern was here ####
+500



Mime
View raw message