hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Harsh J (JIRA)" <>
Subject [jira] [Created] (HIVE-3414) Exception cast issue in
Date Wed, 29 Aug 2012 03:49:07 GMT
Harsh J created HIVE-3414:

             Summary: Exception cast issue in
                 Key: HIVE-3414
             Project: Hive
          Issue Type: Bug
          Components: Metastore
    Affects Versions: 0.8.1
            Reporter: Harsh J
            Priority: Trivial

(This is reading the 0.8 code)

Faulty way of checking for types in, under the HMSHandler.rename_partition

1914 } catch (Exception e) { 
1915 assert(e instanceof RuntimeException); 
1916 throw (RuntimeException)e; 
1917 }

Leads to:

Caused by: java.lang.ClassCastException: org.apache.hadoop.hive.metastore.api.InvalidOperationException
cannot be cast to java.lang.RuntimeException
        at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.rename_partition(
        at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.alter_partition(
        at org.apache.hadoop.hive.metastore.HiveMetaStoreClient.alter_partition(
        at org.apache.hadoop.hive.ql.metadata.Hive.alterPartition(
        at org.apache.hadoop.hive.ql.metadata.Hive.getPartition(
        ... 18 more

When a genuine exception occurs when processing the alter_partition method.

Why do we cast here and not re-throw in a wrapped fashion?

On trunk the similar statements now exist just in createDefaultDB and get_database methods.

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:

View raw message