|
@@ -0,0 +1,5231 @@
|
|
|
|
+#
|
|
|
|
+# Autogenerated by Thrift
|
|
|
|
+#
|
|
|
|
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
|
|
+#
|
|
|
|
+
|
|
|
|
+from thrift.Thrift import *
|
|
|
|
+import fb303.FacebookService
|
|
|
|
+from ttypes import *
|
|
|
|
+from thrift.Thrift import TProcessor
|
|
|
|
+from thrift.transport import TTransport
|
|
|
|
+from thrift.protocol import TBinaryProtocol
|
|
|
|
+try:
|
|
|
|
+ from thrift.protocol import fastbinary
|
|
|
|
+except:
|
|
|
|
+ fastbinary = None
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+class Iface(fb303.FacebookService.Iface):
|
|
|
|
+ def create_database(self, name, location_uri):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_database(self, name):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def drop_database(self, name):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_databases(self, ):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_type(self, name):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def create_type(self, type):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def drop_type(self, type):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_type_all(self, name):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_fields(self, db_name, table_name):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def create_table(self, tbl):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def drop_table(self, dbname, name, deleteData):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_tables(self, db_name, pattern):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_table(self, dbname, tbl_name):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def set_table_parameters(self, dbname, tbl_name, params):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def alter_table(self, dbname, tbl_name, new_tbl):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def truncate_table(self, db_name, table_name, partition):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def cat(self, db_name, table_name, partition, high):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def add_partition(self, new_part):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def append_partition(self, db_name, tbl_name, part_vals):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def drop_partition(self, db_name, tbl_name, part_vals, deleteData):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_partition(self, db_name, tbl_name, part_vals):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def get_partitions(self, db_name, tbl_name, max_parts):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def set_partition_parameters(self, db_name, tbl_name, pname, params):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def alter_partitions(self, sd, parts):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def create_index(self, index_def):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+class Client(fb303.FacebookService.Client, Iface):
|
|
|
|
+ def __init__(self, iprot, oprot=None):
|
|
|
|
+ fb303.FacebookService.Client.__init__(self, iprot, oprot)
|
|
|
|
+
|
|
|
|
+ def create_database(self, name, location_uri):
|
|
|
|
+ self.send_create_database(name, location_uri)
|
|
|
|
+ return self.recv_create_database()
|
|
|
|
+
|
|
|
|
+ def send_create_database(self, name, location_uri):
|
|
|
|
+ self._oprot.writeMessageBegin('create_database', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = create_database_args()
|
|
|
|
+ args.name = name
|
|
|
|
+ args.location_uri = location_uri
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_create_database(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = create_database_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "create_database failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_database(self, name):
|
|
|
|
+ self.send_get_database(name)
|
|
|
|
+ return self.recv_get_database()
|
|
|
|
+
|
|
|
|
+ def send_get_database(self, name):
|
|
|
|
+ self._oprot.writeMessageBegin('get_database', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_database_args()
|
|
|
|
+ args.name = name
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_database(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_database_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_database failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def drop_database(self, name):
|
|
|
|
+ self.send_drop_database(name)
|
|
|
|
+ return self.recv_drop_database()
|
|
|
|
+
|
|
|
|
+ def send_drop_database(self, name):
|
|
|
|
+ self._oprot.writeMessageBegin('drop_database', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = drop_database_args()
|
|
|
|
+ args.name = name
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_drop_database(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = drop_database_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_database failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_databases(self, ):
|
|
|
|
+ self.send_get_databases()
|
|
|
|
+ return self.recv_get_databases()
|
|
|
|
+
|
|
|
|
+ def send_get_databases(self, ):
|
|
|
|
+ self._oprot.writeMessageBegin('get_databases', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_databases_args()
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_databases(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_databases_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_databases failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_type(self, name):
|
|
|
|
+ self.send_get_type(name)
|
|
|
|
+ return self.recv_get_type()
|
|
|
|
+
|
|
|
|
+ def send_get_type(self, name):
|
|
|
|
+ self._oprot.writeMessageBegin('get_type', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_type_args()
|
|
|
|
+ args.name = name
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_type(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_type_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_type failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def create_type(self, type):
|
|
|
|
+ self.send_create_type(type)
|
|
|
|
+ return self.recv_create_type()
|
|
|
|
+
|
|
|
|
+ def send_create_type(self, type):
|
|
|
|
+ self._oprot.writeMessageBegin('create_type', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = create_type_args()
|
|
|
|
+ args.type = type
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_create_type(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = create_type_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ if result.o3 != None:
|
|
|
|
+ raise result.o3
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "create_type failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def drop_type(self, type):
|
|
|
|
+ self.send_drop_type(type)
|
|
|
|
+ return self.recv_drop_type()
|
|
|
|
+
|
|
|
|
+ def send_drop_type(self, type):
|
|
|
|
+ self._oprot.writeMessageBegin('drop_type', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = drop_type_args()
|
|
|
|
+ args.type = type
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_drop_type(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = drop_type_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_type failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_type_all(self, name):
|
|
|
|
+ self.send_get_type_all(name)
|
|
|
|
+ return self.recv_get_type_all()
|
|
|
|
+
|
|
|
|
+ def send_get_type_all(self, name):
|
|
|
|
+ self._oprot.writeMessageBegin('get_type_all', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_type_all_args()
|
|
|
|
+ args.name = name
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_type_all(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_type_all_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_type_all failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_fields(self, db_name, table_name):
|
|
|
|
+ self.send_get_fields(db_name, table_name)
|
|
|
|
+ return self.recv_get_fields()
|
|
|
|
+
|
|
|
|
+ def send_get_fields(self, db_name, table_name):
|
|
|
|
+ self._oprot.writeMessageBegin('get_fields', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_fields_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.table_name = table_name
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_fields(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_fields_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.ouch1 != None:
|
|
|
|
+ raise result.ouch1
|
|
|
|
+ if result.ouch2 != None:
|
|
|
|
+ raise result.ouch2
|
|
|
|
+ if result.ouch3 != None:
|
|
|
|
+ raise result.ouch3
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_fields failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def create_table(self, tbl):
|
|
|
|
+ self.send_create_table(tbl)
|
|
|
|
+ self.recv_create_table()
|
|
|
|
+
|
|
|
|
+ def send_create_table(self, tbl):
|
|
|
|
+ self._oprot.writeMessageBegin('create_table', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = create_table_args()
|
|
|
|
+ args.tbl = tbl
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_create_table(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = create_table_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.ouch1 != None:
|
|
|
|
+ raise result.ouch1
|
|
|
|
+ if result.ouch2 != None:
|
|
|
|
+ raise result.ouch2
|
|
|
|
+ if result.ouch3 != None:
|
|
|
|
+ raise result.ouch3
|
|
|
|
+ if result.o4 != None:
|
|
|
|
+ raise result.o4
|
|
|
|
+ return
|
|
|
|
+
|
|
|
|
+ def drop_table(self, dbname, name, deleteData):
|
|
|
|
+ self.send_drop_table(dbname, name, deleteData)
|
|
|
|
+ self.recv_drop_table()
|
|
|
|
+
|
|
|
|
+ def send_drop_table(self, dbname, name, deleteData):
|
|
|
|
+ self._oprot.writeMessageBegin('drop_table', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = drop_table_args()
|
|
|
|
+ args.dbname = dbname
|
|
|
|
+ args.name = name
|
|
|
|
+ args.deleteData = deleteData
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_drop_table(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = drop_table_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.ouch3 != None:
|
|
|
|
+ raise result.ouch3
|
|
|
|
+ return
|
|
|
|
+
|
|
|
|
+ def get_tables(self, db_name, pattern):
|
|
|
|
+ self.send_get_tables(db_name, pattern)
|
|
|
|
+ return self.recv_get_tables()
|
|
|
|
+
|
|
|
|
+ def send_get_tables(self, db_name, pattern):
|
|
|
|
+ self._oprot.writeMessageBegin('get_tables', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_tables_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.pattern = pattern
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_tables(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_tables_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.ouch1 != None:
|
|
|
|
+ raise result.ouch1
|
|
|
|
+ if result.ouch2 != None:
|
|
|
|
+ raise result.ouch2
|
|
|
|
+ if result.ouch3 != None:
|
|
|
|
+ raise result.ouch3
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_tables failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_table(self, dbname, tbl_name):
|
|
|
|
+ self.send_get_table(dbname, tbl_name)
|
|
|
|
+ return self.recv_get_table()
|
|
|
|
+
|
|
|
|
+ def send_get_table(self, dbname, tbl_name):
|
|
|
|
+ self._oprot.writeMessageBegin('get_table', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_table_args()
|
|
|
|
+ args.dbname = dbname
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_table(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_table_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_table failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def set_table_parameters(self, dbname, tbl_name, params):
|
|
|
|
+ self.send_set_table_parameters(dbname, tbl_name, params)
|
|
|
|
+ return self.recv_set_table_parameters()
|
|
|
|
+
|
|
|
|
+ def send_set_table_parameters(self, dbname, tbl_name, params):
|
|
|
|
+ self._oprot.writeMessageBegin('set_table_parameters', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = set_table_parameters_args()
|
|
|
|
+ args.dbname = dbname
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.params = params
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_set_table_parameters(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = set_table_parameters_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "set_table_parameters failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def alter_table(self, dbname, tbl_name, new_tbl):
|
|
|
|
+ self.send_alter_table(dbname, tbl_name, new_tbl)
|
|
|
|
+ self.recv_alter_table()
|
|
|
|
+
|
|
|
|
+ def send_alter_table(self, dbname, tbl_name, new_tbl):
|
|
|
|
+ self._oprot.writeMessageBegin('alter_table', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = alter_table_args()
|
|
|
|
+ args.dbname = dbname
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.new_tbl = new_tbl
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_alter_table(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = alter_table_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ return
|
|
|
|
+
|
|
|
|
+ def truncate_table(self, db_name, table_name, partition):
|
|
|
|
+ self.send_truncate_table(db_name, table_name, partition)
|
|
|
|
+ self.recv_truncate_table()
|
|
|
|
+
|
|
|
|
+ def send_truncate_table(self, db_name, table_name, partition):
|
|
|
|
+ self._oprot.writeMessageBegin('truncate_table', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = truncate_table_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.table_name = table_name
|
|
|
|
+ args.partition = partition
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_truncate_table(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = truncate_table_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.ouch1 != None:
|
|
|
|
+ raise result.ouch1
|
|
|
|
+ if result.ouch2 != None:
|
|
|
|
+ raise result.ouch2
|
|
|
|
+ if result.ouch3 != None:
|
|
|
|
+ raise result.ouch3
|
|
|
|
+ return
|
|
|
|
+
|
|
|
|
+ def cat(self, db_name, table_name, partition, high):
|
|
|
|
+ self.send_cat(db_name, table_name, partition, high)
|
|
|
|
+ return self.recv_cat()
|
|
|
|
+
|
|
|
|
+ def send_cat(self, db_name, table_name, partition, high):
|
|
|
|
+ self._oprot.writeMessageBegin('cat', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = cat_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.table_name = table_name
|
|
|
|
+ args.partition = partition
|
|
|
|
+ args.high = high
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_cat(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = cat_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.ouch1 != None:
|
|
|
|
+ raise result.ouch1
|
|
|
|
+ if result.ouch2 != None:
|
|
|
|
+ raise result.ouch2
|
|
|
|
+ if result.ouch3 != None:
|
|
|
|
+ raise result.ouch3
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "cat failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def add_partition(self, new_part):
|
|
|
|
+ self.send_add_partition(new_part)
|
|
|
|
+ return self.recv_add_partition()
|
|
|
|
+
|
|
|
|
+ def send_add_partition(self, new_part):
|
|
|
|
+ self._oprot.writeMessageBegin('add_partition', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = add_partition_args()
|
|
|
|
+ args.new_part = new_part
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_add_partition(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = add_partition_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ if result.o3 != None:
|
|
|
|
+ raise result.o3
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partition failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def append_partition(self, db_name, tbl_name, part_vals):
|
|
|
|
+ self.send_append_partition(db_name, tbl_name, part_vals)
|
|
|
|
+ return self.recv_append_partition()
|
|
|
|
+
|
|
|
|
+ def send_append_partition(self, db_name, tbl_name, part_vals):
|
|
|
|
+ self._oprot.writeMessageBegin('append_partition', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = append_partition_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.part_vals = part_vals
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_append_partition(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = append_partition_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ if result.o3 != None:
|
|
|
|
+ raise result.o3
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "append_partition failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def drop_partition(self, db_name, tbl_name, part_vals, deleteData):
|
|
|
|
+ self.send_drop_partition(db_name, tbl_name, part_vals, deleteData)
|
|
|
|
+ return self.recv_drop_partition()
|
|
|
|
+
|
|
|
|
+ def send_drop_partition(self, db_name, tbl_name, part_vals, deleteData):
|
|
|
|
+ self._oprot.writeMessageBegin('drop_partition', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = drop_partition_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.part_vals = part_vals
|
|
|
|
+ args.deleteData = deleteData
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_drop_partition(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = drop_partition_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "drop_partition failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_partition(self, db_name, tbl_name, part_vals):
|
|
|
|
+ self.send_get_partition(db_name, tbl_name, part_vals)
|
|
|
|
+ return self.recv_get_partition()
|
|
|
|
+
|
|
|
|
+ def send_get_partition(self, db_name, tbl_name, part_vals):
|
|
|
|
+ self._oprot.writeMessageBegin('get_partition', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_partition_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.part_vals = part_vals
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_partition(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_partition_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def get_partitions(self, db_name, tbl_name, max_parts):
|
|
|
|
+ self.send_get_partitions(db_name, tbl_name, max_parts)
|
|
|
|
+ return self.recv_get_partitions()
|
|
|
|
+
|
|
|
|
+ def send_get_partitions(self, db_name, tbl_name, max_parts):
|
|
|
|
+ self._oprot.writeMessageBegin('get_partitions', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = get_partitions_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.max_parts = max_parts
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_get_partitions(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = get_partitions_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def set_partition_parameters(self, db_name, tbl_name, pname, params):
|
|
|
|
+ self.send_set_partition_parameters(db_name, tbl_name, pname, params)
|
|
|
|
+ return self.recv_set_partition_parameters()
|
|
|
|
+
|
|
|
|
+ def send_set_partition_parameters(self, db_name, tbl_name, pname, params):
|
|
|
|
+ self._oprot.writeMessageBegin('set_partition_parameters', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = set_partition_parameters_args()
|
|
|
|
+ args.db_name = db_name
|
|
|
|
+ args.tbl_name = tbl_name
|
|
|
|
+ args.pname = pname
|
|
|
|
+ args.params = params
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_set_partition_parameters(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = set_partition_parameters_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "set_partition_parameters failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def alter_partitions(self, sd, parts):
|
|
|
|
+ self.send_alter_partitions(sd, parts)
|
|
|
|
+ return self.recv_alter_partitions()
|
|
|
|
+
|
|
|
|
+ def send_alter_partitions(self, sd, parts):
|
|
|
|
+ self._oprot.writeMessageBegin('alter_partitions', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = alter_partitions_args()
|
|
|
|
+ args.sd = sd
|
|
|
|
+ args.parts = parts
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_alter_partitions(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = alter_partitions_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "alter_partitions failed: unknown result");
|
|
|
|
+
|
|
|
|
+ def create_index(self, index_def):
|
|
|
|
+ self.send_create_index(index_def)
|
|
|
|
+ return self.recv_create_index()
|
|
|
|
+
|
|
|
|
+ def send_create_index(self, index_def):
|
|
|
|
+ self._oprot.writeMessageBegin('create_index', TMessageType.CALL, self._seqid)
|
|
|
|
+ args = create_index_args()
|
|
|
|
+ args.index_def = index_def
|
|
|
|
+ args.write(self._oprot)
|
|
|
|
+ self._oprot.writeMessageEnd()
|
|
|
|
+ self._oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def recv_create_index(self, ):
|
|
|
|
+ (fname, mtype, rseqid) = self._iprot.readMessageBegin()
|
|
|
|
+ if mtype == TMessageType.EXCEPTION:
|
|
|
|
+ x = TApplicationException()
|
|
|
|
+ x.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ raise x
|
|
|
|
+ result = create_index_result()
|
|
|
|
+ result.read(self._iprot)
|
|
|
|
+ self._iprot.readMessageEnd()
|
|
|
|
+ if result.success != None:
|
|
|
|
+ return result.success
|
|
|
|
+ if result.o1 != None:
|
|
|
|
+ raise result.o1
|
|
|
|
+ if result.o2 != None:
|
|
|
|
+ raise result.o2
|
|
|
|
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "create_index failed: unknown result");
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+class Processor(fb303.FacebookService.Processor, Iface, TProcessor):
|
|
|
|
+ def __init__(self, handler):
|
|
|
|
+ fb303.FacebookService.Processor.__init__(self, handler)
|
|
|
|
+ self._processMap["create_database"] = Processor.process_create_database
|
|
|
|
+ self._processMap["get_database"] = Processor.process_get_database
|
|
|
|
+ self._processMap["drop_database"] = Processor.process_drop_database
|
|
|
|
+ self._processMap["get_databases"] = Processor.process_get_databases
|
|
|
|
+ self._processMap["get_type"] = Processor.process_get_type
|
|
|
|
+ self._processMap["create_type"] = Processor.process_create_type
|
|
|
|
+ self._processMap["drop_type"] = Processor.process_drop_type
|
|
|
|
+ self._processMap["get_type_all"] = Processor.process_get_type_all
|
|
|
|
+ self._processMap["get_fields"] = Processor.process_get_fields
|
|
|
|
+ self._processMap["create_table"] = Processor.process_create_table
|
|
|
|
+ self._processMap["drop_table"] = Processor.process_drop_table
|
|
|
|
+ self._processMap["get_tables"] = Processor.process_get_tables
|
|
|
|
+ self._processMap["get_table"] = Processor.process_get_table
|
|
|
|
+ self._processMap["set_table_parameters"] = Processor.process_set_table_parameters
|
|
|
|
+ self._processMap["alter_table"] = Processor.process_alter_table
|
|
|
|
+ self._processMap["truncate_table"] = Processor.process_truncate_table
|
|
|
|
+ self._processMap["cat"] = Processor.process_cat
|
|
|
|
+ self._processMap["add_partition"] = Processor.process_add_partition
|
|
|
|
+ self._processMap["append_partition"] = Processor.process_append_partition
|
|
|
|
+ self._processMap["drop_partition"] = Processor.process_drop_partition
|
|
|
|
+ self._processMap["get_partition"] = Processor.process_get_partition
|
|
|
|
+ self._processMap["get_partitions"] = Processor.process_get_partitions
|
|
|
|
+ self._processMap["set_partition_parameters"] = Processor.process_set_partition_parameters
|
|
|
|
+ self._processMap["alter_partitions"] = Processor.process_alter_partitions
|
|
|
|
+ self._processMap["create_index"] = Processor.process_create_index
|
|
|
|
+
|
|
|
|
+ def process(self, iprot, oprot):
|
|
|
|
+ (name, type, seqid) = iprot.readMessageBegin()
|
|
|
|
+ if name not in self._processMap:
|
|
|
|
+ iprot.skip(TType.STRUCT)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
|
|
|
|
+ oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
|
|
|
|
+ x.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+ return
|
|
|
|
+ else:
|
|
|
|
+ self._processMap[name](self, seqid, iprot, oprot)
|
|
|
|
+ return True
|
|
|
|
+
|
|
|
|
+ def process_create_database(self, seqid, iprot, oprot):
|
|
|
|
+ args = create_database_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = create_database_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.create_database(args.name, args.location_uri)
|
|
|
|
+ except AlreadyExistsException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("create_database", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_database(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_database_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_database_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_database(args.name)
|
|
|
|
+ except NoSuchObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("get_database", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_drop_database(self, seqid, iprot, oprot):
|
|
|
|
+ args = drop_database_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = drop_database_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.drop_database(args.name)
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("drop_database", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_databases(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_databases_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_databases_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_databases()
|
|
|
|
+ except MetaException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ oprot.writeMessageBegin("get_databases", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_type(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_type_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_type_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_type(args.name)
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("get_type", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_create_type(self, seqid, iprot, oprot):
|
|
|
|
+ args = create_type_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = create_type_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.create_type(args.type)
|
|
|
|
+ except AlreadyExistsException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except InvalidObjectException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ except MetaException, o3:
|
|
|
|
+ result.o3 = o3
|
|
|
|
+ oprot.writeMessageBegin("create_type", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_drop_type(self, seqid, iprot, oprot):
|
|
|
|
+ args = drop_type_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = drop_type_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.drop_type(args.type)
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("drop_type", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_type_all(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_type_all_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_type_all_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_type_all(args.name)
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("get_type_all", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_fields(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_fields_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_fields_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_fields(args.db_name, args.table_name)
|
|
|
|
+ except MetaException, ouch1:
|
|
|
|
+ result.ouch1 = ouch1
|
|
|
|
+ except UnknownTableException, ouch2:
|
|
|
|
+ result.ouch2 = ouch2
|
|
|
|
+ except UnknownDBException, ouch3:
|
|
|
|
+ result.ouch3 = ouch3
|
|
|
|
+ oprot.writeMessageBegin("get_fields", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_create_table(self, seqid, iprot, oprot):
|
|
|
|
+ args = create_table_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = create_table_result()
|
|
|
|
+ try:
|
|
|
|
+ self._handler.create_table(args.tbl)
|
|
|
|
+ except AlreadyExistsException, ouch1:
|
|
|
|
+ result.ouch1 = ouch1
|
|
|
|
+ except InvalidObjectException, ouch2:
|
|
|
|
+ result.ouch2 = ouch2
|
|
|
|
+ except MetaException, ouch3:
|
|
|
|
+ result.ouch3 = ouch3
|
|
|
|
+ except NoSuchObjectException, o4:
|
|
|
|
+ result.o4 = o4
|
|
|
|
+ oprot.writeMessageBegin("create_table", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_drop_table(self, seqid, iprot, oprot):
|
|
|
|
+ args = drop_table_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = drop_table_result()
|
|
|
|
+ try:
|
|
|
|
+ self._handler.drop_table(args.dbname, args.name, args.deleteData)
|
|
|
|
+ except NoSuchObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, ouch3:
|
|
|
|
+ result.ouch3 = ouch3
|
|
|
|
+ oprot.writeMessageBegin("drop_table", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_tables(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_tables_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_tables_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_tables(args.db_name, args.pattern)
|
|
|
|
+ except MetaException, ouch1:
|
|
|
|
+ result.ouch1 = ouch1
|
|
|
|
+ except UnknownTableException, ouch2:
|
|
|
|
+ result.ouch2 = ouch2
|
|
|
|
+ except UnknownDBException, ouch3:
|
|
|
|
+ result.ouch3 = ouch3
|
|
|
|
+ oprot.writeMessageBegin("get_tables", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_table(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_table_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_table_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_table(args.dbname, args.tbl_name)
|
|
|
|
+ except MetaException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except NoSuchObjectException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("get_table", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_set_table_parameters(self, seqid, iprot, oprot):
|
|
|
|
+ args = set_table_parameters_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = set_table_parameters_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.set_table_parameters(args.dbname, args.tbl_name, args.params)
|
|
|
|
+ except NoSuchObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("set_table_parameters", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_alter_table(self, seqid, iprot, oprot):
|
|
|
|
+ args = alter_table_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = alter_table_result()
|
|
|
|
+ try:
|
|
|
|
+ self._handler.alter_table(args.dbname, args.tbl_name, args.new_tbl)
|
|
|
|
+ except InvalidOperationException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("alter_table", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_truncate_table(self, seqid, iprot, oprot):
|
|
|
|
+ args = truncate_table_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = truncate_table_result()
|
|
|
|
+ try:
|
|
|
|
+ self._handler.truncate_table(args.db_name, args.table_name, args.partition)
|
|
|
|
+ except MetaException, ouch1:
|
|
|
|
+ result.ouch1 = ouch1
|
|
|
|
+ except UnknownTableException, ouch2:
|
|
|
|
+ result.ouch2 = ouch2
|
|
|
|
+ except UnknownDBException, ouch3:
|
|
|
|
+ result.ouch3 = ouch3
|
|
|
|
+ oprot.writeMessageBegin("truncate_table", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_cat(self, seqid, iprot, oprot):
|
|
|
|
+ args = cat_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = cat_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.cat(args.db_name, args.table_name, args.partition, args.high)
|
|
|
|
+ except MetaException, ouch1:
|
|
|
|
+ result.ouch1 = ouch1
|
|
|
|
+ except UnknownDBException, ouch2:
|
|
|
|
+ result.ouch2 = ouch2
|
|
|
|
+ except UnknownTableException, ouch3:
|
|
|
|
+ result.ouch3 = ouch3
|
|
|
|
+ oprot.writeMessageBegin("cat", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_add_partition(self, seqid, iprot, oprot):
|
|
|
|
+ args = add_partition_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = add_partition_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.add_partition(args.new_part)
|
|
|
|
+ except InvalidObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except AlreadyExistsException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ except MetaException, o3:
|
|
|
|
+ result.o3 = o3
|
|
|
|
+ oprot.writeMessageBegin("add_partition", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_append_partition(self, seqid, iprot, oprot):
|
|
|
|
+ args = append_partition_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = append_partition_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.append_partition(args.db_name, args.tbl_name, args.part_vals)
|
|
|
|
+ except InvalidObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except AlreadyExistsException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ except MetaException, o3:
|
|
|
|
+ result.o3 = o3
|
|
|
|
+ oprot.writeMessageBegin("append_partition", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_drop_partition(self, seqid, iprot, oprot):
|
|
|
|
+ args = drop_partition_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ 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:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("drop_partition", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_partition(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_partition_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_partition_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_partition(args.db_name, args.tbl_name, args.part_vals)
|
|
|
|
+ except MetaException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ oprot.writeMessageBegin("get_partition", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_get_partitions(self, seqid, iprot, oprot):
|
|
|
|
+ args = get_partitions_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = get_partitions_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.get_partitions(args.db_name, args.tbl_name, args.max_parts)
|
|
|
|
+ except NoSuchObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("get_partitions", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_set_partition_parameters(self, seqid, iprot, oprot):
|
|
|
|
+ args = set_partition_parameters_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = set_partition_parameters_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.set_partition_parameters(args.db_name, args.tbl_name, args.pname, args.params)
|
|
|
|
+ except NoSuchObjectException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("set_partition_parameters", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_alter_partitions(self, seqid, iprot, oprot):
|
|
|
|
+ args = alter_partitions_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = alter_partitions_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.alter_partitions(args.sd, args.parts)
|
|
|
|
+ except InvalidOperationException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("alter_partitions", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+ def process_create_index(self, seqid, iprot, oprot):
|
|
|
|
+ args = create_index_args()
|
|
|
|
+ args.read(iprot)
|
|
|
|
+ iprot.readMessageEnd()
|
|
|
|
+ result = create_index_result()
|
|
|
|
+ try:
|
|
|
|
+ result.success = self._handler.create_index(args.index_def)
|
|
|
|
+ except IndexAlreadyExistsException, o1:
|
|
|
|
+ result.o1 = o1
|
|
|
|
+ except MetaException, o2:
|
|
|
|
+ result.o2 = o2
|
|
|
|
+ oprot.writeMessageBegin("create_index", TMessageType.REPLY, seqid)
|
|
|
|
+ result.write(oprot)
|
|
|
|
+ oprot.writeMessageEnd()
|
|
|
|
+ oprot.trans.flush()
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+# HELPER FUNCTIONS AND STRUCTURES
|
|
|
|
+
|
|
|
|
+class create_database_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'location_uri', None, None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.name = None
|
|
|
|
+ self.location_uri = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'name' in d:
|
|
|
|
+ self.name = d['name']
|
|
|
|
+ if 'location_uri' in d:
|
|
|
|
+ self.location_uri = d['location_uri']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.location_uri = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_database_args')
|
|
|
|
+ if self.name != None:
|
|
|
|
+ oprot.writeFieldBegin('name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.location_uri != None:
|
|
|
|
+ oprot.writeFieldBegin('location_uri', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.location_uri)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_database_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (AlreadyExistsException, AlreadyExistsException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = AlreadyExistsException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_database_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_database_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'name', None, None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.name = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'name' in d:
|
|
|
|
+ self.name = d['name']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_database_args')
|
|
|
|
+ if self.name != None:
|
|
|
|
+ oprot.writeFieldBegin('name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_database_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.STRUCT, 'success', (Database, Database.thrift_spec), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.success = Database()
|
|
|
|
+ self.success.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = NoSuchObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_database_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
|
+ self.success.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_database_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'name', None, None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.name = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'name' in d:
|
|
|
|
+ self.name = d['name']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_database_args')
|
|
|
|
+ if self.name != None:
|
|
|
|
+ oprot.writeFieldBegin('name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_database_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ None, # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_database_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_databases_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ pass
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_databases_args')
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_databases_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.LIST, 'success', (TType.STRING,None), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.success = []
|
|
|
|
+ (_etype88, _size85) = iprot.readListBegin()
|
|
|
|
+ for _i89 in xrange(_size85):
|
|
|
|
+ _elem90 = iprot.readString();
|
|
|
|
+ self.success.append(_elem90)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = MetaException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_databases_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.LIST, 0)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.success))
|
|
|
|
+ for iter91 in self.success:
|
|
|
|
+ oprot.writeString(iter91)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_type_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'name', None, None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.name = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'name' in d:
|
|
|
|
+ self.name = d['name']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_type_args')
|
|
|
|
+ if self.name != None:
|
|
|
|
+ oprot.writeFieldBegin('name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_type_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.STRUCT, 'success', (Type, Type.thrift_spec), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.success = Type()
|
|
|
|
+ self.success.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_type_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
|
+ self.success.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 1)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_type_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'type', (Type, Type.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.type = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'type' in d:
|
|
|
|
+ self.type = d['type']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.type = Type()
|
|
|
|
+ self.type.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_type_args')
|
|
|
|
+ if self.type != None:
|
|
|
|
+ oprot.writeFieldBegin('type', TType.STRUCT, 1)
|
|
|
|
+ self.type.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_type_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (AlreadyExistsException, AlreadyExistsException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (InvalidObjectException, InvalidObjectException.thrift_spec), None, ), # 2
|
|
|
|
+ (3, TType.STRUCT, 'o3', (MetaException, MetaException.thrift_spec), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ self.o3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+ if 'o3' in d:
|
|
|
|
+ self.o3 = d['o3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = AlreadyExistsException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = InvalidObjectException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o3 = MetaException()
|
|
|
|
+ self.o3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_type_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o3 != None:
|
|
|
|
+ oprot.writeFieldBegin('o3', TType.STRUCT, 3)
|
|
|
|
+ self.o3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_type_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'type', None, None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.type = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'type' in d:
|
|
|
|
+ self.type = d['type']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.type = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_type_args')
|
|
|
|
+ if self.type != None:
|
|
|
|
+ oprot.writeFieldBegin('type', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.type)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_type_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_type_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 1)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_type_all_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'name', None, None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.name = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'name' in d:
|
|
|
|
+ self.name = d['name']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_type_all_args')
|
|
|
|
+ if self.name != None:
|
|
|
|
+ oprot.writeFieldBegin('name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_type_all_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.MAP, 'success', (TType.STRING,None,TType.STRUCT,(Type, Type.thrift_spec)), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.MAP:
|
|
|
|
+ self.success = {}
|
|
|
|
+ (_ktype93, _vtype94, _size92 ) = iprot.readMapBegin()
|
|
|
|
+ for _i96 in xrange(_size92):
|
|
|
|
+ _key97 = iprot.readString();
|
|
|
|
+ _val98 = Type()
|
|
|
|
+ _val98.read(iprot)
|
|
|
|
+ self.success[_key97] = _val98
|
|
|
|
+ iprot.readMapEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_type_all_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.MAP, 0)
|
|
|
|
+ oprot.writeMapBegin(TType.STRING, TType.STRUCT, len(self.success))
|
|
|
|
+ for kiter99,viter100 in self.success.items():
|
|
|
|
+ oprot.writeString(kiter99)
|
|
|
|
+ viter100.write(oprot)
|
|
|
|
+ oprot.writeMapEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 1)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_fields_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = None
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.table_name = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'table_name' in d:
|
|
|
|
+ self.table_name = d['table_name']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == -1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.table_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_fields_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, -1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.table_name != None:
|
|
|
|
+ oprot.writeFieldBegin('table_name', TType.STRING, -2)
|
|
|
|
+ oprot.writeString(self.table_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_fields_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = None
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.ouch1 = None
|
|
|
|
+ self.ouch2 = None
|
|
|
|
+ self.ouch3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'ouch1' in d:
|
|
|
|
+ self.ouch1 = d['ouch1']
|
|
|
|
+ if 'ouch2' in d:
|
|
|
|
+ self.ouch2 = d['ouch2']
|
|
|
|
+ if 'ouch3' in d:
|
|
|
|
+ self.ouch3 = d['ouch3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.success = []
|
|
|
|
+ (_etype104, _size101) = iprot.readListBegin()
|
|
|
|
+ for _i105 in xrange(_size101):
|
|
|
|
+ _elem106 = FieldSchema()
|
|
|
|
+ _elem106.read(iprot)
|
|
|
|
+ self.success.append(_elem106)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch1 = MetaException()
|
|
|
|
+ self.ouch1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -4:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch2 = UnknownTableException()
|
|
|
|
+ self.ouch2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -5:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch3 = UnknownDBException()
|
|
|
|
+ self.ouch3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_fields_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.LIST, 0)
|
|
|
|
+ oprot.writeListBegin(TType.STRUCT, len(self.success))
|
|
|
|
+ for iter107 in self.success:
|
|
|
|
+ iter107.write(oprot)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch1 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch1', TType.STRUCT, -3)
|
|
|
|
+ self.ouch1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch2 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch2', TType.STRUCT, -4)
|
|
|
|
+ self.ouch2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch3 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch3', TType.STRUCT, -5)
|
|
|
|
+ self.ouch3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_table_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'tbl', (Table, Table.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.tbl = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'tbl' in d:
|
|
|
|
+ self.tbl = d['tbl']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.tbl = Table()
|
|
|
|
+ self.tbl.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_table_args')
|
|
|
|
+ if self.tbl != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl', TType.STRUCT, 1)
|
|
|
|
+ self.tbl.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_table_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'ouch1', (AlreadyExistsException, AlreadyExistsException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'ouch2', (InvalidObjectException, InvalidObjectException.thrift_spec), None, ), # 2
|
|
|
|
+ (3, TType.STRUCT, 'ouch3', (MetaException, MetaException.thrift_spec), None, ), # 3
|
|
|
|
+ (4, TType.STRUCT, 'o4', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 4
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.ouch1 = None
|
|
|
|
+ self.ouch2 = None
|
|
|
|
+ self.ouch3 = None
|
|
|
|
+ self.o4 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'ouch1' in d:
|
|
|
|
+ self.ouch1 = d['ouch1']
|
|
|
|
+ if 'ouch2' in d:
|
|
|
|
+ self.ouch2 = d['ouch2']
|
|
|
|
+ if 'ouch3' in d:
|
|
|
|
+ self.ouch3 = d['ouch3']
|
|
|
|
+ if 'o4' in d:
|
|
|
|
+ self.o4 = d['o4']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch1 = AlreadyExistsException()
|
|
|
|
+ self.ouch1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch2 = InvalidObjectException()
|
|
|
|
+ self.ouch2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch3 = MetaException()
|
|
|
|
+ self.ouch3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 4:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o4 = NoSuchObjectException()
|
|
|
|
+ self.o4.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_table_result')
|
|
|
|
+ if self.ouch1 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch1', TType.STRUCT, 1)
|
|
|
|
+ self.ouch1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch2 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch2', TType.STRUCT, 2)
|
|
|
|
+ self.ouch2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch3 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch3', TType.STRUCT, 3)
|
|
|
|
+ self.ouch3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o4 != None:
|
|
|
|
+ oprot.writeFieldBegin('o4', TType.STRUCT, 4)
|
|
|
|
+ self.o4.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_table_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'dbname', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'name', None, None, ), # 2
|
|
|
|
+ (3, TType.BOOL, 'deleteData', None, None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.dbname = None
|
|
|
|
+ self.name = None
|
|
|
|
+ self.deleteData = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'dbname' in d:
|
|
|
|
+ self.dbname = d['dbname']
|
|
|
|
+ if 'name' in d:
|
|
|
|
+ self.name = d['name']
|
|
|
|
+ if 'deleteData' in d:
|
|
|
|
+ self.deleteData = d['deleteData']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.dbname = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.deleteData = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_table_args')
|
|
|
|
+ if self.dbname != None:
|
|
|
|
+ oprot.writeFieldBegin('dbname', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.dbname)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.name != None:
|
|
|
|
+ oprot.writeFieldBegin('name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.deleteData != None:
|
|
|
|
+ oprot.writeFieldBegin('deleteData', TType.BOOL, 3)
|
|
|
|
+ oprot.writeBool(self.deleteData)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_table_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'ouch3', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.ouch3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'ouch3' in d:
|
|
|
|
+ self.ouch3 = d['ouch3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = NoSuchObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch3 = MetaException()
|
|
|
|
+ self.ouch3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_table_result')
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch3 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch3', TType.STRUCT, 2)
|
|
|
|
+ self.ouch3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_tables_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = None
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.pattern = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'pattern' in d:
|
|
|
|
+ self.pattern = d['pattern']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == -1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.pattern = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_tables_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, -1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.pattern != None:
|
|
|
|
+ oprot.writeFieldBegin('pattern', TType.STRING, -2)
|
|
|
|
+ oprot.writeString(self.pattern)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_tables_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = None
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.ouch1 = None
|
|
|
|
+ self.ouch2 = None
|
|
|
|
+ self.ouch3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'ouch1' in d:
|
|
|
|
+ self.ouch1 = d['ouch1']
|
|
|
|
+ if 'ouch2' in d:
|
|
|
|
+ self.ouch2 = d['ouch2']
|
|
|
|
+ if 'ouch3' in d:
|
|
|
|
+ self.ouch3 = d['ouch3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.success = []
|
|
|
|
+ (_etype111, _size108) = iprot.readListBegin()
|
|
|
|
+ for _i112 in xrange(_size108):
|
|
|
|
+ _elem113 = iprot.readString();
|
|
|
|
+ self.success.append(_elem113)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch1 = MetaException()
|
|
|
|
+ self.ouch1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -4:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch2 = UnknownTableException()
|
|
|
|
+ self.ouch2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -5:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch3 = UnknownDBException()
|
|
|
|
+ self.ouch3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_tables_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.LIST, 0)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.success))
|
|
|
|
+ for iter114 in self.success:
|
|
|
|
+ oprot.writeString(iter114)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch1 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch1', TType.STRUCT, -3)
|
|
|
|
+ self.ouch1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch2 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch2', TType.STRUCT, -4)
|
|
|
|
+ self.ouch2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch3 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch3', TType.STRUCT, -5)
|
|
|
|
+ self.ouch3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_table_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'dbname', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.dbname = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'dbname' in d:
|
|
|
|
+ self.dbname = d['dbname']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.dbname = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_table_args')
|
|
|
|
+ if self.dbname != None:
|
|
|
|
+ oprot.writeFieldBegin('dbname', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.dbname)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_table_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.STRUCT, 'success', (Table, Table.thrift_spec), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.success = Table()
|
|
|
|
+ self.success.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = MetaException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = NoSuchObjectException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_table_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
|
+ self.success.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class set_table_parameters_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'dbname', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.MAP, 'params', (TType.STRING,None,TType.STRING,None), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.dbname = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.params = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'dbname' in d:
|
|
|
|
+ self.dbname = d['dbname']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'params' in d:
|
|
|
|
+ self.params = d['params']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.dbname = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.MAP:
|
|
|
|
+ self.params = {}
|
|
|
|
+ (_ktype116, _vtype117, _size115 ) = iprot.readMapBegin()
|
|
|
|
+ for _i119 in xrange(_size115):
|
|
|
|
+ _key120 = iprot.readString();
|
|
|
|
+ _val121 = iprot.readString();
|
|
|
|
+ self.params[_key120] = _val121
|
|
|
|
+ iprot.readMapEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('set_table_parameters_args')
|
|
|
|
+ if self.dbname != None:
|
|
|
|
+ oprot.writeFieldBegin('dbname', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.dbname)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.params != None:
|
|
|
|
+ oprot.writeFieldBegin('params', TType.MAP, 3)
|
|
|
|
+ oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.params))
|
|
|
|
+ for kiter122,viter123 in self.params.items():
|
|
|
|
+ oprot.writeString(kiter122)
|
|
|
|
+ oprot.writeString(viter123)
|
|
|
|
+ oprot.writeMapEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class set_table_parameters_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = NoSuchObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('set_table_parameters_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class alter_table_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'dbname', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.STRUCT, 'new_tbl', (Table, Table.thrift_spec), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.dbname = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.new_tbl = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'dbname' in d:
|
|
|
|
+ self.dbname = d['dbname']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'new_tbl' in d:
|
|
|
|
+ self.new_tbl = d['new_tbl']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.dbname = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.new_tbl = Table()
|
|
|
|
+ self.new_tbl.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('alter_table_args')
|
|
|
|
+ if self.dbname != None:
|
|
|
|
+ oprot.writeFieldBegin('dbname', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.dbname)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.new_tbl != None:
|
|
|
|
+ oprot.writeFieldBegin('new_tbl', TType.STRUCT, 3)
|
|
|
|
+ self.new_tbl.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class alter_table_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (InvalidOperationException, InvalidOperationException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = InvalidOperationException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('alter_table_result')
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class truncate_table_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'db_name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'table_name', None, None, ), # 2
|
|
|
|
+ (3, TType.STRING, 'partition', None, None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.table_name = None
|
|
|
|
+ self.partition = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'table_name' in d:
|
|
|
|
+ self.table_name = d['table_name']
|
|
|
|
+ if 'partition' in d:
|
|
|
|
+ self.partition = d['partition']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.table_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.partition = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('truncate_table_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.table_name != None:
|
|
|
|
+ oprot.writeFieldBegin('table_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.table_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.partition != None:
|
|
|
|
+ oprot.writeFieldBegin('partition', TType.STRING, 3)
|
|
|
|
+ oprot.writeString(self.partition)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class truncate_table_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'ouch1', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'ouch2', (UnknownTableException, UnknownTableException.thrift_spec), None, ), # 2
|
|
|
|
+ (3, TType.STRUCT, 'ouch3', (UnknownDBException, UnknownDBException.thrift_spec), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.ouch1 = None
|
|
|
|
+ self.ouch2 = None
|
|
|
|
+ self.ouch3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'ouch1' in d:
|
|
|
|
+ self.ouch1 = d['ouch1']
|
|
|
|
+ if 'ouch2' in d:
|
|
|
|
+ self.ouch2 = d['ouch2']
|
|
|
|
+ if 'ouch3' in d:
|
|
|
|
+ self.ouch3 = d['ouch3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch1 = MetaException()
|
|
|
|
+ self.ouch1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch2 = UnknownTableException()
|
|
|
|
+ self.ouch2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch3 = UnknownDBException()
|
|
|
|
+ self.ouch3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('truncate_table_result')
|
|
|
|
+ if self.ouch1 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch1', TType.STRUCT, 1)
|
|
|
|
+ self.ouch1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch2 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch2', TType.STRUCT, 2)
|
|
|
|
+ self.ouch2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch3 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch3', TType.STRUCT, 3)
|
|
|
|
+ self.ouch3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class cat_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = None
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.table_name = None
|
|
|
|
+ self.partition = None
|
|
|
|
+ self.high = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'table_name' in d:
|
|
|
|
+ self.table_name = d['table_name']
|
|
|
|
+ if 'partition' in d:
|
|
|
|
+ self.partition = d['partition']
|
|
|
|
+ if 'high' in d:
|
|
|
|
+ self.high = d['high']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.table_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.partition = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -1:
|
|
|
|
+ if ftype == TType.I32:
|
|
|
|
+ self.high = iprot.readI32();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('cat_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.table_name != None:
|
|
|
|
+ oprot.writeFieldBegin('table_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.table_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.partition != None:
|
|
|
|
+ oprot.writeFieldBegin('partition', TType.STRING, 3)
|
|
|
|
+ oprot.writeString(self.partition)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.high != None:
|
|
|
|
+ oprot.writeFieldBegin('high', TType.I32, -1)
|
|
|
|
+ oprot.writeI32(self.high)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class cat_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = None
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.ouch1 = None
|
|
|
|
+ self.ouch2 = None
|
|
|
|
+ self.ouch3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'ouch1' in d:
|
|
|
|
+ self.ouch1 = d['ouch1']
|
|
|
|
+ if 'ouch2' in d:
|
|
|
|
+ self.ouch2 = d['ouch2']
|
|
|
|
+ if 'ouch3' in d:
|
|
|
|
+ self.ouch3 = d['ouch3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.success = []
|
|
|
|
+ (_etype127, _size124) = iprot.readListBegin()
|
|
|
|
+ for _i128 in xrange(_size124):
|
|
|
|
+ _elem129 = iprot.readString();
|
|
|
|
+ self.success.append(_elem129)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch1 = MetaException()
|
|
|
|
+ self.ouch1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch2 = UnknownDBException()
|
|
|
|
+ self.ouch2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == -4:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.ouch3 = UnknownTableException()
|
|
|
|
+ self.ouch3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('cat_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.LIST, 0)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.success))
|
|
|
|
+ for iter130 in self.success:
|
|
|
|
+ oprot.writeString(iter130)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch1 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch1', TType.STRUCT, -2)
|
|
|
|
+ self.ouch1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch2 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch2', TType.STRUCT, -3)
|
|
|
|
+ self.ouch2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.ouch3 != None:
|
|
|
|
+ oprot.writeFieldBegin('ouch3', TType.STRUCT, -4)
|
|
|
|
+ self.ouch3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class add_partition_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'new_part', (Partition, Partition.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.new_part = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'new_part' in d:
|
|
|
|
+ self.new_part = d['new_part']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.new_part = Partition()
|
|
|
|
+ self.new_part.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('add_partition_args')
|
|
|
|
+ if self.new_part != None:
|
|
|
|
+ oprot.writeFieldBegin('new_part', TType.STRUCT, 1)
|
|
|
|
+ self.new_part.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class add_partition_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.STRUCT, 'success', (Partition, Partition.thrift_spec), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (InvalidObjectException, InvalidObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (AlreadyExistsException, AlreadyExistsException.thrift_spec), None, ), # 2
|
|
|
|
+ (3, TType.STRUCT, 'o3', (MetaException, MetaException.thrift_spec), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ self.o3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+ if 'o3' in d:
|
|
|
|
+ self.o3 = d['o3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.success = Partition()
|
|
|
|
+ self.success.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = InvalidObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = AlreadyExistsException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o3 = MetaException()
|
|
|
|
+ self.o3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('add_partition_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
|
+ self.success.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o3 != None:
|
|
|
|
+ oprot.writeFieldBegin('o3', TType.STRUCT, 3)
|
|
|
|
+ self.o3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class append_partition_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'db_name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.LIST, 'part_vals', (TType.STRING,None), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.part_vals = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'part_vals' in d:
|
|
|
|
+ self.part_vals = d['part_vals']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.part_vals = []
|
|
|
|
+ (_etype134, _size131) = iprot.readListBegin()
|
|
|
|
+ for _i135 in xrange(_size131):
|
|
|
|
+ _elem136 = iprot.readString();
|
|
|
|
+ self.part_vals.append(_elem136)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('append_partition_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.part_vals != None:
|
|
|
|
+ oprot.writeFieldBegin('part_vals', TType.LIST, 3)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.part_vals))
|
|
|
|
+ for iter137 in self.part_vals:
|
|
|
|
+ oprot.writeString(iter137)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class append_partition_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.STRUCT, 'success', (Partition, Partition.thrift_spec), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (InvalidObjectException, InvalidObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (AlreadyExistsException, AlreadyExistsException.thrift_spec), None, ), # 2
|
|
|
|
+ (3, TType.STRUCT, 'o3', (MetaException, MetaException.thrift_spec), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ self.o3 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+ if 'o3' in d:
|
|
|
|
+ self.o3 = d['o3']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.success = Partition()
|
|
|
|
+ self.success.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = InvalidObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = AlreadyExistsException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o3 = MetaException()
|
|
|
|
+ self.o3.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('append_partition_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
|
+ self.success.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o3 != None:
|
|
|
|
+ oprot.writeFieldBegin('o3', TType.STRUCT, 3)
|
|
|
|
+ self.o3.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_partition_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'db_name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.LIST, 'part_vals', (TType.STRING,None), None, ), # 3
|
|
|
|
+ (4, TType.BOOL, 'deleteData', None, None, ), # 4
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.part_vals = None
|
|
|
|
+ self.deleteData = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'part_vals' in d:
|
|
|
|
+ self.part_vals = d['part_vals']
|
|
|
|
+ if 'deleteData' in d:
|
|
|
|
+ self.deleteData = d['deleteData']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.part_vals = []
|
|
|
|
+ (_etype141, _size138) = iprot.readListBegin()
|
|
|
|
+ for _i142 in xrange(_size138):
|
|
|
|
+ _elem143 = iprot.readString();
|
|
|
|
+ self.part_vals.append(_elem143)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 4:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.deleteData = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_partition_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.part_vals != None:
|
|
|
|
+ oprot.writeFieldBegin('part_vals', TType.LIST, 3)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.part_vals))
|
|
|
|
+ for iter144 in self.part_vals:
|
|
|
|
+ oprot.writeString(iter144)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.deleteData != None:
|
|
|
|
+ oprot.writeFieldBegin('deleteData', TType.BOOL, 4)
|
|
|
|
+ oprot.writeBool(self.deleteData)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class drop_partition_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = NoSuchObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('drop_partition_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_partition_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'db_name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.LIST, 'part_vals', (TType.STRING,None), None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.part_vals = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'part_vals' in d:
|
|
|
|
+ self.part_vals = d['part_vals']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.part_vals = []
|
|
|
|
+ (_etype148, _size145) = iprot.readListBegin()
|
|
|
|
+ for _i149 in xrange(_size145):
|
|
|
|
+ _elem150 = iprot.readString();
|
|
|
|
+ self.part_vals.append(_elem150)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_partition_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.part_vals != None:
|
|
|
|
+ oprot.writeFieldBegin('part_vals', TType.LIST, 3)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.part_vals))
|
|
|
|
+ for iter151 in self.part_vals:
|
|
|
|
+ oprot.writeString(iter151)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_partition_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.STRUCT, 'success', (Partition, Partition.thrift_spec), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (MetaException, MetaException.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.success = Partition()
|
|
|
|
+ self.success.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = MetaException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_partition_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
|
|
|
|
+ self.success.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_partitions_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'db_name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.I16, 'max_parts', None, None, ), # 3
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.max_parts = -1
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'max_parts' in d:
|
|
|
|
+ self.max_parts = d['max_parts']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.I16:
|
|
|
|
+ self.max_parts = iprot.readI16();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_partitions_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.max_parts != None:
|
|
|
|
+ oprot.writeFieldBegin('max_parts', TType.I16, 3)
|
|
|
|
+ oprot.writeI16(self.max_parts)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class get_partitions_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.LIST, 'success', (TType.STRUCT,(Partition, Partition.thrift_spec)), None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.success = []
|
|
|
|
+ (_etype155, _size152) = iprot.readListBegin()
|
|
|
|
+ for _i156 in xrange(_size152):
|
|
|
|
+ _elem157 = Partition()
|
|
|
|
+ _elem157.read(iprot)
|
|
|
|
+ self.success.append(_elem157)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = NoSuchObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('get_partitions_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.LIST, 0)
|
|
|
|
+ oprot.writeListBegin(TType.STRUCT, len(self.success))
|
|
|
|
+ for iter158 in self.success:
|
|
|
|
+ iter158.write(oprot)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class set_partition_parameters_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRING, 'db_name', None, None, ), # 1
|
|
|
|
+ (2, TType.STRING, 'tbl_name', None, None, ), # 2
|
|
|
|
+ (3, TType.STRING, 'pname', None, None, ), # 3
|
|
|
|
+ (4, TType.MAP, 'params', (TType.STRING,None,TType.STRING,None), None, ), # 4
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.db_name = None
|
|
|
|
+ self.tbl_name = None
|
|
|
|
+ self.pname = None
|
|
|
|
+ self.params = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'db_name' in d:
|
|
|
|
+ self.db_name = d['db_name']
|
|
|
|
+ if 'tbl_name' in d:
|
|
|
|
+ self.tbl_name = d['tbl_name']
|
|
|
|
+ if 'pname' in d:
|
|
|
|
+ self.pname = d['pname']
|
|
|
|
+ if 'params' in d:
|
|
|
|
+ self.params = d['params']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.db_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.tbl_name = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 3:
|
|
|
|
+ if ftype == TType.STRING:
|
|
|
|
+ self.pname = iprot.readString();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 4:
|
|
|
|
+ if ftype == TType.MAP:
|
|
|
|
+ self.params = {}
|
|
|
|
+ (_ktype160, _vtype161, _size159 ) = iprot.readMapBegin()
|
|
|
|
+ for _i163 in xrange(_size159):
|
|
|
|
+ _key164 = iprot.readString();
|
|
|
|
+ _val165 = iprot.readString();
|
|
|
|
+ self.params[_key164] = _val165
|
|
|
|
+ iprot.readMapEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('set_partition_parameters_args')
|
|
|
|
+ if self.db_name != None:
|
|
|
|
+ oprot.writeFieldBegin('db_name', TType.STRING, 1)
|
|
|
|
+ oprot.writeString(self.db_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.tbl_name != None:
|
|
|
|
+ oprot.writeFieldBegin('tbl_name', TType.STRING, 2)
|
|
|
|
+ oprot.writeString(self.tbl_name)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.pname != None:
|
|
|
|
+ oprot.writeFieldBegin('pname', TType.STRING, 3)
|
|
|
|
+ oprot.writeString(self.pname)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.params != None:
|
|
|
|
+ oprot.writeFieldBegin('params', TType.MAP, 4)
|
|
|
|
+ oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.params))
|
|
|
|
+ for kiter166,viter167 in self.params.items():
|
|
|
|
+ oprot.writeString(kiter166)
|
|
|
|
+ oprot.writeString(viter167)
|
|
|
|
+ oprot.writeMapEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class set_partition_parameters_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = NoSuchObjectException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('set_partition_parameters_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class alter_partitions_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'sd', (StorageDescriptor, StorageDescriptor.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.LIST, 'parts', (TType.STRING,None), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.sd = None
|
|
|
|
+ self.parts = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'sd' in d:
|
|
|
|
+ self.sd = d['sd']
|
|
|
|
+ if 'parts' in d:
|
|
|
|
+ self.parts = d['parts']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.sd = StorageDescriptor()
|
|
|
|
+ self.sd.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.LIST:
|
|
|
|
+ self.parts = []
|
|
|
|
+ (_etype171, _size168) = iprot.readListBegin()
|
|
|
|
+ for _i172 in xrange(_size168):
|
|
|
|
+ _elem173 = iprot.readString();
|
|
|
|
+ self.parts.append(_elem173)
|
|
|
|
+ iprot.readListEnd()
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('alter_partitions_args')
|
|
|
|
+ if self.sd != None:
|
|
|
|
+ oprot.writeFieldBegin('sd', TType.STRUCT, 1)
|
|
|
|
+ self.sd.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.parts != None:
|
|
|
|
+ oprot.writeFieldBegin('parts', TType.LIST, 2)
|
|
|
|
+ oprot.writeListBegin(TType.STRING, len(self.parts))
|
|
|
|
+ for iter174 in self.parts:
|
|
|
|
+ oprot.writeString(iter174)
|
|
|
|
+ oprot.writeListEnd()
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class alter_partitions_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (InvalidOperationException, InvalidOperationException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = InvalidOperationException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('alter_partitions_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_index_args:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ None, # 0
|
|
|
|
+ (1, TType.STRUCT, 'index_def', (Index, Index.thrift_spec), None, ), # 1
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.index_def = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'index_def' in d:
|
|
|
|
+ self.index_def = d['index_def']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.index_def = Index()
|
|
|
|
+ self.index_def.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_index_args')
|
|
|
|
+ if self.index_def != None:
|
|
|
|
+ oprot.writeFieldBegin('index_def', TType.STRUCT, 1)
|
|
|
|
+ self.index_def.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+class create_index_result:
|
|
|
|
+
|
|
|
|
+ thrift_spec = (
|
|
|
|
+ (0, TType.BOOL, 'success', None, None, ), # 0
|
|
|
|
+ (1, TType.STRUCT, 'o1', (IndexAlreadyExistsException, IndexAlreadyExistsException.thrift_spec), None, ), # 1
|
|
|
|
+ (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2
|
|
|
|
+ )
|
|
|
|
+
|
|
|
|
+ def __init__(self, d=None):
|
|
|
|
+ self.success = None
|
|
|
|
+ self.o1 = None
|
|
|
|
+ self.o2 = None
|
|
|
|
+ if isinstance(d, dict):
|
|
|
|
+ if 'success' in d:
|
|
|
|
+ self.success = d['success']
|
|
|
|
+ if 'o1' in d:
|
|
|
|
+ self.o1 = d['o1']
|
|
|
|
+ if 'o2' in d:
|
|
|
|
+ self.o2 = d['o2']
|
|
|
|
+
|
|
|
|
+ def read(self, iprot):
|
|
|
|
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
|
|
|
|
+ return
|
|
|
|
+ iprot.readStructBegin()
|
|
|
|
+ while True:
|
|
|
|
+ (fname, ftype, fid) = iprot.readFieldBegin()
|
|
|
|
+ if ftype == TType.STOP:
|
|
|
|
+ break
|
|
|
|
+ if fid == 0:
|
|
|
|
+ if ftype == TType.BOOL:
|
|
|
|
+ self.success = iprot.readBool();
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 1:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o1 = IndexAlreadyExistsException()
|
|
|
|
+ self.o1.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ elif fid == 2:
|
|
|
|
+ if ftype == TType.STRUCT:
|
|
|
|
+ self.o2 = MetaException()
|
|
|
|
+ self.o2.read(iprot)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ else:
|
|
|
|
+ iprot.skip(ftype)
|
|
|
|
+ iprot.readFieldEnd()
|
|
|
|
+ iprot.readStructEnd()
|
|
|
|
+
|
|
|
|
+ def write(self, oprot):
|
|
|
|
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
|
|
|
|
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
|
|
|
|
+ return
|
|
|
|
+ oprot.writeStructBegin('create_index_result')
|
|
|
|
+ if self.success != None:
|
|
|
|
+ oprot.writeFieldBegin('success', TType.BOOL, 0)
|
|
|
|
+ oprot.writeBool(self.success)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o1 != None:
|
|
|
|
+ oprot.writeFieldBegin('o1', TType.STRUCT, 1)
|
|
|
|
+ self.o1.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ if self.o2 != None:
|
|
|
|
+ oprot.writeFieldBegin('o2', TType.STRUCT, 2)
|
|
|
|
+ self.o2.write(oprot)
|
|
|
|
+ oprot.writeFieldEnd()
|
|
|
|
+ oprot.writeFieldStop()
|
|
|
|
+ oprot.writeStructEnd()
|
|
|
|
+
|
|
|
|
+ def __str__(self):
|
|
|
|
+ return str(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __repr__(self):
|
|
|
|
+ return repr(self.__dict__)
|
|
|
|
+
|
|
|
|
+ def __eq__(self, other):
|
|
|
|
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
|
|
|
|
+
|
|
|
|
+ def __ne__(self, other):
|
|
|
|
+ return not (self == other)
|
|
|
|
+
|
|
|
|
+
|