You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by br...@apache.org on 2015/01/05 17:34:30 UTC
svn commit: r1649582 - in /hive/branches/HIVE-8065/ql/src/test:
queries/clientpositive/encryption_insert_partition_static.q
results/clientpositive/encrypted/encryption_insert_partition_static.q.out
Author: brock
Date: Mon Jan 5 16:34:30 2015
New Revision: 1649582
URL: http://svn.apache.org/r1649582
Log:
HIVE-9238 - enable unit test for inserting into statically partitioned table with the crypto command (Dong Chen via Brock)
Modified:
hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_insert_partition_static.q
hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_insert_partition_static.q.out
Modified: hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_insert_partition_static.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_insert_partition_static.q?rev=1649582&r1=1649581&r2=1649582&view=diff
==============================================================================
--- hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_insert_partition_static.q (original)
+++ hive/branches/HIVE-8065/ql/src/test/queries/clientpositive/encryption_insert_partition_static.q Mon Jan 5 16:34:30 2015
@@ -5,48 +5,51 @@ set hive.enforce.bucketing=true;
-- SORT_QUERY_RESULTS
-- init
-drop table IF EXISTS encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey;
+drop table IF EXISTS encryptedTable;
drop table IF EXISTS unencryptedTable;
-create table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey(key string,
- value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true');
+create table encryptedTable(key string,
+ value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc
+ location '/build/ql/test/data/warehouse/encryptedTable' TBLPROPERTIES ('transactional'='true');
+CRYPTO CREATE_KEY --keyName key_1 --bitLength 128;
+CRYPTO CREATE_ZONE --keyName key_1 --path /build/ql/test/data/warehouse/encryptedTable;
create table unencryptedTable(key string,
value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true');
-- insert encrypted table from values
-explain extended insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
+explain extended insert into table encryptedTable partition
(ds='today') values
('501', 'val_501'),
('502', 'val_502');
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
+insert into table encryptedTable partition
(ds='today') values
('501', 'val_501'),
('502', 'val_502');
-select * from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey order by key;
+select * from encryptedTable order by key;
-- insert encrypted table from unencrypted source
explain extended from src
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
+insert into table encryptedTable partition
(ds='yesterday')
select * limit 2;
from src
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
+insert into table encryptedTable partition
(ds='yesterday')
select * limit 2;
-select * from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey order by key;
+select * from encryptedTable order by key;
-- insert unencrypted table from encrypted source
-explain extended from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
+explain extended from encryptedTable
insert into table unencryptedTable partition
(ds='today')
select key, value;
-from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
+from encryptedTable
insert into table unencryptedTable partition
(ds='today')
select key, value;
@@ -54,5 +57,6 @@ insert into table unencryptedTable parti
select * from unencryptedTable order by key;
-- clean up
-drop table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey;
+drop table encryptedTable;
+CRYPTO DELETE_KEY --keyName key_1;
drop table unencryptedTable;
\ No newline at end of file
Modified: hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_insert_partition_static.q.out
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_insert_partition_static.q.out?rev=1649582&r1=1649581&r2=1649582&view=diff
==============================================================================
--- hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_insert_partition_static.q.out (original)
+++ hive/branches/HIVE-8065/ql/src/test/results/clientpositive/encrypted/encryption_insert_partition_static.q.out Mon Jan 5 16:34:30 2015
@@ -1,48 +1,34 @@
-PREHOOK: query: -- SORT_QUERY_RESULTS
-
--- init
-drop table IF EXISTS encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
+PREHOOK: query: drop table IF EXISTS encryptedTable
PREHOOK: type: DROPTABLE
-POSTHOOK: query: -- SORT_QUERY_RESULTS
-
--- init
-drop table IF EXISTS encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
+POSTHOOK: query: drop table IF EXISTS encryptedTable
POSTHOOK: type: DROPTABLE
PREHOOK: query: drop table IF EXISTS unencryptedTable
PREHOOK: type: DROPTABLE
POSTHOOK: query: drop table IF EXISTS unencryptedTable
POSTHOOK: type: DROPTABLE
-PREHOOK: query: create table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey(key string,
- value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true')
+PREHOOK: query: create table encryptedTable(key string, value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc location '/build/ql/test/data/warehouse/encryptedTable' TBLPROPERTIES ('transactional'='true')
PREHOOK: type: CREATETABLE
-PREHOOK: Output: database:encryptedwith128bitskeydb
-PREHOOK: Output: encryptedWith128BitsKeyDB@encryptedTableIn128BitsKey
-POSTHOOK: query: create table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey(key string,
- value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true')
+#### A masked pattern was here ####
+PREHOOK: Output: database:default
+PREHOOK: Output: default@encryptedTable
+POSTHOOK: query: create table encryptedTable(key string, value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc location '/build/ql/test/data/warehouse/encryptedTable' TBLPROPERTIES ('transactional'='true')
POSTHOOK: type: CREATETABLE
-POSTHOOK: Output: database:encryptedwith128bitskeydb
-POSTHOOK: Output: encryptedWith128BitsKeyDB@encryptedTableIn128BitsKey
-PREHOOK: query: create table unencryptedTable(key string,
- value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true')
+#### A masked pattern was here ####
+POSTHOOK: Output: database:default
+POSTHOOK: Output: default@encryptedTable
+Encryption key created: 'key_1'
+Encryption zone created: '/build/ql/test/data/warehouse/encryptedTable' using key: 'key_1'
+PREHOOK: query: create table unencryptedTable(key string, value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true')
PREHOOK: type: CREATETABLE
PREHOOK: Output: database:default
PREHOOK: Output: default@unencryptedTable
-POSTHOOK: query: create table unencryptedTable(key string,
- value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true')
+POSTHOOK: query: create table unencryptedTable(key string, value string) partitioned by (ds string) clustered by (key) into 2 buckets stored as orc TBLPROPERTIES ('transactional'='true')
POSTHOOK: type: CREATETABLE
POSTHOOK: Output: database:default
POSTHOOK: Output: default@unencryptedTable
-PREHOOK: query: -- insert encrypted table from values
-explain extended insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='today') values
- ('501', 'val_501'),
- ('502', 'val_502')
+PREHOOK: query: explain extended insert into table encryptedTable partition (ds='today') values ('501', 'val_501'), ('502', 'val_502')
PREHOOK: type: QUERY
-POSTHOOK: query: -- insert encrypted table from values
-explain extended insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='today') values
- ('501', 'val_501'),
- ('502', 'val_502')
+POSTHOOK: query: explain extended insert into table encryptedTable partition (ds='today') values ('501', 'val_501'), ('502', 'val_502')
POSTHOOK: type: QUERY
ABSTRACT SYNTAX TREE:
@@ -55,8 +41,7 @@ TOK_QUERY
TOK_INSERT_INTO
TOK_TAB
TOK_TABNAME
- encryptedWith128BitsKeyDB
- encryptedTableIn128BitsKey
+ encryptedTable
TOK_PARTSPEC
TOK_PARTVAL
ds
@@ -101,7 +86,7 @@ STAGE PLANS:
properties:
bucket_count -1
columns tmp_values_col1,tmp_values_col2
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
name default.values__tmp__table__1
@@ -115,7 +100,7 @@ STAGE PLANS:
properties:
bucket_count -1
columns tmp_values_col1,tmp_values_col2
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
name default.values__tmp__table__1
@@ -134,11 +119,11 @@ STAGE PLANS:
File Output Operator
compressed: false
GlobalTableId: 1
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=today/.hive-staging
NumFilesPerFileSink: 1
Static Partition Specification: ds=today/
Statistics: Num rows: 0 Data size: 24 Basic stats: PARTIAL Column stats: NONE
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=today/.hive-staging
table:
input format: org.apache.hadoop.hive.ql.io.orc.OrcInputFormat
output format: org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat
@@ -146,19 +131,19 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
partition_columns ds
partition_columns.types string
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
transactional true
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name: default.encryptedtable
TotalFiles: 1
GatherStats: true
MultiFileSpray: false
@@ -169,7 +154,7 @@ STAGE PLANS:
partition:
ds today
replace: false
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=today/.hive-staging
table:
input format: org.apache.hadoop.hive.ql.io.orc.OrcInputFormat
output format: org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat
@@ -177,63 +162,49 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
partition_columns ds
partition_columns.types string
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
transactional true
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name: default.encryptedtable
Stage: Stage-2
Stats-Aggr Operator
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=today/.hive-staging
-PREHOOK: query: insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='today') values
- ('501', 'val_501'),
- ('502', 'val_502')
+PREHOOK: query: insert into table encryptedTable partition (ds='today') values ('501', 'val_501'), ('502', 'val_502')
PREHOOK: type: QUERY
PREHOOK: Input: default@values__tmp__table__2
-PREHOOK: Output: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-POSTHOOK: query: insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='today') values
- ('501', 'val_501'),
- ('502', 'val_502')
+PREHOOK: Output: default@encryptedtable@ds=today
+POSTHOOK: query: insert into table encryptedTable partition (ds='today') values ('501', 'val_501'), ('502', 'val_502')
POSTHOOK: type: QUERY
POSTHOOK: Input: default@values__tmp__table__2
-POSTHOOK: Output: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-POSTHOOK: Lineage: encryptedtablein128bitskey PARTITION(ds=today).key SIMPLE [(values__tmp__table__2)values__tmp__table__2.FieldSchema(name:tmp_values_col1, type:string, comment:), ]
-POSTHOOK: Lineage: encryptedtablein128bitskey PARTITION(ds=today).value SIMPLE [(values__tmp__table__2)values__tmp__table__2.FieldSchema(name:tmp_values_col2, type:string, comment:), ]
-PREHOOK: query: select * from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey order by key
+POSTHOOK: Output: default@encryptedtable@ds=today
+POSTHOOK: Lineage: encryptedtable PARTITION(ds=today).key SIMPLE [(values__tmp__table__2)values__tmp__table__2.FieldSchema(name:tmp_values_col1, type:string, comment:), ]
+POSTHOOK: Lineage: encryptedtable PARTITION(ds=today).value SIMPLE [(values__tmp__table__2)values__tmp__table__2.FieldSchema(name:tmp_values_col2, type:string, comment:), ]
+PREHOOK: query: select * from encryptedTable order by key
PREHOOK: type: QUERY
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-#### A masked pattern was here ####
-POSTHOOK: query: select * from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey order by key
+PREHOOK: Input: default@encryptedtable
+PREHOOK: Input: default@encryptedtable@ds=today
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/.hive-staging
+POSTHOOK: query: select * from encryptedTable order by key
POSTHOOK: type: QUERY
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-#### A masked pattern was here ####
+POSTHOOK: Input: default@encryptedtable
+POSTHOOK: Input: default@encryptedtable@ds=today
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/.hive-staging
501 val_501 today
502 val_502 today
-PREHOOK: query: -- insert encrypted table from unencrypted source
-explain extended from src
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='yesterday')
- select * limit 2
+PREHOOK: query: explain extended from src insert into table encryptedTable partition (ds='yesterday') select * limit 2
PREHOOK: type: QUERY
-POSTHOOK: query: -- insert encrypted table from unencrypted source
-explain extended from src
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='yesterday')
- select * limit 2
+POSTHOOK: query: explain extended from src insert into table encryptedTable partition (ds='yesterday') select * limit 2
POSTHOOK: type: QUERY
ABSTRACT SYNTAX TREE:
@@ -246,8 +217,7 @@ TOK_QUERY
TOK_INSERT_INTO
TOK_TAB
TOK_TABNAME
- encryptedWith128BitsKeyDB
- encryptedTableIn128BitsKey
+ encryptedTable
TOK_PARTSPEC
TOK_PARTVAL
ds
@@ -298,7 +268,7 @@ STAGE PLANS:
COLUMN_STATS_ACCURATE true
bucket_count -1
columns key,value
- columns.comments default default
+ columns.comments 'default','default'
columns.types string:string
#### A masked pattern was here ####
name default.src
@@ -318,7 +288,7 @@ STAGE PLANS:
COLUMN_STATS_ACCURATE true
bucket_count -1
columns key,value
- columns.comments default default
+ columns.comments 'default','default'
columns.types string:string
#### A masked pattern was here ####
name default.src
@@ -406,11 +376,11 @@ STAGE PLANS:
File Output Operator
compressed: false
GlobalTableId: 1
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=yesterday/.hive-staging
NumFilesPerFileSink: 1
Static Partition Specification: ds=yesterday/
Statistics: Num rows: 2 Data size: 400 Basic stats: COMPLETE Column stats: NONE
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=yesterday/.hive-staging
table:
input format: org.apache.hadoop.hive.ql.io.orc.OrcInputFormat
output format: org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat
@@ -418,19 +388,19 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
partition_columns ds
partition_columns.types string
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
transactional true
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name: default.encryptedtable
TotalFiles: 1
GatherStats: true
MultiFileSpray: false
@@ -441,7 +411,7 @@ STAGE PLANS:
partition:
ds yesterday
replace: false
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=yesterday/.hive-staging
table:
input format: org.apache.hadoop.hive.ql.io.orc.OrcInputFormat
output format: org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat
@@ -449,67 +419,53 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
partition_columns ds
partition_columns.types string
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
transactional true
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name: default.encryptedtable
Stage: Stage-3
Stats-Aggr Operator
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/ds=yesterday/.hive-staging
-PREHOOK: query: from src
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='yesterday')
- select * limit 2
+PREHOOK: query: from src insert into table encryptedTable partition (ds='yesterday') select * limit 2
PREHOOK: type: QUERY
PREHOOK: Input: default@src
-PREHOOK: Output: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=yesterday
-POSTHOOK: query: from src
-insert into table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey partition
- (ds='yesterday')
- select * limit 2
+PREHOOK: Output: default@encryptedtable@ds=yesterday
+POSTHOOK: query: from src insert into table encryptedTable partition (ds='yesterday') select * limit 2
POSTHOOK: type: QUERY
POSTHOOK: Input: default@src
-POSTHOOK: Output: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=yesterday
-POSTHOOK: Lineage: encryptedtablein128bitskey PARTITION(ds=yesterday).key SIMPLE [(src)src.FieldSchema(name:key, type:string, comment:default), ]
-POSTHOOK: Lineage: encryptedtablein128bitskey PARTITION(ds=yesterday).value SIMPLE [(src)src.FieldSchema(name:value, type:string, comment:default), ]
-PREHOOK: query: select * from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey order by key
+POSTHOOK: Output: default@encryptedtable@ds=yesterday
+POSTHOOK: Lineage: encryptedtable PARTITION(ds=yesterday).key SIMPLE [(src)src.FieldSchema(name:key, type:string, comment:default), ]
+POSTHOOK: Lineage: encryptedtable PARTITION(ds=yesterday).value SIMPLE [(src)src.FieldSchema(name:value, type:string, comment:default), ]
+PREHOOK: query: select * from encryptedTable order by key
PREHOOK: type: QUERY
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=yesterday
-#### A masked pattern was here ####
-POSTHOOK: query: select * from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey order by key
+PREHOOK: Input: default@encryptedtable
+PREHOOK: Input: default@encryptedtable@ds=today
+PREHOOK: Input: default@encryptedtable@ds=yesterday
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/.hive-staging
+POSTHOOK: query: select * from encryptedTable order by key
POSTHOOK: type: QUERY
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=yesterday
-#### A masked pattern was here ####
+POSTHOOK: Input: default@encryptedtable
+POSTHOOK: Input: default@encryptedtable@ds=today
+POSTHOOK: Input: default@encryptedtable@ds=yesterday
+#### A PARTIAL masked pattern was here #### data/warehouse/encryptedTable/.hive-staging
238 val_238 yesterday
501 val_501 today
502 val_502 today
86 val_86 yesterday
-PREHOOK: query: -- insert unencrypted table from encrypted source
-explain extended from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
-insert into table unencryptedTable partition
- (ds='today')
- select key, value
+PREHOOK: query: explain extended from encryptedTable insert into table unencryptedTable partition (ds='today') select key, value
PREHOOK: type: QUERY
-POSTHOOK: query: -- insert unencrypted table from encrypted source
-explain extended from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
-insert into table unencryptedTable partition
- (ds='today')
- select key, value
+POSTHOOK: query: explain extended from encryptedTable insert into table unencryptedTable partition (ds='today') select key, value
POSTHOOK: type: QUERY
ABSTRACT SYNTAX TREE:
@@ -517,8 +473,7 @@ TOK_QUERY
TOK_FROM
TOK_TABREF
TOK_TABNAME
- encryptedWith128BitsKeyDB
- encryptedTableIn128BitsKey
+ encryptedTable
TOK_INSERT
TOK_INSERT_INTO
TOK_TAB
@@ -547,17 +502,17 @@ STAGE PLANS:
Map Reduce
Map Operator Tree:
TableScan
- alias: encryptedtablein128bitskey
- Statistics: Num rows: 12 Data size: 2567 Basic stats: COMPLETE Column stats: NONE
+ alias: encryptedtable
+ Statistics: Num rows: 12 Data size: 2575 Basic stats: COMPLETE Column stats: NONE
GatherStats: false
Select Operator
expressions: key (type: string), value (type: string)
outputColumnNames: _col0, _col1
- Statistics: Num rows: 12 Data size: 2567 Basic stats: COMPLETE Column stats: NONE
+ Statistics: Num rows: 12 Data size: 2575 Basic stats: COMPLETE Column stats: NONE
Reduce Output Operator
sort order:
Map-reduce partition columns: _col0 (type: string)
- Statistics: Num rows: 12 Data size: 2567 Basic stats: COMPLETE Column stats: NONE
+ Statistics: Num rows: 12 Data size: 2575 Basic stats: COMPLETE Column stats: NONE
tag: -1
value expressions: _col0 (type: string), _col1 (type: string)
auto parallelism: false
@@ -576,19 +531,19 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
numFiles 2
numRows 0
partition_columns ds
partition_columns.types string
rawDataSize 0
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
- totalSize 1283
+ totalSize 1287
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
@@ -598,20 +553,20 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
partition_columns ds
partition_columns.types string
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
transactional true
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name: default.encryptedtable
+ name: default.encryptedtable
#### A masked pattern was here ####
Partition
base file name: ds=yesterday
@@ -624,19 +579,19 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
numFiles 2
numRows 0
partition_columns ds
partition_columns.types string
rawDataSize 0
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
- totalSize 1284
+ totalSize 1288
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
@@ -646,35 +601,35 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
- name encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name default.encryptedtable
partition_columns ds
partition_columns.types string
- serialization.ddl struct encryptedtablein128bitskey { string key, string value}
+ serialization.ddl struct encryptedtable { string key, string value}
serialization.format 1
serialization.lib org.apache.hadoop.hive.ql.io.orc.OrcSerde
transactional true
#### A masked pattern was here ####
serde: org.apache.hadoop.hive.ql.io.orc.OrcSerde
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
- name: encryptedwith128bitskeydb.encryptedtablein128bitskey
+ name: default.encryptedtable
+ name: default.encryptedtable
Truncated Path -> Alias:
- /encryptedwith128bitskeydb.db/encryptedtablein128bitskey/ds=today [encryptedtablein128bitskey]
- /encryptedwith128bitskeydb.db/encryptedtablein128bitskey/ds=yesterday [encryptedtablein128bitskey]
+ /encryptedTable/ds=today [encryptedtable]
+ /encryptedTable/ds=yesterday [encryptedtable]
Needs Tagging: false
Reduce Operator Tree:
Extract
- Statistics: Num rows: 12 Data size: 2567 Basic stats: COMPLETE Column stats: NONE
+ Statistics: Num rows: 12 Data size: 2575 Basic stats: COMPLETE Column stats: NONE
File Output Operator
compressed: false
GlobalTableId: 1
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/unencryptedtable/ds=today/.hive-staging
NumFilesPerFileSink: 1
Static Partition Specification: ds=today/
- Statistics: Num rows: 12 Data size: 2567 Basic stats: COMPLETE Column stats: NONE
-#### A masked pattern was here ####
+ Statistics: Num rows: 12 Data size: 2575 Basic stats: COMPLETE Column stats: NONE
+#### A PARTIAL masked pattern was here #### data/warehouse/unencryptedtable/ds=today/.hive-staging
table:
input format: org.apache.hadoop.hive.ql.io.orc.OrcInputFormat
output format: org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat
@@ -682,7 +637,7 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
name default.unencryptedtable
@@ -705,7 +660,7 @@ STAGE PLANS:
partition:
ds today
replace: false
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/unencryptedtable/ds=today/.hive-staging
table:
input format: org.apache.hadoop.hive.ql.io.orc.OrcInputFormat
output format: org.apache.hadoop.hive.ql.io.orc.OrcOutputFormat
@@ -713,7 +668,7 @@ STAGE PLANS:
bucket_count 2
bucket_field_name key
columns key,value
- columns.comments
+ columns.comments
columns.types string:string
#### A masked pattern was here ####
name default.unencryptedtable
@@ -729,52 +684,45 @@ STAGE PLANS:
Stage: Stage-2
Stats-Aggr Operator
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/unencryptedtable/ds=today/.hive-staging
-PREHOOK: query: from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
-insert into table unencryptedTable partition
- (ds='today')
- select key, value
+PREHOOK: query: from encryptedTable insert into table unencryptedTable partition (ds='today') select key, value
PREHOOK: type: QUERY
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=yesterday
+PREHOOK: Input: default@encryptedtable
+PREHOOK: Input: default@encryptedtable@ds=today
+PREHOOK: Input: default@encryptedtable@ds=yesterday
PREHOOK: Output: default@unencryptedtable@ds=today
-POSTHOOK: query: from encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
-insert into table unencryptedTable partition
- (ds='today')
- select key, value
+POSTHOOK: query: from encryptedTable insert into table unencryptedTable partition (ds='today') select key, value
POSTHOOK: type: QUERY
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=today
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey@ds=yesterday
+POSTHOOK: Input: default@encryptedtable
+POSTHOOK: Input: default@encryptedtable@ds=today
+POSTHOOK: Input: default@encryptedtable@ds=yesterday
POSTHOOK: Output: default@unencryptedtable@ds=today
-POSTHOOK: Lineage: unencryptedtable PARTITION(ds=today).key SIMPLE [(encryptedtablein128bitskey)encryptedtablein128bitskey.FieldSchema(name:key, type:string, comment:null), ]
-POSTHOOK: Lineage: unencryptedtable PARTITION(ds=today).value SIMPLE [(encryptedtablein128bitskey)encryptedtablein128bitskey.FieldSchema(name:value, type:string, comment:null), ]
+POSTHOOK: Lineage: unencryptedtable PARTITION(ds=today).key SIMPLE [(encryptedtable)encryptedtable.FieldSchema(name:key, type:string, comment:null), ]
+POSTHOOK: Lineage: unencryptedtable PARTITION(ds=today).value SIMPLE [(encryptedtable)encryptedtable.FieldSchema(name:value, type:string, comment:null), ]
PREHOOK: query: select * from unencryptedTable order by key
PREHOOK: type: QUERY
PREHOOK: Input: default@unencryptedtable
PREHOOK: Input: default@unencryptedtable@ds=today
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/unencryptedtable/.hive-staging
POSTHOOK: query: select * from unencryptedTable order by key
POSTHOOK: type: QUERY
POSTHOOK: Input: default@unencryptedtable
POSTHOOK: Input: default@unencryptedtable@ds=today
-#### A masked pattern was here ####
+#### A PARTIAL masked pattern was here #### data/warehouse/unencryptedtable/.hive-staging
238 val_238 today
501 val_501 today
502 val_502 today
86 val_86 today
-PREHOOK: query: -- clean up
-drop table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
+PREHOOK: query: drop table encryptedTable
PREHOOK: type: DROPTABLE
-PREHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-PREHOOK: Output: encryptedwith128bitskeydb@encryptedtablein128bitskey
-POSTHOOK: query: -- clean up
-drop table encryptedWith128BitsKeyDB.encryptedTableIn128BitsKey
+PREHOOK: Input: default@encryptedtable
+PREHOOK: Output: default@encryptedtable
+POSTHOOK: query: drop table encryptedTable
POSTHOOK: type: DROPTABLE
-POSTHOOK: Input: encryptedwith128bitskeydb@encryptedtablein128bitskey
-POSTHOOK: Output: encryptedwith128bitskeydb@encryptedtablein128bitskey
+POSTHOOK: Input: default@encryptedtable
+POSTHOOK: Output: default@encryptedtable
+Encryption key deleted: 'key_1'
PREHOOK: query: drop table unencryptedTable
PREHOOK: type: DROPTABLE
PREHOOK: Input: default@unencryptedtable