hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject [12/22] hive git commit: HIVE-12832 Thrift and RDBMS schema changes for ACID fixes, branch-1 version.
Date Fri, 15 Jan 2016 01:18:01 GMT
http://git-wip-us.apache.org/repos/asf/hive/blob/92072ad2/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py
----------------------------------------------------------------------
diff --git a/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py b/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py
index 0829c52..1cc6acf 100644
--- a/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py
+++ b/metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py
@@ -1,5 +1,5 @@
 #
-# Autogenerated by Thrift Compiler (0.9.2)
+# Autogenerated by Thrift Compiler (0.9.3)
 #
 # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
 #
@@ -8,6 +8,7 @@
 
 from thrift.Thrift import TType, TMessageType, TException, TApplicationException
 import fb303.FacebookService
+import logging
 from ttypes import *
 from thrift.Thrift import TProcessor
 from thrift.transport import TTransport
@@ -1071,7 +1072,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMetaConf failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "getMetaConf failed: unknown result")
 
   def setMetaConf(self, key, value):
     """
@@ -1174,7 +1175,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_database failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_database failed: unknown result")
 
   def drop_database(self, name, deleteData, cascade):
     """
@@ -1246,7 +1247,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_databases failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_databases failed: unknown result")
 
   def get_all_databases(self):
     self.send_get_all_databases()
@@ -1274,7 +1275,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_all_databases failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_all_databases failed: unknown result")
 
   def alter_database(self, dbname, db):
     """
@@ -1344,7 +1345,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_type failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_type failed: unknown result")
 
   def create_type(self, type):
     """
@@ -1381,7 +1382,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "create_type failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "create_type failed: unknown result")
 
   def drop_type(self, type):
     """
@@ -1416,7 +1417,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_type failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_type failed: unknown result")
 
   def get_type_all(self, name):
     """
@@ -1449,7 +1450,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_type_all failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_type_all failed: unknown result")
 
   def get_fields(self, db_name, table_name):
     """
@@ -1488,7 +1489,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_fields failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_fields failed: unknown result")
 
   def get_fields_with_environment_context(self, db_name, table_name, environment_context):
     """
@@ -1529,7 +1530,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_fields_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_fields_with_environment_context failed: unknown result")
 
   def get_schema(self, db_name, table_name):
     """
@@ -1568,7 +1569,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_schema failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_schema failed: unknown result")
 
   def get_schema_with_environment_context(self, db_name, table_name, environment_context):
     """
@@ -1609,7 +1610,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_schema_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_schema_with_environment_context failed: unknown result")
 
   def create_table(self, tbl):
     """
@@ -1796,7 +1797,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_tables failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_tables failed: unknown result")
 
   def get_all_tables(self, db_name):
     """
@@ -1829,7 +1830,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_all_tables failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_all_tables failed: unknown result")
 
   def get_table(self, dbname, tbl_name):
     """
@@ -1866,7 +1867,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table failed: unknown result")
 
   def get_table_objects_by_name(self, dbname, tbl_names):
     """
@@ -1905,7 +1906,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_objects_by_name failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_objects_by_name failed: unknown result")
 
   def get_table_names_by_filter(self, dbname, filter, max_tables):
     """
@@ -1946,7 +1947,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_names_by_filter failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_names_by_filter failed: unknown result")
 
   def alter_table(self, dbname, tbl_name, new_tbl):
     """
@@ -2098,7 +2099,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partition failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partition failed: unknown result")
 
   def add_partition_with_environment_context(self, new_part, environment_context):
     """
@@ -2137,7 +2138,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partition_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partition_with_environment_context failed: unknown result")
 
   def add_partitions(self, new_parts):
     """
@@ -2174,7 +2175,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions failed: unknown result")
 
   def add_partitions_pspec(self, new_parts):
     """
@@ -2211,7 +2212,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions_pspec failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions_pspec failed: unknown result")
 
   def append_partition(self, db_name, tbl_name, part_vals):
     """
@@ -2252,7 +2253,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition failed: unknown result")
 
   def add_partitions_req(self, request):
     """
@@ -2289,7 +2290,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions_req failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions_req failed: unknown result")
 
   def append_partition_with_environment_context(self, db_name, tbl_name, part_vals, environment_context):
     """
@@ -2332,7 +2333,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition_with_environment_context failed: unknown result")
 
   def append_partition_by_name(self, db_name, tbl_name, part_name):
     """
@@ -2373,7 +2374,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition_by_name failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition_by_name failed: unknown result")
 
   def append_partition_by_name_with_environment_context(self, db_name, tbl_name, part_name, environment_context):
     """
@@ -2416,7 +2417,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition_by_name_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition_by_name_with_environment_context failed: unknown result")
 
   def drop_partition(self, db_name, tbl_name, part_vals, deleteData):
     """
@@ -2457,7 +2458,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition failed: unknown result")
 
   def drop_partition_with_environment_context(self, db_name, tbl_name, part_vals, deleteData, environment_context):
     """
@@ -2500,7 +2501,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition_with_environment_context failed: unknown result")
 
   def drop_partition_by_name(self, db_name, tbl_name, part_name, deleteData):
     """
@@ -2541,7 +2542,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition_by_name failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition_by_name failed: unknown result")
 
   def drop_partition_by_name_with_environment_context(self, db_name, tbl_name, part_name, deleteData, environment_context):
     """
@@ -2584,7 +2585,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition_by_name_with_environment_context failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition_by_name_with_environment_context failed: unknown result")
 
   def drop_partitions_req(self, req):
     """
@@ -2619,7 +2620,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partitions_req failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partitions_req failed: unknown result")
 
   def get_partition(self, db_name, tbl_name, part_vals):
     """
@@ -2658,7 +2659,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition failed: unknown result")
 
   def exchange_partition(self, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name):
     """
@@ -2705,7 +2706,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "exchange_partition failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "exchange_partition failed: unknown result")
 
   def exchange_partitions(self, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name):
     """
@@ -2752,7 +2753,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "exchange_partitions failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "exchange_partitions failed: unknown result")
 
   def get_partition_with_auth(self, db_name, tbl_name, part_vals, user_name, group_names):
     """
@@ -2795,7 +2796,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_with_auth failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_with_auth failed: unknown result")
 
   def get_partition_by_name(self, db_name, tbl_name, part_name):
     """
@@ -2834,7 +2835,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_by_name failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_by_name failed: unknown result")
 
   def get_partitions(self, db_name, tbl_name, max_parts):
     """
@@ -2873,7 +2874,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions failed: unknown result")
 
   def get_partitions_with_auth(self, db_name, tbl_name, max_parts, user_name, group_names):
     """
@@ -2916,7 +2917,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_with_auth failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_with_auth failed: unknown result")
 
   def get_partitions_pspec(self, db_name, tbl_name, max_parts):
     """
@@ -2955,7 +2956,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_pspec failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_pspec failed: unknown result")
 
   def get_partition_names(self, db_name, tbl_name, max_parts):
     """
@@ -2992,7 +2993,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_names failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_names failed: unknown result")
 
   def get_partitions_ps(self, db_name, tbl_name, part_vals, max_parts):
     """
@@ -3033,7 +3034,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_ps failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_ps failed: unknown result")
 
   def get_partitions_ps_with_auth(self, db_name, tbl_name, part_vals, max_parts, user_name, group_names):
     """
@@ -3078,7 +3079,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_ps_with_auth failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_ps_with_auth failed: unknown result")
 
   def get_partition_names_ps(self, db_name, tbl_name, part_vals, max_parts):
     """
@@ -3119,7 +3120,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_names_ps failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_names_ps failed: unknown result")
 
   def get_partitions_by_filter(self, db_name, tbl_name, filter, max_parts):
     """
@@ -3160,7 +3161,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_filter failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_filter failed: unknown result")
 
   def get_part_specs_by_filter(self, db_name, tbl_name, filter, max_parts):
     """
@@ -3201,7 +3202,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_part_specs_by_filter failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_part_specs_by_filter failed: unknown result")
 
   def get_partitions_by_expr(self, req):
     """
@@ -3236,7 +3237,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_expr failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_expr failed: unknown result")
 
   def get_partitions_by_names(self, db_name, tbl_name, names):
     """
@@ -3275,7 +3276,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_names failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_names failed: unknown result")
 
   def alter_partition(self, db_name, tbl_name, new_part):
     """
@@ -3462,7 +3463,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "partition_name_has_valid_characters failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "partition_name_has_valid_characters failed: unknown result")
 
   def get_config_value(self, name, defaultValue):
     """
@@ -3497,7 +3498,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_config_value failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_config_value failed: unknown result")
 
   def partition_name_to_vals(self, part_name):
     """
@@ -3530,7 +3531,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "partition_name_to_vals failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "partition_name_to_vals failed: unknown result")
 
   def partition_name_to_spec(self, part_name):
     """
@@ -3563,7 +3564,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "partition_name_to_spec failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "partition_name_to_spec failed: unknown result")
 
   def markPartitionForEvent(self, db_name, tbl_name, part_vals, eventType):
     """
@@ -3659,7 +3660,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o5
     if result.o6 is not None:
       raise result.o6
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "isPartitionMarkedForEvent failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "isPartitionMarkedForEvent failed: unknown result")
 
   def add_index(self, new_index, index_table):
     """
@@ -3698,7 +3699,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_index failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "add_index failed: unknown result")
 
   def alter_index(self, dbname, base_tbl_name, idx_name, new_idx):
     """
@@ -3778,7 +3779,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_index_by_name failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_index_by_name failed: unknown result")
 
   def get_index_by_name(self, db_name, tbl_name, index_name):
     """
@@ -3817,7 +3818,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_index_by_name failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_index_by_name failed: unknown result")
 
   def get_indexes(self, db_name, tbl_name, max_indexes):
     """
@@ -3856,7 +3857,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_indexes failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_indexes failed: unknown result")
 
   def get_index_names(self, db_name, tbl_name, max_indexes):
     """
@@ -3893,7 +3894,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_index_names failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_index_names failed: unknown result")
 
   def update_table_column_statistics(self, stats_obj):
     """
@@ -3932,7 +3933,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "update_table_column_statistics failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "update_table_column_statistics failed: unknown result")
 
   def update_partition_column_statistics(self, stats_obj):
     """
@@ -3971,7 +3972,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "update_partition_column_statistics failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "update_partition_column_statistics failed: unknown result")
 
   def get_table_column_statistics(self, db_name, tbl_name, col_name):
     """
@@ -4014,7 +4015,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_column_statistics failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_column_statistics failed: unknown result")
 
   def get_partition_column_statistics(self, db_name, tbl_name, part_name, col_name):
     """
@@ -4059,7 +4060,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_column_statistics failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition_column_statistics failed: unknown result")
 
   def get_table_statistics_req(self, request):
     """
@@ -4094,7 +4095,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_statistics_req failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table_statistics_req failed: unknown result")
 
   def get_partitions_statistics_req(self, request):
     """
@@ -4129,7 +4130,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_statistics_req failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_statistics_req failed: unknown result")
 
   def get_aggr_stats_for(self, request):
     """
@@ -4164,7 +4165,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_aggr_stats_for failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_aggr_stats_for failed: unknown result")
 
   def set_aggr_stats_for(self, request):
     """
@@ -4203,7 +4204,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "set_aggr_stats_for failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "set_aggr_stats_for failed: unknown result")
 
   def delete_partition_column_statistics(self, db_name, tbl_name, part_name, col_name):
     """
@@ -4248,7 +4249,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "delete_partition_column_statistics failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "delete_partition_column_statistics failed: unknown result")
 
   def delete_table_column_statistics(self, db_name, tbl_name, col_name):
     """
@@ -4291,7 +4292,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o3
     if result.o4 is not None:
       raise result.o4
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "delete_table_column_statistics failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "delete_table_column_statistics failed: unknown result")
 
   def create_function(self, func):
     """
@@ -4435,7 +4436,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_functions failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_functions failed: unknown result")
 
   def get_function(self, dbName, funcName):
     """
@@ -4472,7 +4473,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_function failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_function failed: unknown result")
 
   def get_all_functions(self):
     self.send_get_all_functions()
@@ -4500,7 +4501,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_all_functions failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_all_functions failed: unknown result")
 
   def create_role(self, role):
     """
@@ -4533,7 +4534,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "create_role failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "create_role failed: unknown result")
 
   def drop_role(self, role_name):
     """
@@ -4566,7 +4567,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_role failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_role failed: unknown result")
 
   def get_role_names(self):
     self.send_get_role_names()
@@ -4594,7 +4595,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_role_names failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_role_names failed: unknown result")
 
   def grant_role(self, role_name, principal_name, principal_type, grantor, grantorType, grant_option):
     """
@@ -4637,7 +4638,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_role failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_role failed: unknown result")
 
   def revoke_role(self, role_name, principal_name, principal_type):
     """
@@ -4674,7 +4675,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "revoke_role failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "revoke_role failed: unknown result")
 
   def list_roles(self, principal_name, principal_type):
     """
@@ -4709,7 +4710,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "list_roles failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "list_roles failed: unknown result")
 
   def grant_revoke_role(self, request):
     """
@@ -4742,7 +4743,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_revoke_role failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_revoke_role failed: unknown result")
 
   def get_principals_in_role(self, request):
     """
@@ -4775,7 +4776,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_principals_in_role failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_principals_in_role failed: unknown result")
 
   def get_role_grants_for_principal(self, request):
     """
@@ -4808,7 +4809,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_role_grants_for_principal failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_role_grants_for_principal failed: unknown result")
 
   def get_privilege_set(self, hiveObject, user_name, group_names):
     """
@@ -4845,7 +4846,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_privilege_set failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_privilege_set failed: unknown result")
 
   def list_privileges(self, principal_name, principal_type, hiveObject):
     """
@@ -4882,7 +4883,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "list_privileges failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "list_privileges failed: unknown result")
 
   def grant_privileges(self, privileges):
     """
@@ -4915,7 +4916,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_privileges failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_privileges failed: unknown result")
 
   def revoke_privileges(self, privileges):
     """
@@ -4948,7 +4949,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "revoke_privileges failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "revoke_privileges failed: unknown result")
 
   def grant_revoke_privileges(self, request):
     """
@@ -4981,7 +4982,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_revoke_privileges failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_revoke_privileges failed: unknown result")
 
   def set_ugi(self, user_name, group_names):
     """
@@ -5016,7 +5017,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "set_ugi failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "set_ugi failed: unknown result")
 
   def get_delegation_token(self, token_owner, renewer_kerberos_principal_name):
     """
@@ -5051,7 +5052,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_delegation_token failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_delegation_token failed: unknown result")
 
   def renew_delegation_token(self, token_str_form):
     """
@@ -5084,7 +5085,7 @@ class Client(fb303.FacebookService.Client, Iface):
       return result.success
     if result.o1 is not None:
       raise result.o1
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "renew_delegation_token failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "renew_delegation_token failed: unknown result")
 
   def cancel_delegation_token(self, token_str_form):
     """
@@ -5141,7 +5142,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_open_txns failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_open_txns failed: unknown result")
 
   def get_open_txns_info(self):
     self.send_get_open_txns_info()
@@ -5167,7 +5168,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_open_txns_info failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_open_txns_info failed: unknown result")
 
   def open_txns(self, rqst):
     """
@@ -5198,7 +5199,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "open_txns failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "open_txns failed: unknown result")
 
   def abort_txn(self, rqst):
     """
@@ -5297,7 +5298,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o1
     if result.o2 is not None:
       raise result.o2
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "lock failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "lock failed: unknown result")
 
   def check_lock(self, rqst):
     """
@@ -5334,7 +5335,7 @@ class Client(fb303.FacebookService.Client, Iface):
       raise result.o2
     if result.o3 is not None:
       raise result.o3
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "check_lock failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "check_lock failed: unknown result")
 
   def unlock(self, rqst):
     """
@@ -5398,7 +5399,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "show_locks failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "show_locks failed: unknown result")
 
   def heartbeat(self, ids):
     """
@@ -5464,7 +5465,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "heartbeat_txn_range failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "heartbeat_txn_range failed: unknown result")
 
   def compact(self, rqst):
     """
@@ -5524,7 +5525,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "show_compact failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "show_compact failed: unknown result")
 
   def add_dynamic_partitions(self, rqst):
     """
@@ -5588,7 +5589,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_next_notification failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_next_notification failed: unknown result")
 
   def get_current_notificationEventId(self):
     self.send_get_current_notificationEventId()
@@ -5614,7 +5615,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_current_notificationEventId failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "get_current_notificationEventId failed: unknown result")
 
   def fire_listener_event(self, rqst):
     """
@@ -5645,7 +5646,7 @@ class Client(fb303.FacebookService.Client, Iface):
     iprot.readMessageEnd()
     if result.success is not None:
       return result.success
-    raise TApplicationException(TApplicationException.MISSING_RESULT, "fire_listener_event failed: unknown result");
+    raise TApplicationException(TApplicationException.MISSING_RESULT, "fire_listener_event failed: unknown result")
 
 
 class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
@@ -5799,9 +5800,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = getMetaConf_result()
     try:
       result.success = self._handler.getMetaConf(args.key)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    oprot.writeMessageBegin("getMetaConf", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("getMetaConf", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5813,9 +5822,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = setMetaConf_result()
     try:
       self._handler.setMetaConf(args.key, args.value)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    oprot.writeMessageBegin("setMetaConf", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("setMetaConf", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5827,13 +5844,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = create_database_result()
     try:
       self._handler.create_database(args.database)
-    except AlreadyExistsException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except AlreadyExistsException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidObjectException, o2:
+    except InvalidObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("create_database", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("create_database", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5845,11 +5872,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_database_result()
     try:
       result.success = self._handler.get_database(args.name)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o2:
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("get_database", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_database", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5861,13 +5897,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_database_result()
     try:
       self._handler.drop_database(args.name, args.deleteData, args.cascade)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidOperationException, o2:
+    except InvalidOperationException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("drop_database", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("drop_database", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5879,9 +5925,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_databases_result()
     try:
       result.success = self._handler.get_databases(args.pattern)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    oprot.writeMessageBegin("get_databases", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_databases", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5893,9 +5947,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_all_databases_result()
     try:
       result.success = self._handler.get_all_databases()
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    oprot.writeMessageBegin("get_all_databases", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_all_databases", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5907,11 +5969,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = alter_database_result()
     try:
       self._handler.alter_database(args.dbname, args.db)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except NoSuchObjectException, o2:
+    except NoSuchObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("alter_database", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("alter_database", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5923,11 +5994,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_type_result()
     try:
       result.success = self._handler.get_type(args.name)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except NoSuchObjectException, o2:
+    except NoSuchObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("get_type", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_type", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5939,13 +6019,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = create_type_result()
     try:
       result.success = self._handler.create_type(args.type)
-    except AlreadyExistsException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except AlreadyExistsException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidObjectException, o2:
+    except InvalidObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("create_type", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("create_type", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5957,11 +6047,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_type_result()
     try:
       result.success = self._handler.drop_type(args.type)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except NoSuchObjectException, o2:
+    except NoSuchObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("drop_type", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("drop_type", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5973,9 +6072,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_type_all_result()
     try:
       result.success = self._handler.get_type_all(args.name)
-    except MetaException, o2:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("get_type_all", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_type_all", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -5987,13 +6094,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_fields_result()
     try:
       result.success = self._handler.get_fields(args.db_name, args.table_name)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except UnknownTableException, o2:
+    except UnknownTableException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except UnknownDBException, o3:
+    except UnknownDBException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("get_fields", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_fields", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6005,13 +6122,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_fields_with_environment_context_result()
     try:
       result.success = self._handler.get_fields_with_environment_context(args.db_name, args.table_name, args.environment_context)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except UnknownTableException, o2:
+    except UnknownTableException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except UnknownDBException, o3:
+    except UnknownDBException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("get_fields_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_fields_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6023,13 +6150,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_schema_result()
     try:
       result.success = self._handler.get_schema(args.db_name, args.table_name)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except UnknownTableException, o2:
+    except UnknownTableException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except UnknownDBException, o3:
+    except UnknownDBException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("get_schema", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_schema", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6041,13 +6178,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_schema_with_environment_context_result()
     try:
       result.success = self._handler.get_schema_with_environment_context(args.db_name, args.table_name, args.environment_context)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except UnknownTableException, o2:
+    except UnknownTableException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except UnknownDBException, o3:
+    except UnknownDBException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("get_schema_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_schema_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6059,15 +6206,26 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = create_table_result()
     try:
       self._handler.create_table(args.tbl)
-    except AlreadyExistsException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except AlreadyExistsException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidObjectException, o2:
+    except InvalidObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    except NoSuchObjectException, o4:
+    except NoSuchObjectException as o4:
+      msg_type = TMessageType.REPLY
       result.o4 = o4
-    oprot.writeMessageBegin("create_table", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("create_table", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6079,15 +6237,26 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = create_table_with_environment_context_result()
     try:
       self._handler.create_table_with_environment_context(args.tbl, args.environment_context)
-    except AlreadyExistsException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except AlreadyExistsException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidObjectException, o2:
+    except InvalidObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    except NoSuchObjectException, o4:
+    except NoSuchObjectException as o4:
+      msg_type = TMessageType.REPLY
       result.o4 = o4
-    oprot.writeMessageBegin("create_table_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("create_table_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6099,11 +6268,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_table_result()
     try:
       self._handler.drop_table(args.dbname, args.name, args.deleteData)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("drop_table", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("drop_table", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6115,11 +6293,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_table_with_environment_context_result()
     try:
       self._handler.drop_table_with_environment_context(args.dbname, args.name, args.deleteData, args.environment_context)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("drop_table_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("drop_table_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6131,9 +6318,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_tables_result()
     try:
       result.success = self._handler.get_tables(args.db_name, args.pattern)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    oprot.writeMessageBegin("get_tables", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_tables", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6145,9 +6340,17 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_all_tables_result()
     try:
       result.success = self._handler.get_all_tables(args.db_name)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    oprot.writeMessageBegin("get_all_tables", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_all_tables", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6159,11 +6362,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_table_result()
     try:
       result.success = self._handler.get_table(args.dbname, args.tbl_name)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except NoSuchObjectException, o2:
+    except NoSuchObjectException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("get_table", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_table", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6175,13 +6387,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_table_objects_by_name_result()
     try:
       result.success = self._handler.get_table_objects_by_name(args.dbname, args.tbl_names)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidOperationException, o2:
+    except InvalidOperationException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except UnknownDBException, o3:
+    except UnknownDBException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("get_table_objects_by_name", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_table_objects_by_name", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6193,13 +6415,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = get_table_names_by_filter_result()
     try:
       result.success = self._handler.get_table_names_by_filter(args.dbname, args.filter, args.max_tables)
-    except MetaException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except MetaException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except InvalidOperationException, o2:
+    except InvalidOperationException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except UnknownDBException, o3:
+    except UnknownDBException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("get_table_names_by_filter", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("get_table_names_by_filter", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6211,11 +6443,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = alter_table_result()
     try:
       self._handler.alter_table(args.dbname, args.tbl_name, args.new_tbl)
-    except InvalidOperationException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidOperationException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o2:
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("alter_table", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("alter_table", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6227,11 +6468,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = alter_table_with_environment_context_result()
     try:
       self._handler.alter_table_with_environment_context(args.dbname, args.tbl_name, args.new_tbl, args.environment_context)
-    except InvalidOperationException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidOperationException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o2:
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("alter_table_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("alter_table_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6243,11 +6493,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = alter_table_with_cascade_result()
     try:
       self._handler.alter_table_with_cascade(args.dbname, args.tbl_name, args.new_tbl, args.cascade)
-    except InvalidOperationException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidOperationException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o2:
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("alter_table_with_cascade", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("alter_table_with_cascade", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6259,13 +6518,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = add_partition_result()
     try:
       result.success = self._handler.add_partition(args.new_part)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("add_partition", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("add_partition", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6277,13 +6546,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = add_partition_with_environment_context_result()
     try:
       result.success = self._handler.add_partition_with_environment_context(args.new_part, args.environment_context)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("add_partition_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("add_partition_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6295,13 +6574,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = add_partitions_result()
     try:
       result.success = self._handler.add_partitions(args.new_parts)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("add_partitions", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("add_partitions", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6313,13 +6602,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = add_partitions_pspec_result()
     try:
       result.success = self._handler.add_partitions_pspec(args.new_parts)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("add_partitions_pspec", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("add_partitions_pspec", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6331,13 +6630,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = append_partition_result()
     try:
       result.success = self._handler.append_partition(args.db_name, args.tbl_name, args.part_vals)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("append_partition", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("append_partition", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6349,13 +6658,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = add_partitions_req_result()
     try:
       result.success = self._handler.add_partitions_req(args.request)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("add_partitions_req", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("add_partitions_req", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6367,13 +6686,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = append_partition_with_environment_context_result()
     try:
       result.success = self._handler.append_partition_with_environment_context(args.db_name, args.tbl_name, args.part_vals, args.environment_context)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("append_partition_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("append_partition_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6385,13 +6714,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = append_partition_by_name_result()
     try:
       result.success = self._handler.append_partition_by_name(args.db_name, args.tbl_name, args.part_name)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("append_partition_by_name", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("append_partition_by_name", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6403,13 +6742,23 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = append_partition_by_name_with_environment_context_result()
     try:
       result.success = self._handler.append_partition_by_name_with_environment_context(args.db_name, args.tbl_name, args.part_name, args.environment_context)
-    except InvalidObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except InvalidObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except AlreadyExistsException, o2:
+    except AlreadyExistsException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    except MetaException, o3:
+    except MetaException as o3:
+      msg_type = TMessageType.REPLY
       result.o3 = o3
-    oprot.writeMessageBegin("append_partition_by_name_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("append_partition_by_name_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6421,11 +6770,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_partition_result()
     try:
       result.success = self._handler.drop_partition(args.db_name, args.tbl_name, args.part_vals, args.deleteData)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o2:
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("drop_partition", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("drop_partition", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6437,11 +6795,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_partition_with_environment_context_result()
     try:
       result.success = self._handler.drop_partition_with_environment_context(args.db_name, args.tbl_name, args.part_vals, args.deleteData, args.environment_context)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
       result.o1 = o1
-    except MetaException, o2:
+    except MetaException as o2:
+      msg_type = TMessageType.REPLY
       result.o2 = o2
-    oprot.writeMessageBegin("drop_partition_with_environment_context", TMessageType.REPLY, seqid)
+    except Exception as ex:
+      msg_type = TMessageType.EXCEPTION
+      logging.exception(ex)
+      result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+    oprot.writeMessageBegin("drop_partition_with_environment_context", msg_type, seqid)
     result.write(oprot)
     oprot.writeMessageEnd()
     oprot.trans.flush()
@@ -6453,11 +6820,20 @@ class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
     result = drop_partition_by_name_result()
     try:
       result.success = self._handler.drop_partition_by_name(args.db_name, args.tbl_name, args.part_name, args.deleteData)
-    except NoSuchObjectException, o1:
+      msg_type = TMessageType.REPLY
+    except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+      raise
+    except NoSuchObjectException as o1:
+      msg_type = TMessageType.REPLY
  

<TRUNCATED>

Mime
View raw message