Index: metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java (revision 1471261) +++ metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java (working copy) @@ -308,6 +308,28 @@ } /** + * Given a list of partition columns and a partial mapping from + * some partition columns to values the function returns the values + * for the column. + * @param partCols the list of table partition columns + * @param partSpec the partial mapping from partition column to values + * @return list of values of for given partition columns, any missing + * values in partSpec is replaced by an empty string + */ + public static List getPvals(List partCols, + Map partSpec) { + List pvals = new ArrayList(); + for (FieldSchema field : partCols) { + String val = partSpec.get(field.getName()); + if (val == null) { + val = ""; + } + pvals.add(val); + } + return pvals; + } + + /** * validateName * * Checks the name conforms to our standars which are: "[a-zA-z_0-9]+". checks @@ -1158,6 +1180,39 @@ return getPartitionValWithInvalidCharacter(partVals, partitionValidationPattern) == null; } + /** + * @param schema1: The first schema to be compared + * @param schema2: The second schema to be compared + * @return true if the two schemas are the same else false + * for comparing a field we ignore the comment it has + */ + public static boolean compareFieldColumns(List schema1, List schema2) { + if (schema1.size() != schema2.size()) { + return false; + } + for (int i = 0; i < schema1.size(); i++) { + FieldSchema f1 = schema1.get(i); + FieldSchema f2 = schema2.get(i); + // The default equals provided by thrift compares the comments too for + // equality, thus we need to compare the relevant fields here. + if (f1.getName() == null) { + if (f2.getName() != null) { + return false; + } + } else if (!f1.getName().equals(f2.getName())) { + return false; + } + if (f1.getType() == null) { + if (f2.getType() != null) { + return false; + } + } else if (!f1.getType().equals(f2.getType())) { + return false; + } + } + return true; + } + private static String getPartitionValWithInvalidCharacter(List partVals, Pattern partitionValidationPattern) { if (partitionValidationPattern == null) { Index: metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java (revision 1471261) +++ metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java (working copy) @@ -424,6 +424,22 @@ partName, envContext)); } + /** + * Exchange the partition between two tables + * @param partitionSpecs partitions specs of the parent partition to be exchanged + * @param destDb the db of the destination table + * @param destinationTableName the destination table name + @ @return new partition after exchanging + */ + @Override + public Partition exchange_partition(Map partitionSpecs, + String sourceDb, String sourceTable, String destDb, + String destinationTableName) throws MetaException, + NoSuchObjectException, InvalidObjectException, TException { + return client.exchange_partition(partitionSpecs, sourceDb, sourceTable, + destDb, destinationTableName); + } + public void validatePartitionNameCharacters(List partVals) throws TException, MetaException { client.partition_name_has_valid_characters(partVals, true); Index: metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java (revision 1471261) +++ metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java (working copy) @@ -1863,6 +1863,73 @@ return ret; } + @Override + public Partition exchange_partition(Map partitionSpecs, + String sourceDbName, String sourceTableName, String destDbName, + String destTableName) throws MetaException, NoSuchObjectException, + InvalidObjectException, InvalidInputException, TException { + boolean success = false; + boolean pathCreated = false; + RawStore ms = getMS(); + ms.openTransaction(); + Table destinationTable = ms.getTable(destDbName, destTableName); + Table sourceTable = ms.getTable(sourceDbName, sourceTableName); + List partVals = MetaStoreUtils.getPvals(sourceTable.getPartitionKeys(), + partitionSpecs); + List partValsPresent = new ArrayList (); + List partitionKeysPresent = new ArrayList (); + int i = 0; + for (FieldSchema fs: sourceTable.getPartitionKeys()) { + String partVal = partVals.get(i); + if (partVal != null && !partVal.equals("")) { + partValsPresent.add(partVal); + partitionKeysPresent.add(fs); + } + i++; + } + List partitionsToExchange = get_partitions_ps(sourceDbName, sourceTableName, + partVals, (short)-1); + boolean sameColumns = MetaStoreUtils.compareFieldColumns( + sourceTable.getSd().getCols(), destinationTable.getSd().getCols()); + boolean samePartitions = MetaStoreUtils.compareFieldColumns( + sourceTable.getPartitionKeys(), destinationTable.getPartitionKeys()); + if (!sameColumns || !samePartitions) { + throw new MetaException("The tables have different schemas." + + " Their partitions cannot be exchanged."); + } + Path sourcePath = new Path(sourceTable.getSd().getLocation(), + Warehouse.makePartName(partitionKeysPresent, partValsPresent)); + Path destPath = new Path(destinationTable.getSd().getLocation(), + Warehouse.makePartName(partitionKeysPresent, partValsPresent)); + try { + for (Partition partition: partitionsToExchange) { + Partition destPartition = new Partition(partition); + destPartition.setDbName(destDbName); + destPartition.setTableName(destinationTable.getTableName()); + Path destPartitionPath = new Path(destinationTable.getSd().getLocation(), + Warehouse.makePartName(destinationTable.getPartitionKeys(), partition.getValues())); + destPartition.getSd().setLocation(destPartitionPath.toString()); + ms.addPartition(destPartition); + ms.dropPartition(partition.getDbName(), sourceTable.getTableName(), + partition.getValues()); + } + /** + * TODO: Use the hard link feature of hdfs + * once https://issues.apache.org/jira/browse/HDFS-3370 is done + */ + pathCreated = wh.renameDir(sourcePath, destPath); + success = ms.commitTransaction(); + } finally { + if (!success) { + ms.rollbackTransaction(); + if (pathCreated) { + wh.renameDir(destPath, sourcePath); + } + } + } + return new Partition(); + } + private boolean drop_partition_common(RawStore ms, String db_name, String tbl_name, List part_vals, final boolean deleteData, final EnvironmentContext envContext) throws MetaException, NoSuchObjectException, IOException, InvalidObjectException, Index: metastore/src/java/org/apache/hadoop/hive/metastore/Warehouse.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/Warehouse.java (revision 1471261) +++ metastore/src/java/org/apache/hadoop/hive/metastore/Warehouse.java (working copy) @@ -204,6 +204,18 @@ return false; } + public boolean renameDir(Path sourcePath, Path destPath) throws MetaException { + FileSystem fs = null; + try { + fs = getFs(sourcePath); + fs.rename(sourcePath, destPath); + return true; + } catch (Exception ex) { + MetaStoreUtils.logAndThrowMetaException(ex); + } + return false; + } + public boolean deleteDir(Path f, boolean recursive) throws MetaException { FileSystem fs = getFs(f); return fsHandler.deleteDir(fs, f, recursive, conf); Index: metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java (revision 1471261) +++ metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java (working copy) @@ -347,6 +347,17 @@ List partVals) throws NoSuchObjectException, MetaException, TException; /** + * @param partition + * @param destdb + * @param destTableName + * @return partition object + */ + public Partition exchange_partition(Map partitionSpecs, + String sourceDb, String sourceTable, String destdb, + String destTableName) throws MetaException, NoSuchObjectException, + InvalidObjectException, TException; + + /** * @param dbName * @param tblName * @param name - partition name i.e. 'ds=2010-02-03/ts=2010-02-03 18%3A16%3A01' Index: metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py =================================================================== --- metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py (revision 1471261) +++ metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py (working copy) @@ -311,6 +311,17 @@ """ pass + def exchange_partition(self, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name): + """ + Parameters: + - partitionSpecs + - source_db + - source_table_name + - dest_db + - dest_table_name + """ + pass + def get_partition_with_auth(self, db_name, tbl_name, part_vals, user_name, group_names): """ Parameters: @@ -2011,6 +2022,52 @@ raise result.o2 raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partition failed: unknown result"); + def exchange_partition(self, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name): + """ + Parameters: + - partitionSpecs + - source_db + - source_table_name + - dest_db + - dest_table_name + """ + self.send_exchange_partition(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name) + return self.recv_exchange_partition() + + def send_exchange_partition(self, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name): + self._oprot.writeMessageBegin('exchange_partition', TMessageType.CALL, self._seqid) + args = exchange_partition_args() + args.partitionSpecs = partitionSpecs + args.source_db = source_db + args.source_table_name = source_table_name + args.dest_db = dest_db + args.dest_table_name = dest_table_name + args.write(self._oprot) + self._oprot.writeMessageEnd() + self._oprot.trans.flush() + + def recv_exchange_partition(self, ): + (fname, mtype, rseqid) = self._iprot.readMessageBegin() + if mtype == TMessageType.EXCEPTION: + x = TApplicationException() + x.read(self._iprot) + self._iprot.readMessageEnd() + raise x + result = exchange_partition_result() + result.read(self._iprot) + self._iprot.readMessageEnd() + if result.success is not None: + return result.success + if result.o1 is not None: + raise result.o1 + if result.o2 is not None: + raise result.o2 + if result.o3 is not None: + raise result.o3 + if result.o4 is not None: + raise result.o4 + raise TApplicationException(TApplicationException.MISSING_RESULT, "exchange_partition failed: unknown result"); + def get_partition_with_auth(self, db_name, tbl_name, part_vals, user_name, group_names): """ Parameters: @@ -3767,6 +3824,7 @@ self._processMap["drop_partition_by_name"] = Processor.process_drop_partition_by_name self._processMap["drop_partition_by_name_with_environment_context"] = Processor.process_drop_partition_by_name_with_environment_context self._processMap["get_partition"] = Processor.process_get_partition + self._processMap["exchange_partition"] = Processor.process_exchange_partition self._processMap["get_partition_with_auth"] = Processor.process_get_partition_with_auth self._processMap["get_partition_by_name"] = Processor.process_get_partition_by_name self._processMap["get_partitions"] = Processor.process_get_partitions @@ -4415,6 +4473,26 @@ oprot.writeMessageEnd() oprot.trans.flush() + def process_exchange_partition(self, seqid, iprot, oprot): + args = exchange_partition_args() + args.read(iprot) + iprot.readMessageEnd() + result = exchange_partition_result() + try: + result.success = self._handler.exchange_partition(args.partitionSpecs, args.source_db, args.source_table_name, args.dest_db, args.dest_table_name) + except MetaException as o1: + result.o1 = o1 + except NoSuchObjectException as o2: + result.o2 = o2 + except InvalidObjectException as o3: + result.o3 = o3 + except InvalidInputException as o4: + result.o4 = o4 + oprot.writeMessageBegin("exchange_partition", TMessageType.REPLY, seqid) + result.write(oprot) + oprot.writeMessageEnd() + oprot.trans.flush() + def process_get_partition_with_auth(self, seqid, iprot, oprot): args = get_partition_with_auth_args() args.read(iprot) @@ -11021,6 +11099,236 @@ def __ne__(self, other): return not (self == other) +class exchange_partition_args: + """ + Attributes: + - partitionSpecs + - source_db + - source_table_name + - dest_db + - dest_table_name + """ + + thrift_spec = ( + None, # 0 + (1, TType.MAP, 'partitionSpecs', (TType.STRING,None,TType.STRING,None), None, ), # 1 + (2, TType.STRING, 'source_db', None, None, ), # 2 + (3, TType.STRING, 'source_table_name', None, None, ), # 3 + (4, TType.STRING, 'dest_db', None, None, ), # 4 + (5, TType.STRING, 'dest_table_name', None, None, ), # 5 + ) + + def __init__(self, partitionSpecs=None, source_db=None, source_table_name=None, dest_db=None, dest_table_name=None,): + self.partitionSpecs = partitionSpecs + self.source_db = source_db + self.source_table_name = source_table_name + self.dest_db = dest_db + self.dest_table_name = dest_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.MAP: + self.partitionSpecs = {} + (_ktype342, _vtype343, _size341 ) = iprot.readMapBegin() + for _i345 in xrange(_size341): + _key346 = iprot.readString(); + _val347 = iprot.readString(); + self.partitionSpecs[_key346] = _val347 + iprot.readMapEnd() + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRING: + self.source_db = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.STRING: + self.source_table_name = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 4: + if ftype == TType.STRING: + self.dest_db = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 5: + if ftype == TType.STRING: + self.dest_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('exchange_partition_args') + if self.partitionSpecs is not None: + oprot.writeFieldBegin('partitionSpecs', TType.MAP, 1) + oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.partitionSpecs)) + for kiter348,viter349 in self.partitionSpecs.items(): + oprot.writeString(kiter348) + oprot.writeString(viter349) + oprot.writeMapEnd() + oprot.writeFieldEnd() + if self.source_db is not None: + oprot.writeFieldBegin('source_db', TType.STRING, 2) + oprot.writeString(self.source_db) + oprot.writeFieldEnd() + if self.source_table_name is not None: + oprot.writeFieldBegin('source_table_name', TType.STRING, 3) + oprot.writeString(self.source_table_name) + oprot.writeFieldEnd() + if self.dest_db is not None: + oprot.writeFieldBegin('dest_db', TType.STRING, 4) + oprot.writeString(self.dest_db) + oprot.writeFieldEnd() + if self.dest_table_name is not None: + oprot.writeFieldBegin('dest_table_name', TType.STRING, 5) + oprot.writeString(self.dest_table_name) + oprot.writeFieldEnd() + oprot.writeFieldStop() + oprot.writeStructEnd() + + def validate(self): + return + + + def __repr__(self): + L = ['%s=%r' % (key, value) + for key, value in self.__dict__.iteritems()] + return '%s(%s)' % (self.__class__.__name__, ', '.join(L)) + + def __eq__(self, other): + return isinstance(other, self.__class__) and self.__dict__ == other.__dict__ + + def __ne__(self, other): + return not (self == other) + +class exchange_partition_result: + """ + Attributes: + - success + - o1 + - o2 + - o3 + - o4 + """ + + thrift_spec = ( + (0, TType.STRUCT, 'success', (Partition, Partition.thrift_spec), None, ), # 0 + (1, TType.STRUCT, 'o1', (MetaException, MetaException.thrift_spec), None, ), # 1 + (2, TType.STRUCT, 'o2', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 2 + (3, TType.STRUCT, 'o3', (InvalidObjectException, InvalidObjectException.thrift_spec), None, ), # 3 + (4, TType.STRUCT, 'o4', (InvalidInputException, InvalidInputException.thrift_spec), None, ), # 4 + ) + + def __init__(self, success=None, o1=None, o2=None, o3=None, o4=None,): + self.success = success + self.o1 = o1 + self.o2 = o2 + self.o3 = o3 + self.o4 = 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 == 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) + elif fid == 2: + if ftype == TType.STRUCT: + self.o2 = NoSuchObjectException() + self.o2.read(iprot) + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.STRUCT: + self.o3 = InvalidObjectException() + self.o3.read(iprot) + else: + iprot.skip(ftype) + elif fid == 4: + if ftype == TType.STRUCT: + self.o4 = InvalidInputException() + 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('exchange_partition_result') + if self.success is not None: + oprot.writeFieldBegin('success', TType.STRUCT, 0) + self.success.write(oprot) + oprot.writeFieldEnd() + if self.o1 is not None: + oprot.writeFieldBegin('o1', TType.STRUCT, 1) + self.o1.write(oprot) + oprot.writeFieldEnd() + if self.o2 is not None: + oprot.writeFieldBegin('o2', TType.STRUCT, 2) + self.o2.write(oprot) + oprot.writeFieldEnd() + if self.o3 is not None: + oprot.writeFieldBegin('o3', TType.STRUCT, 3) + self.o3.write(oprot) + oprot.writeFieldEnd() + if self.o4 is not None: + oprot.writeFieldBegin('o4', TType.STRUCT, 4) + self.o4.write(oprot) + oprot.writeFieldEnd() + oprot.writeFieldStop() + oprot.writeStructEnd() + + def validate(self): + return + + + def __repr__(self): + L = ['%s=%r' % (key, value) + for key, value in self.__dict__.iteritems()] + return '%s(%s)' % (self.__class__.__name__, ', '.join(L)) + + 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_with_auth_args: """ Attributes: @@ -11069,10 +11377,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype344, _size341) = iprot.readListBegin() - for _i345 in xrange(_size341): - _elem346 = iprot.readString(); - self.part_vals.append(_elem346) + (_etype353, _size350) = iprot.readListBegin() + for _i354 in xrange(_size350): + _elem355 = iprot.readString(); + self.part_vals.append(_elem355) iprot.readListEnd() else: iprot.skip(ftype) @@ -11084,10 +11392,10 @@ elif fid == 5: if ftype == TType.LIST: self.group_names = [] - (_etype350, _size347) = iprot.readListBegin() - for _i351 in xrange(_size347): - _elem352 = iprot.readString(); - self.group_names.append(_elem352) + (_etype359, _size356) = iprot.readListBegin() + for _i360 in xrange(_size356): + _elem361 = iprot.readString(); + self.group_names.append(_elem361) iprot.readListEnd() else: iprot.skip(ftype) @@ -11112,8 +11420,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter353 in self.part_vals: - oprot.writeString(iter353) + for iter362 in self.part_vals: + oprot.writeString(iter362) oprot.writeListEnd() oprot.writeFieldEnd() if self.user_name is not None: @@ -11123,8 +11431,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 5) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter354 in self.group_names: - oprot.writeString(iter354) + for iter363 in self.group_names: + oprot.writeString(iter363) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11516,11 +11824,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype358, _size355) = iprot.readListBegin() - for _i359 in xrange(_size355): - _elem360 = Partition() - _elem360.read(iprot) - self.success.append(_elem360) + (_etype367, _size364) = iprot.readListBegin() + for _i368 in xrange(_size364): + _elem369 = Partition() + _elem369.read(iprot) + self.success.append(_elem369) iprot.readListEnd() else: iprot.skip(ftype) @@ -11549,8 +11857,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter361 in self.success: - iter361.write(oprot) + for iter370 in self.success: + iter370.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -11637,10 +11945,10 @@ elif fid == 5: if ftype == TType.LIST: self.group_names = [] - (_etype365, _size362) = iprot.readListBegin() - for _i366 in xrange(_size362): - _elem367 = iprot.readString(); - self.group_names.append(_elem367) + (_etype374, _size371) = iprot.readListBegin() + for _i375 in xrange(_size371): + _elem376 = iprot.readString(); + self.group_names.append(_elem376) iprot.readListEnd() else: iprot.skip(ftype) @@ -11673,8 +11981,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 5) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter368 in self.group_names: - oprot.writeString(iter368) + for iter377 in self.group_names: + oprot.writeString(iter377) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11726,11 +12034,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype372, _size369) = iprot.readListBegin() - for _i373 in xrange(_size369): - _elem374 = Partition() - _elem374.read(iprot) - self.success.append(_elem374) + (_etype381, _size378) = iprot.readListBegin() + for _i382 in xrange(_size378): + _elem383 = Partition() + _elem383.read(iprot) + self.success.append(_elem383) iprot.readListEnd() else: iprot.skip(ftype) @@ -11759,8 +12067,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter375 in self.success: - iter375.write(oprot) + for iter384 in self.success: + iter384.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -11901,10 +12209,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype379, _size376) = iprot.readListBegin() - for _i380 in xrange(_size376): - _elem381 = iprot.readString(); - self.success.append(_elem381) + (_etype388, _size385) = iprot.readListBegin() + for _i389 in xrange(_size385): + _elem390 = iprot.readString(); + self.success.append(_elem390) iprot.readListEnd() else: iprot.skip(ftype) @@ -11927,8 +12235,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter382 in self.success: - oprot.writeString(iter382) + for iter391 in self.success: + oprot.writeString(iter391) oprot.writeListEnd() oprot.writeFieldEnd() if self.o2 is not None: @@ -11998,10 +12306,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype386, _size383) = iprot.readListBegin() - for _i387 in xrange(_size383): - _elem388 = iprot.readString(); - self.part_vals.append(_elem388) + (_etype395, _size392) = iprot.readListBegin() + for _i396 in xrange(_size392): + _elem397 = iprot.readString(); + self.part_vals.append(_elem397) iprot.readListEnd() else: iprot.skip(ftype) @@ -12031,8 +12339,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter389 in self.part_vals: - oprot.writeString(iter389) + for iter398 in self.part_vals: + oprot.writeString(iter398) oprot.writeListEnd() oprot.writeFieldEnd() if self.max_parts is not None: @@ -12088,11 +12396,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype393, _size390) = iprot.readListBegin() - for _i394 in xrange(_size390): - _elem395 = Partition() - _elem395.read(iprot) - self.success.append(_elem395) + (_etype402, _size399) = iprot.readListBegin() + for _i403 in xrange(_size399): + _elem404 = Partition() + _elem404.read(iprot) + self.success.append(_elem404) iprot.readListEnd() else: iprot.skip(ftype) @@ -12121,8 +12429,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter396 in self.success: - iter396.write(oprot) + for iter405 in self.success: + iter405.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -12202,10 +12510,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype400, _size397) = iprot.readListBegin() - for _i401 in xrange(_size397): - _elem402 = iprot.readString(); - self.part_vals.append(_elem402) + (_etype409, _size406) = iprot.readListBegin() + for _i410 in xrange(_size406): + _elem411 = iprot.readString(); + self.part_vals.append(_elem411) iprot.readListEnd() else: iprot.skip(ftype) @@ -12222,10 +12530,10 @@ elif fid == 6: if ftype == TType.LIST: self.group_names = [] - (_etype406, _size403) = iprot.readListBegin() - for _i407 in xrange(_size403): - _elem408 = iprot.readString(); - self.group_names.append(_elem408) + (_etype415, _size412) = iprot.readListBegin() + for _i416 in xrange(_size412): + _elem417 = iprot.readString(); + self.group_names.append(_elem417) iprot.readListEnd() else: iprot.skip(ftype) @@ -12250,8 +12558,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter409 in self.part_vals: - oprot.writeString(iter409) + for iter418 in self.part_vals: + oprot.writeString(iter418) oprot.writeListEnd() oprot.writeFieldEnd() if self.max_parts is not None: @@ -12265,8 +12573,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 6) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter410 in self.group_names: - oprot.writeString(iter410) + for iter419 in self.group_names: + oprot.writeString(iter419) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -12318,11 +12626,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype414, _size411) = iprot.readListBegin() - for _i415 in xrange(_size411): - _elem416 = Partition() - _elem416.read(iprot) - self.success.append(_elem416) + (_etype423, _size420) = iprot.readListBegin() + for _i424 in xrange(_size420): + _elem425 = Partition() + _elem425.read(iprot) + self.success.append(_elem425) iprot.readListEnd() else: iprot.skip(ftype) @@ -12351,8 +12659,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter417 in self.success: - iter417.write(oprot) + for iter426 in self.success: + iter426.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -12426,10 +12734,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype421, _size418) = iprot.readListBegin() - for _i422 in xrange(_size418): - _elem423 = iprot.readString(); - self.part_vals.append(_elem423) + (_etype430, _size427) = iprot.readListBegin() + for _i431 in xrange(_size427): + _elem432 = iprot.readString(); + self.part_vals.append(_elem432) iprot.readListEnd() else: iprot.skip(ftype) @@ -12459,8 +12767,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter424 in self.part_vals: - oprot.writeString(iter424) + for iter433 in self.part_vals: + oprot.writeString(iter433) oprot.writeListEnd() oprot.writeFieldEnd() if self.max_parts is not None: @@ -12516,10 +12824,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype428, _size425) = iprot.readListBegin() - for _i429 in xrange(_size425): - _elem430 = iprot.readString(); - self.success.append(_elem430) + (_etype437, _size434) = iprot.readListBegin() + for _i438 in xrange(_size434): + _elem439 = iprot.readString(); + self.success.append(_elem439) iprot.readListEnd() else: iprot.skip(ftype) @@ -12548,8 +12856,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter431 in self.success: - oprot.writeString(iter431) + for iter440 in self.success: + oprot.writeString(iter440) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -12705,11 +13013,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype435, _size432) = iprot.readListBegin() - for _i436 in xrange(_size432): - _elem437 = Partition() - _elem437.read(iprot) - self.success.append(_elem437) + (_etype444, _size441) = iprot.readListBegin() + for _i445 in xrange(_size441): + _elem446 = Partition() + _elem446.read(iprot) + self.success.append(_elem446) iprot.readListEnd() else: iprot.skip(ftype) @@ -12738,8 +13046,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter438 in self.success: - iter438.write(oprot) + for iter447 in self.success: + iter447.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -12810,10 +13118,10 @@ elif fid == 3: if ftype == TType.LIST: self.names = [] - (_etype442, _size439) = iprot.readListBegin() - for _i443 in xrange(_size439): - _elem444 = iprot.readString(); - self.names.append(_elem444) + (_etype451, _size448) = iprot.readListBegin() + for _i452 in xrange(_size448): + _elem453 = iprot.readString(); + self.names.append(_elem453) iprot.readListEnd() else: iprot.skip(ftype) @@ -12838,8 +13146,8 @@ if self.names is not None: oprot.writeFieldBegin('names', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.names)) - for iter445 in self.names: - oprot.writeString(iter445) + for iter454 in self.names: + oprot.writeString(iter454) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -12891,11 +13199,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype449, _size446) = iprot.readListBegin() - for _i450 in xrange(_size446): - _elem451 = Partition() - _elem451.read(iprot) - self.success.append(_elem451) + (_etype458, _size455) = iprot.readListBegin() + for _i459 in xrange(_size455): + _elem460 = Partition() + _elem460.read(iprot) + self.success.append(_elem460) iprot.readListEnd() else: iprot.skip(ftype) @@ -12924,8 +13232,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter452 in self.success: - iter452.write(oprot) + for iter461 in self.success: + iter461.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -13155,11 +13463,11 @@ elif fid == 3: if ftype == TType.LIST: self.new_parts = [] - (_etype456, _size453) = iprot.readListBegin() - for _i457 in xrange(_size453): - _elem458 = Partition() - _elem458.read(iprot) - self.new_parts.append(_elem458) + (_etype465, _size462) = iprot.readListBegin() + for _i466 in xrange(_size462): + _elem467 = Partition() + _elem467.read(iprot) + self.new_parts.append(_elem467) iprot.readListEnd() else: iprot.skip(ftype) @@ -13184,8 +13492,8 @@ if self.new_parts is not None: oprot.writeFieldBegin('new_parts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.new_parts)) - for iter459 in self.new_parts: - iter459.write(oprot) + for iter468 in self.new_parts: + iter468.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13497,10 +13805,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype463, _size460) = iprot.readListBegin() - for _i464 in xrange(_size460): - _elem465 = iprot.readString(); - self.part_vals.append(_elem465) + (_etype472, _size469) = iprot.readListBegin() + for _i473 in xrange(_size469): + _elem474 = iprot.readString(); + self.part_vals.append(_elem474) iprot.readListEnd() else: iprot.skip(ftype) @@ -13531,8 +13839,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter466 in self.part_vals: - oprot.writeString(iter466) + for iter475 in self.part_vals: + oprot.writeString(iter475) oprot.writeListEnd() oprot.writeFieldEnd() if self.new_part is not None: @@ -13660,10 +13968,10 @@ if fid == 1: if ftype == TType.LIST: self.part_vals = [] - (_etype470, _size467) = iprot.readListBegin() - for _i471 in xrange(_size467): - _elem472 = iprot.readString(); - self.part_vals.append(_elem472) + (_etype479, _size476) = iprot.readListBegin() + for _i480 in xrange(_size476): + _elem481 = iprot.readString(); + self.part_vals.append(_elem481) iprot.readListEnd() else: iprot.skip(ftype) @@ -13685,8 +13993,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 1) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter473 in self.part_vals: - oprot.writeString(iter473) + for iter482 in self.part_vals: + oprot.writeString(iter482) oprot.writeListEnd() oprot.writeFieldEnd() if self.throw_exception is not None: @@ -14015,10 +14323,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype477, _size474) = iprot.readListBegin() - for _i478 in xrange(_size474): - _elem479 = iprot.readString(); - self.success.append(_elem479) + (_etype486, _size483) = iprot.readListBegin() + for _i487 in xrange(_size483): + _elem488 = iprot.readString(); + self.success.append(_elem488) iprot.readListEnd() else: iprot.skip(ftype) @@ -14041,8 +14349,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter480 in self.success: - oprot.writeString(iter480) + for iter489 in self.success: + oprot.writeString(iter489) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -14155,11 +14463,11 @@ if fid == 0: if ftype == TType.MAP: self.success = {} - (_ktype482, _vtype483, _size481 ) = iprot.readMapBegin() - for _i485 in xrange(_size481): - _key486 = iprot.readString(); - _val487 = iprot.readString(); - self.success[_key486] = _val487 + (_ktype491, _vtype492, _size490 ) = iprot.readMapBegin() + for _i494 in xrange(_size490): + _key495 = iprot.readString(); + _val496 = iprot.readString(); + self.success[_key495] = _val496 iprot.readMapEnd() else: iprot.skip(ftype) @@ -14182,9 +14490,9 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.MAP, 0) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.success)) - for kiter488,viter489 in self.success.items(): - oprot.writeString(kiter488) - oprot.writeString(viter489) + for kiter497,viter498 in self.success.items(): + oprot.writeString(kiter497) + oprot.writeString(viter498) oprot.writeMapEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -14254,11 +14562,11 @@ elif fid == 3: if ftype == TType.MAP: self.part_vals = {} - (_ktype491, _vtype492, _size490 ) = iprot.readMapBegin() - for _i494 in xrange(_size490): - _key495 = iprot.readString(); - _val496 = iprot.readString(); - self.part_vals[_key495] = _val496 + (_ktype500, _vtype501, _size499 ) = iprot.readMapBegin() + for _i503 in xrange(_size499): + _key504 = iprot.readString(); + _val505 = iprot.readString(); + self.part_vals[_key504] = _val505 iprot.readMapEnd() else: iprot.skip(ftype) @@ -14288,9 +14596,9 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.MAP, 3) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.part_vals)) - for kiter497,viter498 in self.part_vals.items(): - oprot.writeString(kiter497) - oprot.writeString(viter498) + for kiter506,viter507 in self.part_vals.items(): + oprot.writeString(kiter506) + oprot.writeString(viter507) oprot.writeMapEnd() oprot.writeFieldEnd() if self.eventType is not None: @@ -14486,11 +14794,11 @@ elif fid == 3: if ftype == TType.MAP: self.part_vals = {} - (_ktype500, _vtype501, _size499 ) = iprot.readMapBegin() - for _i503 in xrange(_size499): - _key504 = iprot.readString(); - _val505 = iprot.readString(); - self.part_vals[_key504] = _val505 + (_ktype509, _vtype510, _size508 ) = iprot.readMapBegin() + for _i512 in xrange(_size508): + _key513 = iprot.readString(); + _val514 = iprot.readString(); + self.part_vals[_key513] = _val514 iprot.readMapEnd() else: iprot.skip(ftype) @@ -14520,9 +14828,9 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.MAP, 3) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.part_vals)) - for kiter506,viter507 in self.part_vals.items(): - oprot.writeString(kiter506) - oprot.writeString(viter507) + for kiter515,viter516 in self.part_vals.items(): + oprot.writeString(kiter515) + oprot.writeString(viter516) oprot.writeMapEnd() oprot.writeFieldEnd() if self.eventType is not None: @@ -15494,11 +15802,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype511, _size508) = iprot.readListBegin() - for _i512 in xrange(_size508): - _elem513 = Index() - _elem513.read(iprot) - self.success.append(_elem513) + (_etype520, _size517) = iprot.readListBegin() + for _i521 in xrange(_size517): + _elem522 = Index() + _elem522.read(iprot) + self.success.append(_elem522) iprot.readListEnd() else: iprot.skip(ftype) @@ -15527,8 +15835,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter514 in self.success: - iter514.write(oprot) + for iter523 in self.success: + iter523.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -15669,10 +15977,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype518, _size515) = iprot.readListBegin() - for _i519 in xrange(_size515): - _elem520 = iprot.readString(); - self.success.append(_elem520) + (_etype527, _size524) = iprot.readListBegin() + for _i528 in xrange(_size524): + _elem529 = iprot.readString(); + self.success.append(_elem529) iprot.readListEnd() else: iprot.skip(ftype) @@ -15695,8 +16003,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter521 in self.success: - oprot.writeString(iter521) + for iter530 in self.success: + oprot.writeString(iter530) oprot.writeListEnd() oprot.writeFieldEnd() if self.o2 is not None: @@ -17206,10 +17514,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype525, _size522) = iprot.readListBegin() - for _i526 in xrange(_size522): - _elem527 = iprot.readString(); - self.success.append(_elem527) + (_etype534, _size531) = iprot.readListBegin() + for _i535 in xrange(_size531): + _elem536 = iprot.readString(); + self.success.append(_elem536) iprot.readListEnd() else: iprot.skip(ftype) @@ -17232,8 +17540,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter528 in self.success: - oprot.writeString(iter528) + for iter537 in self.success: + oprot.writeString(iter537) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -17706,11 +18014,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype532, _size529) = iprot.readListBegin() - for _i533 in xrange(_size529): - _elem534 = Role() - _elem534.read(iprot) - self.success.append(_elem534) + (_etype541, _size538) = iprot.readListBegin() + for _i542 in xrange(_size538): + _elem543 = Role() + _elem543.read(iprot) + self.success.append(_elem543) iprot.readListEnd() else: iprot.skip(ftype) @@ -17733,8 +18041,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter535 in self.success: - iter535.write(oprot) + for iter544 in self.success: + iter544.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -17802,10 +18110,10 @@ elif fid == 3: if ftype == TType.LIST: self.group_names = [] - (_etype539, _size536) = iprot.readListBegin() - for _i540 in xrange(_size536): - _elem541 = iprot.readString(); - self.group_names.append(_elem541) + (_etype548, _size545) = iprot.readListBegin() + for _i549 in xrange(_size545): + _elem550 = iprot.readString(); + self.group_names.append(_elem550) iprot.readListEnd() else: iprot.skip(ftype) @@ -17830,8 +18138,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter542 in self.group_names: - oprot.writeString(iter542) + for iter551 in self.group_names: + oprot.writeString(iter551) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -18038,11 +18346,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype546, _size543) = iprot.readListBegin() - for _i547 in xrange(_size543): - _elem548 = HiveObjectPrivilege() - _elem548.read(iprot) - self.success.append(_elem548) + (_etype555, _size552) = iprot.readListBegin() + for _i556 in xrange(_size552): + _elem557 = HiveObjectPrivilege() + _elem557.read(iprot) + self.success.append(_elem557) iprot.readListEnd() else: iprot.skip(ftype) @@ -18065,8 +18373,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter549 in self.success: - iter549.write(oprot) + for iter558 in self.success: + iter558.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -18391,10 +18699,10 @@ elif fid == 2: if ftype == TType.LIST: self.group_names = [] - (_etype553, _size550) = iprot.readListBegin() - for _i554 in xrange(_size550): - _elem555 = iprot.readString(); - self.group_names.append(_elem555) + (_etype562, _size559) = iprot.readListBegin() + for _i563 in xrange(_size559): + _elem564 = iprot.readString(); + self.group_names.append(_elem564) iprot.readListEnd() else: iprot.skip(ftype) @@ -18415,8 +18723,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter556 in self.group_names: - oprot.writeString(iter556) + for iter565 in self.group_names: + oprot.writeString(iter565) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -18465,10 +18773,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype560, _size557) = iprot.readListBegin() - for _i561 in xrange(_size557): - _elem562 = iprot.readString(); - self.success.append(_elem562) + (_etype569, _size566) = iprot.readListBegin() + for _i570 in xrange(_size566): + _elem571 = iprot.readString(); + self.success.append(_elem571) iprot.readListEnd() else: iprot.skip(ftype) @@ -18491,8 +18799,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter563 in self.success: - oprot.writeString(iter563) + for iter572 in self.success: + oprot.writeString(iter572) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: Index: metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote =================================================================== --- metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote (revision 1471261) +++ metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote (working copy) @@ -58,6 +58,7 @@ print ' bool drop_partition_by_name(string db_name, string tbl_name, string part_name, bool deleteData)' print ' bool drop_partition_by_name_with_environment_context(string db_name, string tbl_name, string part_name, bool deleteData, EnvironmentContext environment_context)' print ' Partition get_partition(string db_name, string tbl_name, part_vals)' + print ' Partition exchange_partition( partitionSpecs, string source_db, string source_table_name, string dest_db, string dest_table_name)' print ' Partition get_partition_with_auth(string db_name, string tbl_name, part_vals, string user_name, group_names)' print ' Partition get_partition_by_name(string db_name, string tbl_name, string part_name)' print ' get_partitions(string db_name, string tbl_name, i16 max_parts)' @@ -365,6 +366,12 @@ sys.exit(1) pp.pprint(client.get_partition(args[0],args[1],eval(args[2]),)) +elif cmd == 'exchange_partition': + if len(args) != 5: + print 'exchange_partition requires 5 args' + sys.exit(1) + pp.pprint(client.exchange_partition(eval(args[0]),args[1],args[2],args[3],args[4],)) + elif cmd == 'get_partition_with_auth': if len(args) != 5: print 'get_partition_with_auth requires 5 args' Index: metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp =================================================================== --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp (revision 1471261) +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp (working copy) @@ -8396,6 +8396,345 @@ return xfer; } +uint32_t ThriftHiveMetastore_exchange_partition_args::read(::apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + + while (true) + { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) + { + case 1: + if (ftype == ::apache::thrift::protocol::T_MAP) { + { + this->partitionSpecs.clear(); + uint32_t _size353; + ::apache::thrift::protocol::TType _ktype354; + ::apache::thrift::protocol::TType _vtype355; + xfer += iprot->readMapBegin(_ktype354, _vtype355, _size353); + uint32_t _i357; + for (_i357 = 0; _i357 < _size353; ++_i357) + { + std::string _key358; + xfer += iprot->readString(_key358); + std::string& _val359 = this->partitionSpecs[_key358]; + xfer += iprot->readString(_val359); + } + xfer += iprot->readMapEnd(); + } + this->__isset.partitionSpecs = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->source_db); + this->__isset.source_db = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->source_table_name); + this->__isset.source_table_name = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->dest_db); + this->__isset.dest_db = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->dest_table_name); + this->__isset.dest_table_name = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_exchange_partition_args::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_exchange_partition_args"); + + xfer += oprot->writeFieldBegin("partitionSpecs", ::apache::thrift::protocol::T_MAP, 1); + { + xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->partitionSpecs.size())); + std::map ::const_iterator _iter360; + for (_iter360 = this->partitionSpecs.begin(); _iter360 != this->partitionSpecs.end(); ++_iter360) + { + xfer += oprot->writeString(_iter360->first); + xfer += oprot->writeString(_iter360->second); + } + xfer += oprot->writeMapEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("source_db", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->source_db); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("source_table_name", ::apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString(this->source_table_name); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("dest_db", ::apache::thrift::protocol::T_STRING, 4); + xfer += oprot->writeString(this->dest_db); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("dest_table_name", ::apache::thrift::protocol::T_STRING, 5); + xfer += oprot->writeString(this->dest_table_name); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_exchange_partition_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_exchange_partition_pargs"); + + xfer += oprot->writeFieldBegin("partitionSpecs", ::apache::thrift::protocol::T_MAP, 1); + { + xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast((*(this->partitionSpecs)).size())); + std::map ::const_iterator _iter361; + for (_iter361 = (*(this->partitionSpecs)).begin(); _iter361 != (*(this->partitionSpecs)).end(); ++_iter361) + { + xfer += oprot->writeString(_iter361->first); + xfer += oprot->writeString(_iter361->second); + } + xfer += oprot->writeMapEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("source_db", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString((*(this->source_db))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("source_table_name", ::apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString((*(this->source_table_name))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("dest_db", ::apache::thrift::protocol::T_STRING, 4); + xfer += oprot->writeString((*(this->dest_db))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("dest_table_name", ::apache::thrift::protocol::T_STRING, 5); + xfer += oprot->writeString((*(this->dest_table_name))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_exchange_partition_result::read(::apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + + while (true) + { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) + { + case 0: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->success.read(iprot); + this->__isset.success = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 1: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o1.read(iprot); + this->__isset.o1 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o2.read(iprot); + this->__isset.o2 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o3.read(iprot); + this->__isset.o3 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o4.read(iprot); + this->__isset.o4 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_exchange_partition_result::write(::apache::thrift::protocol::TProtocol* oprot) const { + + uint32_t xfer = 0; + + xfer += oprot->writeStructBegin("ThriftHiveMetastore_exchange_partition_result"); + + if (this->__isset.success) { + xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRUCT, 0); + xfer += this->success.write(oprot); + xfer += oprot->writeFieldEnd(); + } else if (this->__isset.o1) { + xfer += oprot->writeFieldBegin("o1", ::apache::thrift::protocol::T_STRUCT, 1); + xfer += this->o1.write(oprot); + xfer += oprot->writeFieldEnd(); + } else if (this->__isset.o2) { + xfer += oprot->writeFieldBegin("o2", ::apache::thrift::protocol::T_STRUCT, 2); + xfer += this->o2.write(oprot); + xfer += oprot->writeFieldEnd(); + } else if (this->__isset.o3) { + xfer += oprot->writeFieldBegin("o3", ::apache::thrift::protocol::T_STRUCT, 3); + xfer += this->o3.write(oprot); + xfer += oprot->writeFieldEnd(); + } else if (this->__isset.o4) { + xfer += oprot->writeFieldBegin("o4", ::apache::thrift::protocol::T_STRUCT, 4); + xfer += this->o4.write(oprot); + xfer += oprot->writeFieldEnd(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_exchange_partition_presult::read(::apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + + while (true) + { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) + { + case 0: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += (*(this->success)).read(iprot); + this->__isset.success = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 1: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o1.read(iprot); + this->__isset.o1 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o2.read(iprot); + this->__isset.o2 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o3.read(iprot); + this->__isset.o3 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o4.read(iprot); + this->__isset.o4 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + uint32_t ThriftHiveMetastore_get_partition_with_auth_args::read(::apache::thrift::protocol::TProtocol* iprot) { uint32_t xfer = 0; @@ -8436,14 +8775,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size353; - ::apache::thrift::protocol::TType _etype356; - xfer += iprot->readListBegin(_etype356, _size353); - this->part_vals.resize(_size353); - uint32_t _i357; - for (_i357 = 0; _i357 < _size353; ++_i357) + uint32_t _size362; + ::apache::thrift::protocol::TType _etype365; + xfer += iprot->readListBegin(_etype365, _size362); + this->part_vals.resize(_size362); + uint32_t _i366; + for (_i366 = 0; _i366 < _size362; ++_i366) { - xfer += iprot->readString(this->part_vals[_i357]); + xfer += iprot->readString(this->part_vals[_i366]); } xfer += iprot->readListEnd(); } @@ -8464,14 +8803,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size358; - ::apache::thrift::protocol::TType _etype361; - xfer += iprot->readListBegin(_etype361, _size358); - this->group_names.resize(_size358); - uint32_t _i362; - for (_i362 = 0; _i362 < _size358; ++_i362) + uint32_t _size367; + ::apache::thrift::protocol::TType _etype370; + xfer += iprot->readListBegin(_etype370, _size367); + this->group_names.resize(_size367); + uint32_t _i371; + for (_i371 = 0; _i371 < _size367; ++_i371) { - xfer += iprot->readString(this->group_names[_i362]); + xfer += iprot->readString(this->group_names[_i371]); } xfer += iprot->readListEnd(); } @@ -8507,10 +8846,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter363; - for (_iter363 = this->part_vals.begin(); _iter363 != this->part_vals.end(); ++_iter363) + std::vector ::const_iterator _iter372; + for (_iter372 = this->part_vals.begin(); _iter372 != this->part_vals.end(); ++_iter372) { - xfer += oprot->writeString((*_iter363)); + xfer += oprot->writeString((*_iter372)); } xfer += oprot->writeListEnd(); } @@ -8523,10 +8862,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 5); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->group_names.size())); - std::vector ::const_iterator _iter364; - for (_iter364 = this->group_names.begin(); _iter364 != this->group_names.end(); ++_iter364) + std::vector ::const_iterator _iter373; + for (_iter373 = this->group_names.begin(); _iter373 != this->group_names.end(); ++_iter373) { - xfer += oprot->writeString((*_iter364)); + xfer += oprot->writeString((*_iter373)); } xfer += oprot->writeListEnd(); } @@ -8552,10 +8891,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter365; - for (_iter365 = (*(this->part_vals)).begin(); _iter365 != (*(this->part_vals)).end(); ++_iter365) + std::vector ::const_iterator _iter374; + for (_iter374 = (*(this->part_vals)).begin(); _iter374 != (*(this->part_vals)).end(); ++_iter374) { - xfer += oprot->writeString((*_iter365)); + xfer += oprot->writeString((*_iter374)); } xfer += oprot->writeListEnd(); } @@ -8568,10 +8907,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 5); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->group_names)).size())); - std::vector ::const_iterator _iter366; - for (_iter366 = (*(this->group_names)).begin(); _iter366 != (*(this->group_names)).end(); ++_iter366) + std::vector ::const_iterator _iter375; + for (_iter375 = (*(this->group_names)).begin(); _iter375 != (*(this->group_names)).end(); ++_iter375) { - xfer += oprot->writeString((*_iter366)); + xfer += oprot->writeString((*_iter375)); } xfer += oprot->writeListEnd(); } @@ -9074,14 +9413,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size367; - ::apache::thrift::protocol::TType _etype370; - xfer += iprot->readListBegin(_etype370, _size367); - this->success.resize(_size367); - uint32_t _i371; - for (_i371 = 0; _i371 < _size367; ++_i371) + uint32_t _size376; + ::apache::thrift::protocol::TType _etype379; + xfer += iprot->readListBegin(_etype379, _size376); + this->success.resize(_size376); + uint32_t _i380; + for (_i380 = 0; _i380 < _size376; ++_i380) { - xfer += this->success[_i371].read(iprot); + xfer += this->success[_i380].read(iprot); } xfer += iprot->readListEnd(); } @@ -9128,10 +9467,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter372; - for (_iter372 = this->success.begin(); _iter372 != this->success.end(); ++_iter372) + std::vector ::const_iterator _iter381; + for (_iter381 = this->success.begin(); _iter381 != this->success.end(); ++_iter381) { - xfer += (*_iter372).write(oprot); + xfer += (*_iter381).write(oprot); } xfer += oprot->writeListEnd(); } @@ -9174,14 +9513,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size373; - ::apache::thrift::protocol::TType _etype376; - xfer += iprot->readListBegin(_etype376, _size373); - (*(this->success)).resize(_size373); - uint32_t _i377; - for (_i377 = 0; _i377 < _size373; ++_i377) + uint32_t _size382; + ::apache::thrift::protocol::TType _etype385; + xfer += iprot->readListBegin(_etype385, _size382); + (*(this->success)).resize(_size382); + uint32_t _i386; + for (_i386 = 0; _i386 < _size382; ++_i386) { - xfer += (*(this->success))[_i377].read(iprot); + xfer += (*(this->success))[_i386].read(iprot); } xfer += iprot->readListEnd(); } @@ -9274,14 +9613,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size378; - ::apache::thrift::protocol::TType _etype381; - xfer += iprot->readListBegin(_etype381, _size378); - this->group_names.resize(_size378); - uint32_t _i382; - for (_i382 = 0; _i382 < _size378; ++_i382) + uint32_t _size387; + ::apache::thrift::protocol::TType _etype390; + xfer += iprot->readListBegin(_etype390, _size387); + this->group_names.resize(_size387); + uint32_t _i391; + for (_i391 = 0; _i391 < _size387; ++_i391) { - xfer += iprot->readString(this->group_names[_i382]); + xfer += iprot->readString(this->group_names[_i391]); } xfer += iprot->readListEnd(); } @@ -9325,10 +9664,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 5); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->group_names.size())); - std::vector ::const_iterator _iter383; - for (_iter383 = this->group_names.begin(); _iter383 != this->group_names.end(); ++_iter383) + std::vector ::const_iterator _iter392; + for (_iter392 = this->group_names.begin(); _iter392 != this->group_names.end(); ++_iter392) { - xfer += oprot->writeString((*_iter383)); + xfer += oprot->writeString((*_iter392)); } xfer += oprot->writeListEnd(); } @@ -9362,10 +9701,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 5); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->group_names)).size())); - std::vector ::const_iterator _iter384; - for (_iter384 = (*(this->group_names)).begin(); _iter384 != (*(this->group_names)).end(); ++_iter384) + std::vector ::const_iterator _iter393; + for (_iter393 = (*(this->group_names)).begin(); _iter393 != (*(this->group_names)).end(); ++_iter393) { - xfer += oprot->writeString((*_iter384)); + xfer += oprot->writeString((*_iter393)); } xfer += oprot->writeListEnd(); } @@ -9400,14 +9739,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size385; - ::apache::thrift::protocol::TType _etype388; - xfer += iprot->readListBegin(_etype388, _size385); - this->success.resize(_size385); - uint32_t _i389; - for (_i389 = 0; _i389 < _size385; ++_i389) + uint32_t _size394; + ::apache::thrift::protocol::TType _etype397; + xfer += iprot->readListBegin(_etype397, _size394); + this->success.resize(_size394); + uint32_t _i398; + for (_i398 = 0; _i398 < _size394; ++_i398) { - xfer += this->success[_i389].read(iprot); + xfer += this->success[_i398].read(iprot); } xfer += iprot->readListEnd(); } @@ -9454,10 +9793,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter390; - for (_iter390 = this->success.begin(); _iter390 != this->success.end(); ++_iter390) + std::vector ::const_iterator _iter399; + for (_iter399 = this->success.begin(); _iter399 != this->success.end(); ++_iter399) { - xfer += (*_iter390).write(oprot); + xfer += (*_iter399).write(oprot); } xfer += oprot->writeListEnd(); } @@ -9500,14 +9839,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size391; - ::apache::thrift::protocol::TType _etype394; - xfer += iprot->readListBegin(_etype394, _size391); - (*(this->success)).resize(_size391); - uint32_t _i395; - for (_i395 = 0; _i395 < _size391; ++_i395) + uint32_t _size400; + ::apache::thrift::protocol::TType _etype403; + xfer += iprot->readListBegin(_etype403, _size400); + (*(this->success)).resize(_size400); + uint32_t _i404; + for (_i404 = 0; _i404 < _size400; ++_i404) { - xfer += (*(this->success))[_i395].read(iprot); + xfer += (*(this->success))[_i404].read(iprot); } xfer += iprot->readListEnd(); } @@ -9666,14 +10005,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size396; - ::apache::thrift::protocol::TType _etype399; - xfer += iprot->readListBegin(_etype399, _size396); - this->success.resize(_size396); - uint32_t _i400; - for (_i400 = 0; _i400 < _size396; ++_i400) + uint32_t _size405; + ::apache::thrift::protocol::TType _etype408; + xfer += iprot->readListBegin(_etype408, _size405); + this->success.resize(_size405); + uint32_t _i409; + for (_i409 = 0; _i409 < _size405; ++_i409) { - xfer += iprot->readString(this->success[_i400]); + xfer += iprot->readString(this->success[_i409]); } xfer += iprot->readListEnd(); } @@ -9712,10 +10051,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::vector ::const_iterator _iter401; - for (_iter401 = this->success.begin(); _iter401 != this->success.end(); ++_iter401) + std::vector ::const_iterator _iter410; + for (_iter410 = this->success.begin(); _iter410 != this->success.end(); ++_iter410) { - xfer += oprot->writeString((*_iter401)); + xfer += oprot->writeString((*_iter410)); } xfer += oprot->writeListEnd(); } @@ -9754,14 +10093,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size402; - ::apache::thrift::protocol::TType _etype405; - xfer += iprot->readListBegin(_etype405, _size402); - (*(this->success)).resize(_size402); - uint32_t _i406; - for (_i406 = 0; _i406 < _size402; ++_i406) + uint32_t _size411; + ::apache::thrift::protocol::TType _etype414; + xfer += iprot->readListBegin(_etype414, _size411); + (*(this->success)).resize(_size411); + uint32_t _i415; + for (_i415 = 0; _i415 < _size411; ++_i415) { - xfer += iprot->readString((*(this->success))[_i406]); + xfer += iprot->readString((*(this->success))[_i415]); } xfer += iprot->readListEnd(); } @@ -9830,14 +10169,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size407; - ::apache::thrift::protocol::TType _etype410; - xfer += iprot->readListBegin(_etype410, _size407); - this->part_vals.resize(_size407); - uint32_t _i411; - for (_i411 = 0; _i411 < _size407; ++_i411) + uint32_t _size416; + ::apache::thrift::protocol::TType _etype419; + xfer += iprot->readListBegin(_etype419, _size416); + this->part_vals.resize(_size416); + uint32_t _i420; + for (_i420 = 0; _i420 < _size416; ++_i420) { - xfer += iprot->readString(this->part_vals[_i411]); + xfer += iprot->readString(this->part_vals[_i420]); } xfer += iprot->readListEnd(); } @@ -9881,10 +10220,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter412; - for (_iter412 = this->part_vals.begin(); _iter412 != this->part_vals.end(); ++_iter412) + std::vector ::const_iterator _iter421; + for (_iter421 = this->part_vals.begin(); _iter421 != this->part_vals.end(); ++_iter421) { - xfer += oprot->writeString((*_iter412)); + xfer += oprot->writeString((*_iter421)); } xfer += oprot->writeListEnd(); } @@ -9914,10 +10253,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter413; - for (_iter413 = (*(this->part_vals)).begin(); _iter413 != (*(this->part_vals)).end(); ++_iter413) + std::vector ::const_iterator _iter422; + for (_iter422 = (*(this->part_vals)).begin(); _iter422 != (*(this->part_vals)).end(); ++_iter422) { - xfer += oprot->writeString((*_iter413)); + xfer += oprot->writeString((*_iter422)); } xfer += oprot->writeListEnd(); } @@ -9956,14 +10295,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size414; - ::apache::thrift::protocol::TType _etype417; - xfer += iprot->readListBegin(_etype417, _size414); - this->success.resize(_size414); - uint32_t _i418; - for (_i418 = 0; _i418 < _size414; ++_i418) + uint32_t _size423; + ::apache::thrift::protocol::TType _etype426; + xfer += iprot->readListBegin(_etype426, _size423); + this->success.resize(_size423); + uint32_t _i427; + for (_i427 = 0; _i427 < _size423; ++_i427) { - xfer += this->success[_i418].read(iprot); + xfer += this->success[_i427].read(iprot); } xfer += iprot->readListEnd(); } @@ -10010,10 +10349,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter419; - for (_iter419 = this->success.begin(); _iter419 != this->success.end(); ++_iter419) + std::vector ::const_iterator _iter428; + for (_iter428 = this->success.begin(); _iter428 != this->success.end(); ++_iter428) { - xfer += (*_iter419).write(oprot); + xfer += (*_iter428).write(oprot); } xfer += oprot->writeListEnd(); } @@ -10056,14 +10395,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size420; - ::apache::thrift::protocol::TType _etype423; - xfer += iprot->readListBegin(_etype423, _size420); - (*(this->success)).resize(_size420); - uint32_t _i424; - for (_i424 = 0; _i424 < _size420; ++_i424) + uint32_t _size429; + ::apache::thrift::protocol::TType _etype432; + xfer += iprot->readListBegin(_etype432, _size429); + (*(this->success)).resize(_size429); + uint32_t _i433; + for (_i433 = 0; _i433 < _size429; ++_i433) { - xfer += (*(this->success))[_i424].read(iprot); + xfer += (*(this->success))[_i433].read(iprot); } xfer += iprot->readListEnd(); } @@ -10140,14 +10479,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size425; - ::apache::thrift::protocol::TType _etype428; - xfer += iprot->readListBegin(_etype428, _size425); - this->part_vals.resize(_size425); - uint32_t _i429; - for (_i429 = 0; _i429 < _size425; ++_i429) + uint32_t _size434; + ::apache::thrift::protocol::TType _etype437; + xfer += iprot->readListBegin(_etype437, _size434); + this->part_vals.resize(_size434); + uint32_t _i438; + for (_i438 = 0; _i438 < _size434; ++_i438) { - xfer += iprot->readString(this->part_vals[_i429]); + xfer += iprot->readString(this->part_vals[_i438]); } xfer += iprot->readListEnd(); } @@ -10176,14 +10515,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size430; - ::apache::thrift::protocol::TType _etype433; - xfer += iprot->readListBegin(_etype433, _size430); - this->group_names.resize(_size430); - uint32_t _i434; - for (_i434 = 0; _i434 < _size430; ++_i434) + uint32_t _size439; + ::apache::thrift::protocol::TType _etype442; + xfer += iprot->readListBegin(_etype442, _size439); + this->group_names.resize(_size439); + uint32_t _i443; + for (_i443 = 0; _i443 < _size439; ++_i443) { - xfer += iprot->readString(this->group_names[_i434]); + xfer += iprot->readString(this->group_names[_i443]); } xfer += iprot->readListEnd(); } @@ -10219,10 +10558,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter435; - for (_iter435 = this->part_vals.begin(); _iter435 != this->part_vals.end(); ++_iter435) + std::vector ::const_iterator _iter444; + for (_iter444 = this->part_vals.begin(); _iter444 != this->part_vals.end(); ++_iter444) { - xfer += oprot->writeString((*_iter435)); + xfer += oprot->writeString((*_iter444)); } xfer += oprot->writeListEnd(); } @@ -10239,10 +10578,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 6); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->group_names.size())); - std::vector ::const_iterator _iter436; - for (_iter436 = this->group_names.begin(); _iter436 != this->group_names.end(); ++_iter436) + std::vector ::const_iterator _iter445; + for (_iter445 = this->group_names.begin(); _iter445 != this->group_names.end(); ++_iter445) { - xfer += oprot->writeString((*_iter436)); + xfer += oprot->writeString((*_iter445)); } xfer += oprot->writeListEnd(); } @@ -10268,10 +10607,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter437; - for (_iter437 = (*(this->part_vals)).begin(); _iter437 != (*(this->part_vals)).end(); ++_iter437) + std::vector ::const_iterator _iter446; + for (_iter446 = (*(this->part_vals)).begin(); _iter446 != (*(this->part_vals)).end(); ++_iter446) { - xfer += oprot->writeString((*_iter437)); + xfer += oprot->writeString((*_iter446)); } xfer += oprot->writeListEnd(); } @@ -10288,10 +10627,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 6); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->group_names)).size())); - std::vector ::const_iterator _iter438; - for (_iter438 = (*(this->group_names)).begin(); _iter438 != (*(this->group_names)).end(); ++_iter438) + std::vector ::const_iterator _iter447; + for (_iter447 = (*(this->group_names)).begin(); _iter447 != (*(this->group_names)).end(); ++_iter447) { - xfer += oprot->writeString((*_iter438)); + xfer += oprot->writeString((*_iter447)); } xfer += oprot->writeListEnd(); } @@ -10326,14 +10665,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size439; - ::apache::thrift::protocol::TType _etype442; - xfer += iprot->readListBegin(_etype442, _size439); - this->success.resize(_size439); - uint32_t _i443; - for (_i443 = 0; _i443 < _size439; ++_i443) + uint32_t _size448; + ::apache::thrift::protocol::TType _etype451; + xfer += iprot->readListBegin(_etype451, _size448); + this->success.resize(_size448); + uint32_t _i452; + for (_i452 = 0; _i452 < _size448; ++_i452) { - xfer += this->success[_i443].read(iprot); + xfer += this->success[_i452].read(iprot); } xfer += iprot->readListEnd(); } @@ -10380,10 +10719,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter444; - for (_iter444 = this->success.begin(); _iter444 != this->success.end(); ++_iter444) + std::vector ::const_iterator _iter453; + for (_iter453 = this->success.begin(); _iter453 != this->success.end(); ++_iter453) { - xfer += (*_iter444).write(oprot); + xfer += (*_iter453).write(oprot); } xfer += oprot->writeListEnd(); } @@ -10426,14 +10765,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size445; - ::apache::thrift::protocol::TType _etype448; - xfer += iprot->readListBegin(_etype448, _size445); - (*(this->success)).resize(_size445); - uint32_t _i449; - for (_i449 = 0; _i449 < _size445; ++_i449) + uint32_t _size454; + ::apache::thrift::protocol::TType _etype457; + xfer += iprot->readListBegin(_etype457, _size454); + (*(this->success)).resize(_size454); + uint32_t _i458; + for (_i458 = 0; _i458 < _size454; ++_i458) { - xfer += (*(this->success))[_i449].read(iprot); + xfer += (*(this->success))[_i458].read(iprot); } xfer += iprot->readListEnd(); } @@ -10510,14 +10849,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size450; - ::apache::thrift::protocol::TType _etype453; - xfer += iprot->readListBegin(_etype453, _size450); - this->part_vals.resize(_size450); - uint32_t _i454; - for (_i454 = 0; _i454 < _size450; ++_i454) + uint32_t _size459; + ::apache::thrift::protocol::TType _etype462; + xfer += iprot->readListBegin(_etype462, _size459); + this->part_vals.resize(_size459); + uint32_t _i463; + for (_i463 = 0; _i463 < _size459; ++_i463) { - xfer += iprot->readString(this->part_vals[_i454]); + xfer += iprot->readString(this->part_vals[_i463]); } xfer += iprot->readListEnd(); } @@ -10561,10 +10900,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter455; - for (_iter455 = this->part_vals.begin(); _iter455 != this->part_vals.end(); ++_iter455) + std::vector ::const_iterator _iter464; + for (_iter464 = this->part_vals.begin(); _iter464 != this->part_vals.end(); ++_iter464) { - xfer += oprot->writeString((*_iter455)); + xfer += oprot->writeString((*_iter464)); } xfer += oprot->writeListEnd(); } @@ -10594,10 +10933,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter456; - for (_iter456 = (*(this->part_vals)).begin(); _iter456 != (*(this->part_vals)).end(); ++_iter456) + std::vector ::const_iterator _iter465; + for (_iter465 = (*(this->part_vals)).begin(); _iter465 != (*(this->part_vals)).end(); ++_iter465) { - xfer += oprot->writeString((*_iter456)); + xfer += oprot->writeString((*_iter465)); } xfer += oprot->writeListEnd(); } @@ -10636,14 +10975,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size457; - ::apache::thrift::protocol::TType _etype460; - xfer += iprot->readListBegin(_etype460, _size457); - this->success.resize(_size457); - uint32_t _i461; - for (_i461 = 0; _i461 < _size457; ++_i461) + uint32_t _size466; + ::apache::thrift::protocol::TType _etype469; + xfer += iprot->readListBegin(_etype469, _size466); + this->success.resize(_size466); + uint32_t _i470; + for (_i470 = 0; _i470 < _size466; ++_i470) { - xfer += iprot->readString(this->success[_i461]); + xfer += iprot->readString(this->success[_i470]); } xfer += iprot->readListEnd(); } @@ -10690,10 +11029,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::vector ::const_iterator _iter462; - for (_iter462 = this->success.begin(); _iter462 != this->success.end(); ++_iter462) + std::vector ::const_iterator _iter471; + for (_iter471 = this->success.begin(); _iter471 != this->success.end(); ++_iter471) { - xfer += oprot->writeString((*_iter462)); + xfer += oprot->writeString((*_iter471)); } xfer += oprot->writeListEnd(); } @@ -10736,14 +11075,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size463; - ::apache::thrift::protocol::TType _etype466; - xfer += iprot->readListBegin(_etype466, _size463); - (*(this->success)).resize(_size463); - uint32_t _i467; - for (_i467 = 0; _i467 < _size463; ++_i467) + uint32_t _size472; + ::apache::thrift::protocol::TType _etype475; + xfer += iprot->readListBegin(_etype475, _size472); + (*(this->success)).resize(_size472); + uint32_t _i476; + for (_i476 = 0; _i476 < _size472; ++_i476) { - xfer += iprot->readString((*(this->success))[_i467]); + xfer += iprot->readString((*(this->success))[_i476]); } xfer += iprot->readListEnd(); } @@ -10918,14 +11257,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size468; - ::apache::thrift::protocol::TType _etype471; - xfer += iprot->readListBegin(_etype471, _size468); - this->success.resize(_size468); - uint32_t _i472; - for (_i472 = 0; _i472 < _size468; ++_i472) + uint32_t _size477; + ::apache::thrift::protocol::TType _etype480; + xfer += iprot->readListBegin(_etype480, _size477); + this->success.resize(_size477); + uint32_t _i481; + for (_i481 = 0; _i481 < _size477; ++_i481) { - xfer += this->success[_i472].read(iprot); + xfer += this->success[_i481].read(iprot); } xfer += iprot->readListEnd(); } @@ -10972,10 +11311,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter473; - for (_iter473 = this->success.begin(); _iter473 != this->success.end(); ++_iter473) + std::vector ::const_iterator _iter482; + for (_iter482 = this->success.begin(); _iter482 != this->success.end(); ++_iter482) { - xfer += (*_iter473).write(oprot); + xfer += (*_iter482).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11018,14 +11357,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size474; - ::apache::thrift::protocol::TType _etype477; - xfer += iprot->readListBegin(_etype477, _size474); - (*(this->success)).resize(_size474); - uint32_t _i478; - for (_i478 = 0; _i478 < _size474; ++_i478) + uint32_t _size483; + ::apache::thrift::protocol::TType _etype486; + xfer += iprot->readListBegin(_etype486, _size483); + (*(this->success)).resize(_size483); + uint32_t _i487; + for (_i487 = 0; _i487 < _size483; ++_i487) { - xfer += (*(this->success))[_i478].read(iprot); + xfer += (*(this->success))[_i487].read(iprot); } xfer += iprot->readListEnd(); } @@ -11102,14 +11441,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->names.clear(); - uint32_t _size479; - ::apache::thrift::protocol::TType _etype482; - xfer += iprot->readListBegin(_etype482, _size479); - this->names.resize(_size479); - uint32_t _i483; - for (_i483 = 0; _i483 < _size479; ++_i483) + uint32_t _size488; + ::apache::thrift::protocol::TType _etype491; + xfer += iprot->readListBegin(_etype491, _size488); + this->names.resize(_size488); + uint32_t _i492; + for (_i492 = 0; _i492 < _size488; ++_i492) { - xfer += iprot->readString(this->names[_i483]); + xfer += iprot->readString(this->names[_i492]); } xfer += iprot->readListEnd(); } @@ -11145,10 +11484,10 @@ xfer += oprot->writeFieldBegin("names", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->names.size())); - std::vector ::const_iterator _iter484; - for (_iter484 = this->names.begin(); _iter484 != this->names.end(); ++_iter484) + std::vector ::const_iterator _iter493; + for (_iter493 = this->names.begin(); _iter493 != this->names.end(); ++_iter493) { - xfer += oprot->writeString((*_iter484)); + xfer += oprot->writeString((*_iter493)); } xfer += oprot->writeListEnd(); } @@ -11174,10 +11513,10 @@ xfer += oprot->writeFieldBegin("names", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->names)).size())); - std::vector ::const_iterator _iter485; - for (_iter485 = (*(this->names)).begin(); _iter485 != (*(this->names)).end(); ++_iter485) + std::vector ::const_iterator _iter494; + for (_iter494 = (*(this->names)).begin(); _iter494 != (*(this->names)).end(); ++_iter494) { - xfer += oprot->writeString((*_iter485)); + xfer += oprot->writeString((*_iter494)); } xfer += oprot->writeListEnd(); } @@ -11212,14 +11551,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size486; - ::apache::thrift::protocol::TType _etype489; - xfer += iprot->readListBegin(_etype489, _size486); - this->success.resize(_size486); - uint32_t _i490; - for (_i490 = 0; _i490 < _size486; ++_i490) + uint32_t _size495; + ::apache::thrift::protocol::TType _etype498; + xfer += iprot->readListBegin(_etype498, _size495); + this->success.resize(_size495); + uint32_t _i499; + for (_i499 = 0; _i499 < _size495; ++_i499) { - xfer += this->success[_i490].read(iprot); + xfer += this->success[_i499].read(iprot); } xfer += iprot->readListEnd(); } @@ -11266,10 +11605,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter491; - for (_iter491 = this->success.begin(); _iter491 != this->success.end(); ++_iter491) + std::vector ::const_iterator _iter500; + for (_iter500 = this->success.begin(); _iter500 != this->success.end(); ++_iter500) { - xfer += (*_iter491).write(oprot); + xfer += (*_iter500).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11312,14 +11651,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size492; - ::apache::thrift::protocol::TType _etype495; - xfer += iprot->readListBegin(_etype495, _size492); - (*(this->success)).resize(_size492); - uint32_t _i496; - for (_i496 = 0; _i496 < _size492; ++_i496) + uint32_t _size501; + ::apache::thrift::protocol::TType _etype504; + xfer += iprot->readListBegin(_etype504, _size501); + (*(this->success)).resize(_size501); + uint32_t _i505; + for (_i505 = 0; _i505 < _size501; ++_i505) { - xfer += (*(this->success))[_i496].read(iprot); + xfer += (*(this->success))[_i505].read(iprot); } xfer += iprot->readListEnd(); } @@ -11610,14 +11949,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->new_parts.clear(); - uint32_t _size497; - ::apache::thrift::protocol::TType _etype500; - xfer += iprot->readListBegin(_etype500, _size497); - this->new_parts.resize(_size497); - uint32_t _i501; - for (_i501 = 0; _i501 < _size497; ++_i501) + uint32_t _size506; + ::apache::thrift::protocol::TType _etype509; + xfer += iprot->readListBegin(_etype509, _size506); + this->new_parts.resize(_size506); + uint32_t _i510; + for (_i510 = 0; _i510 < _size506; ++_i510) { - xfer += this->new_parts[_i501].read(iprot); + xfer += this->new_parts[_i510].read(iprot); } xfer += iprot->readListEnd(); } @@ -11653,10 +11992,10 @@ xfer += oprot->writeFieldBegin("new_parts", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->new_parts.size())); - std::vector ::const_iterator _iter502; - for (_iter502 = this->new_parts.begin(); _iter502 != this->new_parts.end(); ++_iter502) + std::vector ::const_iterator _iter511; + for (_iter511 = this->new_parts.begin(); _iter511 != this->new_parts.end(); ++_iter511) { - xfer += (*_iter502).write(oprot); + xfer += (*_iter511).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11682,10 +12021,10 @@ xfer += oprot->writeFieldBegin("new_parts", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast((*(this->new_parts)).size())); - std::vector ::const_iterator _iter503; - for (_iter503 = (*(this->new_parts)).begin(); _iter503 != (*(this->new_parts)).end(); ++_iter503) + std::vector ::const_iterator _iter512; + for (_iter512 = (*(this->new_parts)).begin(); _iter512 != (*(this->new_parts)).end(); ++_iter512) { - xfer += (*_iter503).write(oprot); + xfer += (*_iter512).write(oprot); } xfer += oprot->writeListEnd(); } @@ -12082,14 +12421,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size504; - ::apache::thrift::protocol::TType _etype507; - xfer += iprot->readListBegin(_etype507, _size504); - this->part_vals.resize(_size504); - uint32_t _i508; - for (_i508 = 0; _i508 < _size504; ++_i508) + uint32_t _size513; + ::apache::thrift::protocol::TType _etype516; + xfer += iprot->readListBegin(_etype516, _size513); + this->part_vals.resize(_size513); + uint32_t _i517; + for (_i517 = 0; _i517 < _size513; ++_i517) { - xfer += iprot->readString(this->part_vals[_i508]); + xfer += iprot->readString(this->part_vals[_i517]); } xfer += iprot->readListEnd(); } @@ -12133,10 +12472,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter509; - for (_iter509 = this->part_vals.begin(); _iter509 != this->part_vals.end(); ++_iter509) + std::vector ::const_iterator _iter518; + for (_iter518 = this->part_vals.begin(); _iter518 != this->part_vals.end(); ++_iter518) { - xfer += oprot->writeString((*_iter509)); + xfer += oprot->writeString((*_iter518)); } xfer += oprot->writeListEnd(); } @@ -12166,10 +12505,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter510; - for (_iter510 = (*(this->part_vals)).begin(); _iter510 != (*(this->part_vals)).end(); ++_iter510) + std::vector ::const_iterator _iter519; + for (_iter519 = (*(this->part_vals)).begin(); _iter519 != (*(this->part_vals)).end(); ++_iter519) { - xfer += oprot->writeString((*_iter510)); + xfer += oprot->writeString((*_iter519)); } xfer += oprot->writeListEnd(); } @@ -12324,14 +12663,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size511; - ::apache::thrift::protocol::TType _etype514; - xfer += iprot->readListBegin(_etype514, _size511); - this->part_vals.resize(_size511); - uint32_t _i515; - for (_i515 = 0; _i515 < _size511; ++_i515) + uint32_t _size520; + ::apache::thrift::protocol::TType _etype523; + xfer += iprot->readListBegin(_etype523, _size520); + this->part_vals.resize(_size520); + uint32_t _i524; + for (_i524 = 0; _i524 < _size520; ++_i524) { - xfer += iprot->readString(this->part_vals[_i515]); + xfer += iprot->readString(this->part_vals[_i524]); } xfer += iprot->readListEnd(); } @@ -12367,10 +12706,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter516; - for (_iter516 = this->part_vals.begin(); _iter516 != this->part_vals.end(); ++_iter516) + std::vector ::const_iterator _iter525; + for (_iter525 = this->part_vals.begin(); _iter525 != this->part_vals.end(); ++_iter525) { - xfer += oprot->writeString((*_iter516)); + xfer += oprot->writeString((*_iter525)); } xfer += oprot->writeListEnd(); } @@ -12392,10 +12731,10 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter517; - for (_iter517 = (*(this->part_vals)).begin(); _iter517 != (*(this->part_vals)).end(); ++_iter517) + std::vector ::const_iterator _iter526; + for (_iter526 = (*(this->part_vals)).begin(); _iter526 != (*(this->part_vals)).end(); ++_iter526) { - xfer += oprot->writeString((*_iter517)); + xfer += oprot->writeString((*_iter526)); } xfer += oprot->writeListEnd(); } @@ -12814,14 +13153,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size518; - ::apache::thrift::protocol::TType _etype521; - xfer += iprot->readListBegin(_etype521, _size518); - this->success.resize(_size518); - uint32_t _i522; - for (_i522 = 0; _i522 < _size518; ++_i522) + uint32_t _size527; + ::apache::thrift::protocol::TType _etype530; + xfer += iprot->readListBegin(_etype530, _size527); + this->success.resize(_size527); + uint32_t _i531; + for (_i531 = 0; _i531 < _size527; ++_i531) { - xfer += iprot->readString(this->success[_i522]); + xfer += iprot->readString(this->success[_i531]); } xfer += iprot->readListEnd(); } @@ -12860,10 +13199,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::vector ::const_iterator _iter523; - for (_iter523 = this->success.begin(); _iter523 != this->success.end(); ++_iter523) + std::vector ::const_iterator _iter532; + for (_iter532 = this->success.begin(); _iter532 != this->success.end(); ++_iter532) { - xfer += oprot->writeString((*_iter523)); + xfer += oprot->writeString((*_iter532)); } xfer += oprot->writeListEnd(); } @@ -12902,14 +13241,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size524; - ::apache::thrift::protocol::TType _etype527; - xfer += iprot->readListBegin(_etype527, _size524); - (*(this->success)).resize(_size524); - uint32_t _i528; - for (_i528 = 0; _i528 < _size524; ++_i528) + uint32_t _size533; + ::apache::thrift::protocol::TType _etype536; + xfer += iprot->readListBegin(_etype536, _size533); + (*(this->success)).resize(_size533); + uint32_t _i537; + for (_i537 = 0; _i537 < _size533; ++_i537) { - xfer += iprot->readString((*(this->success))[_i528]); + xfer += iprot->readString((*(this->success))[_i537]); } xfer += iprot->readListEnd(); } @@ -13028,17 +13367,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->success.clear(); - uint32_t _size529; - ::apache::thrift::protocol::TType _ktype530; - ::apache::thrift::protocol::TType _vtype531; - xfer += iprot->readMapBegin(_ktype530, _vtype531, _size529); - uint32_t _i533; - for (_i533 = 0; _i533 < _size529; ++_i533) + uint32_t _size538; + ::apache::thrift::protocol::TType _ktype539; + ::apache::thrift::protocol::TType _vtype540; + xfer += iprot->readMapBegin(_ktype539, _vtype540, _size538); + uint32_t _i542; + for (_i542 = 0; _i542 < _size538; ++_i542) { - std::string _key534; - xfer += iprot->readString(_key534); - std::string& _val535 = this->success[_key534]; - xfer += iprot->readString(_val535); + std::string _key543; + xfer += iprot->readString(_key543); + std::string& _val544 = this->success[_key543]; + xfer += iprot->readString(_val544); } xfer += iprot->readMapEnd(); } @@ -13077,11 +13416,11 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_MAP, 0); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::map ::const_iterator _iter536; - for (_iter536 = this->success.begin(); _iter536 != this->success.end(); ++_iter536) + std::map ::const_iterator _iter545; + for (_iter545 = this->success.begin(); _iter545 != this->success.end(); ++_iter545) { - xfer += oprot->writeString(_iter536->first); - xfer += oprot->writeString(_iter536->second); + xfer += oprot->writeString(_iter545->first); + xfer += oprot->writeString(_iter545->second); } xfer += oprot->writeMapEnd(); } @@ -13120,17 +13459,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { (*(this->success)).clear(); - uint32_t _size537; - ::apache::thrift::protocol::TType _ktype538; - ::apache::thrift::protocol::TType _vtype539; - xfer += iprot->readMapBegin(_ktype538, _vtype539, _size537); - uint32_t _i541; - for (_i541 = 0; _i541 < _size537; ++_i541) + uint32_t _size546; + ::apache::thrift::protocol::TType _ktype547; + ::apache::thrift::protocol::TType _vtype548; + xfer += iprot->readMapBegin(_ktype547, _vtype548, _size546); + uint32_t _i550; + for (_i550 = 0; _i550 < _size546; ++_i550) { - std::string _key542; - xfer += iprot->readString(_key542); - std::string& _val543 = (*(this->success))[_key542]; - xfer += iprot->readString(_val543); + std::string _key551; + xfer += iprot->readString(_key551); + std::string& _val552 = (*(this->success))[_key551]; + xfer += iprot->readString(_val552); } xfer += iprot->readMapEnd(); } @@ -13199,17 +13538,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->part_vals.clear(); - uint32_t _size544; - ::apache::thrift::protocol::TType _ktype545; - ::apache::thrift::protocol::TType _vtype546; - xfer += iprot->readMapBegin(_ktype545, _vtype546, _size544); - uint32_t _i548; - for (_i548 = 0; _i548 < _size544; ++_i548) + uint32_t _size553; + ::apache::thrift::protocol::TType _ktype554; + ::apache::thrift::protocol::TType _vtype555; + xfer += iprot->readMapBegin(_ktype554, _vtype555, _size553); + uint32_t _i557; + for (_i557 = 0; _i557 < _size553; ++_i557) { - std::string _key549; - xfer += iprot->readString(_key549); - std::string& _val550 = this->part_vals[_key549]; - xfer += iprot->readString(_val550); + std::string _key558; + xfer += iprot->readString(_key558); + std::string& _val559 = this->part_vals[_key558]; + xfer += iprot->readString(_val559); } xfer += iprot->readMapEnd(); } @@ -13220,9 +13559,9 @@ break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast551; - xfer += iprot->readI32(ecast551); - this->eventType = (PartitionEventType::type)ecast551; + int32_t ecast560; + xfer += iprot->readI32(ecast560); + this->eventType = (PartitionEventType::type)ecast560; this->__isset.eventType = true; } else { xfer += iprot->skip(ftype); @@ -13255,11 +13594,11 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_MAP, 3); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::map ::const_iterator _iter552; - for (_iter552 = this->part_vals.begin(); _iter552 != this->part_vals.end(); ++_iter552) + std::map ::const_iterator _iter561; + for (_iter561 = this->part_vals.begin(); _iter561 != this->part_vals.end(); ++_iter561) { - xfer += oprot->writeString(_iter552->first); - xfer += oprot->writeString(_iter552->second); + xfer += oprot->writeString(_iter561->first); + xfer += oprot->writeString(_iter561->second); } xfer += oprot->writeMapEnd(); } @@ -13289,11 +13628,11 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_MAP, 3); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::map ::const_iterator _iter553; - for (_iter553 = (*(this->part_vals)).begin(); _iter553 != (*(this->part_vals)).end(); ++_iter553) + std::map ::const_iterator _iter562; + for (_iter562 = (*(this->part_vals)).begin(); _iter562 != (*(this->part_vals)).end(); ++_iter562) { - xfer += oprot->writeString(_iter553->first); - xfer += oprot->writeString(_iter553->second); + xfer += oprot->writeString(_iter562->first); + xfer += oprot->writeString(_iter562->second); } xfer += oprot->writeMapEnd(); } @@ -13544,17 +13883,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->part_vals.clear(); - uint32_t _size554; - ::apache::thrift::protocol::TType _ktype555; - ::apache::thrift::protocol::TType _vtype556; - xfer += iprot->readMapBegin(_ktype555, _vtype556, _size554); - uint32_t _i558; - for (_i558 = 0; _i558 < _size554; ++_i558) + uint32_t _size563; + ::apache::thrift::protocol::TType _ktype564; + ::apache::thrift::protocol::TType _vtype565; + xfer += iprot->readMapBegin(_ktype564, _vtype565, _size563); + uint32_t _i567; + for (_i567 = 0; _i567 < _size563; ++_i567) { - std::string _key559; - xfer += iprot->readString(_key559); - std::string& _val560 = this->part_vals[_key559]; - xfer += iprot->readString(_val560); + std::string _key568; + xfer += iprot->readString(_key568); + std::string& _val569 = this->part_vals[_key568]; + xfer += iprot->readString(_val569); } xfer += iprot->readMapEnd(); } @@ -13565,9 +13904,9 @@ break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast561; - xfer += iprot->readI32(ecast561); - this->eventType = (PartitionEventType::type)ecast561; + int32_t ecast570; + xfer += iprot->readI32(ecast570); + this->eventType = (PartitionEventType::type)ecast570; this->__isset.eventType = true; } else { xfer += iprot->skip(ftype); @@ -13600,11 +13939,11 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_MAP, 3); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::map ::const_iterator _iter562; - for (_iter562 = this->part_vals.begin(); _iter562 != this->part_vals.end(); ++_iter562) + std::map ::const_iterator _iter571; + for (_iter571 = this->part_vals.begin(); _iter571 != this->part_vals.end(); ++_iter571) { - xfer += oprot->writeString(_iter562->first); - xfer += oprot->writeString(_iter562->second); + xfer += oprot->writeString(_iter571->first); + xfer += oprot->writeString(_iter571->second); } xfer += oprot->writeMapEnd(); } @@ -13634,11 +13973,11 @@ xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_MAP, 3); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::map ::const_iterator _iter563; - for (_iter563 = (*(this->part_vals)).begin(); _iter563 != (*(this->part_vals)).end(); ++_iter563) + std::map ::const_iterator _iter572; + for (_iter572 = (*(this->part_vals)).begin(); _iter572 != (*(this->part_vals)).end(); ++_iter572) { - xfer += oprot->writeString(_iter563->first); - xfer += oprot->writeString(_iter563->second); + xfer += oprot->writeString(_iter572->first); + xfer += oprot->writeString(_iter572->second); } xfer += oprot->writeMapEnd(); } @@ -14943,14 +15282,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size564; - ::apache::thrift::protocol::TType _etype567; - xfer += iprot->readListBegin(_etype567, _size564); - this->success.resize(_size564); - uint32_t _i568; - for (_i568 = 0; _i568 < _size564; ++_i568) + uint32_t _size573; + ::apache::thrift::protocol::TType _etype576; + xfer += iprot->readListBegin(_etype576, _size573); + this->success.resize(_size573); + uint32_t _i577; + for (_i577 = 0; _i577 < _size573; ++_i577) { - xfer += this->success[_i568].read(iprot); + xfer += this->success[_i577].read(iprot); } xfer += iprot->readListEnd(); } @@ -14997,10 +15336,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter569; - for (_iter569 = this->success.begin(); _iter569 != this->success.end(); ++_iter569) + std::vector ::const_iterator _iter578; + for (_iter578 = this->success.begin(); _iter578 != this->success.end(); ++_iter578) { - xfer += (*_iter569).write(oprot); + xfer += (*_iter578).write(oprot); } xfer += oprot->writeListEnd(); } @@ -15043,14 +15382,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size570; - ::apache::thrift::protocol::TType _etype573; - xfer += iprot->readListBegin(_etype573, _size570); - (*(this->success)).resize(_size570); - uint32_t _i574; - for (_i574 = 0; _i574 < _size570; ++_i574) + uint32_t _size579; + ::apache::thrift::protocol::TType _etype582; + xfer += iprot->readListBegin(_etype582, _size579); + (*(this->success)).resize(_size579); + uint32_t _i583; + for (_i583 = 0; _i583 < _size579; ++_i583) { - xfer += (*(this->success))[_i574].read(iprot); + xfer += (*(this->success))[_i583].read(iprot); } xfer += iprot->readListEnd(); } @@ -15209,14 +15548,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size575; - ::apache::thrift::protocol::TType _etype578; - xfer += iprot->readListBegin(_etype578, _size575); - this->success.resize(_size575); - uint32_t _i579; - for (_i579 = 0; _i579 < _size575; ++_i579) + uint32_t _size584; + ::apache::thrift::protocol::TType _etype587; + xfer += iprot->readListBegin(_etype587, _size584); + this->success.resize(_size584); + uint32_t _i588; + for (_i588 = 0; _i588 < _size584; ++_i588) { - xfer += iprot->readString(this->success[_i579]); + xfer += iprot->readString(this->success[_i588]); } xfer += iprot->readListEnd(); } @@ -15255,10 +15594,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::vector ::const_iterator _iter580; - for (_iter580 = this->success.begin(); _iter580 != this->success.end(); ++_iter580) + std::vector ::const_iterator _iter589; + for (_iter589 = this->success.begin(); _iter589 != this->success.end(); ++_iter589) { - xfer += oprot->writeString((*_iter580)); + xfer += oprot->writeString((*_iter589)); } xfer += oprot->writeListEnd(); } @@ -15297,14 +15636,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size581; - ::apache::thrift::protocol::TType _etype584; - xfer += iprot->readListBegin(_etype584, _size581); - (*(this->success)).resize(_size581); - uint32_t _i585; - for (_i585 = 0; _i585 < _size581; ++_i585) + uint32_t _size590; + ::apache::thrift::protocol::TType _etype593; + xfer += iprot->readListBegin(_etype593, _size590); + (*(this->success)).resize(_size590); + uint32_t _i594; + for (_i594 = 0; _i594 < _size590; ++_i594) { - xfer += iprot->readString((*(this->success))[_i585]); + xfer += iprot->readString((*(this->success))[_i594]); } xfer += iprot->readListEnd(); } @@ -17378,14 +17717,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size586; - ::apache::thrift::protocol::TType _etype589; - xfer += iprot->readListBegin(_etype589, _size586); - this->success.resize(_size586); - uint32_t _i590; - for (_i590 = 0; _i590 < _size586; ++_i590) + uint32_t _size595; + ::apache::thrift::protocol::TType _etype598; + xfer += iprot->readListBegin(_etype598, _size595); + this->success.resize(_size595); + uint32_t _i599; + for (_i599 = 0; _i599 < _size595; ++_i599) { - xfer += iprot->readString(this->success[_i590]); + xfer += iprot->readString(this->success[_i599]); } xfer += iprot->readListEnd(); } @@ -17424,10 +17763,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::vector ::const_iterator _iter591; - for (_iter591 = this->success.begin(); _iter591 != this->success.end(); ++_iter591) + std::vector ::const_iterator _iter600; + for (_iter600 = this->success.begin(); _iter600 != this->success.end(); ++_iter600) { - xfer += oprot->writeString((*_iter591)); + xfer += oprot->writeString((*_iter600)); } xfer += oprot->writeListEnd(); } @@ -17466,14 +17805,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size592; - ::apache::thrift::protocol::TType _etype595; - xfer += iprot->readListBegin(_etype595, _size592); - (*(this->success)).resize(_size592); - uint32_t _i596; - for (_i596 = 0; _i596 < _size592; ++_i596) + uint32_t _size601; + ::apache::thrift::protocol::TType _etype604; + xfer += iprot->readListBegin(_etype604, _size601); + (*(this->success)).resize(_size601); + uint32_t _i605; + for (_i605 = 0; _i605 < _size601; ++_i605) { - xfer += iprot->readString((*(this->success))[_i596]); + xfer += iprot->readString((*(this->success))[_i605]); } xfer += iprot->readListEnd(); } @@ -17540,9 +17879,9 @@ break; case 3: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast597; - xfer += iprot->readI32(ecast597); - this->principal_type = (PrincipalType::type)ecast597; + int32_t ecast606; + xfer += iprot->readI32(ecast606); + this->principal_type = (PrincipalType::type)ecast606; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -17558,9 +17897,9 @@ break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast598; - xfer += iprot->readI32(ecast598); - this->grantorType = (PrincipalType::type)ecast598; + int32_t ecast607; + xfer += iprot->readI32(ecast607); + this->grantorType = (PrincipalType::type)ecast607; this->__isset.grantorType = true; } else { xfer += iprot->skip(ftype); @@ -17806,9 +18145,9 @@ break; case 3: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast599; - xfer += iprot->readI32(ecast599); - this->principal_type = (PrincipalType::type)ecast599; + int32_t ecast608; + xfer += iprot->readI32(ecast608); + this->principal_type = (PrincipalType::type)ecast608; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -18014,9 +18353,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast600; - xfer += iprot->readI32(ecast600); - this->principal_type = (PrincipalType::type)ecast600; + int32_t ecast609; + xfer += iprot->readI32(ecast609); + this->principal_type = (PrincipalType::type)ecast609; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -18092,14 +18431,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size601; - ::apache::thrift::protocol::TType _etype604; - xfer += iprot->readListBegin(_etype604, _size601); - this->success.resize(_size601); - uint32_t _i605; - for (_i605 = 0; _i605 < _size601; ++_i605) + uint32_t _size610; + ::apache::thrift::protocol::TType _etype613; + xfer += iprot->readListBegin(_etype613, _size610); + this->success.resize(_size610); + uint32_t _i614; + for (_i614 = 0; _i614 < _size610; ++_i614) { - xfer += this->success[_i605].read(iprot); + xfer += this->success[_i614].read(iprot); } xfer += iprot->readListEnd(); } @@ -18138,10 +18477,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter606; - for (_iter606 = this->success.begin(); _iter606 != this->success.end(); ++_iter606) + std::vector ::const_iterator _iter615; + for (_iter615 = this->success.begin(); _iter615 != this->success.end(); ++_iter615) { - xfer += (*_iter606).write(oprot); + xfer += (*_iter615).write(oprot); } xfer += oprot->writeListEnd(); } @@ -18180,14 +18519,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size607; - ::apache::thrift::protocol::TType _etype610; - xfer += iprot->readListBegin(_etype610, _size607); - (*(this->success)).resize(_size607); - uint32_t _i611; - for (_i611 = 0; _i611 < _size607; ++_i611) + uint32_t _size616; + ::apache::thrift::protocol::TType _etype619; + xfer += iprot->readListBegin(_etype619, _size616); + (*(this->success)).resize(_size616); + uint32_t _i620; + for (_i620 = 0; _i620 < _size616; ++_i620) { - xfer += (*(this->success))[_i611].read(iprot); + xfer += (*(this->success))[_i620].read(iprot); } xfer += iprot->readListEnd(); } @@ -18256,14 +18595,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size612; - ::apache::thrift::protocol::TType _etype615; - xfer += iprot->readListBegin(_etype615, _size612); - this->group_names.resize(_size612); - uint32_t _i616; - for (_i616 = 0; _i616 < _size612; ++_i616) + uint32_t _size621; + ::apache::thrift::protocol::TType _etype624; + xfer += iprot->readListBegin(_etype624, _size621); + this->group_names.resize(_size621); + uint32_t _i625; + for (_i625 = 0; _i625 < _size621; ++_i625) { - xfer += iprot->readString(this->group_names[_i616]); + xfer += iprot->readString(this->group_names[_i625]); } xfer += iprot->readListEnd(); } @@ -18299,10 +18638,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->group_names.size())); - std::vector ::const_iterator _iter617; - for (_iter617 = this->group_names.begin(); _iter617 != this->group_names.end(); ++_iter617) + std::vector ::const_iterator _iter626; + for (_iter626 = this->group_names.begin(); _iter626 != this->group_names.end(); ++_iter626) { - xfer += oprot->writeString((*_iter617)); + xfer += oprot->writeString((*_iter626)); } xfer += oprot->writeListEnd(); } @@ -18328,10 +18667,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->group_names)).size())); - std::vector ::const_iterator _iter618; - for (_iter618 = (*(this->group_names)).begin(); _iter618 != (*(this->group_names)).end(); ++_iter618) + std::vector ::const_iterator _iter627; + for (_iter627 = (*(this->group_names)).begin(); _iter627 != (*(this->group_names)).end(); ++_iter627) { - xfer += oprot->writeString((*_iter618)); + xfer += oprot->writeString((*_iter627)); } xfer += oprot->writeListEnd(); } @@ -18488,9 +18827,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast619; - xfer += iprot->readI32(ecast619); - this->principal_type = (PrincipalType::type)ecast619; + int32_t ecast628; + xfer += iprot->readI32(ecast628); + this->principal_type = (PrincipalType::type)ecast628; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -18582,14 +18921,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size620; - ::apache::thrift::protocol::TType _etype623; - xfer += iprot->readListBegin(_etype623, _size620); - this->success.resize(_size620); - uint32_t _i624; - for (_i624 = 0; _i624 < _size620; ++_i624) + uint32_t _size629; + ::apache::thrift::protocol::TType _etype632; + xfer += iprot->readListBegin(_etype632, _size629); + this->success.resize(_size629); + uint32_t _i633; + for (_i633 = 0; _i633 < _size629; ++_i633) { - xfer += this->success[_i624].read(iprot); + xfer += this->success[_i633].read(iprot); } xfer += iprot->readListEnd(); } @@ -18628,10 +18967,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::vector ::const_iterator _iter625; - for (_iter625 = this->success.begin(); _iter625 != this->success.end(); ++_iter625) + std::vector ::const_iterator _iter634; + for (_iter634 = this->success.begin(); _iter634 != this->success.end(); ++_iter634) { - xfer += (*_iter625).write(oprot); + xfer += (*_iter634).write(oprot); } xfer += oprot->writeListEnd(); } @@ -18670,14 +19009,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size626; - ::apache::thrift::protocol::TType _etype629; - xfer += iprot->readListBegin(_etype629, _size626); - (*(this->success)).resize(_size626); - uint32_t _i630; - for (_i630 = 0; _i630 < _size626; ++_i630) + uint32_t _size635; + ::apache::thrift::protocol::TType _etype638; + xfer += iprot->readListBegin(_etype638, _size635); + (*(this->success)).resize(_size635); + uint32_t _i639; + for (_i639 = 0; _i639 < _size635; ++_i639) { - xfer += (*(this->success))[_i630].read(iprot); + xfer += (*(this->success))[_i639].read(iprot); } xfer += iprot->readListEnd(); } @@ -19102,14 +19441,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size631; - ::apache::thrift::protocol::TType _etype634; - xfer += iprot->readListBegin(_etype634, _size631); - this->group_names.resize(_size631); - uint32_t _i635; - for (_i635 = 0; _i635 < _size631; ++_i635) + uint32_t _size640; + ::apache::thrift::protocol::TType _etype643; + xfer += iprot->readListBegin(_etype643, _size640); + this->group_names.resize(_size640); + uint32_t _i644; + for (_i644 = 0; _i644 < _size640; ++_i644) { - xfer += iprot->readString(this->group_names[_i635]); + xfer += iprot->readString(this->group_names[_i644]); } xfer += iprot->readListEnd(); } @@ -19141,10 +19480,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->group_names.size())); - std::vector ::const_iterator _iter636; - for (_iter636 = this->group_names.begin(); _iter636 != this->group_names.end(); ++_iter636) + std::vector ::const_iterator _iter645; + for (_iter645 = this->group_names.begin(); _iter645 != this->group_names.end(); ++_iter645) { - xfer += oprot->writeString((*_iter636)); + xfer += oprot->writeString((*_iter645)); } xfer += oprot->writeListEnd(); } @@ -19166,10 +19505,10 @@ xfer += oprot->writeFieldBegin("group_names", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->group_names)).size())); - std::vector ::const_iterator _iter637; - for (_iter637 = (*(this->group_names)).begin(); _iter637 != (*(this->group_names)).end(); ++_iter637) + std::vector ::const_iterator _iter646; + for (_iter646 = (*(this->group_names)).begin(); _iter646 != (*(this->group_names)).end(); ++_iter646) { - xfer += oprot->writeString((*_iter637)); + xfer += oprot->writeString((*_iter646)); } xfer += oprot->writeListEnd(); } @@ -19204,14 +19543,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size638; - ::apache::thrift::protocol::TType _etype641; - xfer += iprot->readListBegin(_etype641, _size638); - this->success.resize(_size638); - uint32_t _i642; - for (_i642 = 0; _i642 < _size638; ++_i642) + uint32_t _size647; + ::apache::thrift::protocol::TType _etype650; + xfer += iprot->readListBegin(_etype650, _size647); + this->success.resize(_size647); + uint32_t _i651; + for (_i651 = 0; _i651 < _size647; ++_i651) { - xfer += iprot->readString(this->success[_i642]); + xfer += iprot->readString(this->success[_i651]); } xfer += iprot->readListEnd(); } @@ -19250,10 +19589,10 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_LIST, 0); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->success.size())); - std::vector ::const_iterator _iter643; - for (_iter643 = this->success.begin(); _iter643 != this->success.end(); ++_iter643) + std::vector ::const_iterator _iter652; + for (_iter652 = this->success.begin(); _iter652 != this->success.end(); ++_iter652) { - xfer += oprot->writeString((*_iter643)); + xfer += oprot->writeString((*_iter652)); } xfer += oprot->writeListEnd(); } @@ -19292,14 +19631,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size644; - ::apache::thrift::protocol::TType _etype647; - xfer += iprot->readListBegin(_etype647, _size644); - (*(this->success)).resize(_size644); - uint32_t _i648; - for (_i648 = 0; _i648 < _size644; ++_i648) + uint32_t _size653; + ::apache::thrift::protocol::TType _etype656; + xfer += iprot->readListBegin(_etype656, _size653); + (*(this->success)).resize(_size653); + uint32_t _i657; + for (_i657 = 0; _i657 < _size653; ++_i657) { - xfer += iprot->readString((*(this->success))[_i648]); + xfer += iprot->readString((*(this->success))[_i657]); } xfer += iprot->readListEnd(); } @@ -22151,6 +22490,80 @@ throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_partition failed: unknown result"); } +void ThriftHiveMetastoreClient::exchange_partition(Partition& _return, const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) +{ + send_exchange_partition(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name); + recv_exchange_partition(_return); +} + +void ThriftHiveMetastoreClient::send_exchange_partition(const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) +{ + int32_t cseqid = 0; + oprot_->writeMessageBegin("exchange_partition", ::apache::thrift::protocol::T_CALL, cseqid); + + ThriftHiveMetastore_exchange_partition_pargs args; + args.partitionSpecs = &partitionSpecs; + args.source_db = &source_db; + args.source_table_name = &source_table_name; + args.dest_db = &dest_db; + args.dest_table_name = &dest_table_name; + args.write(oprot_); + + oprot_->writeMessageEnd(); + oprot_->getTransport()->writeEnd(); + oprot_->getTransport()->flush(); +} + +void ThriftHiveMetastoreClient::recv_exchange_partition(Partition& _return) +{ + + int32_t rseqid = 0; + std::string fname; + ::apache::thrift::protocol::TMessageType mtype; + + iprot_->readMessageBegin(fname, mtype, rseqid); + if (mtype == ::apache::thrift::protocol::T_EXCEPTION) { + ::apache::thrift::TApplicationException x; + x.read(iprot_); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + throw x; + } + if (mtype != ::apache::thrift::protocol::T_REPLY) { + iprot_->skip(::apache::thrift::protocol::T_STRUCT); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + } + if (fname.compare("exchange_partition") != 0) { + iprot_->skip(::apache::thrift::protocol::T_STRUCT); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + } + ThriftHiveMetastore_exchange_partition_presult result; + result.success = &_return; + result.read(iprot_); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + + if (result.__isset.success) { + // _return pointer has now been filled + return; + } + if (result.__isset.o1) { + throw result.o1; + } + if (result.__isset.o2) { + throw result.o2; + } + if (result.__isset.o3) { + throw result.o3; + } + if (result.__isset.o4) { + throw result.o4; + } + throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "exchange_partition failed: unknown result"); +} + void ThriftHiveMetastoreClient::get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const std::string& user_name, const std::vector & group_names) { send_get_partition_with_auth(db_name, tbl_name, part_vals, user_name, group_names); @@ -27287,6 +27700,72 @@ } } +void ThriftHiveMetastoreProcessor::process_exchange_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext) +{ + void* ctx = NULL; + if (this->eventHandler_.get() != NULL) { + ctx = this->eventHandler_->getContext("ThriftHiveMetastore.exchange_partition", callContext); + } + ::apache::thrift::TProcessorContextFreer freer(this->eventHandler_.get(), ctx, "ThriftHiveMetastore.exchange_partition"); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->preRead(ctx, "ThriftHiveMetastore.exchange_partition"); + } + + ThriftHiveMetastore_exchange_partition_args args; + args.read(iprot); + iprot->readMessageEnd(); + uint32_t bytes = iprot->getTransport()->readEnd(); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->postRead(ctx, "ThriftHiveMetastore.exchange_partition", bytes); + } + + ThriftHiveMetastore_exchange_partition_result result; + try { + iface_->exchange_partition(result.success, args.partitionSpecs, args.source_db, args.source_table_name, args.dest_db, args.dest_table_name); + result.__isset.success = true; + } catch (MetaException &o1) { + result.o1 = o1; + result.__isset.o1 = true; + } catch (NoSuchObjectException &o2) { + result.o2 = o2; + result.__isset.o2 = true; + } catch (InvalidObjectException &o3) { + result.o3 = o3; + result.__isset.o3 = true; + } catch (InvalidInputException &o4) { + result.o4 = o4; + result.__isset.o4 = true; + } catch (const std::exception& e) { + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->handlerError(ctx, "ThriftHiveMetastore.exchange_partition"); + } + + ::apache::thrift::TApplicationException x(e.what()); + oprot->writeMessageBegin("exchange_partition", ::apache::thrift::protocol::T_EXCEPTION, seqid); + x.write(oprot); + oprot->writeMessageEnd(); + oprot->getTransport()->writeEnd(); + oprot->getTransport()->flush(); + return; + } + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->preWrite(ctx, "ThriftHiveMetastore.exchange_partition"); + } + + oprot->writeMessageBegin("exchange_partition", ::apache::thrift::protocol::T_REPLY, seqid); + result.write(oprot); + oprot->writeMessageEnd(); + bytes = oprot->getTransport()->writeEnd(); + oprot->getTransport()->flush(); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->postWrite(ctx, "ThriftHiveMetastore.exchange_partition", bytes); + } +} + void ThriftHiveMetastoreProcessor::process_get_partition_with_auth(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext) { void* ctx = NULL; Index: metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h =================================================================== --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h (revision 1471261) +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h (working copy) @@ -51,6 +51,7 @@ virtual bool drop_partition_by_name(const std::string& db_name, const std::string& tbl_name, const std::string& part_name, const bool deleteData) = 0; virtual bool drop_partition_by_name_with_environment_context(const std::string& db_name, const std::string& tbl_name, const std::string& part_name, const bool deleteData, const EnvironmentContext& environment_context) = 0; virtual void get_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals) = 0; + virtual void exchange_partition(Partition& _return, const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) = 0; virtual void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const std::string& user_name, const std::vector & group_names) = 0; virtual void get_partition_by_name(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::string& part_name) = 0; virtual void get_partitions(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts) = 0; @@ -238,6 +239,9 @@ void get_partition(Partition& /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const std::vector & /* part_vals */) { return; } + void exchange_partition(Partition& /* _return */, const std::map & /* partitionSpecs */, const std::string& /* source_db */, const std::string& /* source_table_name */, const std::string& /* dest_db */, const std::string& /* dest_table_name */) { + return; + } void get_partition_with_auth(Partition& /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const std::vector & /* part_vals */, const std::string& /* user_name */, const std::vector & /* group_names */) { return; } @@ -5330,6 +5334,190 @@ }; +typedef struct _ThriftHiveMetastore_exchange_partition_args__isset { + _ThriftHiveMetastore_exchange_partition_args__isset() : partitionSpecs(false), source_db(false), source_table_name(false), dest_db(false), dest_table_name(false) {} + bool partitionSpecs; + bool source_db; + bool source_table_name; + bool dest_db; + bool dest_table_name; +} _ThriftHiveMetastore_exchange_partition_args__isset; + +class ThriftHiveMetastore_exchange_partition_args { + public: + + ThriftHiveMetastore_exchange_partition_args() : source_db(), source_table_name(), dest_db(), dest_table_name() { + } + + virtual ~ThriftHiveMetastore_exchange_partition_args() throw() {} + + std::map partitionSpecs; + std::string source_db; + std::string source_table_name; + std::string dest_db; + std::string dest_table_name; + + _ThriftHiveMetastore_exchange_partition_args__isset __isset; + + void __set_partitionSpecs(const std::map & val) { + partitionSpecs = val; + } + + void __set_source_db(const std::string& val) { + source_db = val; + } + + void __set_source_table_name(const std::string& val) { + source_table_name = val; + } + + void __set_dest_db(const std::string& val) { + dest_db = val; + } + + void __set_dest_table_name(const std::string& val) { + dest_table_name = val; + } + + bool operator == (const ThriftHiveMetastore_exchange_partition_args & rhs) const + { + if (!(partitionSpecs == rhs.partitionSpecs)) + return false; + if (!(source_db == rhs.source_db)) + return false; + if (!(source_table_name == rhs.source_table_name)) + return false; + if (!(dest_db == rhs.dest_db)) + return false; + if (!(dest_table_name == rhs.dest_table_name)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_exchange_partition_args &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_exchange_partition_args & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + + +class ThriftHiveMetastore_exchange_partition_pargs { + public: + + + virtual ~ThriftHiveMetastore_exchange_partition_pargs() throw() {} + + const std::map * partitionSpecs; + const std::string* source_db; + const std::string* source_table_name; + const std::string* dest_db; + const std::string* dest_table_name; + + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_exchange_partition_result__isset { + _ThriftHiveMetastore_exchange_partition_result__isset() : success(false), o1(false), o2(false), o3(false), o4(false) {} + bool success; + bool o1; + bool o2; + bool o3; + bool o4; +} _ThriftHiveMetastore_exchange_partition_result__isset; + +class ThriftHiveMetastore_exchange_partition_result { + public: + + ThriftHiveMetastore_exchange_partition_result() { + } + + virtual ~ThriftHiveMetastore_exchange_partition_result() throw() {} + + Partition success; + MetaException o1; + NoSuchObjectException o2; + InvalidObjectException o3; + InvalidInputException o4; + + _ThriftHiveMetastore_exchange_partition_result__isset __isset; + + void __set_success(const Partition& val) { + success = val; + } + + void __set_o1(const MetaException& val) { + o1 = val; + } + + void __set_o2(const NoSuchObjectException& val) { + o2 = val; + } + + void __set_o3(const InvalidObjectException& val) { + o3 = val; + } + + void __set_o4(const InvalidInputException& val) { + o4 = val; + } + + bool operator == (const ThriftHiveMetastore_exchange_partition_result & rhs) const + { + if (!(success == rhs.success)) + return false; + if (!(o1 == rhs.o1)) + return false; + if (!(o2 == rhs.o2)) + return false; + if (!(o3 == rhs.o3)) + return false; + if (!(o4 == rhs.o4)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_exchange_partition_result &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_exchange_partition_result & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_exchange_partition_presult__isset { + _ThriftHiveMetastore_exchange_partition_presult__isset() : success(false), o1(false), o2(false), o3(false), o4(false) {} + bool success; + bool o1; + bool o2; + bool o3; + bool o4; +} _ThriftHiveMetastore_exchange_partition_presult__isset; + +class ThriftHiveMetastore_exchange_partition_presult { + public: + + + virtual ~ThriftHiveMetastore_exchange_partition_presult() throw() {} + + Partition* success; + MetaException o1; + NoSuchObjectException o2; + InvalidObjectException o3; + InvalidInputException o4; + + _ThriftHiveMetastore_exchange_partition_presult__isset __isset; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + +}; + typedef struct _ThriftHiveMetastore_get_partition_with_auth_args__isset { _ThriftHiveMetastore_get_partition_with_auth_args__isset() : db_name(false), tbl_name(false), part_vals(false), user_name(false), group_names(false) {} bool db_name; @@ -12026,6 +12214,9 @@ void get_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals); void send_get_partition(const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals); void recv_get_partition(Partition& _return); + void exchange_partition(Partition& _return, const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name); + void send_exchange_partition(const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name); + void recv_exchange_partition(Partition& _return); void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const std::string& user_name, const std::vector & group_names); void send_get_partition_with_auth(const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const std::string& user_name, const std::vector & group_names); void recv_get_partition_with_auth(Partition& _return); @@ -12209,6 +12400,7 @@ void process_drop_partition_by_name(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_drop_partition_by_name_with_environment_context(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); + void process_exchange_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partition_with_auth(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partition_by_name(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partitions(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); @@ -12294,6 +12486,7 @@ processMap_["drop_partition_by_name"] = &ThriftHiveMetastoreProcessor::process_drop_partition_by_name; processMap_["drop_partition_by_name_with_environment_context"] = &ThriftHiveMetastoreProcessor::process_drop_partition_by_name_with_environment_context; processMap_["get_partition"] = &ThriftHiveMetastoreProcessor::process_get_partition; + processMap_["exchange_partition"] = &ThriftHiveMetastoreProcessor::process_exchange_partition; processMap_["get_partition_with_auth"] = &ThriftHiveMetastoreProcessor::process_get_partition_with_auth; processMap_["get_partition_by_name"] = &ThriftHiveMetastoreProcessor::process_get_partition_by_name; processMap_["get_partitions"] = &ThriftHiveMetastoreProcessor::process_get_partitions; @@ -12707,6 +12900,16 @@ return; } + void exchange_partition(Partition& _return, const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) { + size_t sz = ifaces_.size(); + size_t i = 0; + for (; i < (sz - 1); ++i) { + ifaces_[i]->exchange_partition(_return, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name); + } + ifaces_[i]->exchange_partition(_return, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name); + return; + } + void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const std::string& user_name, const std::vector & group_names) { size_t sz = ifaces_.size(); size_t i = 0; Index: metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp =================================================================== --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp (revision 1471261) +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp (working copy) @@ -197,6 +197,11 @@ printf("get_partition\n"); } + void exchange_partition(Partition& _return, const std::map & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) { + // Your implementation goes here + printf("exchange_partition\n"); + } + void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const std::string& user_name, const std::vector & group_names) { // Your implementation goes here printf("get_partition_with_auth\n"); Index: metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb =================================================================== --- metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb (revision 1471261) +++ metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb (working copy) @@ -611,6 +611,25 @@ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'get_partition failed: unknown result') end + def exchange_partition(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name) + send_exchange_partition(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name) + return recv_exchange_partition() + end + + def send_exchange_partition(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name) + send_message('exchange_partition', Exchange_partition_args, :partitionSpecs => partitionSpecs, :source_db => source_db, :source_table_name => source_table_name, :dest_db => dest_db, :dest_table_name => dest_table_name) + end + + def recv_exchange_partition() + result = receive_message(Exchange_partition_result) + return result.success unless result.success.nil? + raise result.o1 unless result.o1.nil? + raise result.o2 unless result.o2.nil? + raise result.o3 unless result.o3.nil? + raise result.o4 unless result.o4.nil? + raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'exchange_partition failed: unknown result') + end + def get_partition_with_auth(db_name, tbl_name, part_vals, user_name, group_names) send_get_partition_with_auth(db_name, tbl_name, part_vals, user_name, group_names) return recv_get_partition_with_auth() @@ -1873,6 +1892,23 @@ write_result(result, oprot, 'get_partition', seqid) end + def process_exchange_partition(seqid, iprot, oprot) + args = read_args(iprot, Exchange_partition_args) + result = Exchange_partition_result.new() + begin + result.success = @handler.exchange_partition(args.partitionSpecs, args.source_db, args.source_table_name, args.dest_db, args.dest_table_name) + rescue ::MetaException => o1 + result.o1 = o1 + rescue ::NoSuchObjectException => o2 + result.o2 = o2 + rescue ::InvalidObjectException => o3 + result.o3 = o3 + rescue ::InvalidInputException => o4 + result.o4 = o4 + end + write_result(result, oprot, 'exchange_partition', seqid) + end + def process_get_partition_with_auth(seqid, iprot, oprot) args = read_args(iprot, Get_partition_with_auth_args) result = Get_partition_with_auth_result.new() @@ -3840,6 +3876,54 @@ ::Thrift::Struct.generate_accessors self end + class Exchange_partition_args + include ::Thrift::Struct, ::Thrift::Struct_Union + PARTITIONSPECS = 1 + SOURCE_DB = 2 + SOURCE_TABLE_NAME = 3 + DEST_DB = 4 + DEST_TABLE_NAME = 5 + + FIELDS = { + PARTITIONSPECS => {:type => ::Thrift::Types::MAP, :name => 'partitionSpecs', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}, + SOURCE_DB => {:type => ::Thrift::Types::STRING, :name => 'source_db'}, + SOURCE_TABLE_NAME => {:type => ::Thrift::Types::STRING, :name => 'source_table_name'}, + DEST_DB => {:type => ::Thrift::Types::STRING, :name => 'dest_db'}, + DEST_TABLE_NAME => {:type => ::Thrift::Types::STRING, :name => 'dest_table_name'} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + + class Exchange_partition_result + include ::Thrift::Struct, ::Thrift::Struct_Union + SUCCESS = 0 + O1 = 1 + O2 = 2 + O3 = 3 + O4 = 4 + + FIELDS = { + SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => ::Partition}, + O1 => {:type => ::Thrift::Types::STRUCT, :name => 'o1', :class => ::MetaException}, + O2 => {:type => ::Thrift::Types::STRUCT, :name => 'o2', :class => ::NoSuchObjectException}, + O3 => {:type => ::Thrift::Types::STRUCT, :name => 'o3', :class => ::InvalidObjectException}, + O4 => {:type => ::Thrift::Types::STRUCT, :name => 'o4', :class => ::InvalidInputException} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + class Get_partition_with_auth_args include ::Thrift::Struct, ::Thrift::Struct_Union DB_NAME = 1 Index: metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php =================================================================== --- metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php (revision 1471261) +++ metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php (working copy) @@ -51,6 +51,7 @@ public function drop_partition_by_name($db_name, $tbl_name, $part_name, $deleteData); public function drop_partition_by_name_with_environment_context($db_name, $tbl_name, $part_name, $deleteData, \metastore\EnvironmentContext $environment_context); public function get_partition($db_name, $tbl_name, $part_vals); + public function exchange_partition($partitionSpecs, $source_db, $source_table_name, $dest_db, $dest_table_name); public function get_partition_with_auth($db_name, $tbl_name, $part_vals, $user_name, $group_names); public function get_partition_by_name($db_name, $tbl_name, $part_name); public function get_partitions($db_name, $tbl_name, $max_parts); @@ -2158,6 +2159,73 @@ throw new \Exception("get_partition failed: unknown result"); } + public function exchange_partition($partitionSpecs, $source_db, $source_table_name, $dest_db, $dest_table_name) + { + $this->send_exchange_partition($partitionSpecs, $source_db, $source_table_name, $dest_db, $dest_table_name); + return $this->recv_exchange_partition(); + } + + public function send_exchange_partition($partitionSpecs, $source_db, $source_table_name, $dest_db, $dest_table_name) + { + $args = new \metastore\ThriftHiveMetastore_exchange_partition_args(); + $args->partitionSpecs = $partitionSpecs; + $args->source_db = $source_db; + $args->source_table_name = $source_table_name; + $args->dest_db = $dest_db; + $args->dest_table_name = $dest_table_name; + $bin_accel = ($this->output_ instanceof TProtocol::$TBINARYPROTOCOLACCELERATED) && function_exists('thrift_protocol_write_binary'); + if ($bin_accel) + { + thrift_protocol_write_binary($this->output_, 'exchange_partition', TMessageType::CALL, $args, $this->seqid_, $this->output_->isStrictWrite()); + } + else + { + $this->output_->writeMessageBegin('exchange_partition', TMessageType::CALL, $this->seqid_); + $args->write($this->output_); + $this->output_->writeMessageEnd(); + $this->output_->getTransport()->flush(); + } + } + + public function recv_exchange_partition() + { + $bin_accel = ($this->input_ instanceof TProtocol::$TBINARYPROTOCOLACCELERATED) && function_exists('thrift_protocol_read_binary'); + if ($bin_accel) $result = thrift_protocol_read_binary($this->input_, '\metastore\ThriftHiveMetastore_exchange_partition_result', $this->input_->isStrictRead()); + else + { + $rseqid = 0; + $fname = null; + $mtype = 0; + + $this->input_->readMessageBegin($fname, $mtype, $rseqid); + if ($mtype == TMessageType::EXCEPTION) { + $x = new TApplicationException(); + $x->read($this->input_); + $this->input_->readMessageEnd(); + throw $x; + } + $result = new \metastore\ThriftHiveMetastore_exchange_partition_result(); + $result->read($this->input_); + $this->input_->readMessageEnd(); + } + if ($result->success !== null) { + return $result->success; + } + if ($result->o1 !== null) { + throw $result->o1; + } + if ($result->o2 !== null) { + throw $result->o2; + } + if ($result->o3 !== null) { + throw $result->o3; + } + if ($result->o4 !== null) { + throw $result->o4; + } + throw new \Exception("exchange_partition failed: unknown result"); + } + public function get_partition_with_auth($db_name, $tbl_name, $part_vals, $user_name, $group_names) { $this->send_get_partition_with_auth($db_name, $tbl_name, $part_vals, $user_name, $group_names); @@ -13043,6 +13111,357 @@ } +class ThriftHiveMetastore_exchange_partition_args { + static $_TSPEC; + + public $partitionSpecs = null; + public $source_db = null; + public $source_table_name = null; + public $dest_db = null; + public $dest_table_name = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'partitionSpecs', + 'type' => TType::MAP, + 'ktype' => TType::STRING, + 'vtype' => TType::STRING, + 'key' => array( + 'type' => TType::STRING, + ), + 'val' => array( + 'type' => TType::STRING, + ), + ), + 2 => array( + 'var' => 'source_db', + 'type' => TType::STRING, + ), + 3 => array( + 'var' => 'source_table_name', + 'type' => TType::STRING, + ), + 4 => array( + 'var' => 'dest_db', + 'type' => TType::STRING, + ), + 5 => array( + 'var' => 'dest_table_name', + 'type' => TType::STRING, + ), + ); + } + if (is_array($vals)) { + if (isset($vals['partitionSpecs'])) { + $this->partitionSpecs = $vals['partitionSpecs']; + } + if (isset($vals['source_db'])) { + $this->source_db = $vals['source_db']; + } + if (isset($vals['source_table_name'])) { + $this->source_table_name = $vals['source_table_name']; + } + if (isset($vals['dest_db'])) { + $this->dest_db = $vals['dest_db']; + } + if (isset($vals['dest_table_name'])) { + $this->dest_table_name = $vals['dest_table_name']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_exchange_partition_args'; + } + + public function read($input) + { + $xfer = 0; + $fname = null; + $ftype = 0; + $fid = 0; + $xfer += $input->readStructBegin($fname); + while (true) + { + $xfer += $input->readFieldBegin($fname, $ftype, $fid); + if ($ftype == TType::STOP) { + break; + } + switch ($fid) + { + case 1: + if ($ftype == TType::MAP) { + $this->partitionSpecs = array(); + $_size341 = 0; + $_ktype342 = 0; + $_vtype343 = 0; + $xfer += $input->readMapBegin($_ktype342, $_vtype343, $_size341); + for ($_i345 = 0; $_i345 < $_size341; ++$_i345) + { + $key346 = ''; + $val347 = ''; + $xfer += $input->readString($key346); + $xfer += $input->readString($val347); + $this->partitionSpecs[$key346] = $val347; + } + $xfer += $input->readMapEnd(); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->source_db); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->source_table_name); + } else { + $xfer += $input->skip($ftype); + } + break; + case 4: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->dest_db); + } else { + $xfer += $input->skip($ftype); + } + break; + case 5: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->dest_table_name); + } else { + $xfer += $input->skip($ftype); + } + break; + default: + $xfer += $input->skip($ftype); + break; + } + $xfer += $input->readFieldEnd(); + } + $xfer += $input->readStructEnd(); + return $xfer; + } + + public function write($output) { + $xfer = 0; + $xfer += $output->writeStructBegin('ThriftHiveMetastore_exchange_partition_args'); + if ($this->partitionSpecs !== null) { + if (!is_array($this->partitionSpecs)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('partitionSpecs', TType::MAP, 1); + { + $output->writeMapBegin(TType::STRING, TType::STRING, count($this->partitionSpecs)); + { + foreach ($this->partitionSpecs as $kiter348 => $viter349) + { + $xfer += $output->writeString($kiter348); + $xfer += $output->writeString($viter349); + } + } + $output->writeMapEnd(); + } + $xfer += $output->writeFieldEnd(); + } + if ($this->source_db !== null) { + $xfer += $output->writeFieldBegin('source_db', TType::STRING, 2); + $xfer += $output->writeString($this->source_db); + $xfer += $output->writeFieldEnd(); + } + if ($this->source_table_name !== null) { + $xfer += $output->writeFieldBegin('source_table_name', TType::STRING, 3); + $xfer += $output->writeString($this->source_table_name); + $xfer += $output->writeFieldEnd(); + } + if ($this->dest_db !== null) { + $xfer += $output->writeFieldBegin('dest_db', TType::STRING, 4); + $xfer += $output->writeString($this->dest_db); + $xfer += $output->writeFieldEnd(); + } + if ($this->dest_table_name !== null) { + $xfer += $output->writeFieldBegin('dest_table_name', TType::STRING, 5); + $xfer += $output->writeString($this->dest_table_name); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class ThriftHiveMetastore_exchange_partition_result { + static $_TSPEC; + + public $success = null; + public $o1 = null; + public $o2 = null; + public $o3 = null; + public $o4 = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 0 => array( + 'var' => 'success', + 'type' => TType::STRUCT, + 'class' => '\metastore\Partition', + ), + 1 => array( + 'var' => 'o1', + 'type' => TType::STRUCT, + 'class' => '\metastore\MetaException', + ), + 2 => array( + 'var' => 'o2', + 'type' => TType::STRUCT, + 'class' => '\metastore\NoSuchObjectException', + ), + 3 => array( + 'var' => 'o3', + 'type' => TType::STRUCT, + 'class' => '\metastore\InvalidObjectException', + ), + 4 => array( + 'var' => 'o4', + 'type' => TType::STRUCT, + 'class' => '\metastore\InvalidInputException', + ), + ); + } + if (is_array($vals)) { + if (isset($vals['success'])) { + $this->success = $vals['success']; + } + if (isset($vals['o1'])) { + $this->o1 = $vals['o1']; + } + if (isset($vals['o2'])) { + $this->o2 = $vals['o2']; + } + if (isset($vals['o3'])) { + $this->o3 = $vals['o3']; + } + if (isset($vals['o4'])) { + $this->o4 = $vals['o4']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_exchange_partition_result'; + } + + public function read($input) + { + $xfer = 0; + $fname = null; + $ftype = 0; + $fid = 0; + $xfer += $input->readStructBegin($fname); + while (true) + { + $xfer += $input->readFieldBegin($fname, $ftype, $fid); + if ($ftype == TType::STOP) { + break; + } + switch ($fid) + { + case 0: + if ($ftype == TType::STRUCT) { + $this->success = new \metastore\Partition(); + $xfer += $this->success->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 1: + if ($ftype == TType::STRUCT) { + $this->o1 = new \metastore\MetaException(); + $xfer += $this->o1->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRUCT) { + $this->o2 = new \metastore\NoSuchObjectException(); + $xfer += $this->o2->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::STRUCT) { + $this->o3 = new \metastore\InvalidObjectException(); + $xfer += $this->o3->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 4: + if ($ftype == TType::STRUCT) { + $this->o4 = new \metastore\InvalidInputException(); + $xfer += $this->o4->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + default: + $xfer += $input->skip($ftype); + break; + } + $xfer += $input->readFieldEnd(); + } + $xfer += $input->readStructEnd(); + return $xfer; + } + + public function write($output) { + $xfer = 0; + $xfer += $output->writeStructBegin('ThriftHiveMetastore_exchange_partition_result'); + if ($this->success !== null) { + if (!is_object($this->success)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('success', TType::STRUCT, 0); + $xfer += $this->success->write($output); + $xfer += $output->writeFieldEnd(); + } + if ($this->o1 !== null) { + $xfer += $output->writeFieldBegin('o1', TType::STRUCT, 1); + $xfer += $this->o1->write($output); + $xfer += $output->writeFieldEnd(); + } + if ($this->o2 !== null) { + $xfer += $output->writeFieldBegin('o2', TType::STRUCT, 2); + $xfer += $this->o2->write($output); + $xfer += $output->writeFieldEnd(); + } + if ($this->o3 !== null) { + $xfer += $output->writeFieldBegin('o3', TType::STRUCT, 3); + $xfer += $this->o3->write($output); + $xfer += $output->writeFieldEnd(); + } + if ($this->o4 !== null) { + $xfer += $output->writeFieldBegin('o4', TType::STRUCT, 4); + $xfer += $this->o4->write($output); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class ThriftHiveMetastore_get_partition_with_auth_args { static $_TSPEC; @@ -13140,14 +13559,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size341 = 0; - $_etype344 = 0; - $xfer += $input->readListBegin($_etype344, $_size341); - for ($_i345 = 0; $_i345 < $_size341; ++$_i345) + $_size350 = 0; + $_etype353 = 0; + $xfer += $input->readListBegin($_etype353, $_size350); + for ($_i354 = 0; $_i354 < $_size350; ++$_i354) { - $elem346 = null; - $xfer += $input->readString($elem346); - $this->part_vals []= $elem346; + $elem355 = null; + $xfer += $input->readString($elem355); + $this->part_vals []= $elem355; } $xfer += $input->readListEnd(); } else { @@ -13164,14 +13583,14 @@ case 5: if ($ftype == TType::LST) { $this->group_names = array(); - $_size347 = 0; - $_etype350 = 0; - $xfer += $input->readListBegin($_etype350, $_size347); - for ($_i351 = 0; $_i351 < $_size347; ++$_i351) + $_size356 = 0; + $_etype359 = 0; + $xfer += $input->readListBegin($_etype359, $_size356); + for ($_i360 = 0; $_i360 < $_size356; ++$_i360) { - $elem352 = null; - $xfer += $input->readString($elem352); - $this->group_names []= $elem352; + $elem361 = null; + $xfer += $input->readString($elem361); + $this->group_names []= $elem361; } $xfer += $input->readListEnd(); } else { @@ -13209,9 +13628,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter353) + foreach ($this->part_vals as $iter362) { - $xfer += $output->writeString($iter353); + $xfer += $output->writeString($iter362); } } $output->writeListEnd(); @@ -13231,9 +13650,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter354) + foreach ($this->group_names as $iter363) { - $xfer += $output->writeString($iter354); + $xfer += $output->writeString($iter363); } } $output->writeListEnd(); @@ -13779,15 +14198,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size355 = 0; - $_etype358 = 0; - $xfer += $input->readListBegin($_etype358, $_size355); - for ($_i359 = 0; $_i359 < $_size355; ++$_i359) + $_size364 = 0; + $_etype367 = 0; + $xfer += $input->readListBegin($_etype367, $_size364); + for ($_i368 = 0; $_i368 < $_size364; ++$_i368) { - $elem360 = null; - $elem360 = new \metastore\Partition(); - $xfer += $elem360->read($input); - $this->success []= $elem360; + $elem369 = null; + $elem369 = new \metastore\Partition(); + $xfer += $elem369->read($input); + $this->success []= $elem369; } $xfer += $input->readListEnd(); } else { @@ -13831,9 +14250,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter361) + foreach ($this->success as $iter370) { - $xfer += $iter361->write($output); + $xfer += $iter370->write($output); } } $output->writeListEnd(); @@ -13964,14 +14383,14 @@ case 5: if ($ftype == TType::LST) { $this->group_names = array(); - $_size362 = 0; - $_etype365 = 0; - $xfer += $input->readListBegin($_etype365, $_size362); - for ($_i366 = 0; $_i366 < $_size362; ++$_i366) + $_size371 = 0; + $_etype374 = 0; + $xfer += $input->readListBegin($_etype374, $_size371); + for ($_i375 = 0; $_i375 < $_size371; ++$_i375) { - $elem367 = null; - $xfer += $input->readString($elem367); - $this->group_names []= $elem367; + $elem376 = null; + $xfer += $input->readString($elem376); + $this->group_names []= $elem376; } $xfer += $input->readListEnd(); } else { @@ -14019,9 +14438,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter368) + foreach ($this->group_names as $iter377) { - $xfer += $output->writeString($iter368); + $xfer += $output->writeString($iter377); } } $output->writeListEnd(); @@ -14101,15 +14520,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size369 = 0; - $_etype372 = 0; - $xfer += $input->readListBegin($_etype372, $_size369); - for ($_i373 = 0; $_i373 < $_size369; ++$_i373) + $_size378 = 0; + $_etype381 = 0; + $xfer += $input->readListBegin($_etype381, $_size378); + for ($_i382 = 0; $_i382 < $_size378; ++$_i382) { - $elem374 = null; - $elem374 = new \metastore\Partition(); - $xfer += $elem374->read($input); - $this->success []= $elem374; + $elem383 = null; + $elem383 = new \metastore\Partition(); + $xfer += $elem383->read($input); + $this->success []= $elem383; } $xfer += $input->readListEnd(); } else { @@ -14153,9 +14572,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter375) + foreach ($this->success as $iter384) { - $xfer += $iter375->write($output); + $xfer += $iter384->write($output); } } $output->writeListEnd(); @@ -14347,14 +14766,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size376 = 0; - $_etype379 = 0; - $xfer += $input->readListBegin($_etype379, $_size376); - for ($_i380 = 0; $_i380 < $_size376; ++$_i380) + $_size385 = 0; + $_etype388 = 0; + $xfer += $input->readListBegin($_etype388, $_size385); + for ($_i389 = 0; $_i389 < $_size385; ++$_i389) { - $elem381 = null; - $xfer += $input->readString($elem381); - $this->success []= $elem381; + $elem390 = null; + $xfer += $input->readString($elem390); + $this->success []= $elem390; } $xfer += $input->readListEnd(); } else { @@ -14390,9 +14809,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter382) + foreach ($this->success as $iter391) { - $xfer += $output->writeString($iter382); + $xfer += $output->writeString($iter391); } } $output->writeListEnd(); @@ -14496,14 +14915,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size383 = 0; - $_etype386 = 0; - $xfer += $input->readListBegin($_etype386, $_size383); - for ($_i387 = 0; $_i387 < $_size383; ++$_i387) + $_size392 = 0; + $_etype395 = 0; + $xfer += $input->readListBegin($_etype395, $_size392); + for ($_i396 = 0; $_i396 < $_size392; ++$_i396) { - $elem388 = null; - $xfer += $input->readString($elem388); - $this->part_vals []= $elem388; + $elem397 = null; + $xfer += $input->readString($elem397); + $this->part_vals []= $elem397; } $xfer += $input->readListEnd(); } else { @@ -14548,9 +14967,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter389) + foreach ($this->part_vals as $iter398) { - $xfer += $output->writeString($iter389); + $xfer += $output->writeString($iter398); } } $output->writeListEnd(); @@ -14635,15 +15054,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size390 = 0; - $_etype393 = 0; - $xfer += $input->readListBegin($_etype393, $_size390); - for ($_i394 = 0; $_i394 < $_size390; ++$_i394) + $_size399 = 0; + $_etype402 = 0; + $xfer += $input->readListBegin($_etype402, $_size399); + for ($_i403 = 0; $_i403 < $_size399; ++$_i403) { - $elem395 = null; - $elem395 = new \metastore\Partition(); - $xfer += $elem395->read($input); - $this->success []= $elem395; + $elem404 = null; + $elem404 = new \metastore\Partition(); + $xfer += $elem404->read($input); + $this->success []= $elem404; } $xfer += $input->readListEnd(); } else { @@ -14687,9 +15106,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter396) + foreach ($this->success as $iter405) { - $xfer += $iter396->write($output); + $xfer += $iter405->write($output); } } $output->writeListEnd(); @@ -14818,14 +15237,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size397 = 0; - $_etype400 = 0; - $xfer += $input->readListBegin($_etype400, $_size397); - for ($_i401 = 0; $_i401 < $_size397; ++$_i401) + $_size406 = 0; + $_etype409 = 0; + $xfer += $input->readListBegin($_etype409, $_size406); + for ($_i410 = 0; $_i410 < $_size406; ++$_i410) { - $elem402 = null; - $xfer += $input->readString($elem402); - $this->part_vals []= $elem402; + $elem411 = null; + $xfer += $input->readString($elem411); + $this->part_vals []= $elem411; } $xfer += $input->readListEnd(); } else { @@ -14849,14 +15268,14 @@ case 6: if ($ftype == TType::LST) { $this->group_names = array(); - $_size403 = 0; - $_etype406 = 0; - $xfer += $input->readListBegin($_etype406, $_size403); - for ($_i407 = 0; $_i407 < $_size403; ++$_i407) + $_size412 = 0; + $_etype415 = 0; + $xfer += $input->readListBegin($_etype415, $_size412); + for ($_i416 = 0; $_i416 < $_size412; ++$_i416) { - $elem408 = null; - $xfer += $input->readString($elem408); - $this->group_names []= $elem408; + $elem417 = null; + $xfer += $input->readString($elem417); + $this->group_names []= $elem417; } $xfer += $input->readListEnd(); } else { @@ -14894,9 +15313,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter409) + foreach ($this->part_vals as $iter418) { - $xfer += $output->writeString($iter409); + $xfer += $output->writeString($iter418); } } $output->writeListEnd(); @@ -14921,9 +15340,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter410) + foreach ($this->group_names as $iter419) { - $xfer += $output->writeString($iter410); + $xfer += $output->writeString($iter419); } } $output->writeListEnd(); @@ -15003,15 +15422,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size411 = 0; - $_etype414 = 0; - $xfer += $input->readListBegin($_etype414, $_size411); - for ($_i415 = 0; $_i415 < $_size411; ++$_i415) + $_size420 = 0; + $_etype423 = 0; + $xfer += $input->readListBegin($_etype423, $_size420); + for ($_i424 = 0; $_i424 < $_size420; ++$_i424) { - $elem416 = null; - $elem416 = new \metastore\Partition(); - $xfer += $elem416->read($input); - $this->success []= $elem416; + $elem425 = null; + $elem425 = new \metastore\Partition(); + $xfer += $elem425->read($input); + $this->success []= $elem425; } $xfer += $input->readListEnd(); } else { @@ -15055,9 +15474,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter417) + foreach ($this->success as $iter426) { - $xfer += $iter417->write($output); + $xfer += $iter426->write($output); } } $output->writeListEnd(); @@ -15166,14 +15585,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size418 = 0; - $_etype421 = 0; - $xfer += $input->readListBegin($_etype421, $_size418); - for ($_i422 = 0; $_i422 < $_size418; ++$_i422) + $_size427 = 0; + $_etype430 = 0; + $xfer += $input->readListBegin($_etype430, $_size427); + for ($_i431 = 0; $_i431 < $_size427; ++$_i431) { - $elem423 = null; - $xfer += $input->readString($elem423); - $this->part_vals []= $elem423; + $elem432 = null; + $xfer += $input->readString($elem432); + $this->part_vals []= $elem432; } $xfer += $input->readListEnd(); } else { @@ -15218,9 +15637,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter424) + foreach ($this->part_vals as $iter433) { - $xfer += $output->writeString($iter424); + $xfer += $output->writeString($iter433); } } $output->writeListEnd(); @@ -15304,14 +15723,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size425 = 0; - $_etype428 = 0; - $xfer += $input->readListBegin($_etype428, $_size425); - for ($_i429 = 0; $_i429 < $_size425; ++$_i429) + $_size434 = 0; + $_etype437 = 0; + $xfer += $input->readListBegin($_etype437, $_size434); + for ($_i438 = 0; $_i438 < $_size434; ++$_i438) { - $elem430 = null; - $xfer += $input->readString($elem430); - $this->success []= $elem430; + $elem439 = null; + $xfer += $input->readString($elem439); + $this->success []= $elem439; } $xfer += $input->readListEnd(); } else { @@ -15355,9 +15774,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter431) + foreach ($this->success as $iter440) { - $xfer += $output->writeString($iter431); + $xfer += $output->writeString($iter440); } } $output->writeListEnd(); @@ -15579,15 +15998,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size432 = 0; - $_etype435 = 0; - $xfer += $input->readListBegin($_etype435, $_size432); - for ($_i436 = 0; $_i436 < $_size432; ++$_i436) + $_size441 = 0; + $_etype444 = 0; + $xfer += $input->readListBegin($_etype444, $_size441); + for ($_i445 = 0; $_i445 < $_size441; ++$_i445) { - $elem437 = null; - $elem437 = new \metastore\Partition(); - $xfer += $elem437->read($input); - $this->success []= $elem437; + $elem446 = null; + $elem446 = new \metastore\Partition(); + $xfer += $elem446->read($input); + $this->success []= $elem446; } $xfer += $input->readListEnd(); } else { @@ -15631,9 +16050,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter438) + foreach ($this->success as $iter447) { - $xfer += $iter438->write($output); + $xfer += $iter447->write($output); } } $output->writeListEnd(); @@ -15734,14 +16153,14 @@ case 3: if ($ftype == TType::LST) { $this->names = array(); - $_size439 = 0; - $_etype442 = 0; - $xfer += $input->readListBegin($_etype442, $_size439); - for ($_i443 = 0; $_i443 < $_size439; ++$_i443) + $_size448 = 0; + $_etype451 = 0; + $xfer += $input->readListBegin($_etype451, $_size448); + for ($_i452 = 0; $_i452 < $_size448; ++$_i452) { - $elem444 = null; - $xfer += $input->readString($elem444); - $this->names []= $elem444; + $elem453 = null; + $xfer += $input->readString($elem453); + $this->names []= $elem453; } $xfer += $input->readListEnd(); } else { @@ -15779,9 +16198,9 @@ { $output->writeListBegin(TType::STRING, count($this->names)); { - foreach ($this->names as $iter445) + foreach ($this->names as $iter454) { - $xfer += $output->writeString($iter445); + $xfer += $output->writeString($iter454); } } $output->writeListEnd(); @@ -15861,15 +16280,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size446 = 0; - $_etype449 = 0; - $xfer += $input->readListBegin($_etype449, $_size446); - for ($_i450 = 0; $_i450 < $_size446; ++$_i450) + $_size455 = 0; + $_etype458 = 0; + $xfer += $input->readListBegin($_etype458, $_size455); + for ($_i459 = 0; $_i459 < $_size455; ++$_i459) { - $elem451 = null; - $elem451 = new \metastore\Partition(); - $xfer += $elem451->read($input); - $this->success []= $elem451; + $elem460 = null; + $elem460 = new \metastore\Partition(); + $xfer += $elem460->read($input); + $this->success []= $elem460; } $xfer += $input->readListEnd(); } else { @@ -15913,9 +16332,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter452) + foreach ($this->success as $iter461) { - $xfer += $iter452->write($output); + $xfer += $iter461->write($output); } } $output->writeListEnd(); @@ -16230,15 +16649,15 @@ case 3: if ($ftype == TType::LST) { $this->new_parts = array(); - $_size453 = 0; - $_etype456 = 0; - $xfer += $input->readListBegin($_etype456, $_size453); - for ($_i457 = 0; $_i457 < $_size453; ++$_i457) + $_size462 = 0; + $_etype465 = 0; + $xfer += $input->readListBegin($_etype465, $_size462); + for ($_i466 = 0; $_i466 < $_size462; ++$_i466) { - $elem458 = null; - $elem458 = new \metastore\Partition(); - $xfer += $elem458->read($input); - $this->new_parts []= $elem458; + $elem467 = null; + $elem467 = new \metastore\Partition(); + $xfer += $elem467->read($input); + $this->new_parts []= $elem467; } $xfer += $input->readListEnd(); } else { @@ -16276,9 +16695,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->new_parts)); { - foreach ($this->new_parts as $iter459) + foreach ($this->new_parts as $iter468) { - $xfer += $iter459->write($output); + $xfer += $iter468->write($output); } } $output->writeListEnd(); @@ -16712,14 +17131,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size460 = 0; - $_etype463 = 0; - $xfer += $input->readListBegin($_etype463, $_size460); - for ($_i464 = 0; $_i464 < $_size460; ++$_i464) + $_size469 = 0; + $_etype472 = 0; + $xfer += $input->readListBegin($_etype472, $_size469); + for ($_i473 = 0; $_i473 < $_size469; ++$_i473) { - $elem465 = null; - $xfer += $input->readString($elem465); - $this->part_vals []= $elem465; + $elem474 = null; + $xfer += $input->readString($elem474); + $this->part_vals []= $elem474; } $xfer += $input->readListEnd(); } else { @@ -16765,9 +17184,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter466) + foreach ($this->part_vals as $iter475) { - $xfer += $output->writeString($iter466); + $xfer += $output->writeString($iter475); } } $output->writeListEnd(); @@ -16940,14 +17359,14 @@ case 1: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size467 = 0; - $_etype470 = 0; - $xfer += $input->readListBegin($_etype470, $_size467); - for ($_i471 = 0; $_i471 < $_size467; ++$_i471) + $_size476 = 0; + $_etype479 = 0; + $xfer += $input->readListBegin($_etype479, $_size476); + for ($_i480 = 0; $_i480 < $_size476; ++$_i480) { - $elem472 = null; - $xfer += $input->readString($elem472); - $this->part_vals []= $elem472; + $elem481 = null; + $xfer += $input->readString($elem481); + $this->part_vals []= $elem481; } $xfer += $input->readListEnd(); } else { @@ -16982,9 +17401,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter473) + foreach ($this->part_vals as $iter482) { - $xfer += $output->writeString($iter473); + $xfer += $output->writeString($iter482); } } $output->writeListEnd(); @@ -17411,14 +17830,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size474 = 0; - $_etype477 = 0; - $xfer += $input->readListBegin($_etype477, $_size474); - for ($_i478 = 0; $_i478 < $_size474; ++$_i478) + $_size483 = 0; + $_etype486 = 0; + $xfer += $input->readListBegin($_etype486, $_size483); + for ($_i487 = 0; $_i487 < $_size483; ++$_i487) { - $elem479 = null; - $xfer += $input->readString($elem479); - $this->success []= $elem479; + $elem488 = null; + $xfer += $input->readString($elem488); + $this->success []= $elem488; } $xfer += $input->readListEnd(); } else { @@ -17454,9 +17873,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter480) + foreach ($this->success as $iter489) { - $xfer += $output->writeString($iter480); + $xfer += $output->writeString($iter489); } } $output->writeListEnd(); @@ -17607,17 +18026,17 @@ case 0: if ($ftype == TType::MAP) { $this->success = array(); - $_size481 = 0; - $_ktype482 = 0; - $_vtype483 = 0; - $xfer += $input->readMapBegin($_ktype482, $_vtype483, $_size481); - for ($_i485 = 0; $_i485 < $_size481; ++$_i485) + $_size490 = 0; + $_ktype491 = 0; + $_vtype492 = 0; + $xfer += $input->readMapBegin($_ktype491, $_vtype492, $_size490); + for ($_i494 = 0; $_i494 < $_size490; ++$_i494) { - $key486 = ''; - $val487 = ''; - $xfer += $input->readString($key486); - $xfer += $input->readString($val487); - $this->success[$key486] = $val487; + $key495 = ''; + $val496 = ''; + $xfer += $input->readString($key495); + $xfer += $input->readString($val496); + $this->success[$key495] = $val496; } $xfer += $input->readMapEnd(); } else { @@ -17653,10 +18072,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->success)); { - foreach ($this->success as $kiter488 => $viter489) + foreach ($this->success as $kiter497 => $viter498) { - $xfer += $output->writeString($kiter488); - $xfer += $output->writeString($viter489); + $xfer += $output->writeString($kiter497); + $xfer += $output->writeString($viter498); } } $output->writeMapEnd(); @@ -17764,17 +18183,17 @@ case 3: if ($ftype == TType::MAP) { $this->part_vals = array(); - $_size490 = 0; - $_ktype491 = 0; - $_vtype492 = 0; - $xfer += $input->readMapBegin($_ktype491, $_vtype492, $_size490); - for ($_i494 = 0; $_i494 < $_size490; ++$_i494) + $_size499 = 0; + $_ktype500 = 0; + $_vtype501 = 0; + $xfer += $input->readMapBegin($_ktype500, $_vtype501, $_size499); + for ($_i503 = 0; $_i503 < $_size499; ++$_i503) { - $key495 = ''; - $val496 = ''; - $xfer += $input->readString($key495); - $xfer += $input->readString($val496); - $this->part_vals[$key495] = $val496; + $key504 = ''; + $val505 = ''; + $xfer += $input->readString($key504); + $xfer += $input->readString($val505); + $this->part_vals[$key504] = $val505; } $xfer += $input->readMapEnd(); } else { @@ -17819,10 +18238,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $kiter497 => $viter498) + foreach ($this->part_vals as $kiter506 => $viter507) { - $xfer += $output->writeString($kiter497); - $xfer += $output->writeString($viter498); + $xfer += $output->writeString($kiter506); + $xfer += $output->writeString($viter507); } } $output->writeMapEnd(); @@ -18114,17 +18533,17 @@ case 3: if ($ftype == TType::MAP) { $this->part_vals = array(); - $_size499 = 0; - $_ktype500 = 0; - $_vtype501 = 0; - $xfer += $input->readMapBegin($_ktype500, $_vtype501, $_size499); - for ($_i503 = 0; $_i503 < $_size499; ++$_i503) + $_size508 = 0; + $_ktype509 = 0; + $_vtype510 = 0; + $xfer += $input->readMapBegin($_ktype509, $_vtype510, $_size508); + for ($_i512 = 0; $_i512 < $_size508; ++$_i512) { - $key504 = ''; - $val505 = ''; - $xfer += $input->readString($key504); - $xfer += $input->readString($val505); - $this->part_vals[$key504] = $val505; + $key513 = ''; + $val514 = ''; + $xfer += $input->readString($key513); + $xfer += $input->readString($val514); + $this->part_vals[$key513] = $val514; } $xfer += $input->readMapEnd(); } else { @@ -18169,10 +18588,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $kiter506 => $viter507) + foreach ($this->part_vals as $kiter515 => $viter516) { - $xfer += $output->writeString($kiter506); - $xfer += $output->writeString($viter507); + $xfer += $output->writeString($kiter515); + $xfer += $output->writeString($viter516); } } $output->writeMapEnd(); @@ -19532,15 +19951,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size508 = 0; - $_etype511 = 0; - $xfer += $input->readListBegin($_etype511, $_size508); - for ($_i512 = 0; $_i512 < $_size508; ++$_i512) + $_size517 = 0; + $_etype520 = 0; + $xfer += $input->readListBegin($_etype520, $_size517); + for ($_i521 = 0; $_i521 < $_size517; ++$_i521) { - $elem513 = null; - $elem513 = new \metastore\Index(); - $xfer += $elem513->read($input); - $this->success []= $elem513; + $elem522 = null; + $elem522 = new \metastore\Index(); + $xfer += $elem522->read($input); + $this->success []= $elem522; } $xfer += $input->readListEnd(); } else { @@ -19584,9 +20003,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter514) + foreach ($this->success as $iter523) { - $xfer += $iter514->write($output); + $xfer += $iter523->write($output); } } $output->writeListEnd(); @@ -19778,14 +20197,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size515 = 0; - $_etype518 = 0; - $xfer += $input->readListBegin($_etype518, $_size515); - for ($_i519 = 0; $_i519 < $_size515; ++$_i519) + $_size524 = 0; + $_etype527 = 0; + $xfer += $input->readListBegin($_etype527, $_size524); + for ($_i528 = 0; $_i528 < $_size524; ++$_i528) { - $elem520 = null; - $xfer += $input->readString($elem520); - $this->success []= $elem520; + $elem529 = null; + $xfer += $input->readString($elem529); + $this->success []= $elem529; } $xfer += $input->readListEnd(); } else { @@ -19821,9 +20240,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter521) + foreach ($this->success as $iter530) { - $xfer += $output->writeString($iter521); + $xfer += $output->writeString($iter530); } } $output->writeListEnd(); @@ -21897,14 +22316,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size522 = 0; - $_etype525 = 0; - $xfer += $input->readListBegin($_etype525, $_size522); - for ($_i526 = 0; $_i526 < $_size522; ++$_i526) + $_size531 = 0; + $_etype534 = 0; + $xfer += $input->readListBegin($_etype534, $_size531); + for ($_i535 = 0; $_i535 < $_size531; ++$_i535) { - $elem527 = null; - $xfer += $input->readString($elem527); - $this->success []= $elem527; + $elem536 = null; + $xfer += $input->readString($elem536); + $this->success []= $elem536; } $xfer += $input->readListEnd(); } else { @@ -21940,9 +22359,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter528) + foreach ($this->success as $iter537) { - $xfer += $output->writeString($iter528); + $xfer += $output->writeString($iter537); } } $output->writeListEnd(); @@ -22582,15 +23001,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size529 = 0; - $_etype532 = 0; - $xfer += $input->readListBegin($_etype532, $_size529); - for ($_i533 = 0; $_i533 < $_size529; ++$_i533) + $_size538 = 0; + $_etype541 = 0; + $xfer += $input->readListBegin($_etype541, $_size538); + for ($_i542 = 0; $_i542 < $_size538; ++$_i542) { - $elem534 = null; - $elem534 = new \metastore\Role(); - $xfer += $elem534->read($input); - $this->success []= $elem534; + $elem543 = null; + $elem543 = new \metastore\Role(); + $xfer += $elem543->read($input); + $this->success []= $elem543; } $xfer += $input->readListEnd(); } else { @@ -22626,9 +23045,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter535) + foreach ($this->success as $iter544) { - $xfer += $iter535->write($output); + $xfer += $iter544->write($output); } } $output->writeListEnd(); @@ -22726,14 +23145,14 @@ case 3: if ($ftype == TType::LST) { $this->group_names = array(); - $_size536 = 0; - $_etype539 = 0; - $xfer += $input->readListBegin($_etype539, $_size536); - for ($_i540 = 0; $_i540 < $_size536; ++$_i540) + $_size545 = 0; + $_etype548 = 0; + $xfer += $input->readListBegin($_etype548, $_size545); + for ($_i549 = 0; $_i549 < $_size545; ++$_i549) { - $elem541 = null; - $xfer += $input->readString($elem541); - $this->group_names []= $elem541; + $elem550 = null; + $xfer += $input->readString($elem550); + $this->group_names []= $elem550; } $xfer += $input->readListEnd(); } else { @@ -22774,9 +23193,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter542) + foreach ($this->group_names as $iter551) { - $xfer += $output->writeString($iter542); + $xfer += $output->writeString($iter551); } } $output->writeListEnd(); @@ -23063,15 +23482,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size543 = 0; - $_etype546 = 0; - $xfer += $input->readListBegin($_etype546, $_size543); - for ($_i547 = 0; $_i547 < $_size543; ++$_i547) + $_size552 = 0; + $_etype555 = 0; + $xfer += $input->readListBegin($_etype555, $_size552); + for ($_i556 = 0; $_i556 < $_size552; ++$_i556) { - $elem548 = null; - $elem548 = new \metastore\HiveObjectPrivilege(); - $xfer += $elem548->read($input); - $this->success []= $elem548; + $elem557 = null; + $elem557 = new \metastore\HiveObjectPrivilege(); + $xfer += $elem557->read($input); + $this->success []= $elem557; } $xfer += $input->readListEnd(); } else { @@ -23107,9 +23526,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter549) + foreach ($this->success as $iter558) { - $xfer += $iter549->write($output); + $xfer += $iter558->write($output); } } $output->writeListEnd(); @@ -23532,14 +23951,14 @@ case 2: if ($ftype == TType::LST) { $this->group_names = array(); - $_size550 = 0; - $_etype553 = 0; - $xfer += $input->readListBegin($_etype553, $_size550); - for ($_i554 = 0; $_i554 < $_size550; ++$_i554) + $_size559 = 0; + $_etype562 = 0; + $xfer += $input->readListBegin($_etype562, $_size559); + for ($_i563 = 0; $_i563 < $_size559; ++$_i563) { - $elem555 = null; - $xfer += $input->readString($elem555); - $this->group_names []= $elem555; + $elem564 = null; + $xfer += $input->readString($elem564); + $this->group_names []= $elem564; } $xfer += $input->readListEnd(); } else { @@ -23572,9 +23991,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter556) + foreach ($this->group_names as $iter565) { - $xfer += $output->writeString($iter556); + $xfer += $output->writeString($iter565); } } $output->writeListEnd(); @@ -23644,14 +24063,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size557 = 0; - $_etype560 = 0; - $xfer += $input->readListBegin($_etype560, $_size557); - for ($_i561 = 0; $_i561 < $_size557; ++$_i561) + $_size566 = 0; + $_etype569 = 0; + $xfer += $input->readListBegin($_etype569, $_size566); + for ($_i570 = 0; $_i570 < $_size566; ++$_i570) { - $elem562 = null; - $xfer += $input->readString($elem562); - $this->success []= $elem562; + $elem571 = null; + $xfer += $input->readString($elem571); + $this->success []= $elem571; } $xfer += $input->readListEnd(); } else { @@ -23687,9 +24106,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter563) + foreach ($this->success as $iter572) { - $xfer += $output->writeString($iter563); + $xfer += $output->writeString($iter572); } } $output->writeListEnd(); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java (revision 1471261) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java (working copy) @@ -108,6 +108,8 @@ public Partition get_partition(String db_name, String tbl_name, List part_vals) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; + public Partition exchange_partition(Map partitionSpecs, String source_db, String source_table_name, String dest_db, String dest_table_name) throws MetaException, NoSuchObjectException, InvalidObjectException, InvalidInputException, org.apache.thrift.TException; + public Partition get_partition_with_auth(String db_name, String tbl_name, List part_vals, String user_name, List group_names) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; public Partition get_partition_by_name(String db_name, String tbl_name, String part_name) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; @@ -274,6 +276,8 @@ public void get_partition(String db_name, String tbl_name, List part_vals, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void exchange_partition(Map partitionSpecs, String source_db, String source_table_name, String dest_db, String dest_table_name, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void get_partition_with_auth(String db_name, String tbl_name, List part_vals, String user_name, List group_names, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; public void get_partition_by_name(String db_name, String tbl_name, String part_name, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; @@ -1462,6 +1466,45 @@ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "get_partition failed: unknown result"); } + public Partition exchange_partition(Map partitionSpecs, String source_db, String source_table_name, String dest_db, String dest_table_name) throws MetaException, NoSuchObjectException, InvalidObjectException, InvalidInputException, org.apache.thrift.TException + { + send_exchange_partition(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name); + return recv_exchange_partition(); + } + + public void send_exchange_partition(Map partitionSpecs, String source_db, String source_table_name, String dest_db, String dest_table_name) throws org.apache.thrift.TException + { + exchange_partition_args args = new exchange_partition_args(); + args.setPartitionSpecs(partitionSpecs); + args.setSource_db(source_db); + args.setSource_table_name(source_table_name); + args.setDest_db(dest_db); + args.setDest_table_name(dest_table_name); + sendBase("exchange_partition", args); + } + + public Partition recv_exchange_partition() throws MetaException, NoSuchObjectException, InvalidObjectException, InvalidInputException, org.apache.thrift.TException + { + exchange_partition_result result = new exchange_partition_result(); + receiveBase(result, "exchange_partition"); + if (result.isSetSuccess()) { + return result.success; + } + if (result.o1 != null) { + throw result.o1; + } + if (result.o2 != null) { + throw result.o2; + } + if (result.o3 != null) { + throw result.o3; + } + if (result.o4 != null) { + throw result.o4; + } + throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "exchange_partition failed: unknown result"); + } + public Partition get_partition_with_auth(String db_name, String tbl_name, List part_vals, String user_name, List group_names) throws MetaException, NoSuchObjectException, org.apache.thrift.TException { send_get_partition_with_auth(db_name, tbl_name, part_vals, user_name, group_names); @@ -4141,6 +4184,50 @@ } } + public void exchange_partition(Map partitionSpecs, String source_db, String source_table_name, String dest_db, String dest_table_name, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { + checkReady(); + exchange_partition_call method_call = new exchange_partition_call(partitionSpecs, source_db, source_table_name, dest_db, dest_table_name, resultHandler, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class exchange_partition_call extends org.apache.thrift.async.TAsyncMethodCall { + private Map partitionSpecs; + private String source_db; + private String source_table_name; + private String dest_db; + private String dest_table_name; + public exchange_partition_call(Map partitionSpecs, String source_db, String source_table_name, String dest_db, String dest_table_name, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException { + super(client, protocolFactory, transport, resultHandler, false); + this.partitionSpecs = partitionSpecs; + this.source_db = source_db; + this.source_table_name = source_table_name; + this.dest_db = dest_db; + this.dest_table_name = dest_table_name; + } + + public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException { + prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("exchange_partition", org.apache.thrift.protocol.TMessageType.CALL, 0)); + exchange_partition_args args = new exchange_partition_args(); + args.setPartitionSpecs(partitionSpecs); + args.setSource_db(source_db); + args.setSource_table_name(source_table_name); + args.setDest_db(dest_db); + args.setDest_table_name(dest_table_name); + args.write(prot); + prot.writeMessageEnd(); + } + + public Partition getResult() throws MetaException, NoSuchObjectException, InvalidObjectException, InvalidInputException, org.apache.thrift.TException { + if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) { + throw new IllegalStateException("Method call not finished!"); + } + org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array()); + org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport); + return (new Client(prot)).recv_exchange_partition(); + } + } + public void get_partition_with_auth(String db_name, String tbl_name, List part_vals, String user_name, List group_names, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); get_partition_with_auth_call method_call = new get_partition_with_auth_call(db_name, tbl_name, part_vals, user_name, group_names, resultHandler, this, ___protocolFactory, ___transport); @@ -5913,6 +6000,7 @@ processMap.put("drop_partition_by_name", new drop_partition_by_name()); processMap.put("drop_partition_by_name_with_environment_context", new drop_partition_by_name_with_environment_context()); processMap.put("get_partition", new get_partition()); + processMap.put("exchange_partition", new exchange_partition()); processMap.put("get_partition_with_auth", new get_partition_with_auth()); processMap.put("get_partition_by_name", new get_partition_by_name()); processMap.put("get_partitions", new get_partitions()); @@ -6905,6 +6993,36 @@ } } + public static class exchange_partition extends org.apache.thrift.ProcessFunction { + public exchange_partition() { + super("exchange_partition"); + } + + public exchange_partition_args getEmptyArgsInstance() { + return new exchange_partition_args(); + } + + protected boolean isOneway() { + return false; + } + + public exchange_partition_result getResult(I iface, exchange_partition_args args) throws org.apache.thrift.TException { + exchange_partition_result result = new exchange_partition_result(); + try { + result.success = iface.exchange_partition(args.partitionSpecs, args.source_db, args.source_table_name, args.dest_db, args.dest_table_name); + } catch (MetaException o1) { + result.o1 = o1; + } catch (NoSuchObjectException o2) { + result.o2 = o2; + } catch (InvalidObjectException o3) { + result.o3 = o3; + } catch (InvalidInputException o4) { + result.o4 = o4; + } + return result; + } + } + public static class get_partition_with_auth extends org.apache.thrift.ProcessFunction { public get_partition_with_auth() { super("get_partition_with_auth"); @@ -46889,6 +47007,1630 @@ } + public static class exchange_partition_args implements org.apache.thrift.TBase, java.io.Serializable, Cloneable { + private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("exchange_partition_args"); + + private static final org.apache.thrift.protocol.TField PARTITION_SPECS_FIELD_DESC = new org.apache.thrift.protocol.TField("partitionSpecs", org.apache.thrift.protocol.TType.MAP, (short)1); + private static final org.apache.thrift.protocol.TField SOURCE_DB_FIELD_DESC = new org.apache.thrift.protocol.TField("source_db", org.apache.thrift.protocol.TType.STRING, (short)2); + private static final org.apache.thrift.protocol.TField SOURCE_TABLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("source_table_name", org.apache.thrift.protocol.TType.STRING, (short)3); + private static final org.apache.thrift.protocol.TField DEST_DB_FIELD_DESC = new org.apache.thrift.protocol.TField("dest_db", org.apache.thrift.protocol.TType.STRING, (short)4); + private static final org.apache.thrift.protocol.TField DEST_TABLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("dest_table_name", org.apache.thrift.protocol.TType.STRING, (short)5); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new exchange_partition_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new exchange_partition_argsTupleSchemeFactory()); + } + + private Map partitionSpecs; // required + private String source_db; // required + private String source_table_name; // required + private String dest_db; // required + private String dest_table_name; // required + + /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ + public enum _Fields implements org.apache.thrift.TFieldIdEnum { + PARTITION_SPECS((short)1, "partitionSpecs"), + SOURCE_DB((short)2, "source_db"), + SOURCE_TABLE_NAME((short)3, "source_table_name"), + DEST_DB((short)4, "dest_db"), + DEST_TABLE_NAME((short)5, "dest_table_name"); + + private static final Map byName = new HashMap(); + + static { + for (_Fields field : EnumSet.allOf(_Fields.class)) { + byName.put(field.getFieldName(), field); + } + } + + /** + * Find the _Fields constant that matches fieldId, or null if its not found. + */ + public static _Fields findByThriftId(int fieldId) { + switch(fieldId) { + case 1: // PARTITION_SPECS + return PARTITION_SPECS; + case 2: // SOURCE_DB + return SOURCE_DB; + case 3: // SOURCE_TABLE_NAME + return SOURCE_TABLE_NAME; + case 4: // DEST_DB + return DEST_DB; + case 5: // DEST_TABLE_NAME + return DEST_TABLE_NAME; + default: + return null; + } + } + + /** + * Find the _Fields constant that matches fieldId, throwing an exception + * if it is not found. + */ + public static _Fields findByThriftIdOrThrow(int fieldId) { + _Fields fields = findByThriftId(fieldId); + if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!"); + return fields; + } + + /** + * Find the _Fields constant that matches name, or null if its not found. + */ + public static _Fields findByName(String name) { + return byName.get(name); + } + + private final short _thriftId; + private final String _fieldName; + + _Fields(short thriftId, String fieldName) { + _thriftId = thriftId; + _fieldName = fieldName; + } + + public short getThriftFieldId() { + return _thriftId; + } + + public String getFieldName() { + return _fieldName; + } + } + + // isset id assignments + public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap; + static { + Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class); + tmpMap.put(_Fields.PARTITION_SPECS, new org.apache.thrift.meta_data.FieldMetaData("partitionSpecs", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))); + tmpMap.put(_Fields.SOURCE_DB, new org.apache.thrift.meta_data.FieldMetaData("source_db", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.SOURCE_TABLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("source_table_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.DEST_DB, new org.apache.thrift.meta_data.FieldMetaData("dest_db", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.DEST_TABLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("dest_table_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(exchange_partition_args.class, metaDataMap); + } + + public exchange_partition_args() { + } + + public exchange_partition_args( + Map partitionSpecs, + String source_db, + String source_table_name, + String dest_db, + String dest_table_name) + { + this(); + this.partitionSpecs = partitionSpecs; + this.source_db = source_db; + this.source_table_name = source_table_name; + this.dest_db = dest_db; + this.dest_table_name = dest_table_name; + } + + /** + * Performs a deep copy on other. + */ + public exchange_partition_args(exchange_partition_args other) { + if (other.isSetPartitionSpecs()) { + Map __this__partitionSpecs = new HashMap(); + for (Map.Entry other_element : other.partitionSpecs.entrySet()) { + + String other_element_key = other_element.getKey(); + String other_element_value = other_element.getValue(); + + String __this__partitionSpecs_copy_key = other_element_key; + + String __this__partitionSpecs_copy_value = other_element_value; + + __this__partitionSpecs.put(__this__partitionSpecs_copy_key, __this__partitionSpecs_copy_value); + } + this.partitionSpecs = __this__partitionSpecs; + } + if (other.isSetSource_db()) { + this.source_db = other.source_db; + } + if (other.isSetSource_table_name()) { + this.source_table_name = other.source_table_name; + } + if (other.isSetDest_db()) { + this.dest_db = other.dest_db; + } + if (other.isSetDest_table_name()) { + this.dest_table_name = other.dest_table_name; + } + } + + public exchange_partition_args deepCopy() { + return new exchange_partition_args(this); + } + + @Override + public void clear() { + this.partitionSpecs = null; + this.source_db = null; + this.source_table_name = null; + this.dest_db = null; + this.dest_table_name = null; + } + + public int getPartitionSpecsSize() { + return (this.partitionSpecs == null) ? 0 : this.partitionSpecs.size(); + } + + public void putToPartitionSpecs(String key, String val) { + if (this.partitionSpecs == null) { + this.partitionSpecs = new HashMap(); + } + this.partitionSpecs.put(key, val); + } + + public Map getPartitionSpecs() { + return this.partitionSpecs; + } + + public void setPartitionSpecs(Map partitionSpecs) { + this.partitionSpecs = partitionSpecs; + } + + public void unsetPartitionSpecs() { + this.partitionSpecs = null; + } + + /** Returns true if field partitionSpecs is set (has been assigned a value) and false otherwise */ + public boolean isSetPartitionSpecs() { + return this.partitionSpecs != null; + } + + public void setPartitionSpecsIsSet(boolean value) { + if (!value) { + this.partitionSpecs = null; + } + } + + public String getSource_db() { + return this.source_db; + } + + public void setSource_db(String source_db) { + this.source_db = source_db; + } + + public void unsetSource_db() { + this.source_db = null; + } + + /** Returns true if field source_db is set (has been assigned a value) and false otherwise */ + public boolean isSetSource_db() { + return this.source_db != null; + } + + public void setSource_dbIsSet(boolean value) { + if (!value) { + this.source_db = null; + } + } + + public String getSource_table_name() { + return this.source_table_name; + } + + public void setSource_table_name(String source_table_name) { + this.source_table_name = source_table_name; + } + + public void unsetSource_table_name() { + this.source_table_name = null; + } + + /** Returns true if field source_table_name is set (has been assigned a value) and false otherwise */ + public boolean isSetSource_table_name() { + return this.source_table_name != null; + } + + public void setSource_table_nameIsSet(boolean value) { + if (!value) { + this.source_table_name = null; + } + } + + public String getDest_db() { + return this.dest_db; + } + + public void setDest_db(String dest_db) { + this.dest_db = dest_db; + } + + public void unsetDest_db() { + this.dest_db = null; + } + + /** Returns true if field dest_db is set (has been assigned a value) and false otherwise */ + public boolean isSetDest_db() { + return this.dest_db != null; + } + + public void setDest_dbIsSet(boolean value) { + if (!value) { + this.dest_db = null; + } + } + + public String getDest_table_name() { + return this.dest_table_name; + } + + public void setDest_table_name(String dest_table_name) { + this.dest_table_name = dest_table_name; + } + + public void unsetDest_table_name() { + this.dest_table_name = null; + } + + /** Returns true if field dest_table_name is set (has been assigned a value) and false otherwise */ + public boolean isSetDest_table_name() { + return this.dest_table_name != null; + } + + public void setDest_table_nameIsSet(boolean value) { + if (!value) { + this.dest_table_name = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case PARTITION_SPECS: + if (value == null) { + unsetPartitionSpecs(); + } else { + setPartitionSpecs((Map)value); + } + break; + + case SOURCE_DB: + if (value == null) { + unsetSource_db(); + } else { + setSource_db((String)value); + } + break; + + case SOURCE_TABLE_NAME: + if (value == null) { + unsetSource_table_name(); + } else { + setSource_table_name((String)value); + } + break; + + case DEST_DB: + if (value == null) { + unsetDest_db(); + } else { + setDest_db((String)value); + } + break; + + case DEST_TABLE_NAME: + if (value == null) { + unsetDest_table_name(); + } else { + setDest_table_name((String)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case PARTITION_SPECS: + return getPartitionSpecs(); + + case SOURCE_DB: + return getSource_db(); + + case SOURCE_TABLE_NAME: + return getSource_table_name(); + + case DEST_DB: + return getDest_db(); + + case DEST_TABLE_NAME: + return getDest_table_name(); + + } + throw new IllegalStateException(); + } + + /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */ + public boolean isSet(_Fields field) { + if (field == null) { + throw new IllegalArgumentException(); + } + + switch (field) { + case PARTITION_SPECS: + return isSetPartitionSpecs(); + case SOURCE_DB: + return isSetSource_db(); + case SOURCE_TABLE_NAME: + return isSetSource_table_name(); + case DEST_DB: + return isSetDest_db(); + case DEST_TABLE_NAME: + return isSetDest_table_name(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof exchange_partition_args) + return this.equals((exchange_partition_args)that); + return false; + } + + public boolean equals(exchange_partition_args that) { + if (that == null) + return false; + + boolean this_present_partitionSpecs = true && this.isSetPartitionSpecs(); + boolean that_present_partitionSpecs = true && that.isSetPartitionSpecs(); + if (this_present_partitionSpecs || that_present_partitionSpecs) { + if (!(this_present_partitionSpecs && that_present_partitionSpecs)) + return false; + if (!this.partitionSpecs.equals(that.partitionSpecs)) + return false; + } + + boolean this_present_source_db = true && this.isSetSource_db(); + boolean that_present_source_db = true && that.isSetSource_db(); + if (this_present_source_db || that_present_source_db) { + if (!(this_present_source_db && that_present_source_db)) + return false; + if (!this.source_db.equals(that.source_db)) + return false; + } + + boolean this_present_source_table_name = true && this.isSetSource_table_name(); + boolean that_present_source_table_name = true && that.isSetSource_table_name(); + if (this_present_source_table_name || that_present_source_table_name) { + if (!(this_present_source_table_name && that_present_source_table_name)) + return false; + if (!this.source_table_name.equals(that.source_table_name)) + return false; + } + + boolean this_present_dest_db = true && this.isSetDest_db(); + boolean that_present_dest_db = true && that.isSetDest_db(); + if (this_present_dest_db || that_present_dest_db) { + if (!(this_present_dest_db && that_present_dest_db)) + return false; + if (!this.dest_db.equals(that.dest_db)) + return false; + } + + boolean this_present_dest_table_name = true && this.isSetDest_table_name(); + boolean that_present_dest_table_name = true && that.isSetDest_table_name(); + if (this_present_dest_table_name || that_present_dest_table_name) { + if (!(this_present_dest_table_name && that_present_dest_table_name)) + return false; + if (!this.dest_table_name.equals(that.dest_table_name)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_partitionSpecs = true && (isSetPartitionSpecs()); + builder.append(present_partitionSpecs); + if (present_partitionSpecs) + builder.append(partitionSpecs); + + boolean present_source_db = true && (isSetSource_db()); + builder.append(present_source_db); + if (present_source_db) + builder.append(source_db); + + boolean present_source_table_name = true && (isSetSource_table_name()); + builder.append(present_source_table_name); + if (present_source_table_name) + builder.append(source_table_name); + + boolean present_dest_db = true && (isSetDest_db()); + builder.append(present_dest_db); + if (present_dest_db) + builder.append(dest_db); + + boolean present_dest_table_name = true && (isSetDest_table_name()); + builder.append(present_dest_table_name); + if (present_dest_table_name) + builder.append(dest_table_name); + + return builder.toHashCode(); + } + + public int compareTo(exchange_partition_args other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + exchange_partition_args typedOther = (exchange_partition_args)other; + + lastComparison = Boolean.valueOf(isSetPartitionSpecs()).compareTo(typedOther.isSetPartitionSpecs()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPartitionSpecs()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.partitionSpecs, typedOther.partitionSpecs); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetSource_db()).compareTo(typedOther.isSetSource_db()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetSource_db()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.source_db, typedOther.source_db); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetSource_table_name()).compareTo(typedOther.isSetSource_table_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetSource_table_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.source_table_name, typedOther.source_table_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetDest_db()).compareTo(typedOther.isSetDest_db()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetDest_db()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dest_db, typedOther.dest_db); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetDest_table_name()).compareTo(typedOther.isSetDest_table_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetDest_table_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dest_table_name, typedOther.dest_table_name); + if (lastComparison != 0) { + return lastComparison; + } + } + return 0; + } + + public _Fields fieldForId(int fieldId) { + return _Fields.findByThriftId(fieldId); + } + + public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException { + schemes.get(iprot.getScheme()).getScheme().read(iprot, this); + } + + public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException { + schemes.get(oprot.getScheme()).getScheme().write(oprot, this); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder("exchange_partition_args("); + boolean first = true; + + sb.append("partitionSpecs:"); + if (this.partitionSpecs == null) { + sb.append("null"); + } else { + sb.append(this.partitionSpecs); + } + first = false; + if (!first) sb.append(", "); + sb.append("source_db:"); + if (this.source_db == null) { + sb.append("null"); + } else { + sb.append(this.source_db); + } + first = false; + if (!first) sb.append(", "); + sb.append("source_table_name:"); + if (this.source_table_name == null) { + sb.append("null"); + } else { + sb.append(this.source_table_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("dest_db:"); + if (this.dest_db == null) { + sb.append("null"); + } else { + sb.append(this.dest_db); + } + first = false; + if (!first) sb.append(", "); + sb.append("dest_table_name:"); + if (this.dest_table_name == null) { + sb.append("null"); + } else { + sb.append(this.dest_table_name); + } + first = false; + sb.append(")"); + return sb.toString(); + } + + public void validate() throws org.apache.thrift.TException { + // check for required fields + // check for sub-struct validity + } + + private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { + try { + write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out))); + } catch (org.apache.thrift.TException te) { + throw new java.io.IOException(te); + } + } + + private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { + try { + read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in))); + } catch (org.apache.thrift.TException te) { + throw new java.io.IOException(te); + } + } + + private static class exchange_partition_argsStandardSchemeFactory implements SchemeFactory { + public exchange_partition_argsStandardScheme getScheme() { + return new exchange_partition_argsStandardScheme(); + } + } + + private static class exchange_partition_argsStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, exchange_partition_args struct) throws org.apache.thrift.TException { + org.apache.thrift.protocol.TField schemeField; + iprot.readStructBegin(); + while (true) + { + schemeField = iprot.readFieldBegin(); + if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { + break; + } + switch (schemeField.id) { + case 1: // PARTITION_SPECS + if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { + { + org.apache.thrift.protocol.TMap _map386 = iprot.readMapBegin(); + struct.partitionSpecs = new HashMap(2*_map386.size); + for (int _i387 = 0; _i387 < _map386.size; ++_i387) + { + String _key388; // required + String _val389; // required + _key388 = iprot.readString(); + _val389 = iprot.readString(); + struct.partitionSpecs.put(_key388, _val389); + } + iprot.readMapEnd(); + } + struct.setPartitionSpecsIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // SOURCE_DB + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.source_db = iprot.readString(); + struct.setSource_dbIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // SOURCE_TABLE_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.source_table_name = iprot.readString(); + struct.setSource_table_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // DEST_DB + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.dest_db = iprot.readString(); + struct.setDest_dbIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 5: // DEST_TABLE_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.dest_table_name = iprot.readString(); + struct.setDest_table_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + default: + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + struct.validate(); + } + + public void write(org.apache.thrift.protocol.TProtocol oprot, exchange_partition_args struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.partitionSpecs != null) { + oprot.writeFieldBegin(PARTITION_SPECS_FIELD_DESC); + { + oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.partitionSpecs.size())); + for (Map.Entry _iter390 : struct.partitionSpecs.entrySet()) + { + oprot.writeString(_iter390.getKey()); + oprot.writeString(_iter390.getValue()); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (struct.source_db != null) { + oprot.writeFieldBegin(SOURCE_DB_FIELD_DESC); + oprot.writeString(struct.source_db); + oprot.writeFieldEnd(); + } + if (struct.source_table_name != null) { + oprot.writeFieldBegin(SOURCE_TABLE_NAME_FIELD_DESC); + oprot.writeString(struct.source_table_name); + oprot.writeFieldEnd(); + } + if (struct.dest_db != null) { + oprot.writeFieldBegin(DEST_DB_FIELD_DESC); + oprot.writeString(struct.dest_db); + oprot.writeFieldEnd(); + } + if (struct.dest_table_name != null) { + oprot.writeFieldBegin(DEST_TABLE_NAME_FIELD_DESC); + oprot.writeString(struct.dest_table_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class exchange_partition_argsTupleSchemeFactory implements SchemeFactory { + public exchange_partition_argsTupleScheme getScheme() { + return new exchange_partition_argsTupleScheme(); + } + } + + private static class exchange_partition_argsTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, exchange_partition_args struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetPartitionSpecs()) { + optionals.set(0); + } + if (struct.isSetSource_db()) { + optionals.set(1); + } + if (struct.isSetSource_table_name()) { + optionals.set(2); + } + if (struct.isSetDest_db()) { + optionals.set(3); + } + if (struct.isSetDest_table_name()) { + optionals.set(4); + } + oprot.writeBitSet(optionals, 5); + if (struct.isSetPartitionSpecs()) { + { + oprot.writeI32(struct.partitionSpecs.size()); + for (Map.Entry _iter391 : struct.partitionSpecs.entrySet()) + { + oprot.writeString(_iter391.getKey()); + oprot.writeString(_iter391.getValue()); + } + } + } + if (struct.isSetSource_db()) { + oprot.writeString(struct.source_db); + } + if (struct.isSetSource_table_name()) { + oprot.writeString(struct.source_table_name); + } + if (struct.isSetDest_db()) { + oprot.writeString(struct.dest_db); + } + if (struct.isSetDest_table_name()) { + oprot.writeString(struct.dest_table_name); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, exchange_partition_args struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(5); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TMap _map392 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.partitionSpecs = new HashMap(2*_map392.size); + for (int _i393 = 0; _i393 < _map392.size; ++_i393) + { + String _key394; // required + String _val395; // required + _key394 = iprot.readString(); + _val395 = iprot.readString(); + struct.partitionSpecs.put(_key394, _val395); + } + } + struct.setPartitionSpecsIsSet(true); + } + if (incoming.get(1)) { + struct.source_db = iprot.readString(); + struct.setSource_dbIsSet(true); + } + if (incoming.get(2)) { + struct.source_table_name = iprot.readString(); + struct.setSource_table_nameIsSet(true); + } + if (incoming.get(3)) { + struct.dest_db = iprot.readString(); + struct.setDest_dbIsSet(true); + } + if (incoming.get(4)) { + struct.dest_table_name = iprot.readString(); + struct.setDest_table_nameIsSet(true); + } + } + } + + } + + public static class exchange_partition_result implements org.apache.thrift.TBase, java.io.Serializable, Cloneable { + private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("exchange_partition_result"); + + private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0); + private static final org.apache.thrift.protocol.TField O1_FIELD_DESC = new org.apache.thrift.protocol.TField("o1", org.apache.thrift.protocol.TType.STRUCT, (short)1); + private static final org.apache.thrift.protocol.TField O2_FIELD_DESC = new org.apache.thrift.protocol.TField("o2", org.apache.thrift.protocol.TType.STRUCT, (short)2); + private static final org.apache.thrift.protocol.TField O3_FIELD_DESC = new org.apache.thrift.protocol.TField("o3", org.apache.thrift.protocol.TType.STRUCT, (short)3); + private static final org.apache.thrift.protocol.TField O4_FIELD_DESC = new org.apache.thrift.protocol.TField("o4", org.apache.thrift.protocol.TType.STRUCT, (short)4); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new exchange_partition_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new exchange_partition_resultTupleSchemeFactory()); + } + + private Partition success; // required + private MetaException o1; // required + private NoSuchObjectException o2; // required + private InvalidObjectException o3; // required + private InvalidInputException o4; // required + + /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ + public enum _Fields implements org.apache.thrift.TFieldIdEnum { + SUCCESS((short)0, "success"), + O1((short)1, "o1"), + O2((short)2, "o2"), + O3((short)3, "o3"), + O4((short)4, "o4"); + + private static final Map byName = new HashMap(); + + static { + for (_Fields field : EnumSet.allOf(_Fields.class)) { + byName.put(field.getFieldName(), field); + } + } + + /** + * Find the _Fields constant that matches fieldId, or null if its not found. + */ + public static _Fields findByThriftId(int fieldId) { + switch(fieldId) { + case 0: // SUCCESS + return SUCCESS; + case 1: // O1 + return O1; + case 2: // O2 + return O2; + case 3: // O3 + return O3; + case 4: // O4 + return O4; + default: + return null; + } + } + + /** + * Find the _Fields constant that matches fieldId, throwing an exception + * if it is not found. + */ + public static _Fields findByThriftIdOrThrow(int fieldId) { + _Fields fields = findByThriftId(fieldId); + if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!"); + return fields; + } + + /** + * Find the _Fields constant that matches name, or null if its not found. + */ + public static _Fields findByName(String name) { + return byName.get(name); + } + + private final short _thriftId; + private final String _fieldName; + + _Fields(short thriftId, String fieldName) { + _thriftId = thriftId; + _fieldName = fieldName; + } + + public short getThriftFieldId() { + return _thriftId; + } + + public String getFieldName() { + return _fieldName; + } + } + + // isset id assignments + public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap; + static { + Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class); + tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Partition.class))); + tmpMap.put(_Fields.O1, new org.apache.thrift.meta_data.FieldMetaData("o1", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT))); + tmpMap.put(_Fields.O2, new org.apache.thrift.meta_data.FieldMetaData("o2", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT))); + tmpMap.put(_Fields.O3, new org.apache.thrift.meta_data.FieldMetaData("o3", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT))); + tmpMap.put(_Fields.O4, new org.apache.thrift.meta_data.FieldMetaData("o4", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(exchange_partition_result.class, metaDataMap); + } + + public exchange_partition_result() { + } + + public exchange_partition_result( + Partition success, + MetaException o1, + NoSuchObjectException o2, + InvalidObjectException o3, + InvalidInputException o4) + { + this(); + this.success = success; + this.o1 = o1; + this.o2 = o2; + this.o3 = o3; + this.o4 = o4; + } + + /** + * Performs a deep copy on other. + */ + public exchange_partition_result(exchange_partition_result other) { + if (other.isSetSuccess()) { + this.success = new Partition(other.success); + } + if (other.isSetO1()) { + this.o1 = new MetaException(other.o1); + } + if (other.isSetO2()) { + this.o2 = new NoSuchObjectException(other.o2); + } + if (other.isSetO3()) { + this.o3 = new InvalidObjectException(other.o3); + } + if (other.isSetO4()) { + this.o4 = new InvalidInputException(other.o4); + } + } + + public exchange_partition_result deepCopy() { + return new exchange_partition_result(this); + } + + @Override + public void clear() { + this.success = null; + this.o1 = null; + this.o2 = null; + this.o3 = null; + this.o4 = null; + } + + public Partition getSuccess() { + return this.success; + } + + public void setSuccess(Partition success) { + this.success = success; + } + + public void unsetSuccess() { + this.success = null; + } + + /** Returns true if field success is set (has been assigned a value) and false otherwise */ + public boolean isSetSuccess() { + return this.success != null; + } + + public void setSuccessIsSet(boolean value) { + if (!value) { + this.success = null; + } + } + + public MetaException getO1() { + return this.o1; + } + + public void setO1(MetaException o1) { + this.o1 = o1; + } + + public void unsetO1() { + this.o1 = null; + } + + /** Returns true if field o1 is set (has been assigned a value) and false otherwise */ + public boolean isSetO1() { + return this.o1 != null; + } + + public void setO1IsSet(boolean value) { + if (!value) { + this.o1 = null; + } + } + + public NoSuchObjectException getO2() { + return this.o2; + } + + public void setO2(NoSuchObjectException o2) { + this.o2 = o2; + } + + public void unsetO2() { + this.o2 = null; + } + + /** Returns true if field o2 is set (has been assigned a value) and false otherwise */ + public boolean isSetO2() { + return this.o2 != null; + } + + public void setO2IsSet(boolean value) { + if (!value) { + this.o2 = null; + } + } + + public InvalidObjectException getO3() { + return this.o3; + } + + public void setO3(InvalidObjectException o3) { + this.o3 = o3; + } + + public void unsetO3() { + this.o3 = null; + } + + /** Returns true if field o3 is set (has been assigned a value) and false otherwise */ + public boolean isSetO3() { + return this.o3 != null; + } + + public void setO3IsSet(boolean value) { + if (!value) { + this.o3 = null; + } + } + + public InvalidInputException getO4() { + return this.o4; + } + + public void setO4(InvalidInputException o4) { + this.o4 = o4; + } + + public void unsetO4() { + this.o4 = null; + } + + /** Returns true if field o4 is set (has been assigned a value) and false otherwise */ + public boolean isSetO4() { + return this.o4 != null; + } + + public void setO4IsSet(boolean value) { + if (!value) { + this.o4 = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case SUCCESS: + if (value == null) { + unsetSuccess(); + } else { + setSuccess((Partition)value); + } + break; + + case O1: + if (value == null) { + unsetO1(); + } else { + setO1((MetaException)value); + } + break; + + case O2: + if (value == null) { + unsetO2(); + } else { + setO2((NoSuchObjectException)value); + } + break; + + case O3: + if (value == null) { + unsetO3(); + } else { + setO3((InvalidObjectException)value); + } + break; + + case O4: + if (value == null) { + unsetO4(); + } else { + setO4((InvalidInputException)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case SUCCESS: + return getSuccess(); + + case O1: + return getO1(); + + case O2: + return getO2(); + + case O3: + return getO3(); + + case O4: + return getO4(); + + } + throw new IllegalStateException(); + } + + /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */ + public boolean isSet(_Fields field) { + if (field == null) { + throw new IllegalArgumentException(); + } + + switch (field) { + case SUCCESS: + return isSetSuccess(); + case O1: + return isSetO1(); + case O2: + return isSetO2(); + case O3: + return isSetO3(); + case O4: + return isSetO4(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof exchange_partition_result) + return this.equals((exchange_partition_result)that); + return false; + } + + public boolean equals(exchange_partition_result that) { + if (that == null) + return false; + + boolean this_present_success = true && this.isSetSuccess(); + boolean that_present_success = true && that.isSetSuccess(); + if (this_present_success || that_present_success) { + if (!(this_present_success && that_present_success)) + return false; + if (!this.success.equals(that.success)) + return false; + } + + boolean this_present_o1 = true && this.isSetO1(); + boolean that_present_o1 = true && that.isSetO1(); + if (this_present_o1 || that_present_o1) { + if (!(this_present_o1 && that_present_o1)) + return false; + if (!this.o1.equals(that.o1)) + return false; + } + + boolean this_present_o2 = true && this.isSetO2(); + boolean that_present_o2 = true && that.isSetO2(); + if (this_present_o2 || that_present_o2) { + if (!(this_present_o2 && that_present_o2)) + return false; + if (!this.o2.equals(that.o2)) + return false; + } + + boolean this_present_o3 = true && this.isSetO3(); + boolean that_present_o3 = true && that.isSetO3(); + if (this_present_o3 || that_present_o3) { + if (!(this_present_o3 && that_present_o3)) + return false; + if (!this.o3.equals(that.o3)) + return false; + } + + boolean this_present_o4 = true && this.isSetO4(); + boolean that_present_o4 = true && that.isSetO4(); + if (this_present_o4 || that_present_o4) { + if (!(this_present_o4 && that_present_o4)) + return false; + if (!this.o4.equals(that.o4)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_success = true && (isSetSuccess()); + builder.append(present_success); + if (present_success) + builder.append(success); + + boolean present_o1 = true && (isSetO1()); + builder.append(present_o1); + if (present_o1) + builder.append(o1); + + boolean present_o2 = true && (isSetO2()); + builder.append(present_o2); + if (present_o2) + builder.append(o2); + + boolean present_o3 = true && (isSetO3()); + builder.append(present_o3); + if (present_o3) + builder.append(o3); + + boolean present_o4 = true && (isSetO4()); + builder.append(present_o4); + if (present_o4) + builder.append(o4); + + return builder.toHashCode(); + } + + public int compareTo(exchange_partition_result other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + exchange_partition_result typedOther = (exchange_partition_result)other; + + lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetSuccess()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetO1()).compareTo(typedOther.isSetO1()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetO1()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.o1, typedOther.o1); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetO2()).compareTo(typedOther.isSetO2()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetO2()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.o2, typedOther.o2); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetO3()).compareTo(typedOther.isSetO3()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetO3()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.o3, typedOther.o3); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetO4()).compareTo(typedOther.isSetO4()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetO4()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.o4, typedOther.o4); + if (lastComparison != 0) { + return lastComparison; + } + } + return 0; + } + + public _Fields fieldForId(int fieldId) { + return _Fields.findByThriftId(fieldId); + } + + public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException { + schemes.get(iprot.getScheme()).getScheme().read(iprot, this); + } + + public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException { + schemes.get(oprot.getScheme()).getScheme().write(oprot, this); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder("exchange_partition_result("); + boolean first = true; + + sb.append("success:"); + if (this.success == null) { + sb.append("null"); + } else { + sb.append(this.success); + } + first = false; + if (!first) sb.append(", "); + sb.append("o1:"); + if (this.o1 == null) { + sb.append("null"); + } else { + sb.append(this.o1); + } + first = false; + if (!first) sb.append(", "); + sb.append("o2:"); + if (this.o2 == null) { + sb.append("null"); + } else { + sb.append(this.o2); + } + first = false; + if (!first) sb.append(", "); + sb.append("o3:"); + if (this.o3 == null) { + sb.append("null"); + } else { + sb.append(this.o3); + } + first = false; + if (!first) sb.append(", "); + sb.append("o4:"); + if (this.o4 == null) { + sb.append("null"); + } else { + sb.append(this.o4); + } + first = false; + sb.append(")"); + return sb.toString(); + } + + public void validate() throws org.apache.thrift.TException { + // check for required fields + // check for sub-struct validity + if (success != null) { + success.validate(); + } + } + + private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { + try { + write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out))); + } catch (org.apache.thrift.TException te) { + throw new java.io.IOException(te); + } + } + + private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException { + try { + read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in))); + } catch (org.apache.thrift.TException te) { + throw new java.io.IOException(te); + } + } + + private static class exchange_partition_resultStandardSchemeFactory implements SchemeFactory { + public exchange_partition_resultStandardScheme getScheme() { + return new exchange_partition_resultStandardScheme(); + } + } + + private static class exchange_partition_resultStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, exchange_partition_result struct) throws org.apache.thrift.TException { + org.apache.thrift.protocol.TField schemeField; + iprot.readStructBegin(); + while (true) + { + schemeField = iprot.readFieldBegin(); + if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { + break; + } + switch (schemeField.id) { + case 0: // SUCCESS + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.success = new Partition(); + struct.success.read(iprot); + struct.setSuccessIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 1: // O1 + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.o1 = new MetaException(); + struct.o1.read(iprot); + struct.setO1IsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // O2 + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.o2 = new NoSuchObjectException(); + struct.o2.read(iprot); + struct.setO2IsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // O3 + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.o3 = new InvalidObjectException(); + struct.o3.read(iprot); + struct.setO3IsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // O4 + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.o4 = new InvalidInputException(); + struct.o4.read(iprot); + struct.setO4IsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + default: + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + iprot.readFieldEnd(); + } + iprot.readStructEnd(); + struct.validate(); + } + + public void write(org.apache.thrift.protocol.TProtocol oprot, exchange_partition_result struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.success != null) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + struct.success.write(oprot); + oprot.writeFieldEnd(); + } + if (struct.o1 != null) { + oprot.writeFieldBegin(O1_FIELD_DESC); + struct.o1.write(oprot); + oprot.writeFieldEnd(); + } + if (struct.o2 != null) { + oprot.writeFieldBegin(O2_FIELD_DESC); + struct.o2.write(oprot); + oprot.writeFieldEnd(); + } + if (struct.o3 != null) { + oprot.writeFieldBegin(O3_FIELD_DESC); + struct.o3.write(oprot); + oprot.writeFieldEnd(); + } + if (struct.o4 != null) { + oprot.writeFieldBegin(O4_FIELD_DESC); + struct.o4.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class exchange_partition_resultTupleSchemeFactory implements SchemeFactory { + public exchange_partition_resultTupleScheme getScheme() { + return new exchange_partition_resultTupleScheme(); + } + } + + private static class exchange_partition_resultTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, exchange_partition_result struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetSuccess()) { + optionals.set(0); + } + if (struct.isSetO1()) { + optionals.set(1); + } + if (struct.isSetO2()) { + optionals.set(2); + } + if (struct.isSetO3()) { + optionals.set(3); + } + if (struct.isSetO4()) { + optionals.set(4); + } + oprot.writeBitSet(optionals, 5); + if (struct.isSetSuccess()) { + struct.success.write(oprot); + } + if (struct.isSetO1()) { + struct.o1.write(oprot); + } + if (struct.isSetO2()) { + struct.o2.write(oprot); + } + if (struct.isSetO3()) { + struct.o3.write(oprot); + } + if (struct.isSetO4()) { + struct.o4.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, exchange_partition_result struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(5); + if (incoming.get(0)) { + struct.success = new Partition(); + struct.success.read(iprot); + struct.setSuccessIsSet(true); + } + if (incoming.get(1)) { + struct.o1 = new MetaException(); + struct.o1.read(iprot); + struct.setO1IsSet(true); + } + if (incoming.get(2)) { + struct.o2 = new NoSuchObjectException(); + struct.o2.read(iprot); + struct.setO2IsSet(true); + } + if (incoming.get(3)) { + struct.o3 = new InvalidObjectException(); + struct.o3.read(iprot); + struct.setO3IsSet(true); + } + if (incoming.get(4)) { + struct.o4 = new InvalidInputException(); + struct.o4.read(iprot); + struct.setO4IsSet(true); + } + } + } + + } + public static class get_partition_with_auth_args implements org.apache.thrift.TBase, java.io.Serializable, Cloneable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("get_partition_with_auth_args"); @@ -46984,17 +48726,17 @@ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap; static { Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class); - tmpMap.put(_Fields.DB_NAME, new org.apache.thrift.meta_data.FieldMetaData("db_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.DB_NAME, new org.apache.thrift.meta_data.FieldMetaData("db_name", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); - tmpMap.put(_Fields.TBL_NAME, new org.apache.thrift.meta_data.FieldMetaData("tbl_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.TBL_NAME, new org.apache.thrift.meta_data.FieldMetaData("tbl_name", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); - tmpMap.put(_Fields.PART_VALS, new org.apache.thrift.meta_data.FieldMetaData("part_vals", org.apache.thrift.TFieldRequirementType.DEFAULT, - new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, + tmpMap.put(_Fields.PART_VALS, new org.apache.thrift.meta_data.FieldMetaData("part_vals", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))); - tmpMap.put(_Fields.USER_NAME, new org.apache.thrift.meta_data.FieldMetaData("user_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.USER_NAME, new org.apache.thrift.meta_data.FieldMetaData("user_name", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); - tmpMap.put(_Fields.GROUP_NAMES, new org.apache.thrift.meta_data.FieldMetaData("group_names", org.apache.thrift.TFieldRequirementType.DEFAULT, - new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, + tmpMap.put(_Fields.GROUP_NAMES, new org.apache.thrift.meta_data.FieldMetaData("group_names", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))); metaDataMap = Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(get_partition_with_auth_args.class, metaDataMap); @@ -47541,7 +49283,7 @@ while (true) { schemeField = iprot.readFieldBegin(); - if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { + if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { break; } switch (schemeField.id) { @@ -47549,7 +49291,7 @@ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { struct.db_name = iprot.readString(); struct.setDb_nameIsSet(true); - } else { + } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; @@ -47557,25 +49299,25 @@ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { struct.tbl_name = iprot.readString(); struct.setTbl_nameIsSet(true); - } else { + } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list386 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list386.size); - for (int _i387 = 0; _i387 < _list386.size; ++_i387) + org.apache.thrift.protocol.TList _list396 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list396.size); + for (int _i397 = 0; _i397 < _list396.size; ++_i397) { - String _elem388; // required - _elem388 = iprot.readString(); - struct.part_vals.add(_elem388); + String _elem398; // required + _elem398 = iprot.readString(); + struct.part_vals.add(_elem398); } iprot.readListEnd(); } struct.setPart_valsIsSet(true); - } else { + } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; @@ -47583,25 +49325,25 @@ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { struct.user_name = iprot.readString(); struct.setUser_nameIsSet(true); - } else { + } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; case 5: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list389 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list389.size); - for (int _i390 = 0; _i390 < _list389.size; ++_i390) + org.apache.thrift.protocol.TList _list399 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list399.size); + for (int _i400 = 0; _i400 < _list399.size; ++_i400) { - String _elem391; // required - _elem391 = iprot.readString(); - struct.group_names.add(_elem391); + String _elem401; // required + _elem401 = iprot.readString(); + struct.group_names.add(_elem401); } iprot.readListEnd(); } struct.setGroup_namesIsSet(true); - } else { + } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; @@ -47632,9 +49374,9 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (String _iter392 : struct.part_vals) + for (String _iter402 : struct.part_vals) { - oprot.writeString(_iter392); + oprot.writeString(_iter402); } oprot.writeListEnd(); } @@ -47649,9 +49391,9 @@ oprot.writeFieldBegin(GROUP_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.group_names.size())); - for (String _iter393 : struct.group_names) + for (String _iter403 : struct.group_names) { - oprot.writeString(_iter393); + oprot.writeString(_iter403); } oprot.writeListEnd(); } @@ -47700,9 +49442,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter394 : struct.part_vals) + for (String _iter404 : struct.part_vals) { - oprot.writeString(_iter394); + oprot.writeString(_iter404); } } } @@ -47712,9 +49454,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter395 : struct.group_names) + for (String _iter405 : struct.group_names) { - oprot.writeString(_iter395); + oprot.writeString(_iter405); } } } @@ -47734,13 +49476,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list396 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list396.size); - for (int _i397 = 0; _i397 < _list396.size; ++_i397) + org.apache.thrift.protocol.TList _list406 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list406.size); + for (int _i407 = 0; _i407 < _list406.size; ++_i407) { - String _elem398; // required - _elem398 = iprot.readString(); - struct.part_vals.add(_elem398); + String _elem408; // required + _elem408 = iprot.readString(); + struct.part_vals.add(_elem408); } } struct.setPart_valsIsSet(true); @@ -47751,13 +49493,13 @@ } if (incoming.get(4)) { { - org.apache.thrift.protocol.TList _list399 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list399.size); - for (int _i400 = 0; _i400 < _list399.size; ++_i400) + org.apache.thrift.protocol.TList _list409 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list409.size); + for (int _i410 = 0; _i410 < _list409.size; ++_i410) { - String _elem401; // required - _elem401 = iprot.readString(); - struct.group_names.add(_elem401); + String _elem411; // required + _elem411 = iprot.readString(); + struct.group_names.add(_elem411); } } struct.setGroup_namesIsSet(true); @@ -47852,11 +49594,11 @@ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap; static { Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class); - tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Partition.class))); - tmpMap.put(_Fields.O1, new org.apache.thrift.meta_data.FieldMetaData("o1", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.O1, new org.apache.thrift.meta_data.FieldMetaData("o1", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT))); - tmpMap.put(_Fields.O2, new org.apache.thrift.meta_data.FieldMetaData("o2", org.apache.thrift.TFieldRequirementType.DEFAULT, + tmpMap.put(_Fields.O2, new org.apache.thrift.meta_data.FieldMetaData("o2", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT))); metaDataMap = Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(get_partition_with_auth_result.class, metaDataMap); @@ -50526,14 +52268,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list402 = iprot.readListBegin(); - struct.success = new ArrayList(_list402.size); - for (int _i403 = 0; _i403 < _list402.size; ++_i403) + org.apache.thrift.protocol.TList _list412 = iprot.readListBegin(); + struct.success = new ArrayList(_list412.size); + for (int _i413 = 0; _i413 < _list412.size; ++_i413) { - Partition _elem404; // required - _elem404 = new Partition(); - _elem404.read(iprot); - struct.success.add(_elem404); + Partition _elem414; // required + _elem414 = new Partition(); + _elem414.read(iprot); + struct.success.add(_elem414); } iprot.readListEnd(); } @@ -50577,9 +52319,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Partition _iter405 : struct.success) + for (Partition _iter415 : struct.success) { - _iter405.write(oprot); + _iter415.write(oprot); } oprot.writeListEnd(); } @@ -50626,9 +52368,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter406 : struct.success) + for (Partition _iter416 : struct.success) { - _iter406.write(oprot); + _iter416.write(oprot); } } } @@ -50646,14 +52388,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list407 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list407.size); - for (int _i408 = 0; _i408 < _list407.size; ++_i408) + org.apache.thrift.protocol.TList _list417 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list417.size); + for (int _i418 = 0; _i418 < _list417.size; ++_i418) { - Partition _elem409; // required - _elem409 = new Partition(); - _elem409.read(iprot); - struct.success.add(_elem409); + Partition _elem419; // required + _elem419 = new Partition(); + _elem419.read(iprot); + struct.success.add(_elem419); } } struct.setSuccessIsSet(true); @@ -51346,13 +53088,13 @@ case 5: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list410 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list410.size); - for (int _i411 = 0; _i411 < _list410.size; ++_i411) + org.apache.thrift.protocol.TList _list420 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list420.size); + for (int _i421 = 0; _i421 < _list420.size; ++_i421) { - String _elem412; // required - _elem412 = iprot.readString(); - struct.group_names.add(_elem412); + String _elem422; // required + _elem422 = iprot.readString(); + struct.group_names.add(_elem422); } iprot.readListEnd(); } @@ -51396,9 +53138,9 @@ oprot.writeFieldBegin(GROUP_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.group_names.size())); - for (String _iter413 : struct.group_names) + for (String _iter423 : struct.group_names) { - oprot.writeString(_iter413); + oprot.writeString(_iter423); } oprot.writeListEnd(); } @@ -51453,9 +53195,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter414 : struct.group_names) + for (String _iter424 : struct.group_names) { - oprot.writeString(_iter414); + oprot.writeString(_iter424); } } } @@ -51483,13 +53225,13 @@ } if (incoming.get(4)) { { - org.apache.thrift.protocol.TList _list415 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list415.size); - for (int _i416 = 0; _i416 < _list415.size; ++_i416) + org.apache.thrift.protocol.TList _list425 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list425.size); + for (int _i426 = 0; _i426 < _list425.size; ++_i426) { - String _elem417; // required - _elem417 = iprot.readString(); - struct.group_names.add(_elem417); + String _elem427; // required + _elem427 = iprot.readString(); + struct.group_names.add(_elem427); } } struct.setGroup_namesIsSet(true); @@ -51976,14 +53718,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list418 = iprot.readListBegin(); - struct.success = new ArrayList(_list418.size); - for (int _i419 = 0; _i419 < _list418.size; ++_i419) + org.apache.thrift.protocol.TList _list428 = iprot.readListBegin(); + struct.success = new ArrayList(_list428.size); + for (int _i429 = 0; _i429 < _list428.size; ++_i429) { - Partition _elem420; // required - _elem420 = new Partition(); - _elem420.read(iprot); - struct.success.add(_elem420); + Partition _elem430; // required + _elem430 = new Partition(); + _elem430.read(iprot); + struct.success.add(_elem430); } iprot.readListEnd(); } @@ -52027,9 +53769,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Partition _iter421 : struct.success) + for (Partition _iter431 : struct.success) { - _iter421.write(oprot); + _iter431.write(oprot); } oprot.writeListEnd(); } @@ -52076,9 +53818,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter422 : struct.success) + for (Partition _iter432 : struct.success) { - _iter422.write(oprot); + _iter432.write(oprot); } } } @@ -52096,14 +53838,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list423 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list423.size); - for (int _i424 = 0; _i424 < _list423.size; ++_i424) + org.apache.thrift.protocol.TList _list433 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list433.size); + for (int _i434 = 0; _i434 < _list433.size; ++_i434) { - Partition _elem425; // required - _elem425 = new Partition(); - _elem425.read(iprot); - struct.success.add(_elem425); + Partition _elem435; // required + _elem435 = new Partition(); + _elem435.read(iprot); + struct.success.add(_elem435); } } struct.setSuccessIsSet(true); @@ -53085,13 +54827,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list426 = iprot.readListBegin(); - struct.success = new ArrayList(_list426.size); - for (int _i427 = 0; _i427 < _list426.size; ++_i427) + org.apache.thrift.protocol.TList _list436 = iprot.readListBegin(); + struct.success = new ArrayList(_list436.size); + for (int _i437 = 0; _i437 < _list436.size; ++_i437) { - String _elem428; // required - _elem428 = iprot.readString(); - struct.success.add(_elem428); + String _elem438; // required + _elem438 = iprot.readString(); + struct.success.add(_elem438); } iprot.readListEnd(); } @@ -53126,9 +54868,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (String _iter429 : struct.success) + for (String _iter439 : struct.success) { - oprot.writeString(_iter429); + oprot.writeString(_iter439); } oprot.writeListEnd(); } @@ -53167,9 +54909,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter430 : struct.success) + for (String _iter440 : struct.success) { - oprot.writeString(_iter430); + oprot.writeString(_iter440); } } } @@ -53184,13 +54926,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list431 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list431.size); - for (int _i432 = 0; _i432 < _list431.size; ++_i432) + org.apache.thrift.protocol.TList _list441 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list441.size); + for (int _i442 = 0; _i442 < _list441.size; ++_i442) { - String _elem433; // required - _elem433 = iprot.readString(); - struct.success.add(_elem433); + String _elem443; // required + _elem443 = iprot.readString(); + struct.success.add(_elem443); } } struct.setSuccessIsSet(true); @@ -53781,13 +55523,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list434 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list434.size); - for (int _i435 = 0; _i435 < _list434.size; ++_i435) + org.apache.thrift.protocol.TList _list444 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list444.size); + for (int _i445 = 0; _i445 < _list444.size; ++_i445) { - String _elem436; // required - _elem436 = iprot.readString(); - struct.part_vals.add(_elem436); + String _elem446; // required + _elem446 = iprot.readString(); + struct.part_vals.add(_elem446); } iprot.readListEnd(); } @@ -53831,9 +55573,9 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (String _iter437 : struct.part_vals) + for (String _iter447 : struct.part_vals) { - oprot.writeString(_iter437); + oprot.writeString(_iter447); } oprot.writeListEnd(); } @@ -53882,9 +55624,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter438 : struct.part_vals) + for (String _iter448 : struct.part_vals) { - oprot.writeString(_iter438); + oprot.writeString(_iter448); } } } @@ -53907,13 +55649,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list439 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list439.size); - for (int _i440 = 0; _i440 < _list439.size; ++_i440) + org.apache.thrift.protocol.TList _list449 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list449.size); + for (int _i450 = 0; _i450 < _list449.size; ++_i450) { - String _elem441; // required - _elem441 = iprot.readString(); - struct.part_vals.add(_elem441); + String _elem451; // required + _elem451 = iprot.readString(); + struct.part_vals.add(_elem451); } } struct.setPart_valsIsSet(true); @@ -54404,14 +56146,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list442 = iprot.readListBegin(); - struct.success = new ArrayList(_list442.size); - for (int _i443 = 0; _i443 < _list442.size; ++_i443) + org.apache.thrift.protocol.TList _list452 = iprot.readListBegin(); + struct.success = new ArrayList(_list452.size); + for (int _i453 = 0; _i453 < _list452.size; ++_i453) { - Partition _elem444; // required - _elem444 = new Partition(); - _elem444.read(iprot); - struct.success.add(_elem444); + Partition _elem454; // required + _elem454 = new Partition(); + _elem454.read(iprot); + struct.success.add(_elem454); } iprot.readListEnd(); } @@ -54455,9 +56197,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Partition _iter445 : struct.success) + for (Partition _iter455 : struct.success) { - _iter445.write(oprot); + _iter455.write(oprot); } oprot.writeListEnd(); } @@ -54504,9 +56246,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter446 : struct.success) + for (Partition _iter456 : struct.success) { - _iter446.write(oprot); + _iter456.write(oprot); } } } @@ -54524,14 +56266,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list447 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list447.size); - for (int _i448 = 0; _i448 < _list447.size; ++_i448) + org.apache.thrift.protocol.TList _list457 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list457.size); + for (int _i458 = 0; _i458 < _list457.size; ++_i458) { - Partition _elem449; // required - _elem449 = new Partition(); - _elem449.read(iprot); - struct.success.add(_elem449); + Partition _elem459; // required + _elem459 = new Partition(); + _elem459.read(iprot); + struct.success.add(_elem459); } } struct.setSuccessIsSet(true); @@ -55309,13 +57051,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list450 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list450.size); - for (int _i451 = 0; _i451 < _list450.size; ++_i451) + org.apache.thrift.protocol.TList _list460 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list460.size); + for (int _i461 = 0; _i461 < _list460.size; ++_i461) { - String _elem452; // required - _elem452 = iprot.readString(); - struct.part_vals.add(_elem452); + String _elem462; // required + _elem462 = iprot.readString(); + struct.part_vals.add(_elem462); } iprot.readListEnd(); } @@ -55343,13 +57085,13 @@ case 6: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list453 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list453.size); - for (int _i454 = 0; _i454 < _list453.size; ++_i454) + org.apache.thrift.protocol.TList _list463 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list463.size); + for (int _i464 = 0; _i464 < _list463.size; ++_i464) { - String _elem455; // required - _elem455 = iprot.readString(); - struct.group_names.add(_elem455); + String _elem465; // required + _elem465 = iprot.readString(); + struct.group_names.add(_elem465); } iprot.readListEnd(); } @@ -55385,9 +57127,9 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (String _iter456 : struct.part_vals) + for (String _iter466 : struct.part_vals) { - oprot.writeString(_iter456); + oprot.writeString(_iter466); } oprot.writeListEnd(); } @@ -55405,9 +57147,9 @@ oprot.writeFieldBegin(GROUP_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.group_names.size())); - for (String _iter457 : struct.group_names) + for (String _iter467 : struct.group_names) { - oprot.writeString(_iter457); + oprot.writeString(_iter467); } oprot.writeListEnd(); } @@ -55459,9 +57201,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter458 : struct.part_vals) + for (String _iter468 : struct.part_vals) { - oprot.writeString(_iter458); + oprot.writeString(_iter468); } } } @@ -55474,9 +57216,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter459 : struct.group_names) + for (String _iter469 : struct.group_names) { - oprot.writeString(_iter459); + oprot.writeString(_iter469); } } } @@ -55496,13 +57238,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list460 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list460.size); - for (int _i461 = 0; _i461 < _list460.size; ++_i461) + org.apache.thrift.protocol.TList _list470 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list470.size); + for (int _i471 = 0; _i471 < _list470.size; ++_i471) { - String _elem462; // required - _elem462 = iprot.readString(); - struct.part_vals.add(_elem462); + String _elem472; // required + _elem472 = iprot.readString(); + struct.part_vals.add(_elem472); } } struct.setPart_valsIsSet(true); @@ -55517,13 +57259,13 @@ } if (incoming.get(5)) { { - org.apache.thrift.protocol.TList _list463 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list463.size); - for (int _i464 = 0; _i464 < _list463.size; ++_i464) + org.apache.thrift.protocol.TList _list473 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list473.size); + for (int _i474 = 0; _i474 < _list473.size; ++_i474) { - String _elem465; // required - _elem465 = iprot.readString(); - struct.group_names.add(_elem465); + String _elem475; // required + _elem475 = iprot.readString(); + struct.group_names.add(_elem475); } } struct.setGroup_namesIsSet(true); @@ -56010,14 +57752,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list466 = iprot.readListBegin(); - struct.success = new ArrayList(_list466.size); - for (int _i467 = 0; _i467 < _list466.size; ++_i467) + org.apache.thrift.protocol.TList _list476 = iprot.readListBegin(); + struct.success = new ArrayList(_list476.size); + for (int _i477 = 0; _i477 < _list476.size; ++_i477) { - Partition _elem468; // required - _elem468 = new Partition(); - _elem468.read(iprot); - struct.success.add(_elem468); + Partition _elem478; // required + _elem478 = new Partition(); + _elem478.read(iprot); + struct.success.add(_elem478); } iprot.readListEnd(); } @@ -56061,9 +57803,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Partition _iter469 : struct.success) + for (Partition _iter479 : struct.success) { - _iter469.write(oprot); + _iter479.write(oprot); } oprot.writeListEnd(); } @@ -56110,9 +57852,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter470 : struct.success) + for (Partition _iter480 : struct.success) { - _iter470.write(oprot); + _iter480.write(oprot); } } } @@ -56130,14 +57872,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list471 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list471.size); - for (int _i472 = 0; _i472 < _list471.size; ++_i472) + org.apache.thrift.protocol.TList _list481 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list481.size); + for (int _i482 = 0; _i482 < _list481.size; ++_i482) { - Partition _elem473; // required - _elem473 = new Partition(); - _elem473.read(iprot); - struct.success.add(_elem473); + Partition _elem483; // required + _elem483 = new Partition(); + _elem483.read(iprot); + struct.success.add(_elem483); } } struct.setSuccessIsSet(true); @@ -56733,13 +58475,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list474 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list474.size); - for (int _i475 = 0; _i475 < _list474.size; ++_i475) + org.apache.thrift.protocol.TList _list484 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list484.size); + for (int _i485 = 0; _i485 < _list484.size; ++_i485) { - String _elem476; // required - _elem476 = iprot.readString(); - struct.part_vals.add(_elem476); + String _elem486; // required + _elem486 = iprot.readString(); + struct.part_vals.add(_elem486); } iprot.readListEnd(); } @@ -56783,9 +58525,9 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (String _iter477 : struct.part_vals) + for (String _iter487 : struct.part_vals) { - oprot.writeString(_iter477); + oprot.writeString(_iter487); } oprot.writeListEnd(); } @@ -56834,9 +58576,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter478 : struct.part_vals) + for (String _iter488 : struct.part_vals) { - oprot.writeString(_iter478); + oprot.writeString(_iter488); } } } @@ -56859,13 +58601,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list479 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list479.size); - for (int _i480 = 0; _i480 < _list479.size; ++_i480) + org.apache.thrift.protocol.TList _list489 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list489.size); + for (int _i490 = 0; _i490 < _list489.size; ++_i490) { - String _elem481; // required - _elem481 = iprot.readString(); - struct.part_vals.add(_elem481); + String _elem491; // required + _elem491 = iprot.readString(); + struct.part_vals.add(_elem491); } } struct.setPart_valsIsSet(true); @@ -57356,13 +59098,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list482 = iprot.readListBegin(); - struct.success = new ArrayList(_list482.size); - for (int _i483 = 0; _i483 < _list482.size; ++_i483) + org.apache.thrift.protocol.TList _list492 = iprot.readListBegin(); + struct.success = new ArrayList(_list492.size); + for (int _i493 = 0; _i493 < _list492.size; ++_i493) { - String _elem484; // required - _elem484 = iprot.readString(); - struct.success.add(_elem484); + String _elem494; // required + _elem494 = iprot.readString(); + struct.success.add(_elem494); } iprot.readListEnd(); } @@ -57406,9 +59148,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (String _iter485 : struct.success) + for (String _iter495 : struct.success) { - oprot.writeString(_iter485); + oprot.writeString(_iter495); } oprot.writeListEnd(); } @@ -57455,9 +59197,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter486 : struct.success) + for (String _iter496 : struct.success) { - oprot.writeString(_iter486); + oprot.writeString(_iter496); } } } @@ -57475,13 +59217,13 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list487 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list487.size); - for (int _i488 = 0; _i488 < _list487.size; ++_i488) + org.apache.thrift.protocol.TList _list497 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list497.size); + for (int _i498 = 0; _i498 < _list497.size; ++_i498) { - String _elem489; // required - _elem489 = iprot.readString(); - struct.success.add(_elem489); + String _elem499; // required + _elem499 = iprot.readString(); + struct.success.add(_elem499); } } struct.setSuccessIsSet(true); @@ -58648,14 +60390,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list490 = iprot.readListBegin(); - struct.success = new ArrayList(_list490.size); - for (int _i491 = 0; _i491 < _list490.size; ++_i491) + org.apache.thrift.protocol.TList _list500 = iprot.readListBegin(); + struct.success = new ArrayList(_list500.size); + for (int _i501 = 0; _i501 < _list500.size; ++_i501) { - Partition _elem492; // required - _elem492 = new Partition(); - _elem492.read(iprot); - struct.success.add(_elem492); + Partition _elem502; // required + _elem502 = new Partition(); + _elem502.read(iprot); + struct.success.add(_elem502); } iprot.readListEnd(); } @@ -58699,9 +60441,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Partition _iter493 : struct.success) + for (Partition _iter503 : struct.success) { - _iter493.write(oprot); + _iter503.write(oprot); } oprot.writeListEnd(); } @@ -58748,9 +60490,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter494 : struct.success) + for (Partition _iter504 : struct.success) { - _iter494.write(oprot); + _iter504.write(oprot); } } } @@ -58768,14 +60510,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list495 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list495.size); - for (int _i496 = 0; _i496 < _list495.size; ++_i496) + org.apache.thrift.protocol.TList _list505 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list505.size); + for (int _i506 = 0; _i506 < _list505.size; ++_i506) { - Partition _elem497; // required - _elem497 = new Partition(); - _elem497.read(iprot); - struct.success.add(_elem497); + Partition _elem507; // required + _elem507 = new Partition(); + _elem507.read(iprot); + struct.success.add(_elem507); } } struct.setSuccessIsSet(true); @@ -59288,13 +61030,13 @@ case 3: // NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list498 = iprot.readListBegin(); - struct.names = new ArrayList(_list498.size); - for (int _i499 = 0; _i499 < _list498.size; ++_i499) + org.apache.thrift.protocol.TList _list508 = iprot.readListBegin(); + struct.names = new ArrayList(_list508.size); + for (int _i509 = 0; _i509 < _list508.size; ++_i509) { - String _elem500; // required - _elem500 = iprot.readString(); - struct.names.add(_elem500); + String _elem510; // required + _elem510 = iprot.readString(); + struct.names.add(_elem510); } iprot.readListEnd(); } @@ -59330,9 +61072,9 @@ oprot.writeFieldBegin(NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.names.size())); - for (String _iter501 : struct.names) + for (String _iter511 : struct.names) { - oprot.writeString(_iter501); + oprot.writeString(_iter511); } oprot.writeListEnd(); } @@ -59375,9 +61117,9 @@ if (struct.isSetNames()) { { oprot.writeI32(struct.names.size()); - for (String _iter502 : struct.names) + for (String _iter512 : struct.names) { - oprot.writeString(_iter502); + oprot.writeString(_iter512); } } } @@ -59397,13 +61139,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list503 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.names = new ArrayList(_list503.size); - for (int _i504 = 0; _i504 < _list503.size; ++_i504) + org.apache.thrift.protocol.TList _list513 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.names = new ArrayList(_list513.size); + for (int _i514 = 0; _i514 < _list513.size; ++_i514) { - String _elem505; // required - _elem505 = iprot.readString(); - struct.names.add(_elem505); + String _elem515; // required + _elem515 = iprot.readString(); + struct.names.add(_elem515); } } struct.setNamesIsSet(true); @@ -59890,14 +61632,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list506 = iprot.readListBegin(); - struct.success = new ArrayList(_list506.size); - for (int _i507 = 0; _i507 < _list506.size; ++_i507) + org.apache.thrift.protocol.TList _list516 = iprot.readListBegin(); + struct.success = new ArrayList(_list516.size); + for (int _i517 = 0; _i517 < _list516.size; ++_i517) { - Partition _elem508; // required - _elem508 = new Partition(); - _elem508.read(iprot); - struct.success.add(_elem508); + Partition _elem518; // required + _elem518 = new Partition(); + _elem518.read(iprot); + struct.success.add(_elem518); } iprot.readListEnd(); } @@ -59941,9 +61683,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Partition _iter509 : struct.success) + for (Partition _iter519 : struct.success) { - _iter509.write(oprot); + _iter519.write(oprot); } oprot.writeListEnd(); } @@ -59990,9 +61732,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter510 : struct.success) + for (Partition _iter520 : struct.success) { - _iter510.write(oprot); + _iter520.write(oprot); } } } @@ -60010,14 +61752,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list511 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list511.size); - for (int _i512 = 0; _i512 < _list511.size; ++_i512) + org.apache.thrift.protocol.TList _list521 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list521.size); + for (int _i522 = 0; _i522 < _list521.size; ++_i522) { - Partition _elem513; // required - _elem513 = new Partition(); - _elem513.read(iprot); - struct.success.add(_elem513); + Partition _elem523; // required + _elem523 = new Partition(); + _elem523.read(iprot); + struct.success.add(_elem523); } } struct.setSuccessIsSet(true); @@ -61567,14 +63309,14 @@ case 3: // NEW_PARTS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list514 = iprot.readListBegin(); - struct.new_parts = new ArrayList(_list514.size); - for (int _i515 = 0; _i515 < _list514.size; ++_i515) + org.apache.thrift.protocol.TList _list524 = iprot.readListBegin(); + struct.new_parts = new ArrayList(_list524.size); + for (int _i525 = 0; _i525 < _list524.size; ++_i525) { - Partition _elem516; // required - _elem516 = new Partition(); - _elem516.read(iprot); - struct.new_parts.add(_elem516); + Partition _elem526; // required + _elem526 = new Partition(); + _elem526.read(iprot); + struct.new_parts.add(_elem526); } iprot.readListEnd(); } @@ -61610,9 +63352,9 @@ oprot.writeFieldBegin(NEW_PARTS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.new_parts.size())); - for (Partition _iter517 : struct.new_parts) + for (Partition _iter527 : struct.new_parts) { - _iter517.write(oprot); + _iter527.write(oprot); } oprot.writeListEnd(); } @@ -61655,9 +63397,9 @@ if (struct.isSetNew_parts()) { { oprot.writeI32(struct.new_parts.size()); - for (Partition _iter518 : struct.new_parts) + for (Partition _iter528 : struct.new_parts) { - _iter518.write(oprot); + _iter528.write(oprot); } } } @@ -61677,14 +63419,14 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list519 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.new_parts = new ArrayList(_list519.size); - for (int _i520 = 0; _i520 < _list519.size; ++_i520) + org.apache.thrift.protocol.TList _list529 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.new_parts = new ArrayList(_list529.size); + for (int _i530 = 0; _i530 < _list529.size; ++_i530) { - Partition _elem521; // required - _elem521 = new Partition(); - _elem521.read(iprot); - struct.new_parts.add(_elem521); + Partition _elem531; // required + _elem531 = new Partition(); + _elem531.read(iprot); + struct.new_parts.add(_elem531); } } struct.setNew_partsIsSet(true); @@ -63883,13 +65625,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list522 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list522.size); - for (int _i523 = 0; _i523 < _list522.size; ++_i523) + org.apache.thrift.protocol.TList _list532 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list532.size); + for (int _i533 = 0; _i533 < _list532.size; ++_i533) { - String _elem524; // required - _elem524 = iprot.readString(); - struct.part_vals.add(_elem524); + String _elem534; // required + _elem534 = iprot.readString(); + struct.part_vals.add(_elem534); } iprot.readListEnd(); } @@ -63934,9 +65676,9 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (String _iter525 : struct.part_vals) + for (String _iter535 : struct.part_vals) { - oprot.writeString(_iter525); + oprot.writeString(_iter535); } oprot.writeListEnd(); } @@ -63987,9 +65729,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter526 : struct.part_vals) + for (String _iter536 : struct.part_vals) { - oprot.writeString(_iter526); + oprot.writeString(_iter536); } } } @@ -64012,13 +65754,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list527 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list527.size); - for (int _i528 = 0; _i528 < _list527.size; ++_i528) + org.apache.thrift.protocol.TList _list537 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list537.size); + for (int _i538 = 0; _i538 < _list537.size; ++_i538) { - String _elem529; // required - _elem529 = iprot.readString(); - struct.part_vals.add(_elem529); + String _elem539; // required + _elem539 = iprot.readString(); + struct.part_vals.add(_elem539); } } struct.setPart_valsIsSet(true); @@ -64895,13 +66637,13 @@ case 1: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list530 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list530.size); - for (int _i531 = 0; _i531 < _list530.size; ++_i531) + org.apache.thrift.protocol.TList _list540 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list540.size); + for (int _i541 = 0; _i541 < _list540.size; ++_i541) { - String _elem532; // required - _elem532 = iprot.readString(); - struct.part_vals.add(_elem532); + String _elem542; // required + _elem542 = iprot.readString(); + struct.part_vals.add(_elem542); } iprot.readListEnd(); } @@ -64935,9 +66677,9 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (String _iter533 : struct.part_vals) + for (String _iter543 : struct.part_vals) { - oprot.writeString(_iter533); + oprot.writeString(_iter543); } oprot.writeListEnd(); } @@ -64974,9 +66716,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter534 : struct.part_vals) + for (String _iter544 : struct.part_vals) { - oprot.writeString(_iter534); + oprot.writeString(_iter544); } } } @@ -64991,13 +66733,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list535 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list535.size); - for (int _i536 = 0; _i536 < _list535.size; ++_i536) + org.apache.thrift.protocol.TList _list545 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list545.size); + for (int _i546 = 0; _i546 < _list545.size; ++_i546) { - String _elem537; // required - _elem537 = iprot.readString(); - struct.part_vals.add(_elem537); + String _elem547; // required + _elem547 = iprot.readString(); + struct.part_vals.add(_elem547); } } struct.setPart_valsIsSet(true); @@ -67155,13 +68897,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list538 = iprot.readListBegin(); - struct.success = new ArrayList(_list538.size); - for (int _i539 = 0; _i539 < _list538.size; ++_i539) + org.apache.thrift.protocol.TList _list548 = iprot.readListBegin(); + struct.success = new ArrayList(_list548.size); + for (int _i549 = 0; _i549 < _list548.size; ++_i549) { - String _elem540; // required - _elem540 = iprot.readString(); - struct.success.add(_elem540); + String _elem550; // required + _elem550 = iprot.readString(); + struct.success.add(_elem550); } iprot.readListEnd(); } @@ -67196,9 +68938,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (String _iter541 : struct.success) + for (String _iter551 : struct.success) { - oprot.writeString(_iter541); + oprot.writeString(_iter551); } oprot.writeListEnd(); } @@ -67237,9 +68979,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter542 : struct.success) + for (String _iter552 : struct.success) { - oprot.writeString(_iter542); + oprot.writeString(_iter552); } } } @@ -67254,13 +68996,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list543 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list543.size); - for (int _i544 = 0; _i544 < _list543.size; ++_i544) + org.apache.thrift.protocol.TList _list553 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list553.size); + for (int _i554 = 0; _i554 < _list553.size; ++_i554) { - String _elem545; // required - _elem545 = iprot.readString(); - struct.success.add(_elem545); + String _elem555; // required + _elem555 = iprot.readString(); + struct.success.add(_elem555); } } struct.setSuccessIsSet(true); @@ -68034,15 +69776,15 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map546 = iprot.readMapBegin(); - struct.success = new HashMap(2*_map546.size); - for (int _i547 = 0; _i547 < _map546.size; ++_i547) + org.apache.thrift.protocol.TMap _map556 = iprot.readMapBegin(); + struct.success = new HashMap(2*_map556.size); + for (int _i557 = 0; _i557 < _map556.size; ++_i557) { - String _key548; // required - String _val549; // required - _key548 = iprot.readString(); - _val549 = iprot.readString(); - struct.success.put(_key548, _val549); + String _key558; // required + String _val559; // required + _key558 = iprot.readString(); + _val559 = iprot.readString(); + struct.success.put(_key558, _val559); } iprot.readMapEnd(); } @@ -68077,10 +69819,10 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (Map.Entry _iter550 : struct.success.entrySet()) + for (Map.Entry _iter560 : struct.success.entrySet()) { - oprot.writeString(_iter550.getKey()); - oprot.writeString(_iter550.getValue()); + oprot.writeString(_iter560.getKey()); + oprot.writeString(_iter560.getValue()); } oprot.writeMapEnd(); } @@ -68119,10 +69861,10 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Map.Entry _iter551 : struct.success.entrySet()) + for (Map.Entry _iter561 : struct.success.entrySet()) { - oprot.writeString(_iter551.getKey()); - oprot.writeString(_iter551.getValue()); + oprot.writeString(_iter561.getKey()); + oprot.writeString(_iter561.getValue()); } } } @@ -68137,15 +69879,15 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TMap _map552 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new HashMap(2*_map552.size); - for (int _i553 = 0; _i553 < _map552.size; ++_i553) + org.apache.thrift.protocol.TMap _map562 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new HashMap(2*_map562.size); + for (int _i563 = 0; _i563 < _map562.size; ++_i563) { - String _key554; // required - String _val555; // required - _key554 = iprot.readString(); - _val555 = iprot.readString(); - struct.success.put(_key554, _val555); + String _key564; // required + String _val565; // required + _key564 = iprot.readString(); + _val565 = iprot.readString(); + struct.success.put(_key564, _val565); } } struct.setSuccessIsSet(true); @@ -68751,15 +70493,15 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map556 = iprot.readMapBegin(); - struct.part_vals = new HashMap(2*_map556.size); - for (int _i557 = 0; _i557 < _map556.size; ++_i557) + org.apache.thrift.protocol.TMap _map566 = iprot.readMapBegin(); + struct.part_vals = new HashMap(2*_map566.size); + for (int _i567 = 0; _i567 < _map566.size; ++_i567) { - String _key558; // required - String _val559; // required - _key558 = iprot.readString(); - _val559 = iprot.readString(); - struct.part_vals.put(_key558, _val559); + String _key568; // required + String _val569; // required + _key568 = iprot.readString(); + _val569 = iprot.readString(); + struct.part_vals.put(_key568, _val569); } iprot.readMapEnd(); } @@ -68803,10 +70545,10 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (Map.Entry _iter560 : struct.part_vals.entrySet()) + for (Map.Entry _iter570 : struct.part_vals.entrySet()) { - oprot.writeString(_iter560.getKey()); - oprot.writeString(_iter560.getValue()); + oprot.writeString(_iter570.getKey()); + oprot.writeString(_iter570.getValue()); } oprot.writeMapEnd(); } @@ -68857,10 +70599,10 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (Map.Entry _iter561 : struct.part_vals.entrySet()) + for (Map.Entry _iter571 : struct.part_vals.entrySet()) { - oprot.writeString(_iter561.getKey()); - oprot.writeString(_iter561.getValue()); + oprot.writeString(_iter571.getKey()); + oprot.writeString(_iter571.getValue()); } } } @@ -68883,15 +70625,15 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TMap _map562 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new HashMap(2*_map562.size); - for (int _i563 = 0; _i563 < _map562.size; ++_i563) + org.apache.thrift.protocol.TMap _map572 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new HashMap(2*_map572.size); + for (int _i573 = 0; _i573 < _map572.size; ++_i573) { - String _key564; // required - String _val565; // required - _key564 = iprot.readString(); - _val565 = iprot.readString(); - struct.part_vals.put(_key564, _val565); + String _key574; // required + String _val575; // required + _key574 = iprot.readString(); + _val575 = iprot.readString(); + struct.part_vals.put(_key574, _val575); } } struct.setPart_valsIsSet(true); @@ -70386,15 +72128,15 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map566 = iprot.readMapBegin(); - struct.part_vals = new HashMap(2*_map566.size); - for (int _i567 = 0; _i567 < _map566.size; ++_i567) + org.apache.thrift.protocol.TMap _map576 = iprot.readMapBegin(); + struct.part_vals = new HashMap(2*_map576.size); + for (int _i577 = 0; _i577 < _map576.size; ++_i577) { - String _key568; // required - String _val569; // required - _key568 = iprot.readString(); - _val569 = iprot.readString(); - struct.part_vals.put(_key568, _val569); + String _key578; // required + String _val579; // required + _key578 = iprot.readString(); + _val579 = iprot.readString(); + struct.part_vals.put(_key578, _val579); } iprot.readMapEnd(); } @@ -70438,10 +72180,10 @@ oprot.writeFieldBegin(PART_VALS_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.part_vals.size())); - for (Map.Entry _iter570 : struct.part_vals.entrySet()) + for (Map.Entry _iter580 : struct.part_vals.entrySet()) { - oprot.writeString(_iter570.getKey()); - oprot.writeString(_iter570.getValue()); + oprot.writeString(_iter580.getKey()); + oprot.writeString(_iter580.getValue()); } oprot.writeMapEnd(); } @@ -70492,10 +72234,10 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (Map.Entry _iter571 : struct.part_vals.entrySet()) + for (Map.Entry _iter581 : struct.part_vals.entrySet()) { - oprot.writeString(_iter571.getKey()); - oprot.writeString(_iter571.getValue()); + oprot.writeString(_iter581.getKey()); + oprot.writeString(_iter581.getValue()); } } } @@ -70518,15 +72260,15 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TMap _map572 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new HashMap(2*_map572.size); - for (int _i573 = 0; _i573 < _map572.size; ++_i573) + org.apache.thrift.protocol.TMap _map582 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new HashMap(2*_map582.size); + for (int _i583 = 0; _i583 < _map582.size; ++_i583) { - String _key574; // required - String _val575; // required - _key574 = iprot.readString(); - _val575 = iprot.readString(); - struct.part_vals.put(_key574, _val575); + String _key584; // required + String _val585; // required + _key584 = iprot.readString(); + _val585 = iprot.readString(); + struct.part_vals.put(_key584, _val585); } } struct.setPart_valsIsSet(true); @@ -77250,14 +78992,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list576 = iprot.readListBegin(); - struct.success = new ArrayList(_list576.size); - for (int _i577 = 0; _i577 < _list576.size; ++_i577) + org.apache.thrift.protocol.TList _list586 = iprot.readListBegin(); + struct.success = new ArrayList(_list586.size); + for (int _i587 = 0; _i587 < _list586.size; ++_i587) { - Index _elem578; // required - _elem578 = new Index(); - _elem578.read(iprot); - struct.success.add(_elem578); + Index _elem588; // required + _elem588 = new Index(); + _elem588.read(iprot); + struct.success.add(_elem588); } iprot.readListEnd(); } @@ -77301,9 +79043,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Index _iter579 : struct.success) + for (Index _iter589 : struct.success) { - _iter579.write(oprot); + _iter589.write(oprot); } oprot.writeListEnd(); } @@ -77350,9 +79092,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Index _iter580 : struct.success) + for (Index _iter590 : struct.success) { - _iter580.write(oprot); + _iter590.write(oprot); } } } @@ -77370,14 +79112,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list581 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list581.size); - for (int _i582 = 0; _i582 < _list581.size; ++_i582) + org.apache.thrift.protocol.TList _list591 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list591.size); + for (int _i592 = 0; _i592 < _list591.size; ++_i592) { - Index _elem583; // required - _elem583 = new Index(); - _elem583.read(iprot); - struct.success.add(_elem583); + Index _elem593; // required + _elem593 = new Index(); + _elem593.read(iprot); + struct.success.add(_elem593); } } struct.setSuccessIsSet(true); @@ -78359,13 +80101,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list584 = iprot.readListBegin(); - struct.success = new ArrayList(_list584.size); - for (int _i585 = 0; _i585 < _list584.size; ++_i585) + org.apache.thrift.protocol.TList _list594 = iprot.readListBegin(); + struct.success = new ArrayList(_list594.size); + for (int _i595 = 0; _i595 < _list594.size; ++_i595) { - String _elem586; // required - _elem586 = iprot.readString(); - struct.success.add(_elem586); + String _elem596; // required + _elem596 = iprot.readString(); + struct.success.add(_elem596); } iprot.readListEnd(); } @@ -78400,9 +80142,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (String _iter587 : struct.success) + for (String _iter597 : struct.success) { - oprot.writeString(_iter587); + oprot.writeString(_iter597); } oprot.writeListEnd(); } @@ -78441,9 +80183,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter588 : struct.success) + for (String _iter598 : struct.success) { - oprot.writeString(_iter588); + oprot.writeString(_iter598); } } } @@ -78458,13 +80200,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list589 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list589.size); - for (int _i590 = 0; _i590 < _list589.size; ++_i590) + org.apache.thrift.protocol.TList _list599 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list599.size); + for (int _i600 = 0; _i600 < _list599.size; ++_i600) { - String _elem591; // required - _elem591 = iprot.readString(); - struct.success.add(_elem591); + String _elem601; // required + _elem601 = iprot.readString(); + struct.success.add(_elem601); } } struct.setSuccessIsSet(true); @@ -88670,13 +90412,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list592 = iprot.readListBegin(); - struct.success = new ArrayList(_list592.size); - for (int _i593 = 0; _i593 < _list592.size; ++_i593) + org.apache.thrift.protocol.TList _list602 = iprot.readListBegin(); + struct.success = new ArrayList(_list602.size); + for (int _i603 = 0; _i603 < _list602.size; ++_i603) { - String _elem594; // required - _elem594 = iprot.readString(); - struct.success.add(_elem594); + String _elem604; // required + _elem604 = iprot.readString(); + struct.success.add(_elem604); } iprot.readListEnd(); } @@ -88711,9 +90453,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (String _iter595 : struct.success) + for (String _iter605 : struct.success) { - oprot.writeString(_iter595); + oprot.writeString(_iter605); } oprot.writeListEnd(); } @@ -88752,9 +90494,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter596 : struct.success) + for (String _iter606 : struct.success) { - oprot.writeString(_iter596); + oprot.writeString(_iter606); } } } @@ -88769,13 +90511,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list597 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list597.size); - for (int _i598 = 0; _i598 < _list597.size; ++_i598) + org.apache.thrift.protocol.TList _list607 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list607.size); + for (int _i608 = 0; _i608 < _list607.size; ++_i608) { - String _elem599; // required - _elem599 = iprot.readString(); - struct.success.add(_elem599); + String _elem609; // required + _elem609 = iprot.readString(); + struct.success.add(_elem609); } } struct.setSuccessIsSet(true); @@ -92066,14 +93808,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list600 = iprot.readListBegin(); - struct.success = new ArrayList(_list600.size); - for (int _i601 = 0; _i601 < _list600.size; ++_i601) + org.apache.thrift.protocol.TList _list610 = iprot.readListBegin(); + struct.success = new ArrayList(_list610.size); + for (int _i611 = 0; _i611 < _list610.size; ++_i611) { - Role _elem602; // required - _elem602 = new Role(); - _elem602.read(iprot); - struct.success.add(_elem602); + Role _elem612; // required + _elem612 = new Role(); + _elem612.read(iprot); + struct.success.add(_elem612); } iprot.readListEnd(); } @@ -92108,9 +93850,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Role _iter603 : struct.success) + for (Role _iter613 : struct.success) { - _iter603.write(oprot); + _iter613.write(oprot); } oprot.writeListEnd(); } @@ -92149,9 +93891,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Role _iter604 : struct.success) + for (Role _iter614 : struct.success) { - _iter604.write(oprot); + _iter614.write(oprot); } } } @@ -92166,14 +93908,14 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list605 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list605.size); - for (int _i606 = 0; _i606 < _list605.size; ++_i606) + org.apache.thrift.protocol.TList _list615 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list615.size); + for (int _i616 = 0; _i616 < _list615.size; ++_i616) { - Role _elem607; // required - _elem607 = new Role(); - _elem607.read(iprot); - struct.success.add(_elem607); + Role _elem617; // required + _elem617 = new Role(); + _elem617.read(iprot); + struct.success.add(_elem617); } } struct.setSuccessIsSet(true); @@ -92685,13 +94427,13 @@ case 3: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list608 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list608.size); - for (int _i609 = 0; _i609 < _list608.size; ++_i609) + org.apache.thrift.protocol.TList _list618 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list618.size); + for (int _i619 = 0; _i619 < _list618.size; ++_i619) { - String _elem610; // required - _elem610 = iprot.readString(); - struct.group_names.add(_elem610); + String _elem620; // required + _elem620 = iprot.readString(); + struct.group_names.add(_elem620); } iprot.readListEnd(); } @@ -92727,9 +94469,9 @@ oprot.writeFieldBegin(GROUP_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.group_names.size())); - for (String _iter611 : struct.group_names) + for (String _iter621 : struct.group_names) { - oprot.writeString(_iter611); + oprot.writeString(_iter621); } oprot.writeListEnd(); } @@ -92772,9 +94514,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter612 : struct.group_names) + for (String _iter622 : struct.group_names) { - oprot.writeString(_iter612); + oprot.writeString(_iter622); } } } @@ -92795,13 +94537,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list613 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list613.size); - for (int _i614 = 0; _i614 < _list613.size; ++_i614) + org.apache.thrift.protocol.TList _list623 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list623.size); + for (int _i624 = 0; _i624 < _list623.size; ++_i624) { - String _elem615; // required - _elem615 = iprot.readString(); - struct.group_names.add(_elem615); + String _elem625; // required + _elem625 = iprot.readString(); + struct.group_names.add(_elem625); } } struct.setGroup_namesIsSet(true); @@ -94259,14 +96001,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list616 = iprot.readListBegin(); - struct.success = new ArrayList(_list616.size); - for (int _i617 = 0; _i617 < _list616.size; ++_i617) + org.apache.thrift.protocol.TList _list626 = iprot.readListBegin(); + struct.success = new ArrayList(_list626.size); + for (int _i627 = 0; _i627 < _list626.size; ++_i627) { - HiveObjectPrivilege _elem618; // required - _elem618 = new HiveObjectPrivilege(); - _elem618.read(iprot); - struct.success.add(_elem618); + HiveObjectPrivilege _elem628; // required + _elem628 = new HiveObjectPrivilege(); + _elem628.read(iprot); + struct.success.add(_elem628); } iprot.readListEnd(); } @@ -94301,9 +96043,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (HiveObjectPrivilege _iter619 : struct.success) + for (HiveObjectPrivilege _iter629 : struct.success) { - _iter619.write(oprot); + _iter629.write(oprot); } oprot.writeListEnd(); } @@ -94342,9 +96084,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (HiveObjectPrivilege _iter620 : struct.success) + for (HiveObjectPrivilege _iter630 : struct.success) { - _iter620.write(oprot); + _iter630.write(oprot); } } } @@ -94359,14 +96101,14 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list621 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list621.size); - for (int _i622 = 0; _i622 < _list621.size; ++_i622) + org.apache.thrift.protocol.TList _list631 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list631.size); + for (int _i632 = 0; _i632 < _list631.size; ++_i632) { - HiveObjectPrivilege _elem623; // required - _elem623 = new HiveObjectPrivilege(); - _elem623.read(iprot); - struct.success.add(_elem623); + HiveObjectPrivilege _elem633; // required + _elem633 = new HiveObjectPrivilege(); + _elem633.read(iprot); + struct.success.add(_elem633); } } struct.setSuccessIsSet(true); @@ -96439,13 +98181,13 @@ case 2: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list624 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list624.size); - for (int _i625 = 0; _i625 < _list624.size; ++_i625) + org.apache.thrift.protocol.TList _list634 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list634.size); + for (int _i635 = 0; _i635 < _list634.size; ++_i635) { - String _elem626; // required - _elem626 = iprot.readString(); - struct.group_names.add(_elem626); + String _elem636; // required + _elem636 = iprot.readString(); + struct.group_names.add(_elem636); } iprot.readListEnd(); } @@ -96476,9 +98218,9 @@ oprot.writeFieldBegin(GROUP_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.group_names.size())); - for (String _iter627 : struct.group_names) + for (String _iter637 : struct.group_names) { - oprot.writeString(_iter627); + oprot.writeString(_iter637); } oprot.writeListEnd(); } @@ -96515,9 +98257,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter628 : struct.group_names) + for (String _iter638 : struct.group_names) { - oprot.writeString(_iter628); + oprot.writeString(_iter638); } } } @@ -96533,13 +98275,13 @@ } if (incoming.get(1)) { { - org.apache.thrift.protocol.TList _list629 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list629.size); - for (int _i630 = 0; _i630 < _list629.size; ++_i630) + org.apache.thrift.protocol.TList _list639 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list639.size); + for (int _i640 = 0; _i640 < _list639.size; ++_i640) { - String _elem631; // required - _elem631 = iprot.readString(); - struct.group_names.add(_elem631); + String _elem641; // required + _elem641 = iprot.readString(); + struct.group_names.add(_elem641); } } struct.setGroup_namesIsSet(true); @@ -96945,13 +98687,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list632 = iprot.readListBegin(); - struct.success = new ArrayList(_list632.size); - for (int _i633 = 0; _i633 < _list632.size; ++_i633) + org.apache.thrift.protocol.TList _list642 = iprot.readListBegin(); + struct.success = new ArrayList(_list642.size); + for (int _i643 = 0; _i643 < _list642.size; ++_i643) { - String _elem634; // required - _elem634 = iprot.readString(); - struct.success.add(_elem634); + String _elem644; // required + _elem644 = iprot.readString(); + struct.success.add(_elem644); } iprot.readListEnd(); } @@ -96986,9 +98728,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.success.size())); - for (String _iter635 : struct.success) + for (String _iter645 : struct.success) { - oprot.writeString(_iter635); + oprot.writeString(_iter645); } oprot.writeListEnd(); } @@ -97027,9 +98769,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter636 : struct.success) + for (String _iter646 : struct.success) { - oprot.writeString(_iter636); + oprot.writeString(_iter646); } } } @@ -97044,13 +98786,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list637 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list637.size); - for (int _i638 = 0; _i638 < _list637.size; ++_i638) + org.apache.thrift.protocol.TList _list647 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list647.size); + for (int _i648 = 0; _i648 < _list647.size; ++_i648) { - String _elem639; // required - _elem639 = iprot.readString(); - struct.success.add(_elem639); + String _elem649; // required + _elem649 = iprot.readString(); + struct.success.add(_elem649); } } struct.setSuccessIsSet(true); Index: metastore/if/hive_metastore.thrift =================================================================== --- metastore/if/hive_metastore.thrift (revision 1471261) +++ metastore/if/hive_metastore.thrift (working copy) @@ -455,6 +455,10 @@ throws(1:NoSuchObjectException o1, 2:MetaException o2) Partition get_partition(1:string db_name, 2:string tbl_name, 3:list part_vals) throws(1:MetaException o1, 2:NoSuchObjectException o2) + Partition exchange_partition(1:map partitionSpecs, 2:string source_db, + 3:string source_table_name, 4:string dest_db, 5:string dest_table_name) + throws(1:MetaException o1, 2:NoSuchObjectException o2, 3:InvalidObjectException o3, + 4:InvalidInputException o4) Partition get_partition_with_auth(1:string db_name, 2:string tbl_name, 3:list part_vals, 4: string user_name, 5: list group_names) throws(1:MetaException o1, 2:NoSuchObjectException o2) Index: .gitignore =================================================================== --- .gitignore (revision 1471261) +++ .gitignore (working copy) @@ -13,4 +13,7 @@ *.iml *.ipr *.iws +ql/derby.log +derby.log +.arc Index: ql/src/test/results/clientpositive/exchange_partition3.q.out =================================================================== --- ql/src/test/results/clientpositive/exchange_partition3.q.out (revision 0) +++ ql/src/test/results/clientpositive/exchange_partition3.q.out (working copy) @@ -0,0 +1,58 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=1 +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 +ds=2013-04-05/hr=2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: -- This will exchange both partitions hr=1 and hr=2 +ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2 +PREHOOK: type: null +POSTHOOK: query: -- This will exchange both partitions hr=1 and hr=2 +ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2 +POSTHOOK: type: null +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 +ds=2013-04-05/hr=2 Index: ql/src/test/results/clientpositive/exchange_partition.q.out =================================================================== --- ql/src/test/results/clientpositive/exchange_partition.q.out (revision 0) +++ ql/src/test/results/clientpositive/exchange_partition.q.out (working copy) @@ -0,0 +1,47 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2 +PREHOOK: type: null +POSTHOOK: query: ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2 +POSTHOOK: type: null +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05 Index: ql/src/test/results/clientpositive/exchange_partition2.q.out =================================================================== --- ql/src/test/results/clientpositive/exchange_partition2.q.out (revision 0) +++ ql/src/test/results/clientpositive/exchange_partition2.q.out (working copy) @@ -0,0 +1,47 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=1 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05', hr='1') WITH TABLE exchange_part_test2 +PREHOOK: type: null +POSTHOOK: query: ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05', hr='1') WITH TABLE exchange_part_test2 +POSTHOOK: type: null +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 Index: ql/src/test/results/clientnegative/exchange_partition_neg_table_missing.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_table_missing.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_table_missing.q.out (working copy) @@ -0,0 +1 @@ +FAILED: SemanticException [Error 10001]: Table not found t1 Index: ql/src/test/results/clientnegative/exchange_partition_neg_table_missing2.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_table_missing2.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_table_missing2.q.out (working copy) @@ -0,0 +1,22 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05 +FAILED: SemanticException [Error 10001]: Table not found exchange_part_test2 Index: ql/src/test/results/clientnegative/exchange_partition_neg_test.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_test.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_test.q.out (working copy) @@ -0,0 +1,35 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string, f2 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string, f2 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +FAILED: SemanticException [Error 10235]: Tables have incompatible schemas and their partitions cannot be exchanged. Index: ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists2.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists2.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists2.q.out (working copy) @@ -0,0 +1,51 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=1 +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=2 +PREHOOK: query: ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05', hr='3') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test2 +POSTHOOK: query: ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05', hr='3') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test2 +POSTHOOK: Output: default@exchange_part_test2@ds=2013-04-05/hr=3 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 +ds=2013-04-05/hr=2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=3 +FAILED: SemanticException [Error 10118]: Partition already exists [exchange_part_test2(ds=2013-04-05/hr=3)] Index: ql/src/test/results/clientnegative/exchange_partition_neg_partition_missing.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_partition_missing.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_partition_missing.q.out (working copy) @@ -0,0 +1,15 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +FAILED: SemanticException [Error 10006]: Partition not found {ds=2013-04-05} Index: ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists.q.out (working copy) @@ -0,0 +1,43 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05 +PREHOOK: query: ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test2 +POSTHOOK: query: ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test2 +POSTHOOK: Output: default@exchange_part_test2@ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05 +FAILED: SemanticException [Error 10118]: Partition already exists [exchange_part_test2(ds=2013-04-05)] Index: ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists3.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists3.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_partition_exists3.q.out (working copy) @@ -0,0 +1,51 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=1 +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=2 +PREHOOK: query: ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05', hr='1') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test2 +POSTHOOK: query: ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05', hr='1') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test2 +POSTHOOK: Output: default@exchange_part_test2@ds=2013-04-05/hr=1 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 +ds=2013-04-05/hr=2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=1 +FAILED: SemanticException [Error 10118]: Partition already exists [exchange_part_test2(ds=2013-04-05/hr=1)] Index: ql/src/test/results/clientnegative/exchange_partition_neg_incomplete_partition.q.out =================================================================== --- ql/src/test/results/clientnegative/exchange_partition_neg_incomplete_partition.q.out (revision 0) +++ ql/src/test/results/clientnegative/exchange_partition_neg_incomplete_partition.q.out (working copy) @@ -0,0 +1,43 @@ +PREHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test1 +PREHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +PREHOOK: type: CREATETABLE +POSTHOOK: query: CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING) +POSTHOOK: type: CREATETABLE +POSTHOOK: Output: default@exchange_part_test2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='h1') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='h1') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=h1 +PREHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='h2') +PREHOOK: type: ALTERTABLE_ADDPARTS +PREHOOK: Input: default@exchange_part_test1 +POSTHOOK: query: ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='h2') +POSTHOOK: type: ALTERTABLE_ADDPARTS +POSTHOOK: Input: default@exchange_part_test1 +POSTHOOK: Output: default@exchange_part_test1@ds=2013-04-05/hr=h2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test1 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test1 +POSTHOOK: type: SHOWPARTITIONS +ds=2013-04-05/hr=h1 +ds=2013-04-05/hr=h2 +PREHOOK: query: SHOW PARTITIONS exchange_part_test2 +PREHOOK: type: SHOWPARTITIONS +POSTHOOK: query: SHOW PARTITIONS exchange_part_test2 +POSTHOOK: type: SHOWPARTITIONS +FAILED: SemanticException [Error 10234]: Parition values specifed are not continuous. A subpartition value is specified without specififying the parent partition's value {hr=h1} Index: ql/src/test/queries/clientpositive/exchange_partition.q =================================================================== --- ql/src/test/queries/clientpositive/exchange_partition.q (revision 0) +++ ql/src/test/queries/clientpositive/exchange_partition.q (working copy) @@ -0,0 +1,12 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2; +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; Index: ql/src/test/queries/clientpositive/exchange_partition2.q =================================================================== --- ql/src/test/queries/clientpositive/exchange_partition2.q (revision 0) +++ ql/src/test/queries/clientpositive/exchange_partition2.q (working copy) @@ -0,0 +1,12 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05', hr='1') WITH TABLE exchange_part_test2; +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; Index: ql/src/test/queries/clientpositive/exchange_partition3.q =================================================================== --- ql/src/test/queries/clientpositive/exchange_partition3.q (revision 0) +++ ql/src/test/queries/clientpositive/exchange_partition3.q (working copy) @@ -0,0 +1,14 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1'); +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +-- This will exchange both partitions hr=1 and hr=2 +ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2; +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_incomplete_partition.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_incomplete_partition.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_incomplete_partition.q (working copy) @@ -0,0 +1,12 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='h1'); +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='h2'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +-- for exchange_part_test1 the value of ds is not given and the value of hr is given, thus this query will fail +alter table exchange_part_test1 exchange partition (hr='h1') with table exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_table_missing2.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_table_missing2.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_table_missing2.q (working copy) @@ -0,0 +1,8 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING); +SHOW PARTITIONS exchange_part_test1; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05'); +SHOW PARTITIONS exchange_part_test1; + +-- exchange_part_test2 table does not exist thus this query will fail +alter table exchange_part_test1 exchange partition (ds='2013-04-05') with table exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_table_missing.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_table_missing.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_table_missing.q (working copy) @@ -0,0 +1,2 @@ +-- t1 does not exist and the query fails +alter table t1 exchange partition (ds='2013-04-05') with table t2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists2.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists2.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists2.q (working copy) @@ -0,0 +1,13 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1'); +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2'); +ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05', hr='3'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +-- exchange_part_test2 table partition (ds='2013-04-05', hr='3') already exists thus this query will fail +alter table exchange_part_test1 exchange partition (ds='2013-04-05') with table exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists3.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists3.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists3.q (working copy) @@ -0,0 +1,13 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING, hr STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='1'); +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05', hr='2'); +ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05', hr='1'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +-- exchange_part_test2 table partition (ds='2013-04-05', hr='1') already exists thus this query will fail +alter table exchange_part_test1 exchange partition (ds='2013-04-05') with table exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_partition_missing.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_partition_missing.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_partition_missing.q (working copy) @@ -0,0 +1,6 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING); +SHOW PARTITIONS exchange_part_test1; + +-- exchange_part_test1 partition (ds='2013-04-05') does not exist thus this query will fail +alter table exchange_part_test1 exchange partition (ds='2013-04-05') with table exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_test.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_test.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_test.q (working copy) @@ -0,0 +1,11 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING); +CREATE TABLE exchange_part_test2 (f1 string, f2 string) PARTITIONED BY (ds STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +-- exchange_part_test1 and exchange_part_test2 do not have the same scheme and thus they fail +ALTER TABLE exchange_part_test1 EXCHANGE PARTITION (ds='2013-04-05') WITH TABLE exchange_part_test2; Index: ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists.q =================================================================== --- ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists.q (revision 0) +++ ql/src/test/queries/clientnegative/exchange_partition_neg_partition_exists.q (working copy) @@ -0,0 +1,12 @@ +CREATE TABLE exchange_part_test1 (f1 string) PARTITIONED BY (ds STRING); +CREATE TABLE exchange_part_test2 (f1 string) PARTITIONED BY (ds STRING); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +ALTER TABLE exchange_part_test1 ADD PARTITION (ds='2013-04-05'); +ALTER TABLE exchange_part_test2 ADD PARTITION (ds='2013-04-05'); +SHOW PARTITIONS exchange_part_test1; +SHOW PARTITIONS exchange_part_test2; + +-- exchange_part_test2 table partition (ds='2013-04-05') already exists thus this query will fail +alter table exchange_part_test1 exchange partition (ds='2013-04-05') with table exchange_part_test2; Index: ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java (working copy) @@ -1671,7 +1671,7 @@ List names = null; Table t = getTable(dbName, tblName); - List pvals = getPvals(t.getPartCols(), partSpec); + List pvals = MetaStoreUtils.getPvals(t.getPartCols(), partSpec); try { names = getMSC().listPartitionNames(dbName, tblName, pvals, max); @@ -1713,19 +1713,6 @@ } } - public static List getPvals(List partCols, - Map partSpec) { - List pvals = new ArrayList(); - for (FieldSchema field : partCols) { - String val = partSpec.get(field.getName()); - if (val == null) { - val = ""; - } - pvals.add(val); - } - return pvals; - } - /** * get all the partitions of the table that matches the given partial * specification. partition columns whose value is can be anything should be @@ -1745,7 +1732,7 @@ "partitioned table"); } - List partialPvals = getPvals(tbl.getPartCols(), partialPartSpec); + List partialPvals = MetaStoreUtils.getPvals(tbl.getPartCols(), partialPartSpec); List partitions = null; try { @@ -2251,6 +2238,18 @@ } } + public void exchangeTablePartitions(Map partitionSpecs, + String sourceDb, String sourceTable, String destDb, + String destinationTableName) throws HiveException { + try { + getMSC().exchange_partition(partitionSpecs, sourceDb, sourceTable, destDb, + destinationTableName); + } catch (Exception ex) { + LOG.error(StringUtils.stringifyException(ex)); + throw new HiveException(ex); + } + } + /** * Creates a metastore client. Currently it creates only JDBC based client as * File based store support is removed Index: ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java (working copy) @@ -429,6 +429,12 @@ return truncateTable(db, truncateTableDesc); } + AlterTableExchangePartition alterTableExchangePartition = + work.getAlterTableExchangePartition(); + if (alterTableExchangePartition != null) { + return exchangeTablePartition(db, alterTableExchangePartition); + } + } catch (InvalidTableException e) { formatter.consoleError(console, "Table " + e.getTableName() + " does not exist", formatter.MISSING); @@ -3969,6 +3975,17 @@ return 0; } + private int exchangeTablePartition(Hive db, + AlterTableExchangePartition exchangePartition) throws HiveException { + Map partitionSpecs = exchangePartition.getPartitionSpecs(); + Table destTable = exchangePartition.getDestinationTable(); + Table sourceTable = exchangePartition.getSourceTable(); + db.exchangeTablePartitions(partitionSpecs, sourceTable.getDbName(), + sourceTable.getTableName(),destTable.getDbName(), + destTable.getTableName()); + return 0; + } + private List getLocations(Hive db, Table table, Map partSpec) throws HiveException { List locations = new ArrayList(); Index: ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java (working copy) @@ -35,6 +35,7 @@ import org.apache.hadoop.fs.LocalFileSystem; import org.apache.hadoop.fs.Path; import org.apache.hadoop.hive.conf.HiveConf; +import org.apache.hadoop.hive.metastore.MetaStoreUtils; import org.apache.hadoop.hive.metastore.api.InvalidOperationException; import org.apache.hadoop.hive.metastore.api.Order; import org.apache.hadoop.hive.ql.Context; @@ -46,7 +47,6 @@ import org.apache.hadoop.hive.ql.lockmgr.HiveLock; import org.apache.hadoop.hive.ql.lockmgr.HiveLockManager; import org.apache.hadoop.hive.ql.lockmgr.HiveLockObj; -import org.apache.hadoop.hive.ql.metadata.Hive; import org.apache.hadoop.hive.ql.metadata.HiveException; import org.apache.hadoop.hive.ql.metadata.Partition; import org.apache.hadoop.hive.ql.metadata.Table; @@ -394,7 +394,8 @@ } dc = null; // reset data container to prevent it being added again. } else { // static partitions - List partVals = Hive.getPvals(table.getPartCols(), tbd.getPartitionSpec()); + List partVals = MetaStoreUtils.getPvals(table.getPartCols(), + tbd.getPartitionSpec()); db.validatePartitionNameCharacters(partVals); db.loadPartition(new Path(tbd.getSourceDir()), tbd.getTable().getTableName(), tbd.getPartitionSpec(), tbd.getReplace(), tbd.getHoldDDLTime(), Index: ql/src/java/org/apache/hadoop/hive/ql/plan/DDLWork.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/plan/DDLWork.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/plan/DDLWork.java (working copy) @@ -64,6 +64,7 @@ private AlterDatabaseDesc alterDbDesc; private AlterTableAlterPartDesc alterTableAlterPartDesc; private TruncateTableDesc truncateTblDesc; + private AlterTableExchangePartition alterTableExchangePartition; private RoleDDLDesc roleDDLDesc; private GrantDesc grantDesc; @@ -449,6 +450,12 @@ this.alterTableAlterPartDesc = alterPartDesc; } + public DDLWork(HashSet inputs, HashSet outputs, + AlterTableExchangePartition alterTableExchangePartition) { + this(inputs, outputs); + this.alterTableExchangePartition = alterTableExchangePartition; + } + /** * @return Create Database descriptor */ @@ -1025,4 +1032,20 @@ public void setTruncateTblDesc(TruncateTableDesc truncateTblDesc) { this.truncateTblDesc = truncateTblDesc; } + + /** + * @return information about the table partition to be exchanged + */ + public AlterTableExchangePartition getAlterTableExchangePartition() { + return this.alterTableExchangePartition; + } + + /** + * @param alterTableExchangePartition + * set the value of the table partition to be exchanged + */ + public void setAlterTableExchangePartition( + AlterTableExchangePartition alterTableExchangePartition) { + this.alterTableExchangePartition = alterTableExchangePartition; + } } Index: ql/src/java/org/apache/hadoop/hive/ql/plan/AlterTableExchangePartition.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/plan/AlterTableExchangePartition.java (revision 0) +++ ql/src/java/org/apache/hadoop/hive/ql/plan/AlterTableExchangePartition.java (working copy) @@ -0,0 +1,67 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.hadoop.hive.ql.plan; + +import java.util.Map; + +import org.apache.hadoop.hive.ql.metadata.Table; + +public class AlterTableExchangePartition extends DDLDesc { + + // The source table + private Table sourceTable; + + // The destination table + private Table destinationTable; + + // The partition that has to be exchanged + private Map partitionSpecs; + + public AlterTableExchangePartition(Table sourceTable, Table destinationTable, + Map partitionSpecs) { + super(); + this.sourceTable = sourceTable; + this.destinationTable = destinationTable; + this.partitionSpecs = partitionSpecs; + } + + public void setSourceTable(Table sourceTable) { + this.sourceTable = sourceTable; + } + + public Table getSourceTable() { + return this.sourceTable; + } + + public void setDestinationTable(Table destinationTable) { + this.destinationTable = destinationTable; + } + + public Table getDestinationTable() { + return this.destinationTable; + } + + public void setPartitionSpecs(Map partitionSpecs) { + this.partitionSpecs = partitionSpecs; + } + + public Map getPartitionSpecs() { + return this.partitionSpecs; + } +} Index: ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g (working copy) @@ -295,6 +295,7 @@ TOK_WINDOWVALUES; TOK_WINDOWRANGE; TOK_IGNOREPROTECTION; +TOK_EXCHANGEPARTITION; } @@ -867,6 +868,7 @@ | alterStatementSuffixProperties | alterTblPartitionStatement | alterStatementSuffixSkewedby + | alterStatementSuffixExchangePartition ; alterViewStatementSuffix @@ -1103,6 +1105,13 @@ ->^(TOK_ALTERTABLE_SKEWED $name storedAsDirs) ; +alterStatementSuffixExchangePartition +@init {msgs.push("alter exchange partition");} +@after{msgs.pop();} + : name=tableName KW_EXCHANGE partitionSpec KW_WITH KW_TABLE exchangename=tableName + -> ^(TOK_EXCHANGEPARTITION $name partitionSpec $exchangename) + ; + alterStatementSuffixProtectMode @init { msgs.push("alter partition protect mode statement"); } @after { msgs.pop(); } Index: ql/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g (working copy) @@ -258,6 +258,7 @@ KW_USER: 'USER'; KW_ROLE: 'ROLE'; KW_INNER: 'INNER'; +KW_EXCHANGE: 'EXCHANGE'; // Operators // NOTE: if you add a new function/operator, add it to sysFuncNames so that describe function _FUNC_ will work. Index: ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzerFactory.java (working copy) @@ -202,6 +202,7 @@ case HiveParser.TOK_ALTERDATABASE_PROPERTIES: case HiveParser.TOK_ALTERTABLE_SKEWED: case HiveParser.TOK_TRUNCATETABLE: + case HiveParser.TOK_EXCHANGEPARTITION: return new DDLSemanticAnalyzer(conf); case HiveParser.TOK_ALTERTABLE_PARTITION: HiveOperation commandType = null; Index: ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java (working copy) @@ -43,6 +43,7 @@ import org.apache.hadoop.fs.Path; import org.apache.hadoop.hive.conf.HiveConf; import org.apache.hadoop.hive.conf.HiveConf.ConfVars; +import org.apache.hadoop.hive.metastore.MetaStoreUtils; import org.apache.hadoop.hive.metastore.TableType; import org.apache.hadoop.hive.metastore.Warehouse; import org.apache.hadoop.hive.metastore.api.FieldSchema; @@ -75,8 +76,10 @@ import org.apache.hadoop.hive.ql.plan.AlterDatabaseDesc; import org.apache.hadoop.hive.ql.plan.AlterIndexDesc; import org.apache.hadoop.hive.ql.plan.AlterIndexDesc.AlterIndexTypes; +import org.apache.hadoop.hive.ql.plan.AlterTableAlterPartDesc; import org.apache.hadoop.hive.ql.plan.AlterTableDesc; import org.apache.hadoop.hive.ql.plan.AlterTableDesc.AlterTableTypes; +import org.apache.hadoop.hive.ql.plan.AlterTableExchangePartition; import org.apache.hadoop.hive.ql.plan.AlterTableSimpleDesc; import org.apache.hadoop.hive.ql.plan.CreateDatabaseDesc; import org.apache.hadoop.hive.ql.plan.CreateIndexDesc; @@ -126,7 +129,6 @@ import org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe; import org.apache.hadoop.mapred.InputFormat; import org.apache.hadoop.mapred.TextInputFormat; -import org.apache.hadoop.hive.ql.plan.AlterTableAlterPartDesc; /** * DDLSemanticAnalyzer. @@ -405,6 +407,9 @@ case HiveParser.TOK_ALTERTABLE_SKEWED: analyzeAltertableSkewedby(ast); break; + case HiveParser.TOK_EXCHANGEPARTITION: + analyzeExchangePartition(ast); + break; default: throw new SemanticException("Unsupported command."); } @@ -663,6 +668,69 @@ } + private void analyzeExchangePartition(ASTNode ast) throws SemanticException { + Table sourceTable = getTable(getUnescapedName((ASTNode)ast.getChild(0))); + Table destTable = getTable(getUnescapedName((ASTNode)ast.getChild(2))); + + // Get the partition specs + Map partSpecs = getPartSpec((ASTNode) ast.getChild(1)); + validatePartitionValues(partSpecs); + boolean sameColumns = MetaStoreUtils.compareFieldColumns( + sourceTable.getAllCols(), destTable.getAllCols()); + boolean samePartitions = MetaStoreUtils.compareFieldColumns( + sourceTable.getPartitionKeys(), destTable.getPartitionKeys()); + if (!sameColumns || !samePartitions) { + throw new SemanticException(ErrorMsg.TABLES_INCOMPATIBLE_SCHEMAS.getMsg()); + } + List partitions = getPartitions(sourceTable, partSpecs, true); + + // Verify that the partitions specified are continuous + // If a subpartition value is specified without specifying a partition's value + // then we throw an exception + if (!isPartitionValueContinuous(sourceTable.getPartitionKeys(), partSpecs)) { + throw new SemanticException( + ErrorMsg.PARTITION_VALUE_NOT_CONTINUOUS.getMsg(partSpecs.toString())); + } + List destPartitions = null; + try { + destPartitions = getPartitions(destTable, partSpecs, true); + } catch (SemanticException ex) { + // We should expect a semantic exception being throw as this partition + // should not be present. + } + if (destPartitions != null) { + // If any destination partition is present then throw a Semantic Exception. + throw new SemanticException(ErrorMsg.PARTITION_EXISTS.getMsg(destPartitions.toString())); + } + AlterTableExchangePartition alterTableExchangePartition = + new AlterTableExchangePartition(sourceTable, destTable, partSpecs); + rootTasks.add(TaskFactory.get(new DDLWork(getInputs(), getOutputs(), + alterTableExchangePartition), conf)); + } + + /** + * @param partitionKeys the list of partition keys of the table + * @param partSpecs the partition specs given by the user + * @return true if no subpartition value is specified without a partition's + * value being specified else it returns false + */ + private boolean isPartitionValueContinuous(List partitionKeys, + Map partSpecs) { + boolean partitionMissing = false; + for (FieldSchema partitionKey: partitionKeys) { + if (!partSpecs.containsKey(partitionKey.getName())) { + partitionMissing = true; + } else { + if (partitionMissing) { + // A subpartition value exists after a missing partition + // The partition value specified are not continuous, return false + return false; + } + } + } + return true; + } + private void analyzeCreateDatabase(ASTNode ast) throws SemanticException { String dbName = unescapeIdentifier(ast.getChild(0).getText()); boolean ifNotExists = false; Index: ql/src/java/org/apache/hadoop/hive/ql/ErrorMsg.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/ErrorMsg.java (revision 1471261) +++ ql/src/java/org/apache/hadoop/hive/ql/ErrorMsg.java (working copy) @@ -301,7 +301,7 @@ "Cannot ALTER VIEW AS SELECT if view currently does not exist\n"), REPLACE_VIEW_WITH_PARTITION(10217, "Cannot replace a view with CREATE VIEW or REPLACE VIEW or " + - "ALTER VIEW AS SELECT if the view has paritions\n"), + "ALTER VIEW AS SELECT if the view has partitions\n"), EXISTING_TABLE_IS_NOT_VIEW(10218, "Existing table is not a view\n"), NO_SUPPORTED_ORDERBY_ALLCOLREF_POS(10219, @@ -338,6 +338,10 @@ + "fails to construct aggregation for the partition "), ANALYZE_TABLE_PARTIALSCAN_AUTOGATHER(10233, "Analyze partialscan is not allowed " + "if hive.stats.autogather is set to false"), + PARTITION_VALUE_NOT_CONTINUOUS(10234, "Parition values specifed are not continuous." + + " A subpartition value is specified without specififying the parent partition's value"), + TABLES_INCOMPATIBLE_SCHEMAS(10235, "Tables have incompatible schemas and their partitions " + + " cannot be exchanged."), SCRIPT_INIT_ERROR(20000, "Unable to initialize custom script."), SCRIPT_IO_ERROR(20001, "An error occurred while reading or writing to your custom script. "