[ https://issues.apache.org/jira/browse/HIVE-18892?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16389801#comment-16389801 ]
Sahil Takiar commented on HIVE-18892: ------------------------------------- +1 pending Hive QA > Fix NPEs in HiveMetastore.exchange_partitions method > ---------------------------------------------------- > > Key: HIVE-18892 > URL: https://issues.apache.org/jira/browse/HIVE-18892 > Project: Hive > Issue Type: Bug > Components: Metastore > Reporter: Marta Kuczora > Assignee: Marta Kuczora > Priority: Minor > Attachments: HIVE-18892.1.patch > > > The TestExchangePartitions tests revealed that NPE is thrown if the > exchange_partitions method is called with null, empty or non-existing DB and > table names. These NPEs could be prevented with a simple null check and a > MetaException with a proper error message should be thrown instead. > Example: NPE is thrown in the following test cases > * testExchangePartitionsNonExistingSourceTable > * testExchangePartitionsNonExistingSourceDB > * testExchangePartitionsNonExistingDestTable > * testExchangePartitionsNonExistingDestDB > * testExchangePartitionsEmptySourceTable > * testExchangePartitionsEmptySourceDB > * testExchangePartitionsEmptyDestTable > * testExchangePartitionsEmptyDestDB > * testExchangePartitionsNullSourceTable > * testExchangePartitionsNullSourceDB > * testExchangePartitionsNullDestTable > * testExchangePartitionsNullDestDB > * testExchangePartitionsNullPartSpec -- This message was sent by Atlassian JIRA (v7.6.3#76005)