You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Eugene Koifman (JIRA)" <ji...@apache.org> on 2013/08/14 23:25:48 UTC
[jira] [Updated] (HIVE-5094) [WebHCat] updating table permission
have no effect
[ https://issues.apache.org/jira/browse/HIVE-5094?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eugene Koifman updated HIVE-5094:
---------------------------------
Description:
Here is a sequence of commands to run to reproduce the issue
curl -i -X DELETE 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&ifExists=true'
curl -i -X PUT -HContent-type:application/json \
-d '{ "comment":"test comment", "columns": [ { "name": "int", "type": "string", "comment":"1st column comment" }, {"name":"int2", "type":"int"} ], "forma\
t": { "storedAs": "rcfile" } }' \
'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&ifExists=true'
curl -i -X GET 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&format=extended'
This returns
{"minFileSize":0,"totalNumberFiles":0,"location":"hdfs://localhost:9000/user/hive/warehouse/test_table","outputFormat":"org.apache.hadoop.hive.ql.io.RCFileOutputFormat","lastAccessTime":0,"lastUpdateTime":1376513774995,"columns":[{"name":"int","comment":"from deserializer","type":"string"},{"name":"int2","comment":"from deserializer","type":"int"}],"maxFileSize":0,"partitioned":false,"owner":"ekoifman","inputFormat":"org.apache.hadoop.hive.ql.io.RCFileInputFormat","totalFileSize":0,"database":"default","table":"test_table","group":"supergroup","permission":"rwxr-xr-x"}
curl -i -X POST -HContent-type:application/json \
-d rename=test_table2 -d permissions='rwx------' \
'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman'
curl -i -X GET 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table2?user.name=ekoifman&format=extended'
This returns:
{"minFileSize":0,"totalNumberFiles":0,"location":"hdfs://localhost:9000/user/hive/warehouse/test_table2","outputFormat":"org.apache.hadoop.hive.ql.io.RCFileOutputFormat","lastAccessTime":0,"lastUpdateTime":1376513774995,"columns":[{"name":"int","comment":"from deserializer","type":"string"},{"name":"int2","comment":"from deserializer","type":"int"}],"maxFileSize":0,"partitioned":false,"owner":"ekoifman","inputFormat":"org.apache.hadoop.hive.ql.io.RCFileInputFormat","totalFileSize":0,"database":"default","table":"test_table2","group":"supergroup","permission":"rwxr-xr-x"}
So the table name is changed but permissions are not.
was:
curl -i -X DELETE 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&ifExists=true'
curl -i -X PUT -HContent-type:application/json \
-d '{ "comment":"test comment", "columns": [ { "name": "int", "type": "string", "comment":"1st column comment" }, {"name":"int2", "type":"int"} ], "forma\
t": { "storedAs": "rcfile" } }' \
'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&ifExists=true'
curl -i -X GET 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&format=extended'
This returns
{"minFileSize":0,"totalNumberFiles":0,"location":"hdfs://localhost:9000/user/hive/warehouse/test_table","outputFormat":"org.apache.hadoop.hive.ql.io.RCFileOutputFormat","lastAccessTime":0,"lastUpdateTime":1376513774995,"columns":[{"name":"int","comment":"from deserializer","type":"string"},{"name":"int2","comment":"from deserializer","type":"int"}],"maxFileSize":0,"partitioned":false,"owner":"ekoifman","inputFormat":"org.apache.hadoop.hive.ql.io.RCFileInputFormat","totalFileSize":0,"database":"default","table":"test_table","group":"supergroup","permission":"rwxr-xr-x"}
curl -i -X POST -HContent-type:application/json \
-d rename=test_table2 -d permissions='rwx------' \
'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman'
curl -i -X GET 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table2?user.name=ekoifman&format=extended'
This returns:
{"minFileSize":0,"totalNumberFiles":0,"location":"hdfs://localhost:9000/user/hive/warehouse/test_table2","outputFormat":"org.apache.hadoop.hive.ql.io.RCFileOutputFormat","lastAccessTime":0,"lastUpdateTime":1376513774995,"columns":[{"name":"int","comment":"from deserializer","type":"string"},{"name":"int2","comment":"from deserializer","type":"int"}],"maxFileSize":0,"partitioned":false,"owner":"ekoifman","inputFormat":"org.apache.hadoop.hive.ql.io.RCFileInputFormat","totalFileSize":0,"database":"default","table":"test_table2","group":"supergroup","permission":"rwxr-xr-x"}
So the table name is changed but permissions are not.
> [WebHCat] updating table permission have no effect
> --------------------------------------------------
>
> Key: HIVE-5094
> URL: https://issues.apache.org/jira/browse/HIVE-5094
> Project: Hive
> Issue Type: Bug
> Components: HCatalog
> Affects Versions: 0.12.0
> Reporter: Eugene Koifman
>
> Here is a sequence of commands to run to reproduce the issue
> curl -i -X DELETE 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&ifExists=true'
> curl -i -X PUT -HContent-type:application/json \
> -d '{ "comment":"test comment", "columns": [ { "name": "int", "type": "string", "comment":"1st column comment" }, {"name":"int2", "type":"int"} ], "forma\
> t": { "storedAs": "rcfile" } }' \
> 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&ifExists=true'
> curl -i -X GET 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman&format=extended'
> This returns
> {"minFileSize":0,"totalNumberFiles":0,"location":"hdfs://localhost:9000/user/hive/warehouse/test_table","outputFormat":"org.apache.hadoop.hive.ql.io.RCFileOutputFormat","lastAccessTime":0,"lastUpdateTime":1376513774995,"columns":[{"name":"int","comment":"from deserializer","type":"string"},{"name":"int2","comment":"from deserializer","type":"int"}],"maxFileSize":0,"partitioned":false,"owner":"ekoifman","inputFormat":"org.apache.hadoop.hive.ql.io.RCFileInputFormat","totalFileSize":0,"database":"default","table":"test_table","group":"supergroup","permission":"rwxr-xr-x"}
> curl -i -X POST -HContent-type:application/json \
> -d rename=test_table2 -d permissions='rwx------' \
> 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table?user.name=ekoifman'
> curl -i -X GET 'http://localhost:50111/templeton/v1/ddl/database/default/table/test_table2?user.name=ekoifman&format=extended'
> This returns:
> {"minFileSize":0,"totalNumberFiles":0,"location":"hdfs://localhost:9000/user/hive/warehouse/test_table2","outputFormat":"org.apache.hadoop.hive.ql.io.RCFileOutputFormat","lastAccessTime":0,"lastUpdateTime":1376513774995,"columns":[{"name":"int","comment":"from deserializer","type":"string"},{"name":"int2","comment":"from deserializer","type":"int"}],"maxFileSize":0,"partitioned":false,"owner":"ekoifman","inputFormat":"org.apache.hadoop.hive.ql.io.RCFileInputFormat","totalFileSize":0,"database":"default","table":"test_table2","group":"supergroup","permission":"rwxr-xr-x"}
> So the table name is changed but permissions are not.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira