[ 
https://issues.apache.org/jira/browse/HIVE-13351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15275342#comment-15275342
 ] 

Sushanth Sowmyan commented on HIVE-13351:
-----------------------------------------

[~hsubramaniyan], the commit for this patch introduced a new test failure, in 
http://ec2-54-177-240-2.us-west-1.compute.amazonaws.com/job/PreCommit-HIVE-MASTER-Build/200/testReport/org.apache.hadoop.hive.ql.security.authorization.plugin/TestHiveOperationType/checkHiveOperationTypeMatch/

(Note that this test failure report is from another jira, but was caused by the 
commit for this one)

{noformat}
Error Message

Unable to find corresponding type in HiveOperationType for 
ALTERTABLE_DROPCONSTRAINT : java.lang.IllegalArgumentException: No enum 
constant 
org.apache.hadoop.hive.ql.security.authorization.plugin.HiveOperationType.ALTERTABLE_DROPCONSTRAINT
Stacktrace

java.lang.AssertionError: Unable to find corresponding type in 
HiveOperationType for ALTERTABLE_DROPCONSTRAINT : 
java.lang.IllegalArgumentException: No enum constant 
org.apache.hadoop.hive.ql.security.authorization.plugin.HiveOperationType.ALTERTABLE_DROPCONSTRAINT
        at org.junit.Assert.fail(Assert.java:88)
        at 
org.apache.hadoop.hive.ql.security.authorization.plugin.TestHiveOperationType.checkHiveOperationTypeMatch(TestHiveOperationType.java:40)
{noformat}

Basically, TestHiveOperationType tries to ensure that for each new 
HiveOperation we add, we make sure that we add a corresponding authorization 
definition in HiveOperationType, so that external security frameworks like 
Apache Ranger can use it. Please create a followup jira to add an entry in 
HiveOperationType, and in conjunction, you will want to add an entry in 
Operation2Privilege as well.


> Support drop Primary Key/Foreign Key constraints
> ------------------------------------------------
>
>                 Key: HIVE-13351
>                 URL: https://issues.apache.org/jira/browse/HIVE-13351
>             Project: Hive
>          Issue Type: Sub-task
>          Components: CBO, Logical Optimizer
>            Reporter: Hari Sankar Sivarama Subramaniyan
>            Assignee: Hari Sankar Sivarama Subramaniyan
>              Labels: TODOC2.1
>             Fix For: 2.1.0
>
>         Attachments: HIVE-13351.1.patch, HIVE-13351.2.patch
>
>
> ALTER TABLE TABLENAME DROP CONSTRAINT CONSTRAINTNAME;
> The CONSTRAINTNAME has to be associated with the mentioned table, i.e. there 
> should be atleast 1 table column of TABLENAME participating in the constraint.
> Otherwise, we should throw an error.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to