Index: metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java =================================================================== --- metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java (revision 1619008) +++ metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java (working copy) @@ -54,6 +54,7 @@ import org.apache.hadoop.hive.metastore.model.MRoleMap; import org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege; import org.apache.hadoop.hive.metastore.model.MTablePrivilege; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.thrift.TException; /** @@ -675,6 +676,11 @@ } @Override + public boolean addPartitions(String dbName, String tblName, PartitionSpecProxy partitionSpec, boolean ifNotExists) throws InvalidObjectException, MetaException { + return false; + } + + @Override public void dropPartitions(String dbName, String tblName, List partNames) throws MetaException, NoSuchObjectException { objectStore.dropPartitions(dbName, tblName, partNames); Index: metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java =================================================================== --- metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java (revision 1619008) +++ metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java (working copy) @@ -55,6 +55,7 @@ import org.apache.hadoop.hive.metastore.model.MRoleMap; import org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege; import org.apache.hadoop.hive.metastore.model.MTablePrivilege; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.thrift.TException; /** @@ -697,6 +698,11 @@ } @Override + public boolean addPartitions(String dbName, String tblName, PartitionSpecProxy partitionSpec, boolean ifNotExists) throws InvalidObjectException, MetaException { + return false; + } + + @Override public void dropPartitions(String dbName, String tblName, List partNames) { } Index: metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStorePartitionSpecs.java =================================================================== --- metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStorePartitionSpecs.java (revision 0) +++ metastore/src/test/org/apache/hadoop/hive/metastore/TestHiveMetaStorePartitionSpecs.java (revision 0) @@ -0,0 +1,399 @@ +package org.apache.hadoop.hive.metastore; + +import org.apache.hadoop.hive.conf.HiveConf; +import org.apache.hadoop.hive.metastore.api.Database; +import org.apache.hadoop.hive.metastore.api.FieldSchema; +import org.apache.hadoop.hive.metastore.api.Partition; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; +import org.apache.hadoop.hive.metastore.api.SerDeInfo; +import org.apache.hadoop.hive.metastore.api.StorageDescriptor; +import org.apache.hadoop.hive.metastore.api.Table; +import org.apache.hadoop.hive.metastore.partition.spec.CompositePartitionSpecProxy; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; +import org.apache.hadoop.hive.serde2.columnar.LazyBinaryColumnarSerDe; +import org.apache.hadoop.util.ExitUtil; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.BeforeClass; +import org.junit.Test; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.security.Permission; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * Test to check PartitionSpec support in HiveMetaStore. + */ +public class TestHiveMetaStorePartitionSpecs { + + private static final Logger LOG = LoggerFactory.getLogger(TestHiveMetaStorePartitionSpecs.class); + private static final String msPort = "20102"; + private static HiveConf hiveConf; + private static SecurityManager securityManager; + + public static class NoExitSecurityManager extends SecurityManager { + + @Override + public void checkPermission(Permission perm) { + // allow anything. + } + + @Override + public void checkPermission(Permission perm, Object context) { + // allow anything. + } + + @Override + public void checkExit(int status) { + + super.checkExit(status); + throw new ExitUtil.ExitException(status, "System.exit() was called. Raising exception. "); + } + } + + private static class RunMS implements Runnable { + + @Override + public void run() { + try { + HiveMetaStore.main(new String[]{"-v", "-p", msPort, "--hiveconf", + "hive.metastore.expression.proxy=" + MockPartitionExpressionForMetastore.class.getCanonicalName()}); + } catch (Throwable t) { + LOG.error("Exiting. Got exception from metastore: ", t); + } + } + } + + @AfterClass + public static void tearDown() throws Exception { + LOG.info("Shutting down metastore."); + System.setSecurityManager(securityManager); + } + + @BeforeClass + public static void startMetaStoreServer() throws Exception { + + Thread t = new Thread(new RunMS()); + t.start(); + Thread.sleep(5000); + + securityManager = System.getSecurityManager(); + System.setSecurityManager(new NoExitSecurityManager()); + hiveConf = new HiveConf(TestHiveMetaStorePartitionSpecs.class); + hiveConf.setVar(HiveConf.ConfVars.METASTOREURIS, "thrift://localhost:" + + msPort); + hiveConf.setIntVar(HiveConf.ConfVars.METASTORETHRIFTCONNECTIONRETRIES, 3); + hiveConf.set(HiveConf.ConfVars.PREEXECHOOKS.varname, ""); + hiveConf.set(HiveConf.ConfVars.POSTEXECHOOKS.varname, ""); + hiveConf.set(HiveConf.ConfVars.HIVE_SUPPORT_CONCURRENCY.varname, + "false"); + hiveConf.set(HiveConf.ConfVars.METASTORE_EXPRESSION_PROXY_CLASS.name(), MockPartitionExpressionForMetastore.class.getCanonicalName()); + System.setProperty(HiveConf.ConfVars.PREEXECHOOKS.varname, " "); + System.setProperty(HiveConf.ConfVars.POSTEXECHOOKS.varname, " "); + } + + private static String dbName = "testpartitionspecs_db"; + private static String tableName = "testpartitionspecs_table"; + private static int nDates = 10; + private static String datePrefix = "2014010"; + + private static void createTable(HiveMetaStoreClient hmsc, boolean enablePartitionGrouping) throws Exception { + + + List columns = new ArrayList(); + columns.add(new FieldSchema("foo", "string", "")); + columns.add(new FieldSchema("bar", "string", "")); + + List partColumns = new ArrayList(); + partColumns.add(new FieldSchema("dt", "string", "")); + partColumns.add(new FieldSchema("blurb", "string", "")); + + SerDeInfo serdeInfo = new SerDeInfo("LBCSerDe", LazyBinaryColumnarSerDe.class.getCanonicalName(), new HashMap()); + + StorageDescriptor storageDescriptor + = new StorageDescriptor(columns, null, + "org.apache.hadoop.hive.ql.io.RCFileInputFormat", + "org.apache.hadoop.hive.ql.io.RCFileOutputFormat", + false, 0, serdeInfo, null, null, null); + + Map tableParameters = new HashMap(); + tableParameters.put("hive.hcatalog.partition.spec.grouping.enabled", enablePartitionGrouping? "true":"false"); + Table table = new Table(tableName, dbName, "", 0, 0, 0, storageDescriptor, partColumns, tableParameters, "", "", ""); + + hmsc.createTable(table); + + } + + private static void clearAndRecreateDB(HiveMetaStoreClient hmsc) throws Exception { + hmsc.dropDatabase(dbName, + true, // Delete data. + true, // Ignore unknownDB. + true // Cascade. + ); + + hmsc.createDatabase(new Database(dbName, + "", // Description. + null, // Location. + null // Parameters. + )); + } + + // Get partition-path. For grid='XYZ', place the partition outside the table-path. + private static String getPartitionPath(Table table, List partValues) { + + return partValues.get(1).equalsIgnoreCase("isLocatedOutsideTablePath")? // i.e. Is the partition outside the table-dir? + table.getSd().getLocation().replace(table.getTableName(), "location_outside_" + table.getTableName()) + + "_" + partValues.get(0) + "_" + partValues.get(1) + : null ; // Use defaults... Partitions are put in the table directory. + + } + + private static void populatePartitions(HiveMetaStoreClient hmsc, Table table, List blurbs) throws Exception { + for (int i=0; i< nDates; ++i) { + for (String blurb : blurbs) { + StorageDescriptor sd = new StorageDescriptor(table.getSd()); + // Add partitions located in the table-directory (i.e. default). + List values = Arrays.asList(datePrefix + i, blurb); + sd.setLocation(getPartitionPath(table, values)); + hmsc.add_partition(new Partition(values, dbName, tableName, 0, 0, sd, null)); + } + } + } + + private void testGetPartitionSpecs(boolean enablePartitionGrouping) { + try { + HiveMetaStoreClient hmsc = new HiveMetaStoreClient(hiveConf); + clearAndRecreateDB(hmsc); + createTable(hmsc, enablePartitionGrouping); + Table table = hmsc.getTable(dbName, tableName); + populatePartitions(hmsc, table, Arrays.asList("isLocatedInTablePath", "isLocatedOutsideTablePath")); + + PartitionSpecProxy partitionSpecProxy = hmsc.listPartitionSpecs(dbName, tableName, -1); + Assert.assertEquals( "Unexpected number of partitions.", nDates * 2, partitionSpecProxy.size()); + + Map> locationToDateMap = new HashMap>(); + locationToDateMap.put("isLocatedInTablePath", new ArrayList()); + locationToDateMap.put("isLocatedOutsideTablePath", new ArrayList()); + PartitionSpecProxy.PartitionIterator iterator = partitionSpecProxy.getPartitionIterator(); + + while (iterator.hasNext()) { + Partition partition = iterator.next(); + locationToDateMap.get(partition.getValues().get(1)).add(partition.getValues().get(0)); + } + + List expectedDates = new ArrayList(nDates); + for (int i=0; i fields = table.getSd().getCols(); + fields.add(new FieldSchema("goo", "string", "Entirely new column. Doesn't apply to older partitions.")); + table.getSd().setCols(fields); + hmsc.alter_table(dbName, tableName, table); + // Check that the change stuck. + table = hmsc.getTable(dbName,tableName); + Assert.assertEquals("Unexpected number of table columns.", + 3, table.getSd().getColsSize()); + + // Add partitions with new schema. + // Mark Partitions with new schema with different blurb. + populatePartitions(hmsc, table, Arrays.asList("hasNewColumn")); + + // Retrieve *all* partitions from the table. + PartitionSpecProxy partitionSpecProxy = hmsc.listPartitionSpecs(dbName, tableName, -1); + Assert.assertEquals("Unexpected number of partitions.", nDates * 3, partitionSpecProxy.size()); + + // Confirm grouping. + Assert.assertTrue("Unexpected type of PartitionSpecProxy.", partitionSpecProxy instanceof CompositePartitionSpecProxy); + CompositePartitionSpecProxy compositePartitionSpecProxy = (CompositePartitionSpecProxy)partitionSpecProxy; + List partitionSpecs = compositePartitionSpecProxy.toPartitionSpec(); + Assert.assertTrue("PartitionSpec[0] should have been a SharedSDPartitionSpec.", + partitionSpecs.get(0).isSetSharedSDPartitionSpec()); + Assert.assertEquals("PartitionSpec[0] should use the table-path as the common root location. ", + table.getSd().getLocation(), partitionSpecs.get(0).getRootPath()); + Assert.assertTrue("PartitionSpec[1] should have been a SharedSDPartitionSpec.", + partitionSpecs.get(1).isSetSharedSDPartitionSpec()); + Assert.assertEquals("PartitionSpec[1] should use the table-path as the common root location. ", + table.getSd().getLocation(), partitionSpecs.get(1).getRootPath()); + Assert.assertTrue("PartitionSpec[2] should have been a ListComposingPartitionSpec.", + partitionSpecs.get(2).isSetPartitionList()); + + // Categorize the partitions returned, and confirm that all partitions are accounted for. + PartitionSpecProxy.PartitionIterator iterator = partitionSpecProxy.getPartitionIterator(); + Map> blurbToPartitionList = new HashMap>(3); + while (iterator.hasNext()) { + + Partition partition = iterator.next(); + String blurb = partition.getValues().get(1); + + if (!blurbToPartitionList.containsKey(blurb)) { + blurbToPartitionList.put(blurb, new ArrayList(nDates)); + } + + blurbToPartitionList.get(blurb).add(partition); + + } // + + // All partitions with blurb="isLocatedOutsideTablePath" should have 2 columns, + // and must have locations outside the table directory. + for (Partition partition : blurbToPartitionList.get("isLocatedOutsideTablePath")) { + Assert.assertEquals("Unexpected number of columns.", 2, partition.getSd().getCols().size()); + Assert.assertEquals("Unexpected first column.", "foo", partition.getSd().getCols().get(0).getName()); + Assert.assertEquals("Unexpected second column.", "bar", partition.getSd().getCols().get(1).getName()); + String partitionLocation = partition.getSd().getLocation(); + String tableLocation = table.getSd().getLocation(); + Assert.assertTrue("Unexpected partition location: " + partitionLocation + ". " + + "Partition should have been outside table location: " + tableLocation, + !partitionLocation.startsWith(tableLocation)); + } + + // All partitions with blurb="isLocatedInTablePath" should have 2 columns, + // and must have locations within the table directory. + for (Partition partition : blurbToPartitionList.get("isLocatedInTablePath")) { + Assert.assertEquals("Unexpected number of columns.", 2, partition.getSd().getCols().size()); + Assert.assertEquals("Unexpected first column.", "foo", partition.getSd().getCols().get(0).getName()); + Assert.assertEquals("Unexpected second column.", "bar", partition.getSd().getCols().get(1).getName()); + String partitionLocation = partition.getSd().getLocation(); + String tableLocation = table.getSd().getLocation(); + Assert.assertTrue("Unexpected partition location: " + partitionLocation + ". " + + "Partition should have been within table location: " + tableLocation, + partitionLocation.startsWith(tableLocation)); + } + + // All partitions with blurb="hasNewColumn" were added after the table schema changed, + // and must have 3 columns. Also, the partition locations must lie within the table directory. + for (Partition partition : blurbToPartitionList.get("hasNewColumn")) { + Assert.assertEquals("Unexpected number of columns.", 3, partition.getSd().getCols().size()); + Assert.assertEquals("Unexpected first column.", "foo", partition.getSd().getCols().get(0).getName()); + Assert.assertEquals("Unexpected second column.", "bar", partition.getSd().getCols().get(1).getName()); + Assert.assertEquals("Unexpected third column.", "goo", partition.getSd().getCols().get(2).getName()); + String partitionLocation = partition.getSd().getLocation(); + String tableLocation = table.getSd().getLocation(); + Assert.assertTrue("Unexpected partition location: " + partitionLocation + ". " + + "Partition should have been within table location: " + tableLocation, + partitionLocation.startsWith(tableLocation)); + } + + } + catch (Throwable t) { + LOG.error("Unexpected Exception!", t); + t.printStackTrace(); + Assert.assertTrue("Unexpected Exception!", false); + } + } + +} Index: metastore/src/test/org/apache/hadoop/hive/metastore/MockPartitionExpressionForMetastore.java =================================================================== --- metastore/src/test/org/apache/hadoop/hive/metastore/MockPartitionExpressionForMetastore.java (revision 0) +++ metastore/src/test/org/apache/hadoop/hive/metastore/MockPartitionExpressionForMetastore.java (revision 0) @@ -0,0 +1,20 @@ +package org.apache.hadoop.hive.metastore; + +import org.apache.hadoop.hive.metastore.api.MetaException; + +import java.util.List; + +/** + * Test Mock-out for PartitionExpressionForMetastore. + */ +public class MockPartitionExpressionForMetastore implements PartitionExpressionProxy { + @Override + public String convertExprToFilter(byte[] expr) throws MetaException { + return null; + } + + @Override + public boolean filterPartitionsByExpr(List columnNames, byte[] expr, String defaultPartitionName, List partitionNames) throws MetaException { + return false; + } +} Index: metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java (working copy) @@ -55,6 +55,7 @@ import org.apache.hadoop.hive.metastore.model.MRoleMap; import org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege; import org.apache.hadoop.hive.metastore.model.MTablePrivilege; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.thrift.TException; public interface RawStore extends Configurable { @@ -128,6 +129,9 @@ public abstract boolean addPartitions(String dbName, String tblName, List parts) throws InvalidObjectException, MetaException; + public abstract boolean addPartitions(String dbName, String tblName, PartitionSpecProxy partitionSpec, boolean ifNotExists) + throws InvalidObjectException, MetaException; + public abstract Partition getPartition(String dbName, String tableName, List part_vals) throws MetaException, NoSuchObjectException; Index: metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java (working copy) @@ -37,6 +37,7 @@ import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.locks.Lock; import java.util.concurrent.locks.ReentrantLock; +import java.util.regex.Pattern; import javax.jdo.JDODataStoreException; import javax.jdo.JDOHelper; @@ -60,6 +61,7 @@ import org.apache.hadoop.hive.common.classification.InterfaceStability; import org.apache.hadoop.hive.conf.HiveConf; import org.apache.hadoop.hive.conf.HiveConf.ConfVars; +import org.apache.hadoop.hive.metastore.api.AlreadyExistsException; import org.apache.hadoop.hive.metastore.api.ColumnStatistics; import org.apache.hadoop.hive.metastore.api.ColumnStatisticsDesc; import org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj; @@ -128,6 +130,7 @@ import org.apache.hadoop.hive.metastore.parser.ExpressionTree.Operator; import org.apache.hadoop.hive.metastore.parser.FilterLexer; import org.apache.hadoop.hive.metastore.parser.FilterParser; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.hadoop.util.StringUtils; import org.apache.thrift.TException; import org.datanucleus.store.rdbms.exceptions.MissingTableException; @@ -178,6 +181,8 @@ private TXN_STATUS transactionStatus = TXN_STATUS.NO_STATE; private final AtomicBoolean isSchemaVerified = new AtomicBoolean(false); + private Pattern partitionValidationPattern; + public ObjectStore() { } @@ -222,6 +227,14 @@ initialize(propsFromConf); + String partitionValidationRegex = + hiveConf.get(HiveConf.ConfVars.METASTORE_PARTITION_NAME_WHITELIST_PATTERN.name()); + if (partitionValidationRegex != null && partitionValidationRegex.equals("")) { + partitionValidationPattern = Pattern.compile(partitionValidationRegex); + } else { + partitionValidationPattern = null; + } + if (!isInitialized) { throw new RuntimeException( "Unable to create persistence manager. Check dss.log for details"); @@ -1276,7 +1289,81 @@ return success; } + private boolean isValidPartition( + Partition part, boolean ifNotExists) throws MetaException { + MetaStoreUtils.validatePartitionNameCharacters(part.getValues(), + partitionValidationPattern); + boolean doesExist = doesPartitionExist( + part.getDbName(), part.getTableName(), part.getValues()); + if (doesExist && !ifNotExists) { + throw new MetaException("Partition already exists: " + part); + } + return !doesExist; + } + + @Override + public boolean addPartitions(String dbName, String tblName, + PartitionSpecProxy partitionSpec, boolean ifNotExists) + throws InvalidObjectException, MetaException { + boolean success = false; + openTransaction(); + try { + List tabGrants = null; + List tabColumnGrants = null; + MTable table = this.getMTable(dbName, tblName); + if ("TRUE".equalsIgnoreCase(table.getParameters().get("PARTITION_LEVEL_PRIVILEGE"))) { + tabGrants = this.listAllTableGrants(dbName, tblName); + tabColumnGrants = this.listTableAllColumnGrants(dbName, tblName); + } + + if (!partitionSpec.getTableName().equals(tblName) || !partitionSpec.getDbName().equals(dbName)) { + throw new MetaException("Partition does not belong to target table " + + dbName + "." + tblName + ": " + partitionSpec); + } + +// List toPersist = new ArrayList(); + PartitionSpecProxy.PartitionIterator iterator = partitionSpec.getPartitionIterator(); + + int now = (int)(System.currentTimeMillis()/1000); + + while (iterator.hasNext()) { + Partition part = iterator.next(); + + if (isValidPartition(part, ifNotExists)) { + MPartition mpart = convertToMPart(part, true); +// toPersist.add(mpart); + pm.makePersistent(mpart); + if (tabGrants != null) { + for (MTablePrivilege tab : tabGrants) { +// toPersist.add(new MPartitionPrivilege(tab.getPrincipalName(), + pm.makePersistent(new MPartitionPrivilege(tab.getPrincipalName(), + tab.getPrincipalType(), mpart, tab.getPrivilege(), now, + tab.getGrantor(), tab.getGrantorType(), tab.getGrantOption())); + } + } + + if (tabColumnGrants != null) { + for (MTableColumnPrivilege col : tabColumnGrants) { +// toPersist.add(new MPartitionColumnPrivilege(col.getPrincipalName(), + pm.makePersistent(new MPartitionColumnPrivilege(col.getPrincipalName(), + col.getPrincipalType(), mpart, col.getColumnName(), col.getPrivilege(), + now, col.getGrantor(), col.getGrantorType(), col.getGrantOption())); + } + } + } + } + + success = commitTransaction(); + } finally { + if (!success) { + rollbackTransaction(); + } + } + return success; + } + + @Override public boolean addPartition(Partition part) throws InvalidObjectException, MetaException { boolean success = false; Index: metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java (working copy) @@ -57,6 +57,7 @@ import org.apache.hadoop.hive.metastore.api.StorageDescriptor; import org.apache.hadoop.hive.metastore.api.Table; import org.apache.hadoop.hive.metastore.api.hive_metastoreConstants; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.hadoop.hive.serde.serdeConstants; import org.apache.hadoop.hive.serde2.Deserializer; import org.apache.hadoop.hive.serde2.SerDeException; @@ -313,6 +314,40 @@ return updated; } + public static boolean updatePartitionStatsFast(PartitionSpecProxy.PartitionIterator part, Warehouse wh, + boolean madeDir, boolean forceRecompute) throws MetaException { + Map params = part.getParameters(); + boolean updated = false; + if (forceRecompute || + params == null || + !containsAllFastStats(params)) { + if (params == null) { + params = new HashMap(); + } + if (!madeDir) { + // The partitition location already existed and may contain data. Lets try to + // populate those statistics that don't require a full scan of the data. + LOG.warn("Updating partition stats fast for: " + part.getTableName()); + FileStatus[] fileStatus = wh.getFileStatusesForLocation(part.getLocation()); + populateQuickStats(fileStatus, params); + LOG.warn("Updated size to " + params.get(StatsSetupConst.TOTAL_SIZE)); + if(!params.containsKey(StatsSetupConst.STATS_GENERATED_VIA_STATS_TASK)) { + // invalidate stats requiring scan since this is a regular ddl alter case + for (String stat : StatsSetupConst.statsRequireCompute) { + params.put(stat, "-1"); + } + params.put(StatsSetupConst.COLUMN_STATS_ACCURATE, StatsSetupConst.FALSE); + } else { + params.remove(StatsSetupConst.STATS_GENERATED_VIA_STATS_TASK); + params.put(StatsSetupConst.COLUMN_STATS_ACCURATE, StatsSetupConst.TRUE); + } + } + part.setParameters(params); + updated = true; + } + return updated; + } + /** * getDeserializer * Index: metastore/src/java/org/apache/hadoop/hive/metastore/events/AddPartitionEvent.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/events/AddPartitionEvent.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/events/AddPartitionEvent.java (working copy) @@ -21,19 +21,23 @@ import org.apache.hadoop.hive.metastore.HiveMetaStore.HMSHandler; import org.apache.hadoop.hive.metastore.api.Partition; import org.apache.hadoop.hive.metastore.api.Table; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import java.util.Arrays; +import java.util.Iterator; import java.util.List; public class AddPartitionEvent extends ListenerEvent { private final Table table; private final List partitions; + private PartitionSpecProxy partitionSpecProxy; public AddPartitionEvent(Table table, List partitions, boolean status, HMSHandler handler) { super(status, handler); this.table = table; this.partitions = partitions; + this.partitionSpecProxy = null; } public AddPartitionEvent(Table table, Partition partition, boolean status, HMSHandler handler) { @@ -41,6 +45,16 @@ } /** + * Alternative constructor to use PartitionSpec APIs. + */ + public AddPartitionEvent(Table table, PartitionSpecProxy partitionSpec, boolean status, HMSHandler handler) { + super(status, handler); + this.table = table; + this.partitions = null; + this.partitionSpecProxy = partitionSpec; + } + + /** * @return The table. */ public Table getTable() { @@ -54,4 +68,11 @@ return partitions; } + /** + * @return Iterator for partitions. + */ + public Iterator getPartitionIterator() { + return partitionSpecProxy == null ? null : partitionSpecProxy.getPartitionIterator(); + } + } Index: metastore/src/java/org/apache/hadoop/hive/metastore/events/PreAddPartitionEvent.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/events/PreAddPartitionEvent.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/events/PreAddPartitionEvent.java (working copy) @@ -21,19 +21,23 @@ import org.apache.hadoop.hive.metastore.HiveMetaStore.HMSHandler; import org.apache.hadoop.hive.metastore.api.Partition; import org.apache.hadoop.hive.metastore.api.Table; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import java.util.Arrays; +import java.util.Iterator; import java.util.List; public class PreAddPartitionEvent extends PreEventContext { private final Table table; private final List partitions; + private PartitionSpecProxy partitionSpecProxy; public PreAddPartitionEvent (Table table, List partitions, HMSHandler handler) { super(PreEventType.ADD_PARTITION, handler); this.table = table; this.partitions = partitions; + this.partitionSpecProxy = null; } public PreAddPartitionEvent(Table table, Partition partition, HMSHandler handler) { @@ -41,6 +45,14 @@ } /** + * Alternative constructor, using + */ + public PreAddPartitionEvent(Table table, PartitionSpecProxy partitionSpecProxy, HMSHandler handler) { + this(table, (List)null, handler); + this.partitionSpecProxy = partitionSpecProxy; + } + + /** * @return the partitions */ public List getPartitions() { @@ -53,4 +65,11 @@ public Table getTable() { return table ; } + + /** + * @return Iterator over partition-list. + */ + public Iterator getPartitionIterator() { + return partitionSpecProxy == null ? null : partitionSpecProxy.getPartitionIterator(); + } } Index: metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionSpecWithSharedSDProxy.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionSpecWithSharedSDProxy.java (revision 0) +++ metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionSpecWithSharedSDProxy.java (revision 0) @@ -0,0 +1,154 @@ +package org.apache.hadoop.hive.metastore.partition.spec; + +import org.apache.hadoop.hive.metastore.api.MetaException; +import org.apache.hadoop.hive.metastore.api.Partition; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; +import org.apache.hadoop.hive.metastore.api.PartitionSpecWithSharedSD; +import org.apache.hadoop.hive.metastore.api.PartitionWithoutSD; +import org.apache.hadoop.hive.metastore.api.StorageDescriptor; + +import java.util.Arrays; +import java.util.List; +import java.util.Map; + +/** + * Subclass of PartitionSpecProxy that pulls out commonality of + * StorageDescriptor properties within a Partition-list into a common + * StorageDescriptor instance. + */ +public class PartitionSpecWithSharedSDProxy extends PartitionSpecProxy { + + private PartitionSpec partitionSpec; + + public PartitionSpecWithSharedSDProxy(PartitionSpec partitionSpec) { + assert partitionSpec.isSetSharedSDPartitionSpec(); + this.partitionSpec = partitionSpec; + } + + @Override + public int size() { + return partitionSpec.getSharedSDPartitionSpec().getPartitionsSize(); + } + + @Override + public void setDbName(String dbName) { + partitionSpec.setDbName(dbName); + } + + @Override + public void setTableName(String tableName) { + partitionSpec.setTableName(tableName); + } + + @Override + public String getDbName() { + return partitionSpec.getDbName(); + } + + @Override + public String getTableName() { + return partitionSpec.getTableName(); + } + + public PartitionIterator getPartitionIterator() { + return new Iterator(this); + } + + @Override + public List toPartitionSpec() { + return Arrays.asList(partitionSpec); + } + + @Override + public void setRootLocation(String rootLocation) throws MetaException { + partitionSpec.setRootPath(rootLocation); + partitionSpec.getSharedSDPartitionSpec().getSd().setLocation(rootLocation); + } + + /** + * Iterator implementation to iterate over all Partitions within the PartitionSpecWithSharedSDProxy. + */ + public static class Iterator implements PartitionIterator { + + private PartitionSpecWithSharedSDProxy partitionSpecWithSharedSDProxy; + private PartitionSpecWithSharedSD pSpec; + private int index; + + Iterator(PartitionSpecWithSharedSDProxy partitionSpecWithSharedSDProxy) { + this.partitionSpecWithSharedSDProxy = partitionSpecWithSharedSDProxy; + this.pSpec = this.partitionSpecWithSharedSDProxy.partitionSpec.getSharedSDPartitionSpec(); + this.index = 0; + } + + @Override + public boolean hasNext() { + return index < pSpec.getPartitions().size(); + } + + @Override + public Partition next() { + Partition partition = getCurrent(); + ++index; + return partition; + } + + @Override + public void remove() { + pSpec.getPartitions().remove(index); + } + + @Override + public Partition getCurrent() { + PartitionWithoutSD partWithoutSD = pSpec.getPartitions().get(index); + StorageDescriptor partSD = new StorageDescriptor(pSpec.getSd()); + partSD.setLocation(partSD.getLocation() + partWithoutSD.getRelativePath()); + + return new Partition( + partWithoutSD.getValues(), + partitionSpecWithSharedSDProxy.partitionSpec.getDbName(), + partitionSpecWithSharedSDProxy.partitionSpec.getTableName(), + partWithoutSD.getCreateTime(), + partWithoutSD.getLastAccessTime(), + partSD, + partWithoutSD.getParameters() + ); + } + + @Override + public String getDbName() { + return partitionSpecWithSharedSDProxy.partitionSpec.getDbName(); + } + + @Override + public String getTableName() { + return partitionSpecWithSharedSDProxy.partitionSpec.getTableName(); + } + + @Override + public Map getParameters() { + return pSpec.getPartitions().get(index).getParameters(); + } + + @Override + public void setParameters(Map parameters) { + pSpec.getPartitions().get(index).setParameters(parameters); + } + + @Override + public String getLocation() { + return pSpec.getSd().getLocation() + pSpec.getPartitions().get(index).getRelativePath(); + } + + @Override + public void putToParameters(String key, String value) { + pSpec.getPartitions().get(index).putToParameters(key, value); + } + + @Override + public void setCreateTime(long time) { + pSpec.getPartitions().get(index).setCreateTime((int)time); + } + + } // static class Iterator; + +} Index: metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionListComposingSpecProxy.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionListComposingSpecProxy.java (revision 0) +++ metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionListComposingSpecProxy.java (revision 0) @@ -0,0 +1,153 @@ +package org.apache.hadoop.hive.metastore.partition.spec; + +import org.apache.hadoop.hive.metastore.api.MetaException; +import org.apache.hadoop.hive.metastore.api.Partition; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; + +import java.util.Arrays; +import java.util.List; +import java.util.Map; + +/** + * PartitionSpecProxy implementation that composes a List of Partitions. + */ +public class PartitionListComposingSpecProxy extends PartitionSpecProxy { + + private PartitionSpec partitionSpec; + + protected PartitionListComposingSpecProxy(PartitionSpec partitionSpec) { + assert partitionSpec.isSetPartitionList() + : "Partition-list should have been set."; + this.partitionSpec = partitionSpec; + } + + @Override + public String getDbName() { + return partitionSpec.getDbName(); + } + + @Override + public String getTableName() { + return partitionSpec.getTableName(); + } + + @Override + public PartitionIterator getPartitionIterator() { + return new Iterator(this); + } + + @Override + public List toPartitionSpec() { + return Arrays.asList(partitionSpec); + } + + @Override + public int size() { + return partitionSpec.getPartitionList().getPartitionsSize(); + } + + @Override + public void setDbName(String dbName) { + partitionSpec.setDbName(dbName); + for (Partition partition : partitionSpec.getPartitionList().getPartitions()) { + partition.setDbName(dbName); + } + } + + @Override + public void setTableName(String tableName) { + partitionSpec.setTableName(tableName); + for (Partition partition : partitionSpec.getPartitionList().getPartitions()) { + partition.setTableName(tableName); + } + } + + @Override + public void setRootLocation(String newRootPath) throws MetaException { + + String oldRootPath = partitionSpec.getRootPath(); + + if (oldRootPath == null) { + throw new MetaException("No common root-path. Can't replace root-path!"); + } + + for (Partition partition : partitionSpec.getPartitionList().getPartitions()) { + String location = partition.getSd().getLocation(); + if (location.startsWith(oldRootPath)) { + partition.getSd().setLocation(location.replace(oldRootPath, newRootPath)); + } + else { + throw new MetaException("Common root-path not found. Can't replace root-path!"); + } + } + } + + public static class Iterator implements PartitionIterator { + + PartitionListComposingSpecProxy partitionSpecProxy; + List partitionList; + int index; + + public Iterator(PartitionListComposingSpecProxy partitionSpecProxy) { + this.partitionSpecProxy = partitionSpecProxy; + this.partitionList = partitionSpecProxy.partitionSpec.getPartitionList().getPartitions(); + this.index = 0; + } + + @Override + public Partition getCurrent() { + return partitionList.get(index); + } + + @Override + public String getDbName() { + return partitionSpecProxy.getDbName(); + } + + @Override + public String getTableName() { + return partitionSpecProxy.getTableName(); + } + + @Override + public Map getParameters() { + return partitionList.get(index).getParameters(); + } + + @Override + public void setParameters(Map parameters) { + partitionList.get(index).setParameters(parameters); + } + + @Override + public String getLocation() { + return partitionList.get(index).getSd().getLocation(); + } + + @Override + public void putToParameters(String key, String value) { + partitionList.get(index).putToParameters(key, value); + } + + @Override + public void setCreateTime(long time) { + partitionList.get(index).setCreateTime((int)time); + } + + @Override + public boolean hasNext() { + return index < partitionList.size(); + } + + @Override + public Partition next() { + return partitionList.get(index++); + } + + @Override + public void remove() { + partitionList.remove(index); + } + } // class Iterator; + +} // class PartitionListComposingSpecProxy; Index: metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionSpecProxy.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionSpecProxy.java (revision 0) +++ metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/PartitionSpecProxy.java (revision 0) @@ -0,0 +1,160 @@ +package org.apache.hadoop.hive.metastore.partition.spec; + +import org.apache.hadoop.hive.metastore.api.MetaException; +import org.apache.hadoop.hive.metastore.api.Partition; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; + +import java.util.List; +import java.util.Map; + +/** + * Polymorphic proxy class, equivalent to org.apache.hadoop.hive.metastore.api.PartitionSpec. + */ +public abstract class PartitionSpecProxy { + + /** + * The number of Partition instances represented by the PartitionSpec. + * @return Number of partitions. + */ + public abstract int size(); + + /** + * Setter for name of the DB. + * @param dbName The name of the DB. + */ + public abstract void setDbName(String dbName); + + /** + * Setter for name of the table. + * @param tableName The name of the table. + */ + public abstract void setTableName(String tableName); + + /** + * Getter for name of the DB. + * @return The name of the DB. + */ + public abstract String getDbName(); + + /** + * Getter for name of the table. + * @return The name of the table. + */ + public abstract String getTableName(); + + /** + * Iterator to the (virtual) sequence of Partitions represented by the PartitionSpec. + * @return A PartitionIterator to the beginning of the Partition sequence. + */ + public abstract PartitionIterator getPartitionIterator(); + + /** + * Conversion to a org.apache.hadoop.hive.metastore.api.PartitionSpec sequence. + * @return A list of org.apache.hadoop.hive.metastore.api.PartitionSpec instances. + */ + public abstract List toPartitionSpec(); + + /** + * Setter for the common root-location for all partitions in the PartitionSet. + * @param rootLocation The new common root-location. + * @throws MetaException + */ + public abstract void setRootLocation(String rootLocation) throws MetaException; + + /** + * Factory to construct PartitionSetProxy instances, from PartitionSets. + */ + public static class Factory { + + /** + * Factory method. Construct PartitionSpecProxy from raw PartitionSpec. + * @param partSpec Raw PartitionSpec from the Thrift API. + * @return PartitionSpecProxy instance. + */ + public static PartitionSpecProxy get(PartitionSpec partSpec) { + + if (partSpec == null) { + return null; + } + else + if (partSpec.isSetPartitionList()) { + return new PartitionListComposingSpecProxy(partSpec); + } + else + if (partSpec.isSetSharedSDPartitionSpec()) { + return new PartitionSpecWithSharedSDProxy(partSpec); + } + + assert false : "Unsupported type of PartitionSpec!"; + return null; + } + + /** + * Factory method to construct CompositePartitionSpecProxy. + * @param partitionSpecs List of raw PartitionSpecs. + * @return A CompositePartitionSpecProxy instance. + */ + public static PartitionSpecProxy get(List partitionSpecs) { + return new CompositePartitionSpecProxy(partitionSpecs); + } + + } // class Factory; + + /** + * Iterator to iterate over Partitions corresponding to a PartitionSpec. + */ + public static interface PartitionIterator extends java.util.Iterator { + + /** + * Getter for the Partition "pointed to" by the iterator. + * Like next(), but without advancing the iterator. + * @return The "current" partition object. + */ + public Partition getCurrent(); + + /** + * Getter for the name of the DB. + * @return Name of the DB. + */ + public String getDbName(); + + /** + * Getter for the name of the table. + * @return Name of the table. + */ + public String getTableName(); + + /** + * Getter for the Partition parameters. + * @return Key-value map for Partition-level parameters. + */ + public Map getParameters(); + + /** + * Setter for Partition parameters. + * @param parameters Key-value map fo Partition-level parameters. + */ + public void setParameters(Map parameters); + + /** + * Insert an individual parameter to a Partition's parameter-set. + * @param key + * @param value + */ + public void putToParameters(String key, String value); + + /** + * Getter for Partition-location. + * @return Partition's location. + */ + public String getLocation(); + + /** + * Setter for creation-time of a Partition. + * @param time Timestamp indicating the time of creation of the Partition. + */ + public void setCreateTime(long time); + + } // class PartitionIterator; + +} // class PartitionSpecProxy; Index: metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/CompositePartitionSpecProxy.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/CompositePartitionSpecProxy.java (revision 0) +++ metastore/src/java/org/apache/hadoop/hive/metastore/partition/spec/CompositePartitionSpecProxy.java (revision 0) @@ -0,0 +1,210 @@ +package org.apache.hadoop.hive.metastore.partition.spec; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.hadoop.hive.metastore.api.MetaException; +import org.apache.hadoop.hive.metastore.api.Partition; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +/** + * Implementation of PartitionSpecProxy that composes a list of PartitionSpecProxy. + */ +public class CompositePartitionSpecProxy extends PartitionSpecProxy { + + private String dbName; + private String tableName; + private List partitionSpecs; + private List partitionSpecProxies; + private int size = 0; + + protected CompositePartitionSpecProxy(List partitionSpecs) { + this.partitionSpecs = partitionSpecs; + if (partitionSpecs.isEmpty()) { + dbName = null; + tableName = null; + } + else { + dbName = partitionSpecs.get(0).getDbName(); + tableName = partitionSpecs.get(0).getTableName(); + this.partitionSpecProxies = new ArrayList(partitionSpecs.size()); + for (PartitionSpec partitionSpec : partitionSpecs) { + PartitionSpecProxy partitionSpecProxy = Factory.get(partitionSpec); + this.partitionSpecProxies.add(partitionSpecProxy); + size += partitionSpecProxy.size(); + } + } + // Assert class-invariant. + assert isValid() : "Invalid CompositePartitionSpecProxy!"; + } + + protected CompositePartitionSpecProxy(String dbName, String tableName, List partitionSpecs) { + this.dbName = dbName; + this.tableName = tableName; + this.partitionSpecs = partitionSpecs; + this.partitionSpecProxies = new ArrayList(partitionSpecs.size()); + for (PartitionSpec partitionSpec : partitionSpecs) { + this.partitionSpecProxies.add(PartitionSpecProxy.Factory.get(partitionSpec)); + } + // Assert class-invariant. + assert isValid() : "Invalid CompositePartitionSpecProxy!"; + } + + private boolean isValid() { + for (PartitionSpecProxy partitionSpecProxy : partitionSpecProxies) { + if (partitionSpecProxy instanceof CompositePartitionSpecProxy) { + return false; + } + } + + return true; + } + + @Override + public int size() { + return size; + } + + /** + * Iterator to iterate over all Partitions, across all PartitionSpecProxy instances within the Composite. + */ + public static class Iterator implements PartitionIterator { + + private CompositePartitionSpecProxy composite; + private List partitionSpecProxies; + private int index = -1; // Index into partitionSpecs. + private PartitionIterator iterator = null; + + public Iterator(CompositePartitionSpecProxy composite) { + this.composite = composite; + this.partitionSpecProxies = composite.partitionSpecProxies; + + if (this.partitionSpecProxies != null && !this.partitionSpecProxies.isEmpty()) { + this.index = 0; + this.iterator = this.partitionSpecProxies.get(this.index).getPartitionIterator(); + } + } + + @Override + public boolean hasNext() { + + if (iterator == null) { + return false; + } + + if (iterator.hasNext()) { + return true; + } + + while ( ++index < partitionSpecProxies.size() + && !(iterator = partitionSpecProxies.get(index).getPartitionIterator()).hasNext()); + + return index < partitionSpecProxies.size() && iterator.hasNext(); + + } + + @Override + public Partition next() { + + if (iterator.hasNext()) + return iterator.next(); + + while (++index < partitionSpecProxies.size() + && !(iterator = partitionSpecProxies.get(index).getPartitionIterator()).hasNext()); + + return index == partitionSpecProxies.size()? null : iterator.next(); + + } + + @Override + public void remove() { + iterator.remove(); + } + + @Override + public Partition getCurrent() { + return iterator.getCurrent(); + } + + @Override + public String getDbName() { + return composite.dbName; + } + + @Override + public String getTableName() { + return composite.tableName; + } + + @Override + public Map getParameters() { + return iterator.getParameters(); + } + + @Override + public void setParameters(Map parameters) { + iterator.setParameters(parameters); + } + + @Override + public String getLocation() { + return iterator.getLocation(); + } + + @Override + public void putToParameters(String key, String value) { + iterator.putToParameters(key, value); + } + + @Override + public void setCreateTime(long time) { + iterator.setCreateTime(time); + } + } + + @Override + public void setDbName(String dbName) { + this.dbName = dbName; + for (PartitionSpecProxy partSpecProxy : partitionSpecProxies) { + partSpecProxy.setDbName(dbName); + } + } + + @Override + public void setTableName(String tableName) { + this.tableName = tableName; + for (PartitionSpecProxy partSpecProxy : partitionSpecProxies) { + partSpecProxy.setTableName(tableName); + } + } + + @Override + public String getDbName() { + return dbName; + } + + @Override + public String getTableName() { + return tableName; + } + + @Override + public PartitionIterator getPartitionIterator() { + return new Iterator(this); + } + + @Override + public List toPartitionSpec() { + return partitionSpecs; + } + + @Override + public void setRootLocation(String rootLocation) throws MetaException { + for (PartitionSpecProxy partSpecProxy : partitionSpecProxies) { + partSpecProxy.setRootLocation(rootLocation); + } + } +} Index: metastore/src/java/org/apache/hadoop/hive/metastore/Warehouse.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/Warehouse.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/Warehouse.java (working copy) @@ -518,6 +518,23 @@ } /** + * @param location + * @return array of FileStatus objects corresponding to the files + * making up the passed storage description + */ + public FileStatus[] getFileStatusesForLocation(String location) + throws MetaException { + try { + Path path = new Path(location); + FileSystem fileSys = path.getFileSystem(conf); + return HiveStatsUtils.getFileStatusRecurse(path, -1, fileSys); + } catch (IOException ioe) { + MetaStoreUtils.logAndThrowMetaException(ioe); + } + return null; + } + + /** * @param table * @return array of FileStatus objects corresponding to the files making up the passed * unpartitioned table Index: metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java (working copy) @@ -28,10 +28,12 @@ import org.apache.hadoop.hive.metastore.api.NoSuchLockException; import org.apache.hadoop.hive.metastore.api.NoSuchTxnException; import org.apache.hadoop.hive.metastore.api.OpenTxnsResponse; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; import org.apache.hadoop.hive.metastore.api.ShowCompactResponse; import org.apache.hadoop.hive.metastore.api.ShowLocksResponse; import org.apache.hadoop.hive.metastore.api.TxnAbortedException; import org.apache.hadoop.hive.metastore.api.TxnOpenException; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.thrift.TException; import java.util.List; @@ -367,6 +369,9 @@ int add_partitions(List partitions) throws InvalidObjectException, AlreadyExistsException, MetaException, TException; + int add_partitions_pspec(PartitionSpecProxy partitionSpec) + throws InvalidObjectException, AlreadyExistsException, MetaException, TException; + /** * Add partitions to the table. * @@ -447,6 +452,8 @@ List listPartitions(String db_name, String tbl_name, short max_parts) throws NoSuchObjectException, MetaException, TException; + public PartitionSpecProxy listPartitionSpecs(String dbName, String tableName, int maxParts) + throws TException; List listPartitions(String db_name, String tbl_name, List part_vals, short max_parts) throws NoSuchObjectException, MetaException, TException; @@ -475,6 +482,9 @@ String filter, short max_parts) throws MetaException, NoSuchObjectException, TException; + PartitionSpecProxy listPartitionSpecsByFilter(String db_name, String tbl_name, + String filter, int max_parts) throws MetaException, + NoSuchObjectException, TException; /** * Get list of partitions matching specified serialized expression Index: metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java (working copy) @@ -97,6 +97,7 @@ import org.apache.hadoop.hive.metastore.api.OpenTxnsResponse; import org.apache.hadoop.hive.metastore.api.Partition; import org.apache.hadoop.hive.metastore.api.PartitionEventType; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; import org.apache.hadoop.hive.metastore.api.PartitionsByExprRequest; import org.apache.hadoop.hive.metastore.api.PartitionsByExprResult; import org.apache.hadoop.hive.metastore.api.PartitionsStatsRequest; @@ -119,6 +120,8 @@ import org.apache.hadoop.hive.metastore.api.UnknownPartitionException; import org.apache.hadoop.hive.metastore.api.UnknownTableException; import org.apache.hadoop.hive.metastore.api.UnlockRequest; +import org.apache.hadoop.hive.metastore.partition.spec.CompositePartitionSpecProxy; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.hadoop.hive.metastore.txn.TxnHandler; import org.apache.hadoop.hive.shims.HadoopShims; import org.apache.hadoop.hive.shims.ShimLoader; @@ -505,6 +508,11 @@ return needResults ? result.getPartitions() : null; } + @Override + public int add_partitions_pspec(PartitionSpecProxy partitionSpec) throws TException { + return client.add_partitions_pspec(partitionSpec.toPartitionSpec()); + } + /** * @param table_name * @param db_name @@ -907,6 +915,11 @@ } @Override + public PartitionSpecProxy listPartitionSpecs(String dbName, String tableName, int maxParts) throws TException { + return PartitionSpecProxy.Factory.get(client.get_partitions_pspec(dbName, tableName, maxParts)); + } + + @Override public List listPartitions(String db_name, String tbl_name, List part_vals, short max_parts) throws NoSuchObjectException, MetaException, TException { @@ -954,6 +967,14 @@ } @Override + public PartitionSpecProxy listPartitionSpecsByFilter(String db_name, String tbl_name, + String filter, int max_parts) throws MetaException, + NoSuchObjectException, TException { + return PartitionSpecProxy.Factory.get( + client.get_part_specs_by_filter(db_name, tbl_name, filter, max_parts)); + } + + @Override public boolean listPartitionsByExpr(String db_name, String tbl_name, byte[] expr, String default_partition_name, short max_parts, List result) throws TException { Index: metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java =================================================================== --- metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java (revision 1619008) +++ metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java (working copy) @@ -47,6 +47,9 @@ import java.util.concurrent.locks.ReentrantLock; import java.util.regex.Pattern; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableListMultimap; +import com.google.common.collect.Multimaps; import org.apache.commons.cli.OptionBuilder; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; @@ -111,6 +114,10 @@ import org.apache.hadoop.hive.metastore.api.OpenTxnsResponse; import org.apache.hadoop.hive.metastore.api.Partition; import org.apache.hadoop.hive.metastore.api.PartitionEventType; +import org.apache.hadoop.hive.metastore.api.PartitionListComposingSpec; +import org.apache.hadoop.hive.metastore.api.PartitionSpec; +import org.apache.hadoop.hive.metastore.api.PartitionSpecWithSharedSD; +import org.apache.hadoop.hive.metastore.api.PartitionWithoutSD; import org.apache.hadoop.hive.metastore.api.PartitionsByExprRequest; import org.apache.hadoop.hive.metastore.api.PartitionsByExprResult; import org.apache.hadoop.hive.metastore.api.PartitionsStatsRequest; @@ -127,6 +134,7 @@ import org.apache.hadoop.hive.metastore.api.ShowLocksRequest; import org.apache.hadoop.hive.metastore.api.ShowLocksResponse; import org.apache.hadoop.hive.metastore.api.SkewedInfo; +import org.apache.hadoop.hive.metastore.api.StorageDescriptor; import org.apache.hadoop.hive.metastore.api.Table; import org.apache.hadoop.hive.metastore.api.TableStatsRequest; import org.apache.hadoop.hive.metastore.api.TableStatsResult; @@ -169,6 +177,7 @@ import org.apache.hadoop.hive.metastore.model.MRoleMap; import org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege; import org.apache.hadoop.hive.metastore.model.MTablePrivilege; +import org.apache.hadoop.hive.metastore.partition.spec.PartitionSpecProxy; import org.apache.hadoop.hive.metastore.txn.TxnHandler; import org.apache.hadoop.hive.serde2.Deserializer; import org.apache.hadoop.hive.serde2.SerDeException; @@ -1841,6 +1850,52 @@ } } + private static class PartValEqWrapperLite { + List values; + String location; + + public PartValEqWrapperLite(Partition partition) { + this.values = partition.isSetValues()? partition.getValues() : null; + this.location = partition.getSd().getLocation(); + } + + @Override + public int hashCode() { + return values == null ? 0 : values.hashCode(); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || !(obj instanceof PartValEqWrapperLite)) { + return false; + } + + List lhsValues = this.values; + List rhsValues = ((PartValEqWrapperLite)obj).values; + + if (lhsValues == null || rhsValues == null) + return lhsValues == rhsValues; + + if (lhsValues.size() != rhsValues.size()) + return false; + + for (int i=0; i add_partitions_core( RawStore ms, String dbName, String tblName, List parts, boolean ifNotExists) throws MetaException, InvalidObjectException, AlreadyExistsException, TException { @@ -1968,6 +2023,85 @@ return ret; } + @Override + public int add_partitions_pspec(final List partSpecs) + throws TException { + logInfo("add_partitions_pspec"); + + if (partSpecs.isEmpty()) { + return 0; + } + + String dbName = partSpecs.get(0).getDbName(); + String tableName = partSpecs.get(0).getTableName(); + + return add_partitions_pspec_core(getMS(), dbName, tableName, partSpecs, false); + } + + private int add_partitions_pspec_core( + RawStore ms, String dbName, String tblName, List partSpecs, boolean ifNotExists) + throws TException { + boolean success = false; + // Ensures that the list doesn't have dups, and keeps track of directories we have created. + Map addedPartitions = new HashMap(); + PartitionSpecProxy partitionSpecProxy = PartitionSpecProxy.Factory.get(partSpecs); + PartitionSpecProxy.PartitionIterator partitionIterator = partitionSpecProxy.getPartitionIterator(); + Table tbl = null; + try { + ms.openTransaction(); + tbl = ms.getTable(dbName, tblName); + if (tbl == null) { + throw new InvalidObjectException("Unable to add partitions because " + + "database or table " + dbName + "." + tblName + " does not exist"); + } + + firePreEvent(new PreAddPartitionEvent(tbl, partitionSpecProxy, this)); + + int nPartitions = 0; + while(partitionIterator.hasNext()) { + + Partition part = partitionIterator.getCurrent(); + + if (!part.getTableName().equals(tblName) || !part.getDbName().equals(dbName)) { + throw new MetaException("Partition does not belong to target table " + + dbName + "." + tblName + ": " + part); + } + boolean shouldAdd = startAddPartition(ms, part, ifNotExists); + if (!shouldAdd) { + LOG.info("Not adding partition " + part + " as it already exists"); + continue; + } + boolean madeDir = createLocationForAddedPartition(tbl, part); + if (addedPartitions.put(new PartValEqWrapperLite(part), madeDir) != null) { + // Technically, for ifNotExists case, we could insert one and discard the other + // because the first one now "exists", but it seems better to report the problem + // upstream as such a command doesn't make sense. + throw new MetaException("Duplicate partitions in the list: " + part); + } + initializeAddedPartition(tbl, partitionIterator, madeDir); + + ++nPartitions; + partitionIterator.next(); + } + + success = ms.addPartitions(dbName, tblName, partitionSpecProxy, ifNotExists) + && ms.commitTransaction(); + + return nPartitions; + } finally { + if (!success) { + ms.rollbackTransaction(); + for (Entry e : addedPartitions.entrySet()) { + if (e.getValue()) { + wh.deleteDir(new Path(e.getKey().location), true); + // we just created this directory - it's not a case of pre-creation, so we nuke + } + } + } + fireMetaStoreAddPartitionEvent(tbl, partitionSpecProxy, null, true); + } + } + private boolean startAddPartition( RawStore ms, Partition part, boolean ifNotExists) throws MetaException, TException { MetaStoreUtils.validatePartitionNameCharacters(part.getValues(), @@ -2059,6 +2193,39 @@ } } + private void initializeAddedPartition( + final Table tbl, final PartitionSpecProxy.PartitionIterator partIterator, boolean madeDir) throws MetaException { + if (HiveConf.getBoolVar(hiveConf, HiveConf.ConfVars.HIVESTATSAUTOGATHER) && + !MetaStoreUtils.isView(tbl)) { + MetaStoreUtils.updatePartitionStatsFast(partIterator, wh, madeDir, false); + } + + // set create time + long time = System.currentTimeMillis() / 1000; + partIterator.setCreateTime((int) time); + if (partIterator.getParameters() == null || + partIterator.getParameters().get(hive_metastoreConstants.DDL_TIME) == null) { + partIterator.putToParameters(hive_metastoreConstants.DDL_TIME, Long.toString(time)); + } + + // Inherit table properties into partition properties. + Map tblParams = tbl.getParameters(); + String inheritProps = hiveConf.getVar(ConfVars.METASTORE_PART_INHERIT_TBL_PROPS).trim(); + // Default value is empty string in which case no properties will be inherited. + // * implies all properties needs to be inherited + Set inheritKeys = new HashSet(Arrays.asList(inheritProps.split(","))); + if (inheritKeys.contains("*")) { + inheritKeys = tblParams.keySet(); + } + + for (String key : inheritKeys) { + String paramVal = tblParams.get(key); + if (null != paramVal) { // add the property only if it exists in table properties + partIterator.putToParameters(key, paramVal); + } + } + } + private Partition add_partition_core(final RawStore ms, final Partition part, final EnvironmentContext envContext) throws InvalidObjectException, AlreadyExistsException, MetaException, TException { @@ -2111,6 +2278,20 @@ } } + private void fireMetaStoreAddPartitionEvent(final Table tbl, + final PartitionSpecProxy partitionSpec, final EnvironmentContext envContext, boolean success) + throws MetaException { + if (tbl != null && partitionSpec != null) { + AddPartitionEvent addPartitionEvent = + new AddPartitionEvent(tbl, partitionSpec, success, this); + addPartitionEvent.setEnvironmentContext(envContext); + + for (MetaStoreEventListener listener : listeners) { + listener.onAddPartition(addPartitionEvent); + } + } + } + @Override public Partition add_partition(final Partition part) throws InvalidObjectException, AlreadyExistsException, MetaException { @@ -2571,6 +2752,161 @@ } @Override + public List get_partitions_pspec(final String db_name, final String tbl_name, final int max_parts) + throws NoSuchObjectException, MetaException { + + String dbName = db_name.toLowerCase(); + String tableName = tbl_name.toLowerCase(); + + startTableFunction("get_partitions_pspec", dbName, tableName); + + List partitionSpecs = null; + try { + Table table = get_table(dbName, tableName); + List partitions = get_partitions(dbName, tableName, (short) max_parts); + + if (is_partition_spec_grouping_enabled(table)) { + partitionSpecs = get_partitionspecs_grouped_by_storage_descriptor(table, partitions); + } + else { + PartitionSpec pSpec = new PartitionSpec(); + pSpec.setPartitionList(new PartitionListComposingSpec(partitions)); + pSpec.setDbName(dbName); + pSpec.setTableName(tableName); + pSpec.setRootPath(table.getSd().getLocation()); + partitionSpecs = Arrays.asList(pSpec); + } + + return partitionSpecs; + } + finally { + endFunction("get_partitions_pspec", partitionSpecs != null && !partitionSpecs.isEmpty(), null, tbl_name); + } + } + + private static class StorageDescriptorKey { + + private StorageDescriptor sd; + + StorageDescriptorKey(StorageDescriptor sd) { this.sd = sd; } + + StorageDescriptor getSd() { + return sd; + } + + private String hashCodeKey() { + return sd.getInputFormat() + "\t" + + sd.getOutputFormat() + "\t" + + sd.getSerdeInfo().getSerializationLib() + "\t" + + sd.getCols(); + } + + @Override + public int hashCode() { + return hashCodeKey().hashCode(); + } + + @Override + public boolean equals(Object rhs) { + if (rhs == this) + return true; + + if (!(rhs instanceof StorageDescriptorKey)) + return false; + + return (hashCodeKey().equals(((StorageDescriptorKey) rhs).hashCodeKey())); + } + } + + private List get_partitionspecs_grouped_by_storage_descriptor(Table table, List partitions) + throws NoSuchObjectException, MetaException { + + assert is_partition_spec_grouping_enabled(table); + + final String tablePath = table.getSd().getLocation(); + + ImmutableListMultimap partitionsWithinTableDirectory + = Multimaps.index(partitions, new com.google.common.base.Function() { + + @Override + public Boolean apply(Partition input) { + return input.getSd().getLocation().startsWith(tablePath); + } + }); + + List partSpecs = new ArrayList(); + + // Classify partitions within the table directory into groups, + // based on shared SD properties. + + Map> sdToPartList + = new HashMap>(); + + if (partitionsWithinTableDirectory.containsKey(true)) { + + ImmutableList partsWithinTableDir = partitionsWithinTableDirectory.get(true); + for (Partition partition : partsWithinTableDir) { + + PartitionWithoutSD partitionWithoutSD + = new PartitionWithoutSD( partition.getValues(), + partition.getCreateTime(), + partition.getLastAccessTime(), + partition.getSd().getLocation().substring(tablePath.length()), partition.getParameters()); + + StorageDescriptorKey sdKey = new StorageDescriptorKey(partition.getSd()); + if (!sdToPartList.containsKey(sdKey)) { + sdToPartList.put(sdKey, new ArrayList()); + } + + sdToPartList.get(sdKey).add(partitionWithoutSD); + + } // for (partitionsWithinTableDirectory); + + for (Map.Entry> entry : sdToPartList.entrySet()) { + partSpecs.add(getSharedSDPartSpec(table, entry.getKey(), entry.getValue())); + } + + } // Done grouping partitions within table-dir. + + // Lump all partitions outside the tablePath into one PartSpec. + if (partitionsWithinTableDirectory.containsKey(false)) { + List partitionsOutsideTableDir = partitionsWithinTableDirectory.get(false); + if (!partitionsOutsideTableDir.isEmpty()) { + PartitionSpec partListSpec = new PartitionSpec(); + partListSpec.setDbName(table.getDbName()); + partListSpec.setTableName(table.getTableName()); + partListSpec.setPartitionList(new PartitionListComposingSpec(partitionsOutsideTableDir)); + partSpecs.add(partListSpec); + } + + } + return partSpecs; + } + + private PartitionSpec getSharedSDPartSpec(Table table, StorageDescriptorKey sdKey, List partitions) { + + StorageDescriptor sd = new StorageDescriptor(sdKey.getSd()); + sd.setLocation(table.getSd().getLocation()); // Use table-dir as root-dir. + PartitionSpecWithSharedSD sharedSDPartSpec = + new PartitionSpecWithSharedSD(partitions, sd); + + PartitionSpec ret = new PartitionSpec(); + ret.setRootPath(sd.getLocation()); + ret.setSharedSDPartitionSpec(sharedSDPartSpec); + ret.setDbName(table.getDbName()); + ret.setTableName(table.getTableName()); + + return ret; + } + + private static boolean is_partition_spec_grouping_enabled(Table table) { + + Map parameters = table.getParameters(); + return parameters.containsKey("hive.hcatalog.partition.spec.grouping.enabled") + && parameters.get("hive.hcatalog.partition.spec.grouping.enabled").equalsIgnoreCase("true"); + } + + @Override public List get_partition_names(final String db_name, final String tbl_name, final short max_parts) throws MetaException { startTableFunction("get_partition_names", db_name, tbl_name); @@ -3779,6 +4115,37 @@ } @Override + public List get_part_specs_by_filter(final String dbName, + final String tblName, final String filter, final int maxParts) + throws MetaException, NoSuchObjectException, TException { + + startTableFunction("get_partitions_by_filter_pspec", dbName, tblName); + + List partitionSpecs = null; + try { + Table table = get_table(dbName, tblName); + List partitions = get_partitions_by_filter(dbName, tblName, filter, (short) maxParts); + + if (is_partition_spec_grouping_enabled(table)) { + partitionSpecs = get_partitionspecs_grouped_by_storage_descriptor(table, partitions); + } + else { + PartitionSpec pSpec = new PartitionSpec(); + pSpec.setPartitionList(new PartitionListComposingSpec(partitions)); + pSpec.setRootPath(table.getSd().getLocation()); + pSpec.setDbName(dbName); + pSpec.setTableName(tblName); + partitionSpecs = Arrays.asList(pSpec); + } + + return partitionSpecs; + } + finally { + endFunction("get_partitions_by_filter_pspec", partitionSpecs != null && !partitionSpecs.isEmpty(), null, tblName); + } + } + + @Override public PartitionsByExprResult get_partitions_by_expr( PartitionsByExprRequest req) throws TException { String dbName = req.getDbName(), tblName = req.getTblName(); Index: metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py =================================================================== --- metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py (revision 1619008) +++ metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py (working copy) @@ -2889,6 +2889,406 @@ def __ne__(self, other): return not (self == other) +class PartitionWithoutSD: + """ + Attributes: + - values + - createTime + - lastAccessTime + - relativePath + - parameters + - privileges + """ + + thrift_spec = ( + None, # 0 + (1, TType.LIST, 'values', (TType.STRING,None), None, ), # 1 + (2, TType.I32, 'createTime', None, None, ), # 2 + (3, TType.I32, 'lastAccessTime', None, None, ), # 3 + (4, TType.STRING, 'relativePath', None, None, ), # 4 + (5, TType.MAP, 'parameters', (TType.STRING,None,TType.STRING,None), None, ), # 5 + (6, TType.STRUCT, 'privileges', (PrincipalPrivilegeSet, PrincipalPrivilegeSet.thrift_spec), None, ), # 6 + ) + + def __init__(self, values=None, createTime=None, lastAccessTime=None, relativePath=None, parameters=None, privileges=None,): + self.values = values + self.createTime = createTime + self.lastAccessTime = lastAccessTime + self.relativePath = relativePath + self.parameters = parameters + self.privileges = privileges + + 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.LIST: + self.values = [] + (_etype203, _size200) = iprot.readListBegin() + for _i204 in xrange(_size200): + _elem205 = iprot.readString(); + self.values.append(_elem205) + iprot.readListEnd() + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.I32: + self.createTime = iprot.readI32(); + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.I32: + self.lastAccessTime = iprot.readI32(); + else: + iprot.skip(ftype) + elif fid == 4: + if ftype == TType.STRING: + self.relativePath = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 5: + if ftype == TType.MAP: + self.parameters = {} + (_ktype207, _vtype208, _size206 ) = iprot.readMapBegin() + for _i210 in xrange(_size206): + _key211 = iprot.readString(); + _val212 = iprot.readString(); + self.parameters[_key211] = _val212 + iprot.readMapEnd() + else: + iprot.skip(ftype) + elif fid == 6: + if ftype == TType.STRUCT: + self.privileges = PrincipalPrivilegeSet() + self.privileges.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('PartitionWithoutSD') + if self.values is not None: + oprot.writeFieldBegin('values', TType.LIST, 1) + oprot.writeListBegin(TType.STRING, len(self.values)) + for iter213 in self.values: + oprot.writeString(iter213) + oprot.writeListEnd() + oprot.writeFieldEnd() + if self.createTime is not None: + oprot.writeFieldBegin('createTime', TType.I32, 2) + oprot.writeI32(self.createTime) + oprot.writeFieldEnd() + if self.lastAccessTime is not None: + oprot.writeFieldBegin('lastAccessTime', TType.I32, 3) + oprot.writeI32(self.lastAccessTime) + oprot.writeFieldEnd() + if self.relativePath is not None: + oprot.writeFieldBegin('relativePath', TType.STRING, 4) + oprot.writeString(self.relativePath) + oprot.writeFieldEnd() + if self.parameters is not None: + oprot.writeFieldBegin('parameters', TType.MAP, 5) + oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.parameters)) + for kiter214,viter215 in self.parameters.items(): + oprot.writeString(kiter214) + oprot.writeString(viter215) + oprot.writeMapEnd() + oprot.writeFieldEnd() + if self.privileges is not None: + oprot.writeFieldBegin('privileges', TType.STRUCT, 6) + self.privileges.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 PartitionSpecWithSharedSD: + """ + Attributes: + - partitions + - sd + """ + + thrift_spec = ( + None, # 0 + (1, TType.LIST, 'partitions', (TType.STRUCT,(PartitionWithoutSD, PartitionWithoutSD.thrift_spec)), None, ), # 1 + (2, TType.STRUCT, 'sd', (StorageDescriptor, StorageDescriptor.thrift_spec), None, ), # 2 + ) + + def __init__(self, partitions=None, sd=None,): + self.partitions = partitions + self.sd = sd + + 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.LIST: + self.partitions = [] + (_etype219, _size216) = iprot.readListBegin() + for _i220 in xrange(_size216): + _elem221 = PartitionWithoutSD() + _elem221.read(iprot) + self.partitions.append(_elem221) + iprot.readListEnd() + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRUCT: + self.sd = StorageDescriptor() + self.sd.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('PartitionSpecWithSharedSD') + if self.partitions is not None: + oprot.writeFieldBegin('partitions', TType.LIST, 1) + oprot.writeListBegin(TType.STRUCT, len(self.partitions)) + for iter222 in self.partitions: + iter222.write(oprot) + oprot.writeListEnd() + oprot.writeFieldEnd() + if self.sd is not None: + oprot.writeFieldBegin('sd', TType.STRUCT, 2) + self.sd.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 PartitionListComposingSpec: + """ + Attributes: + - partitions + """ + + thrift_spec = ( + None, # 0 + (1, TType.LIST, 'partitions', (TType.STRUCT,(Partition, Partition.thrift_spec)), None, ), # 1 + ) + + def __init__(self, partitions=None,): + self.partitions = partitions + + 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.LIST: + self.partitions = [] + (_etype226, _size223) = iprot.readListBegin() + for _i227 in xrange(_size223): + _elem228 = Partition() + _elem228.read(iprot) + self.partitions.append(_elem228) + iprot.readListEnd() + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('PartitionListComposingSpec') + if self.partitions is not None: + oprot.writeFieldBegin('partitions', TType.LIST, 1) + oprot.writeListBegin(TType.STRUCT, len(self.partitions)) + for iter229 in self.partitions: + iter229.write(oprot) + oprot.writeListEnd() + 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 PartitionSpec: + """ + Attributes: + - dbName + - tableName + - rootPath + - sharedSDPartitionSpec + - partitionList + """ + + thrift_spec = ( + None, # 0 + (1, TType.STRING, 'dbName', None, None, ), # 1 + (2, TType.STRING, 'tableName', None, None, ), # 2 + (3, TType.STRING, 'rootPath', None, None, ), # 3 + (4, TType.STRUCT, 'sharedSDPartitionSpec', (PartitionSpecWithSharedSD, PartitionSpecWithSharedSD.thrift_spec), None, ), # 4 + (5, TType.STRUCT, 'partitionList', (PartitionListComposingSpec, PartitionListComposingSpec.thrift_spec), None, ), # 5 + ) + + def __init__(self, dbName=None, tableName=None, rootPath=None, sharedSDPartitionSpec=None, partitionList=None,): + self.dbName = dbName + self.tableName = tableName + self.rootPath = rootPath + self.sharedSDPartitionSpec = sharedSDPartitionSpec + self.partitionList = partitionList + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 1: + if ftype == TType.STRING: + self.dbName = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRING: + self.tableName = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.STRING: + self.rootPath = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 4: + if ftype == TType.STRUCT: + self.sharedSDPartitionSpec = PartitionSpecWithSharedSD() + self.sharedSDPartitionSpec.read(iprot) + else: + iprot.skip(ftype) + elif fid == 5: + if ftype == TType.STRUCT: + self.partitionList = PartitionListComposingSpec() + self.partitionList.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('PartitionSpec') + if self.dbName is not None: + oprot.writeFieldBegin('dbName', TType.STRING, 1) + oprot.writeString(self.dbName) + oprot.writeFieldEnd() + if self.tableName is not None: + oprot.writeFieldBegin('tableName', TType.STRING, 2) + oprot.writeString(self.tableName) + oprot.writeFieldEnd() + if self.rootPath is not None: + oprot.writeFieldBegin('rootPath', TType.STRING, 3) + oprot.writeString(self.rootPath) + oprot.writeFieldEnd() + if self.sharedSDPartitionSpec is not None: + oprot.writeFieldBegin('sharedSDPartitionSpec', TType.STRUCT, 4) + self.sharedSDPartitionSpec.write(oprot) + oprot.writeFieldEnd() + if self.partitionList is not None: + oprot.writeFieldBegin('partitionList', TType.STRUCT, 5) + self.partitionList.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 Index: """ Attributes: @@ -2983,11 +3383,11 @@ elif fid == 9: if ftype == TType.MAP: self.parameters = {} - (_ktype201, _vtype202, _size200 ) = iprot.readMapBegin() - for _i204 in xrange(_size200): - _key205 = iprot.readString(); - _val206 = iprot.readString(); - self.parameters[_key205] = _val206 + (_ktype231, _vtype232, _size230 ) = iprot.readMapBegin() + for _i234 in xrange(_size230): + _key235 = iprot.readString(); + _val236 = iprot.readString(); + self.parameters[_key235] = _val236 iprot.readMapEnd() else: iprot.skip(ftype) @@ -3041,9 +3441,9 @@ if self.parameters is not None: oprot.writeFieldBegin('parameters', TType.MAP, 9) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.parameters)) - for kiter207,viter208 in self.parameters.items(): - oprot.writeString(kiter207) - oprot.writeString(viter208) + for kiter237,viter238 in self.parameters.items(): + oprot.writeString(kiter237) + oprot.writeString(viter238) oprot.writeMapEnd() oprot.writeFieldEnd() if self.deferredRebuild is not None: @@ -4097,11 +4497,11 @@ elif fid == 2: if ftype == TType.LIST: self.statsObj = [] - (_etype212, _size209) = iprot.readListBegin() - for _i213 in xrange(_size209): - _elem214 = ColumnStatisticsObj() - _elem214.read(iprot) - self.statsObj.append(_elem214) + (_etype242, _size239) = iprot.readListBegin() + for _i243 in xrange(_size239): + _elem244 = ColumnStatisticsObj() + _elem244.read(iprot) + self.statsObj.append(_elem244) iprot.readListEnd() else: iprot.skip(ftype) @@ -4122,8 +4522,8 @@ if self.statsObj is not None: oprot.writeFieldBegin('statsObj', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.statsObj)) - for iter215 in self.statsObj: - iter215.write(oprot) + for iter245 in self.statsObj: + iter245.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4177,11 +4577,11 @@ if fid == 1: if ftype == TType.LIST: self.colStats = [] - (_etype219, _size216) = iprot.readListBegin() - for _i220 in xrange(_size216): - _elem221 = ColumnStatisticsObj() - _elem221.read(iprot) - self.colStats.append(_elem221) + (_etype249, _size246) = iprot.readListBegin() + for _i250 in xrange(_size246): + _elem251 = ColumnStatisticsObj() + _elem251.read(iprot) + self.colStats.append(_elem251) iprot.readListEnd() else: iprot.skip(ftype) @@ -4203,8 +4603,8 @@ if self.colStats is not None: oprot.writeFieldBegin('colStats', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.colStats)) - for iter222 in self.colStats: - iter222.write(oprot) + for iter252 in self.colStats: + iter252.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.partsFound is not None: @@ -4262,22 +4662,22 @@ if fid == 1: if ftype == TType.LIST: self.fieldSchemas = [] - (_etype226, _size223) = iprot.readListBegin() - for _i227 in xrange(_size223): - _elem228 = FieldSchema() - _elem228.read(iprot) - self.fieldSchemas.append(_elem228) + (_etype256, _size253) = iprot.readListBegin() + for _i257 in xrange(_size253): + _elem258 = FieldSchema() + _elem258.read(iprot) + self.fieldSchemas.append(_elem258) iprot.readListEnd() else: iprot.skip(ftype) elif fid == 2: if ftype == TType.MAP: self.properties = {} - (_ktype230, _vtype231, _size229 ) = iprot.readMapBegin() - for _i233 in xrange(_size229): - _key234 = iprot.readString(); - _val235 = iprot.readString(); - self.properties[_key234] = _val235 + (_ktype260, _vtype261, _size259 ) = iprot.readMapBegin() + for _i263 in xrange(_size259): + _key264 = iprot.readString(); + _val265 = iprot.readString(); + self.properties[_key264] = _val265 iprot.readMapEnd() else: iprot.skip(ftype) @@ -4294,16 +4694,16 @@ if self.fieldSchemas is not None: oprot.writeFieldBegin('fieldSchemas', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.fieldSchemas)) - for iter236 in self.fieldSchemas: - iter236.write(oprot) + for iter266 in self.fieldSchemas: + iter266.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.properties is not None: oprot.writeFieldBegin('properties', TType.MAP, 2) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.properties)) - for kiter237,viter238 in self.properties.items(): - oprot.writeString(kiter237) - oprot.writeString(viter238) + for kiter267,viter268 in self.properties.items(): + oprot.writeString(kiter267) + oprot.writeString(viter268) oprot.writeMapEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4350,11 +4750,11 @@ if fid == 1: if ftype == TType.MAP: self.properties = {} - (_ktype240, _vtype241, _size239 ) = iprot.readMapBegin() - for _i243 in xrange(_size239): - _key244 = iprot.readString(); - _val245 = iprot.readString(); - self.properties[_key244] = _val245 + (_ktype270, _vtype271, _size269 ) = iprot.readMapBegin() + for _i273 in xrange(_size269): + _key274 = iprot.readString(); + _val275 = iprot.readString(); + self.properties[_key274] = _val275 iprot.readMapEnd() else: iprot.skip(ftype) @@ -4371,9 +4771,9 @@ if self.properties is not None: oprot.writeFieldBegin('properties', TType.MAP, 1) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.properties)) - for kiter246,viter247 in self.properties.items(): - oprot.writeString(kiter246) - oprot.writeString(viter247) + for kiter276,viter277 in self.properties.items(): + oprot.writeString(kiter276) + oprot.writeString(viter277) oprot.writeMapEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4423,11 +4823,11 @@ if fid == 1: if ftype == TType.LIST: self.partitions = [] - (_etype251, _size248) = iprot.readListBegin() - for _i252 in xrange(_size248): - _elem253 = Partition() - _elem253.read(iprot) - self.partitions.append(_elem253) + (_etype281, _size278) = iprot.readListBegin() + for _i282 in xrange(_size278): + _elem283 = Partition() + _elem283.read(iprot) + self.partitions.append(_elem283) iprot.readListEnd() else: iprot.skip(ftype) @@ -4449,8 +4849,8 @@ if self.partitions is not None: oprot.writeFieldBegin('partitions', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.partitions)) - for iter254 in self.partitions: - iter254.write(oprot) + for iter284 in self.partitions: + iter284.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.hasUnknownPartitions is not None: @@ -4619,11 +5019,11 @@ if fid == 1: if ftype == TType.LIST: self.tableStats = [] - (_etype258, _size255) = iprot.readListBegin() - for _i259 in xrange(_size255): - _elem260 = ColumnStatisticsObj() - _elem260.read(iprot) - self.tableStats.append(_elem260) + (_etype288, _size285) = iprot.readListBegin() + for _i289 in xrange(_size285): + _elem290 = ColumnStatisticsObj() + _elem290.read(iprot) + self.tableStats.append(_elem290) iprot.readListEnd() else: iprot.skip(ftype) @@ -4640,8 +5040,8 @@ if self.tableStats is not None: oprot.writeFieldBegin('tableStats', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.tableStats)) - for iter261 in self.tableStats: - iter261.write(oprot) + for iter291 in self.tableStats: + iter291.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4690,17 +5090,17 @@ if fid == 1: if ftype == TType.MAP: self.partStats = {} - (_ktype263, _vtype264, _size262 ) = iprot.readMapBegin() - for _i266 in xrange(_size262): - _key267 = iprot.readString(); - _val268 = [] - (_etype272, _size269) = iprot.readListBegin() - for _i273 in xrange(_size269): - _elem274 = ColumnStatisticsObj() - _elem274.read(iprot) - _val268.append(_elem274) + (_ktype293, _vtype294, _size292 ) = iprot.readMapBegin() + for _i296 in xrange(_size292): + _key297 = iprot.readString(); + _val298 = [] + (_etype302, _size299) = iprot.readListBegin() + for _i303 in xrange(_size299): + _elem304 = ColumnStatisticsObj() + _elem304.read(iprot) + _val298.append(_elem304) iprot.readListEnd() - self.partStats[_key267] = _val268 + self.partStats[_key297] = _val298 iprot.readMapEnd() else: iprot.skip(ftype) @@ -4717,11 +5117,11 @@ if self.partStats is not None: oprot.writeFieldBegin('partStats', TType.MAP, 1) oprot.writeMapBegin(TType.STRING, TType.LIST, len(self.partStats)) - for kiter275,viter276 in self.partStats.items(): - oprot.writeString(kiter275) - oprot.writeListBegin(TType.STRUCT, len(viter276)) - for iter277 in viter276: - iter277.write(oprot) + for kiter305,viter306 in self.partStats.items(): + oprot.writeString(kiter305) + oprot.writeListBegin(TType.STRUCT, len(viter306)) + for iter307 in viter306: + iter307.write(oprot) oprot.writeListEnd() oprot.writeMapEnd() oprot.writeFieldEnd() @@ -4787,10 +5187,10 @@ elif fid == 3: if ftype == TType.LIST: self.colNames = [] - (_etype281, _size278) = iprot.readListBegin() - for _i282 in xrange(_size278): - _elem283 = iprot.readString(); - self.colNames.append(_elem283) + (_etype311, _size308) = iprot.readListBegin() + for _i312 in xrange(_size308): + _elem313 = iprot.readString(); + self.colNames.append(_elem313) iprot.readListEnd() else: iprot.skip(ftype) @@ -4815,8 +5215,8 @@ if self.colNames is not None: oprot.writeFieldBegin('colNames', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.colNames)) - for iter284 in self.colNames: - oprot.writeString(iter284) + for iter314 in self.colNames: + oprot.writeString(iter314) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4888,20 +5288,20 @@ elif fid == 3: if ftype == TType.LIST: self.colNames = [] - (_etype288, _size285) = iprot.readListBegin() - for _i289 in xrange(_size285): - _elem290 = iprot.readString(); - self.colNames.append(_elem290) + (_etype318, _size315) = iprot.readListBegin() + for _i319 in xrange(_size315): + _elem320 = iprot.readString(); + self.colNames.append(_elem320) iprot.readListEnd() else: iprot.skip(ftype) elif fid == 4: if ftype == TType.LIST: self.partNames = [] - (_etype294, _size291) = iprot.readListBegin() - for _i295 in xrange(_size291): - _elem296 = iprot.readString(); - self.partNames.append(_elem296) + (_etype324, _size321) = iprot.readListBegin() + for _i325 in xrange(_size321): + _elem326 = iprot.readString(); + self.partNames.append(_elem326) iprot.readListEnd() else: iprot.skip(ftype) @@ -4926,15 +5326,15 @@ if self.colNames is not None: oprot.writeFieldBegin('colNames', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.colNames)) - for iter297 in self.colNames: - oprot.writeString(iter297) + for iter327 in self.colNames: + oprot.writeString(iter327) oprot.writeListEnd() oprot.writeFieldEnd() if self.partNames is not None: oprot.writeFieldBegin('partNames', TType.LIST, 4) oprot.writeListBegin(TType.STRING, len(self.partNames)) - for iter298 in self.partNames: - oprot.writeString(iter298) + for iter328 in self.partNames: + oprot.writeString(iter328) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -4989,11 +5389,11 @@ if fid == 1: if ftype == TType.LIST: self.partitions = [] - (_etype302, _size299) = iprot.readListBegin() - for _i303 in xrange(_size299): - _elem304 = Partition() - _elem304.read(iprot) - self.partitions.append(_elem304) + (_etype332, _size329) = iprot.readListBegin() + for _i333 in xrange(_size329): + _elem334 = Partition() + _elem334.read(iprot) + self.partitions.append(_elem334) iprot.readListEnd() else: iprot.skip(ftype) @@ -5010,8 +5410,8 @@ if self.partitions is not None: oprot.writeFieldBegin('partitions', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.partitions)) - for iter305 in self.partitions: - iter305.write(oprot) + for iter335 in self.partitions: + iter335.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -5080,11 +5480,11 @@ elif fid == 3: if ftype == TType.LIST: self.parts = [] - (_etype309, _size306) = iprot.readListBegin() - for _i310 in xrange(_size306): - _elem311 = Partition() - _elem311.read(iprot) - self.parts.append(_elem311) + (_etype339, _size336) = iprot.readListBegin() + for _i340 in xrange(_size336): + _elem341 = Partition() + _elem341.read(iprot) + self.parts.append(_elem341) iprot.readListEnd() else: iprot.skip(ftype) @@ -5119,8 +5519,8 @@ if self.parts is not None: oprot.writeFieldBegin('parts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.parts)) - for iter312 in self.parts: - iter312.write(oprot) + for iter342 in self.parts: + iter342.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.ifNotExists is not None: @@ -5183,11 +5583,11 @@ if fid == 1: if ftype == TType.LIST: self.partitions = [] - (_etype316, _size313) = iprot.readListBegin() - for _i317 in xrange(_size313): - _elem318 = Partition() - _elem318.read(iprot) - self.partitions.append(_elem318) + (_etype346, _size343) = iprot.readListBegin() + for _i347 in xrange(_size343): + _elem348 = Partition() + _elem348.read(iprot) + self.partitions.append(_elem348) iprot.readListEnd() else: iprot.skip(ftype) @@ -5204,8 +5604,8 @@ if self.partitions is not None: oprot.writeFieldBegin('partitions', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.partitions)) - for iter319 in self.partitions: - iter319.write(oprot) + for iter349 in self.partitions: + iter349.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -5329,21 +5729,21 @@ if fid == 1: if ftype == TType.LIST: self.names = [] - (_etype323, _size320) = iprot.readListBegin() - for _i324 in xrange(_size320): - _elem325 = iprot.readString(); - self.names.append(_elem325) + (_etype353, _size350) = iprot.readListBegin() + for _i354 in xrange(_size350): + _elem355 = iprot.readString(); + self.names.append(_elem355) iprot.readListEnd() else: iprot.skip(ftype) elif fid == 2: if ftype == TType.LIST: self.exprs = [] - (_etype329, _size326) = iprot.readListBegin() - for _i330 in xrange(_size326): - _elem331 = DropPartitionsExpr() - _elem331.read(iprot) - self.exprs.append(_elem331) + (_etype359, _size356) = iprot.readListBegin() + for _i360 in xrange(_size356): + _elem361 = DropPartitionsExpr() + _elem361.read(iprot) + self.exprs.append(_elem361) iprot.readListEnd() else: iprot.skip(ftype) @@ -5360,15 +5760,15 @@ if self.names is not None: oprot.writeFieldBegin('names', TType.LIST, 1) oprot.writeListBegin(TType.STRING, len(self.names)) - for iter332 in self.names: - oprot.writeString(iter332) + for iter362 in self.names: + oprot.writeString(iter362) oprot.writeListEnd() oprot.writeFieldEnd() if self.exprs is not None: oprot.writeFieldBegin('exprs', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.exprs)) - for iter333 in self.exprs: - iter333.write(oprot) + for iter363 in self.exprs: + iter363.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -5695,11 +6095,11 @@ elif fid == 8: if ftype == TType.LIST: self.resourceUris = [] - (_etype337, _size334) = iprot.readListBegin() - for _i338 in xrange(_size334): - _elem339 = ResourceUri() - _elem339.read(iprot) - self.resourceUris.append(_elem339) + (_etype367, _size364) = iprot.readListBegin() + for _i368 in xrange(_size364): + _elem369 = ResourceUri() + _elem369.read(iprot) + self.resourceUris.append(_elem369) iprot.readListEnd() else: iprot.skip(ftype) @@ -5744,8 +6144,8 @@ if self.resourceUris is not None: oprot.writeFieldBegin('resourceUris', TType.LIST, 8) oprot.writeListBegin(TType.STRUCT, len(self.resourceUris)) - for iter340 in self.resourceUris: - iter340.write(oprot) + for iter370 in self.resourceUris: + iter370.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -5904,11 +6304,11 @@ elif fid == 2: if ftype == TType.LIST: self.open_txns = [] - (_etype344, _size341) = iprot.readListBegin() - for _i345 in xrange(_size341): - _elem346 = TxnInfo() - _elem346.read(iprot) - self.open_txns.append(_elem346) + (_etype374, _size371) = iprot.readListBegin() + for _i375 in xrange(_size371): + _elem376 = TxnInfo() + _elem376.read(iprot) + self.open_txns.append(_elem376) iprot.readListEnd() else: iprot.skip(ftype) @@ -5929,8 +6329,8 @@ if self.open_txns is not None: oprot.writeFieldBegin('open_txns', TType.LIST, 2) oprot.writeListBegin(TType.STRUCT, len(self.open_txns)) - for iter347 in self.open_txns: - iter347.write(oprot) + for iter377 in self.open_txns: + iter377.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -5989,10 +6389,10 @@ elif fid == 2: if ftype == TType.SET: self.open_txns = set() - (_etype351, _size348) = iprot.readSetBegin() - for _i352 in xrange(_size348): - _elem353 = iprot.readI64(); - self.open_txns.add(_elem353) + (_etype381, _size378) = iprot.readSetBegin() + for _i382 in xrange(_size378): + _elem383 = iprot.readI64(); + self.open_txns.add(_elem383) iprot.readSetEnd() else: iprot.skip(ftype) @@ -6013,8 +6413,8 @@ if self.open_txns is not None: oprot.writeFieldBegin('open_txns', TType.SET, 2) oprot.writeSetBegin(TType.I64, len(self.open_txns)) - for iter354 in self.open_txns: - oprot.writeI64(iter354) + for iter384 in self.open_txns: + oprot.writeI64(iter384) oprot.writeSetEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6155,10 +6555,10 @@ if fid == 1: if ftype == TType.LIST: self.txn_ids = [] - (_etype358, _size355) = iprot.readListBegin() - for _i359 in xrange(_size355): - _elem360 = iprot.readI64(); - self.txn_ids.append(_elem360) + (_etype388, _size385) = iprot.readListBegin() + for _i389 in xrange(_size385): + _elem390 = iprot.readI64(); + self.txn_ids.append(_elem390) iprot.readListEnd() else: iprot.skip(ftype) @@ -6175,8 +6575,8 @@ if self.txn_ids is not None: oprot.writeFieldBegin('txn_ids', TType.LIST, 1) oprot.writeListBegin(TType.I64, len(self.txn_ids)) - for iter361 in self.txn_ids: - oprot.writeI64(iter361) + for iter391 in self.txn_ids: + oprot.writeI64(iter391) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -6472,11 +6872,11 @@ if fid == 1: if ftype == TType.LIST: self.component = [] - (_etype365, _size362) = iprot.readListBegin() - for _i366 in xrange(_size362): - _elem367 = LockComponent() - _elem367.read(iprot) - self.component.append(_elem367) + (_etype395, _size392) = iprot.readListBegin() + for _i396 in xrange(_size392): + _elem397 = LockComponent() + _elem397.read(iprot) + self.component.append(_elem397) iprot.readListEnd() else: iprot.skip(ftype) @@ -6508,8 +6908,8 @@ if self.component is not None: oprot.writeFieldBegin('component', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.component)) - for iter368 in self.component: - iter368.write(oprot) + for iter398 in self.component: + iter398.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.txnid is not None: @@ -7010,11 +7410,11 @@ if fid == 1: if ftype == TType.LIST: self.locks = [] - (_etype372, _size369) = iprot.readListBegin() - for _i373 in xrange(_size369): - _elem374 = ShowLocksResponseElement() - _elem374.read(iprot) - self.locks.append(_elem374) + (_etype402, _size399) = iprot.readListBegin() + for _i403 in xrange(_size399): + _elem404 = ShowLocksResponseElement() + _elem404.read(iprot) + self.locks.append(_elem404) iprot.readListEnd() else: iprot.skip(ftype) @@ -7031,8 +7431,8 @@ if self.locks is not None: oprot.writeFieldBegin('locks', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.locks)) - for iter375 in self.locks: - iter375.write(oprot) + for iter405 in self.locks: + iter405.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -7230,20 +7630,20 @@ if fid == 1: if ftype == TType.SET: self.aborted = set() - (_etype379, _size376) = iprot.readSetBegin() - for _i380 in xrange(_size376): - _elem381 = iprot.readI64(); - self.aborted.add(_elem381) + (_etype409, _size406) = iprot.readSetBegin() + for _i410 in xrange(_size406): + _elem411 = iprot.readI64(); + self.aborted.add(_elem411) iprot.readSetEnd() else: iprot.skip(ftype) elif fid == 2: if ftype == TType.SET: self.nosuch = set() - (_etype385, _size382) = iprot.readSetBegin() - for _i386 in xrange(_size382): - _elem387 = iprot.readI64(); - self.nosuch.add(_elem387) + (_etype415, _size412) = iprot.readSetBegin() + for _i416 in xrange(_size412): + _elem417 = iprot.readI64(); + self.nosuch.add(_elem417) iprot.readSetEnd() else: iprot.skip(ftype) @@ -7260,15 +7660,15 @@ if self.aborted is not None: oprot.writeFieldBegin('aborted', TType.SET, 1) oprot.writeSetBegin(TType.I64, len(self.aborted)) - for iter388 in self.aborted: - oprot.writeI64(iter388) + for iter418 in self.aborted: + oprot.writeI64(iter418) oprot.writeSetEnd() oprot.writeFieldEnd() if self.nosuch is not None: oprot.writeFieldBegin('nosuch', TType.SET, 2) oprot.writeSetBegin(TType.I64, len(self.nosuch)) - for iter389 in self.nosuch: - oprot.writeI64(iter389) + for iter419 in self.nosuch: + oprot.writeI64(iter419) oprot.writeSetEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -7635,11 +8035,11 @@ if fid == 1: if ftype == TType.LIST: self.compacts = [] - (_etype393, _size390) = iprot.readListBegin() - for _i394 in xrange(_size390): - _elem395 = ShowCompactResponseElement() - _elem395.read(iprot) - self.compacts.append(_elem395) + (_etype423, _size420) = iprot.readListBegin() + for _i424 in xrange(_size420): + _elem425 = ShowCompactResponseElement() + _elem425.read(iprot) + self.compacts.append(_elem425) iprot.readListEnd() else: iprot.skip(ftype) @@ -7656,8 +8056,8 @@ if self.compacts is not None: oprot.writeFieldBegin('compacts', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.compacts)) - for iter396 in self.compacts: - iter396.write(oprot) + for iter426 in self.compacts: + iter426.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() Index: metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py =================================================================== --- metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py (revision 1619008) +++ metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py (working copy) @@ -237,6 +237,13 @@ """ pass + def add_partitions_pspec(self, new_parts): + """ + Parameters: + - new_parts + """ + pass + def append_partition(self, db_name, tbl_name, part_vals): """ Parameters: @@ -391,6 +398,15 @@ """ pass + def get_partitions_pspec(self, db_name, tbl_name, max_parts): + """ + Parameters: + - db_name + - tbl_name + - max_parts + """ + pass + def get_partition_names(self, db_name, tbl_name, max_parts): """ Parameters: @@ -442,6 +458,16 @@ """ pass + def get_part_specs_by_filter(self, db_name, tbl_name, filter, max_parts): + """ + Parameters: + - db_name + - tbl_name + - filter + - max_parts + """ + pass + def get_partitions_by_expr(self, req): """ Parameters: @@ -1928,6 +1954,42 @@ raise result.o3 raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions failed: unknown result"); + def add_partitions_pspec(self, new_parts): + """ + Parameters: + - new_parts + """ + self.send_add_partitions_pspec(new_parts) + return self.recv_add_partitions_pspec() + + def send_add_partitions_pspec(self, new_parts): + self._oprot.writeMessageBegin('add_partitions_pspec', TMessageType.CALL, self._seqid) + args = add_partitions_pspec_args() + args.new_parts = new_parts + args.write(self._oprot) + self._oprot.writeMessageEnd() + self._oprot.trans.flush() + + def recv_add_partitions_pspec(self, ): + (fname, mtype, rseqid) = self._iprot.readMessageBegin() + if mtype == TMessageType.EXCEPTION: + x = TApplicationException() + x.read(self._iprot) + self._iprot.readMessageEnd() + raise x + result = add_partitions_pspec_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 + raise TApplicationException(TApplicationException.MISSING_RESULT, "add_partitions_pspec failed: unknown result"); + def append_partition(self, db_name, tbl_name, part_vals): """ Parameters: @@ -2570,6 +2632,44 @@ raise result.o2 raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_with_auth failed: unknown result"); + def get_partitions_pspec(self, db_name, tbl_name, max_parts): + """ + Parameters: + - db_name + - tbl_name + - max_parts + """ + self.send_get_partitions_pspec(db_name, tbl_name, max_parts) + return self.recv_get_partitions_pspec() + + def send_get_partitions_pspec(self, db_name, tbl_name, max_parts): + self._oprot.writeMessageBegin('get_partitions_pspec', TMessageType.CALL, self._seqid) + args = get_partitions_pspec_args() + args.db_name = db_name + args.tbl_name = tbl_name + args.max_parts = max_parts + args.write(self._oprot) + self._oprot.writeMessageEnd() + self._oprot.trans.flush() + + def recv_get_partitions_pspec(self, ): + (fname, mtype, rseqid) = self._iprot.readMessageBegin() + if mtype == TMessageType.EXCEPTION: + x = TApplicationException() + x.read(self._iprot) + self._iprot.readMessageEnd() + raise x + result = get_partitions_pspec_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 + raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_pspec failed: unknown result"); + def get_partition_names(self, db_name, tbl_name, max_parts): """ Parameters: @@ -2770,6 +2870,46 @@ raise result.o2 raise TApplicationException(TApplicationException.MISSING_RESULT, "get_partitions_by_filter failed: unknown result"); + def get_part_specs_by_filter(self, db_name, tbl_name, filter, max_parts): + """ + Parameters: + - db_name + - tbl_name + - filter + - max_parts + """ + self.send_get_part_specs_by_filter(db_name, tbl_name, filter, max_parts) + return self.recv_get_part_specs_by_filter() + + def send_get_part_specs_by_filter(self, db_name, tbl_name, filter, max_parts): + self._oprot.writeMessageBegin('get_part_specs_by_filter', TMessageType.CALL, self._seqid) + args = get_part_specs_by_filter_args() + args.db_name = db_name + args.tbl_name = tbl_name + args.filter = filter + args.max_parts = max_parts + args.write(self._oprot) + self._oprot.writeMessageEnd() + self._oprot.trans.flush() + + def recv_get_part_specs_by_filter(self, ): + (fname, mtype, rseqid) = self._iprot.readMessageBegin() + if mtype == TMessageType.EXCEPTION: + x = TApplicationException() + x.read(self._iprot) + self._iprot.readMessageEnd() + raise x + result = get_part_specs_by_filter_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 + raise TApplicationException(TApplicationException.MISSING_RESULT, "get_part_specs_by_filter failed: unknown result"); + def get_partitions_by_expr(self, req): """ Parameters: @@ -4995,6 +5135,7 @@ self._processMap["add_partition"] = Processor.process_add_partition self._processMap["add_partition_with_environment_context"] = Processor.process_add_partition_with_environment_context self._processMap["add_partitions"] = Processor.process_add_partitions + self._processMap["add_partitions_pspec"] = Processor.process_add_partitions_pspec self._processMap["append_partition"] = Processor.process_append_partition self._processMap["add_partitions_req"] = Processor.process_add_partitions_req self._processMap["append_partition_with_environment_context"] = Processor.process_append_partition_with_environment_context @@ -5011,11 +5152,13 @@ self._processMap["get_partition_by_name"] = Processor.process_get_partition_by_name self._processMap["get_partitions"] = Processor.process_get_partitions self._processMap["get_partitions_with_auth"] = Processor.process_get_partitions_with_auth + self._processMap["get_partitions_pspec"] = Processor.process_get_partitions_pspec self._processMap["get_partition_names"] = Processor.process_get_partition_names self._processMap["get_partitions_ps"] = Processor.process_get_partitions_ps self._processMap["get_partitions_ps_with_auth"] = Processor.process_get_partitions_ps_with_auth self._processMap["get_partition_names_ps"] = Processor.process_get_partition_names_ps self._processMap["get_partitions_by_filter"] = Processor.process_get_partitions_by_filter + self._processMap["get_part_specs_by_filter"] = Processor.process_get_part_specs_by_filter self._processMap["get_partitions_by_expr"] = Processor.process_get_partitions_by_expr self._processMap["get_partitions_by_names"] = Processor.process_get_partitions_by_names self._processMap["alter_partition"] = Processor.process_alter_partition @@ -5557,6 +5700,24 @@ oprot.writeMessageEnd() oprot.trans.flush() + def process_add_partitions_pspec(self, seqid, iprot, oprot): + args = add_partitions_pspec_args() + args.read(iprot) + iprot.readMessageEnd() + result = add_partitions_pspec_result() + try: + result.success = self._handler.add_partitions_pspec(args.new_parts) + except InvalidObjectException as o1: + result.o1 = o1 + except AlreadyExistsException as o2: + result.o2 = o2 + except MetaException as o3: + result.o3 = o3 + oprot.writeMessageBegin("add_partitions_pspec", TMessageType.REPLY, seqid) + result.write(oprot) + oprot.writeMessageEnd() + oprot.trans.flush() + def process_append_partition(self, seqid, iprot, oprot): args = append_partition_args() args.read(iprot) @@ -5827,6 +5988,22 @@ oprot.writeMessageEnd() oprot.trans.flush() + def process_get_partitions_pspec(self, seqid, iprot, oprot): + args = get_partitions_pspec_args() + args.read(iprot) + iprot.readMessageEnd() + result = get_partitions_pspec_result() + try: + result.success = self._handler.get_partitions_pspec(args.db_name, args.tbl_name, args.max_parts) + except NoSuchObjectException as o1: + result.o1 = o1 + except MetaException as o2: + result.o2 = o2 + oprot.writeMessageBegin("get_partitions_pspec", TMessageType.REPLY, seqid) + result.write(oprot) + oprot.writeMessageEnd() + oprot.trans.flush() + def process_get_partition_names(self, seqid, iprot, oprot): args = get_partition_names_args() args.read(iprot) @@ -5905,6 +6082,22 @@ oprot.writeMessageEnd() oprot.trans.flush() + def process_get_part_specs_by_filter(self, seqid, iprot, oprot): + args = get_part_specs_by_filter_args() + args.read(iprot) + iprot.readMessageEnd() + result = get_part_specs_by_filter_result() + try: + result.success = self._handler.get_part_specs_by_filter(args.db_name, args.tbl_name, args.filter, args.max_parts) + except MetaException as o1: + result.o1 = o1 + except NoSuchObjectException as o2: + result.o2 = o2 + oprot.writeMessageBegin("get_part_specs_by_filter", TMessageType.REPLY, seqid) + result.write(oprot) + oprot.writeMessageEnd() + oprot.trans.flush() + def process_get_partitions_by_expr(self, seqid, iprot, oprot): args = get_partitions_by_expr_args() args.read(iprot) @@ -7699,10 +7892,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype400, _size397) = iprot.readListBegin() - for _i401 in xrange(_size397): - _elem402 = iprot.readString(); - self.success.append(_elem402) + (_etype430, _size427) = iprot.readListBegin() + for _i431 in xrange(_size427): + _elem432 = iprot.readString(); + self.success.append(_elem432) iprot.readListEnd() else: iprot.skip(ftype) @@ -7725,8 +7918,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter403 in self.success: - oprot.writeString(iter403) + for iter433 in self.success: + oprot.writeString(iter433) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -7821,10 +8014,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype407, _size404) = iprot.readListBegin() - for _i408 in xrange(_size404): - _elem409 = iprot.readString(); - self.success.append(_elem409) + (_etype437, _size434) = iprot.readListBegin() + for _i438 in xrange(_size434): + _elem439 = iprot.readString(); + self.success.append(_elem439) iprot.readListEnd() else: iprot.skip(ftype) @@ -7847,8 +8040,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter410 in self.success: - oprot.writeString(iter410) + for iter440 in self.success: + oprot.writeString(iter440) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -8558,12 +8751,12 @@ if fid == 0: if ftype == TType.MAP: self.success = {} - (_ktype412, _vtype413, _size411 ) = iprot.readMapBegin() - for _i415 in xrange(_size411): - _key416 = iprot.readString(); - _val417 = Type() - _val417.read(iprot) - self.success[_key416] = _val417 + (_ktype442, _vtype443, _size441 ) = iprot.readMapBegin() + for _i445 in xrange(_size441): + _key446 = iprot.readString(); + _val447 = Type() + _val447.read(iprot) + self.success[_key446] = _val447 iprot.readMapEnd() else: iprot.skip(ftype) @@ -8586,9 +8779,9 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.MAP, 0) oprot.writeMapBegin(TType.STRING, TType.STRUCT, len(self.success)) - for kiter418,viter419 in self.success.items(): - oprot.writeString(kiter418) - viter419.write(oprot) + for kiter448,viter449 in self.success.items(): + oprot.writeString(kiter448) + viter449.write(oprot) oprot.writeMapEnd() oprot.writeFieldEnd() if self.o2 is not None: @@ -8719,11 +8912,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype423, _size420) = iprot.readListBegin() - for _i424 in xrange(_size420): - _elem425 = FieldSchema() - _elem425.read(iprot) - self.success.append(_elem425) + (_etype453, _size450) = iprot.readListBegin() + for _i454 in xrange(_size450): + _elem455 = FieldSchema() + _elem455.read(iprot) + self.success.append(_elem455) iprot.readListEnd() else: iprot.skip(ftype) @@ -8758,8 +8951,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter426 in self.success: - iter426.write(oprot) + for iter456 in self.success: + iter456.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -8898,11 +9091,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype430, _size427) = iprot.readListBegin() - for _i431 in xrange(_size427): - _elem432 = FieldSchema() - _elem432.read(iprot) - self.success.append(_elem432) + (_etype460, _size457) = iprot.readListBegin() + for _i461 in xrange(_size457): + _elem462 = FieldSchema() + _elem462.read(iprot) + self.success.append(_elem462) iprot.readListEnd() else: iprot.skip(ftype) @@ -8937,8 +9130,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter433 in self.success: - iter433.write(oprot) + for iter463 in self.success: + iter463.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -9735,10 +9928,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype437, _size434) = iprot.readListBegin() - for _i438 in xrange(_size434): - _elem439 = iprot.readString(); - self.success.append(_elem439) + (_etype467, _size464) = iprot.readListBegin() + for _i468 in xrange(_size464): + _elem469 = iprot.readString(); + self.success.append(_elem469) iprot.readListEnd() else: iprot.skip(ftype) @@ -9761,8 +9954,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter440 in self.success: - oprot.writeString(iter440) + for iter470 in self.success: + oprot.writeString(iter470) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -9875,10 +10068,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype444, _size441) = iprot.readListBegin() - for _i445 in xrange(_size441): - _elem446 = iprot.readString(); - self.success.append(_elem446) + (_etype474, _size471) = iprot.readListBegin() + for _i475 in xrange(_size471): + _elem476 = iprot.readString(); + self.success.append(_elem476) iprot.readListEnd() else: iprot.skip(ftype) @@ -9901,8 +10094,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter447 in self.success: - oprot.writeString(iter447) + for iter477 in self.success: + oprot.writeString(iter477) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -10119,10 +10312,10 @@ elif fid == 2: if ftype == TType.LIST: self.tbl_names = [] - (_etype451, _size448) = iprot.readListBegin() - for _i452 in xrange(_size448): - _elem453 = iprot.readString(); - self.tbl_names.append(_elem453) + (_etype481, _size478) = iprot.readListBegin() + for _i482 in xrange(_size478): + _elem483 = iprot.readString(); + self.tbl_names.append(_elem483) iprot.readListEnd() else: iprot.skip(ftype) @@ -10143,8 +10336,8 @@ if self.tbl_names is not None: oprot.writeFieldBegin('tbl_names', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.tbl_names)) - for iter454 in self.tbl_names: - oprot.writeString(iter454) + for iter484 in self.tbl_names: + oprot.writeString(iter484) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -10199,11 +10392,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype458, _size455) = iprot.readListBegin() - for _i459 in xrange(_size455): - _elem460 = Table() - _elem460.read(iprot) - self.success.append(_elem460) + (_etype488, _size485) = iprot.readListBegin() + for _i489 in xrange(_size485): + _elem490 = Table() + _elem490.read(iprot) + self.success.append(_elem490) iprot.readListEnd() else: iprot.skip(ftype) @@ -10238,8 +10431,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter461 in self.success: - iter461.write(oprot) + for iter491 in self.success: + iter491.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -10390,10 +10583,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype465, _size462) = iprot.readListBegin() - for _i466 in xrange(_size462): - _elem467 = iprot.readString(); - self.success.append(_elem467) + (_etype495, _size492) = iprot.readListBegin() + for _i496 in xrange(_size492): + _elem497 = iprot.readString(); + self.success.append(_elem497) iprot.readListEnd() else: iprot.skip(ftype) @@ -10428,8 +10621,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter468 in self.success: - oprot.writeString(iter468) + for iter498 in self.success: + oprot.writeString(iter498) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -11152,11 +11345,11 @@ if fid == 1: if ftype == TType.LIST: self.new_parts = [] - (_etype472, _size469) = iprot.readListBegin() - for _i473 in xrange(_size469): - _elem474 = Partition() - _elem474.read(iprot) - self.new_parts.append(_elem474) + (_etype502, _size499) = iprot.readListBegin() + for _i503 in xrange(_size499): + _elem504 = Partition() + _elem504.read(iprot) + self.new_parts.append(_elem504) iprot.readListEnd() else: iprot.skip(ftype) @@ -11173,8 +11366,8 @@ if self.new_parts is not None: oprot.writeFieldBegin('new_parts', TType.LIST, 1) oprot.writeListBegin(TType.STRUCT, len(self.new_parts)) - for iter475 in self.new_parts: - iter475.write(oprot) + for iter505 in self.new_parts: + iter505.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11293,6 +11486,173 @@ def __ne__(self, other): return not (self == other) +class add_partitions_pspec_args: + """ + Attributes: + - new_parts + """ + + thrift_spec = ( + None, # 0 + (1, TType.LIST, 'new_parts', (TType.STRUCT,(PartitionSpec, PartitionSpec.thrift_spec)), None, ), # 1 + ) + + def __init__(self, new_parts=None,): + self.new_parts = new_parts + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 1: + if ftype == TType.LIST: + self.new_parts = [] + (_etype509, _size506) = iprot.readListBegin() + for _i510 in xrange(_size506): + _elem511 = PartitionSpec() + _elem511.read(iprot) + self.new_parts.append(_elem511) + iprot.readListEnd() + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('add_partitions_pspec_args') + if self.new_parts is not None: + oprot.writeFieldBegin('new_parts', TType.LIST, 1) + oprot.writeListBegin(TType.STRUCT, len(self.new_parts)) + for iter512 in self.new_parts: + iter512.write(oprot) + oprot.writeListEnd() + 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 add_partitions_pspec_result: + """ + Attributes: + - success + - o1 + - o2 + - o3 + """ + + thrift_spec = ( + (0, TType.I32, 'success', None, None, ), # 0 + (1, TType.STRUCT, 'o1', (InvalidObjectException, InvalidObjectException.thrift_spec), None, ), # 1 + (2, TType.STRUCT, 'o2', (AlreadyExistsException, AlreadyExistsException.thrift_spec), None, ), # 2 + (3, TType.STRUCT, 'o3', (MetaException, MetaException.thrift_spec), None, ), # 3 + ) + + def __init__(self, success=None, o1=None, o2=None, o3=None,): + self.success = success + self.o1 = o1 + self.o2 = o2 + self.o3 = o3 + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 0: + if ftype == TType.I32: + self.success = iprot.readI32(); + else: + iprot.skip(ftype) + elif fid == 1: + if ftype == TType.STRUCT: + self.o1 = InvalidObjectException() + self.o1.read(iprot) + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRUCT: + self.o2 = AlreadyExistsException() + self.o2.read(iprot) + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.STRUCT: + self.o3 = MetaException() + self.o3.read(iprot) + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('add_partitions_pspec_result') + if self.success is not None: + oprot.writeFieldBegin('success', TType.I32, 0) + oprot.writeI32(self.success) + 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() + 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 append_partition_args: """ Attributes: @@ -11335,10 +11695,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype479, _size476) = iprot.readListBegin() - for _i480 in xrange(_size476): - _elem481 = iprot.readString(); - self.part_vals.append(_elem481) + (_etype516, _size513) = iprot.readListBegin() + for _i517 in xrange(_size513): + _elem518 = iprot.readString(); + self.part_vals.append(_elem518) iprot.readListEnd() else: iprot.skip(ftype) @@ -11363,8 +11723,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter482 in self.part_vals: - oprot.writeString(iter482) + for iter519 in self.part_vals: + oprot.writeString(iter519) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -11689,10 +12049,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype486, _size483) = iprot.readListBegin() - for _i487 in xrange(_size483): - _elem488 = iprot.readString(); - self.part_vals.append(_elem488) + (_etype523, _size520) = iprot.readListBegin() + for _i524 in xrange(_size520): + _elem525 = iprot.readString(); + self.part_vals.append(_elem525) iprot.readListEnd() else: iprot.skip(ftype) @@ -11723,8 +12083,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter489 in self.part_vals: - oprot.writeString(iter489) + for iter526 in self.part_vals: + oprot.writeString(iter526) oprot.writeListEnd() oprot.writeFieldEnd() if self.environment_context is not None: @@ -12272,10 +12632,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype493, _size490) = iprot.readListBegin() - for _i494 in xrange(_size490): - _elem495 = iprot.readString(); - self.part_vals.append(_elem495) + (_etype530, _size527) = iprot.readListBegin() + for _i531 in xrange(_size527): + _elem532 = iprot.readString(); + self.part_vals.append(_elem532) iprot.readListEnd() else: iprot.skip(ftype) @@ -12305,8 +12665,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter496 in self.part_vals: - oprot.writeString(iter496) + for iter533 in self.part_vals: + oprot.writeString(iter533) oprot.writeListEnd() oprot.writeFieldEnd() if self.deleteData is not None: @@ -12464,10 +12824,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype500, _size497) = iprot.readListBegin() - for _i501 in xrange(_size497): - _elem502 = iprot.readString(); - self.part_vals.append(_elem502) + (_etype537, _size534) = iprot.readListBegin() + for _i538 in xrange(_size534): + _elem539 = iprot.readString(); + self.part_vals.append(_elem539) iprot.readListEnd() else: iprot.skip(ftype) @@ -12503,8 +12863,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter503 in self.part_vals: - oprot.writeString(iter503) + for iter540 in self.part_vals: + oprot.writeString(iter540) oprot.writeListEnd() oprot.writeFieldEnd() if self.deleteData is not None: @@ -13182,10 +13542,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype507, _size504) = iprot.readListBegin() - for _i508 in xrange(_size504): - _elem509 = iprot.readString(); - self.part_vals.append(_elem509) + (_etype544, _size541) = iprot.readListBegin() + for _i545 in xrange(_size541): + _elem546 = iprot.readString(); + self.part_vals.append(_elem546) iprot.readListEnd() else: iprot.skip(ftype) @@ -13210,8 +13570,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter510 in self.part_vals: - oprot.writeString(iter510) + for iter547 in self.part_vals: + oprot.writeString(iter547) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -13356,11 +13716,11 @@ if fid == 1: if ftype == TType.MAP: self.partitionSpecs = {} - (_ktype512, _vtype513, _size511 ) = iprot.readMapBegin() - for _i515 in xrange(_size511): - _key516 = iprot.readString(); - _val517 = iprot.readString(); - self.partitionSpecs[_key516] = _val517 + (_ktype549, _vtype550, _size548 ) = iprot.readMapBegin() + for _i552 in xrange(_size548): + _key553 = iprot.readString(); + _val554 = iprot.readString(); + self.partitionSpecs[_key553] = _val554 iprot.readMapEnd() else: iprot.skip(ftype) @@ -13397,9 +13757,9 @@ if self.partitionSpecs is not None: oprot.writeFieldBegin('partitionSpecs', TType.MAP, 1) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.partitionSpecs)) - for kiter518,viter519 in self.partitionSpecs.items(): - oprot.writeString(kiter518) - oprot.writeString(viter519) + for kiter555,viter556 in self.partitionSpecs.items(): + oprot.writeString(kiter555) + oprot.writeString(viter556) oprot.writeMapEnd() oprot.writeFieldEnd() if self.source_db is not None: @@ -13596,10 +13956,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype523, _size520) = iprot.readListBegin() - for _i524 in xrange(_size520): - _elem525 = iprot.readString(); - self.part_vals.append(_elem525) + (_etype560, _size557) = iprot.readListBegin() + for _i561 in xrange(_size557): + _elem562 = iprot.readString(); + self.part_vals.append(_elem562) iprot.readListEnd() else: iprot.skip(ftype) @@ -13611,10 +13971,10 @@ elif fid == 5: if ftype == TType.LIST: self.group_names = [] - (_etype529, _size526) = iprot.readListBegin() - for _i530 in xrange(_size526): - _elem531 = iprot.readString(); - self.group_names.append(_elem531) + (_etype566, _size563) = iprot.readListBegin() + for _i567 in xrange(_size563): + _elem568 = iprot.readString(); + self.group_names.append(_elem568) iprot.readListEnd() else: iprot.skip(ftype) @@ -13639,8 +13999,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter532 in self.part_vals: - oprot.writeString(iter532) + for iter569 in self.part_vals: + oprot.writeString(iter569) oprot.writeListEnd() oprot.writeFieldEnd() if self.user_name is not None: @@ -13650,8 +14010,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 5) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter533 in self.group_names: - oprot.writeString(iter533) + for iter570 in self.group_names: + oprot.writeString(iter570) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -14043,11 +14403,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype537, _size534) = iprot.readListBegin() - for _i538 in xrange(_size534): - _elem539 = Partition() - _elem539.read(iprot) - self.success.append(_elem539) + (_etype574, _size571) = iprot.readListBegin() + for _i575 in xrange(_size571): + _elem576 = Partition() + _elem576.read(iprot) + self.success.append(_elem576) iprot.readListEnd() else: iprot.skip(ftype) @@ -14076,8 +14436,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter540 in self.success: - iter540.write(oprot) + for iter577 in self.success: + iter577.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -14164,10 +14524,10 @@ elif fid == 5: if ftype == TType.LIST: self.group_names = [] - (_etype544, _size541) = iprot.readListBegin() - for _i545 in xrange(_size541): - _elem546 = iprot.readString(); - self.group_names.append(_elem546) + (_etype581, _size578) = iprot.readListBegin() + for _i582 in xrange(_size578): + _elem583 = iprot.readString(); + self.group_names.append(_elem583) iprot.readListEnd() else: iprot.skip(ftype) @@ -14200,8 +14560,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 5) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter547 in self.group_names: - oprot.writeString(iter547) + for iter584 in self.group_names: + oprot.writeString(iter584) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -14253,11 +14613,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype551, _size548) = iprot.readListBegin() - for _i552 in xrange(_size548): - _elem553 = Partition() - _elem553.read(iprot) - self.success.append(_elem553) + (_etype588, _size585) = iprot.readListBegin() + for _i589 in xrange(_size585): + _elem590 = Partition() + _elem590.read(iprot) + self.success.append(_elem590) iprot.readListEnd() else: iprot.skip(ftype) @@ -14286,8 +14646,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter554 in self.success: - iter554.write(oprot) + for iter591 in self.success: + iter591.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -14316,6 +14676,184 @@ def __ne__(self, other): return not (self == other) +class get_partitions_pspec_args: + """ + Attributes: + - db_name + - tbl_name + - max_parts + """ + + thrift_spec = ( + None, # 0 + (1, TType.STRING, 'db_name', None, None, ), # 1 + (2, TType.STRING, 'tbl_name', None, None, ), # 2 + (3, TType.I32, 'max_parts', None, -1, ), # 3 + ) + + def __init__(self, db_name=None, tbl_name=None, max_parts=thrift_spec[3][4],): + self.db_name = db_name + self.tbl_name = tbl_name + self.max_parts = max_parts + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 1: + if ftype == TType.STRING: + self.db_name = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRING: + self.tbl_name = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.I32: + self.max_parts = iprot.readI32(); + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('get_partitions_pspec_args') + if self.db_name is not None: + oprot.writeFieldBegin('db_name', TType.STRING, 1) + oprot.writeString(self.db_name) + oprot.writeFieldEnd() + if self.tbl_name is not None: + oprot.writeFieldBegin('tbl_name', TType.STRING, 2) + oprot.writeString(self.tbl_name) + oprot.writeFieldEnd() + if self.max_parts is not None: + oprot.writeFieldBegin('max_parts', TType.I32, 3) + oprot.writeI32(self.max_parts) + 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_partitions_pspec_result: + """ + Attributes: + - success + - o1 + - o2 + """ + + thrift_spec = ( + (0, TType.LIST, 'success', (TType.STRUCT,(PartitionSpec, PartitionSpec.thrift_spec)), None, ), # 0 + (1, TType.STRUCT, 'o1', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 1 + (2, TType.STRUCT, 'o2', (MetaException, MetaException.thrift_spec), None, ), # 2 + ) + + def __init__(self, success=None, o1=None, o2=None,): + self.success = success + self.o1 = o1 + self.o2 = o2 + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 0: + if ftype == TType.LIST: + self.success = [] + (_etype595, _size592) = iprot.readListBegin() + for _i596 in xrange(_size592): + _elem597 = PartitionSpec() + _elem597.read(iprot) + self.success.append(_elem597) + iprot.readListEnd() + else: + iprot.skip(ftype) + elif fid == 1: + if ftype == TType.STRUCT: + self.o1 = NoSuchObjectException() + self.o1.read(iprot) + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRUCT: + self.o2 = MetaException() + self.o2.read(iprot) + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('get_partitions_pspec_result') + if self.success is not None: + oprot.writeFieldBegin('success', TType.LIST, 0) + oprot.writeListBegin(TType.STRUCT, len(self.success)) + for iter598 in self.success: + iter598.write(oprot) + oprot.writeListEnd() + 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() + 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_names_args: """ Attributes: @@ -14428,10 +14966,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype558, _size555) = iprot.readListBegin() - for _i559 in xrange(_size555): - _elem560 = iprot.readString(); - self.success.append(_elem560) + (_etype602, _size599) = iprot.readListBegin() + for _i603 in xrange(_size599): + _elem604 = iprot.readString(); + self.success.append(_elem604) iprot.readListEnd() else: iprot.skip(ftype) @@ -14454,8 +14992,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter561 in self.success: - oprot.writeString(iter561) + for iter605 in self.success: + oprot.writeString(iter605) oprot.writeListEnd() oprot.writeFieldEnd() if self.o2 is not None: @@ -14525,10 +15063,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype565, _size562) = iprot.readListBegin() - for _i566 in xrange(_size562): - _elem567 = iprot.readString(); - self.part_vals.append(_elem567) + (_etype609, _size606) = iprot.readListBegin() + for _i610 in xrange(_size606): + _elem611 = iprot.readString(); + self.part_vals.append(_elem611) iprot.readListEnd() else: iprot.skip(ftype) @@ -14558,8 +15096,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter568 in self.part_vals: - oprot.writeString(iter568) + for iter612 in self.part_vals: + oprot.writeString(iter612) oprot.writeListEnd() oprot.writeFieldEnd() if self.max_parts is not None: @@ -14615,11 +15153,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype572, _size569) = iprot.readListBegin() - for _i573 in xrange(_size569): - _elem574 = Partition() - _elem574.read(iprot) - self.success.append(_elem574) + (_etype616, _size613) = iprot.readListBegin() + for _i617 in xrange(_size613): + _elem618 = Partition() + _elem618.read(iprot) + self.success.append(_elem618) iprot.readListEnd() else: iprot.skip(ftype) @@ -14648,8 +15186,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter575 in self.success: - iter575.write(oprot) + for iter619 in self.success: + iter619.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -14729,10 +15267,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype579, _size576) = iprot.readListBegin() - for _i580 in xrange(_size576): - _elem581 = iprot.readString(); - self.part_vals.append(_elem581) + (_etype623, _size620) = iprot.readListBegin() + for _i624 in xrange(_size620): + _elem625 = iprot.readString(); + self.part_vals.append(_elem625) iprot.readListEnd() else: iprot.skip(ftype) @@ -14749,10 +15287,10 @@ elif fid == 6: if ftype == TType.LIST: self.group_names = [] - (_etype585, _size582) = iprot.readListBegin() - for _i586 in xrange(_size582): - _elem587 = iprot.readString(); - self.group_names.append(_elem587) + (_etype629, _size626) = iprot.readListBegin() + for _i630 in xrange(_size626): + _elem631 = iprot.readString(); + self.group_names.append(_elem631) iprot.readListEnd() else: iprot.skip(ftype) @@ -14777,8 +15315,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter588 in self.part_vals: - oprot.writeString(iter588) + for iter632 in self.part_vals: + oprot.writeString(iter632) oprot.writeListEnd() oprot.writeFieldEnd() if self.max_parts is not None: @@ -14792,8 +15330,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 6) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter589 in self.group_names: - oprot.writeString(iter589) + for iter633 in self.group_names: + oprot.writeString(iter633) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -14845,11 +15383,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype593, _size590) = iprot.readListBegin() - for _i594 in xrange(_size590): - _elem595 = Partition() - _elem595.read(iprot) - self.success.append(_elem595) + (_etype637, _size634) = iprot.readListBegin() + for _i638 in xrange(_size634): + _elem639 = Partition() + _elem639.read(iprot) + self.success.append(_elem639) iprot.readListEnd() else: iprot.skip(ftype) @@ -14878,8 +15416,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter596 in self.success: - iter596.write(oprot) + for iter640 in self.success: + iter640.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -14953,10 +15491,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype600, _size597) = iprot.readListBegin() - for _i601 in xrange(_size597): - _elem602 = iprot.readString(); - self.part_vals.append(_elem602) + (_etype644, _size641) = iprot.readListBegin() + for _i645 in xrange(_size641): + _elem646 = iprot.readString(); + self.part_vals.append(_elem646) iprot.readListEnd() else: iprot.skip(ftype) @@ -14986,8 +15524,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter603 in self.part_vals: - oprot.writeString(iter603) + for iter647 in self.part_vals: + oprot.writeString(iter647) oprot.writeListEnd() oprot.writeFieldEnd() if self.max_parts is not None: @@ -15043,10 +15581,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype607, _size604) = iprot.readListBegin() - for _i608 in xrange(_size604): - _elem609 = iprot.readString(); - self.success.append(_elem609) + (_etype651, _size648) = iprot.readListBegin() + for _i652 in xrange(_size648): + _elem653 = iprot.readString(); + self.success.append(_elem653) iprot.readListEnd() else: iprot.skip(ftype) @@ -15075,8 +15613,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter610 in self.success: - oprot.writeString(iter610) + for iter654 in self.success: + oprot.writeString(iter654) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -15232,11 +15770,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype614, _size611) = iprot.readListBegin() - for _i615 in xrange(_size611): - _elem616 = Partition() - _elem616.read(iprot) - self.success.append(_elem616) + (_etype658, _size655) = iprot.readListBegin() + for _i659 in xrange(_size655): + _elem660 = Partition() + _elem660.read(iprot) + self.success.append(_elem660) iprot.readListEnd() else: iprot.skip(ftype) @@ -15265,8 +15803,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter617 in self.success: - iter617.write(oprot) + for iter661 in self.success: + iter661.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -15295,6 +15833,196 @@ def __ne__(self, other): return not (self == other) +class get_part_specs_by_filter_args: + """ + Attributes: + - db_name + - tbl_name + - filter + - max_parts + """ + + thrift_spec = ( + None, # 0 + (1, TType.STRING, 'db_name', None, None, ), # 1 + (2, TType.STRING, 'tbl_name', None, None, ), # 2 + (3, TType.STRING, 'filter', None, None, ), # 3 + (4, TType.I32, 'max_parts', None, -1, ), # 4 + ) + + def __init__(self, db_name=None, tbl_name=None, filter=None, max_parts=thrift_spec[4][4],): + self.db_name = db_name + self.tbl_name = tbl_name + self.filter = filter + self.max_parts = max_parts + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 1: + if ftype == TType.STRING: + self.db_name = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRING: + self.tbl_name = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.STRING: + self.filter = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 4: + if ftype == TType.I32: + self.max_parts = iprot.readI32(); + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('get_part_specs_by_filter_args') + if self.db_name is not None: + oprot.writeFieldBegin('db_name', TType.STRING, 1) + oprot.writeString(self.db_name) + oprot.writeFieldEnd() + if self.tbl_name is not None: + oprot.writeFieldBegin('tbl_name', TType.STRING, 2) + oprot.writeString(self.tbl_name) + oprot.writeFieldEnd() + if self.filter is not None: + oprot.writeFieldBegin('filter', TType.STRING, 3) + oprot.writeString(self.filter) + oprot.writeFieldEnd() + if self.max_parts is not None: + oprot.writeFieldBegin('max_parts', TType.I32, 4) + oprot.writeI32(self.max_parts) + 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_part_specs_by_filter_result: + """ + Attributes: + - success + - o1 + - o2 + """ + + thrift_spec = ( + (0, TType.LIST, 'success', (TType.STRUCT,(PartitionSpec, PartitionSpec.thrift_spec)), None, ), # 0 + (1, TType.STRUCT, 'o1', (MetaException, MetaException.thrift_spec), None, ), # 1 + (2, TType.STRUCT, 'o2', (NoSuchObjectException, NoSuchObjectException.thrift_spec), None, ), # 2 + ) + + def __init__(self, success=None, o1=None, o2=None,): + self.success = success + self.o1 = o1 + self.o2 = o2 + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 0: + if ftype == TType.LIST: + self.success = [] + (_etype665, _size662) = iprot.readListBegin() + for _i666 in xrange(_size662): + _elem667 = PartitionSpec() + _elem667.read(iprot) + self.success.append(_elem667) + iprot.readListEnd() + else: + iprot.skip(ftype) + elif fid == 1: + if ftype == TType.STRUCT: + self.o1 = MetaException() + self.o1.read(iprot) + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRUCT: + self.o2 = NoSuchObjectException() + self.o2.read(iprot) + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('get_part_specs_by_filter_result') + if self.success is not None: + oprot.writeFieldBegin('success', TType.LIST, 0) + oprot.writeListBegin(TType.STRUCT, len(self.success)) + for iter668 in self.success: + iter668.write(oprot) + oprot.writeListEnd() + 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() + 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_partitions_by_expr_args: """ Attributes: @@ -15484,10 +16212,10 @@ elif fid == 3: if ftype == TType.LIST: self.names = [] - (_etype621, _size618) = iprot.readListBegin() - for _i622 in xrange(_size618): - _elem623 = iprot.readString(); - self.names.append(_elem623) + (_etype672, _size669) = iprot.readListBegin() + for _i673 in xrange(_size669): + _elem674 = iprot.readString(); + self.names.append(_elem674) iprot.readListEnd() else: iprot.skip(ftype) @@ -15512,8 +16240,8 @@ if self.names is not None: oprot.writeFieldBegin('names', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.names)) - for iter624 in self.names: - oprot.writeString(iter624) + for iter675 in self.names: + oprot.writeString(iter675) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -15565,11 +16293,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype628, _size625) = iprot.readListBegin() - for _i629 in xrange(_size625): - _elem630 = Partition() - _elem630.read(iprot) - self.success.append(_elem630) + (_etype679, _size676) = iprot.readListBegin() + for _i680 in xrange(_size676): + _elem681 = Partition() + _elem681.read(iprot) + self.success.append(_elem681) iprot.readListEnd() else: iprot.skip(ftype) @@ -15598,8 +16326,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter631 in self.success: - iter631.write(oprot) + for iter682 in self.success: + iter682.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -15829,11 +16557,11 @@ elif fid == 3: if ftype == TType.LIST: self.new_parts = [] - (_etype635, _size632) = iprot.readListBegin() - for _i636 in xrange(_size632): - _elem637 = Partition() - _elem637.read(iprot) - self.new_parts.append(_elem637) + (_etype686, _size683) = iprot.readListBegin() + for _i687 in xrange(_size683): + _elem688 = Partition() + _elem688.read(iprot) + self.new_parts.append(_elem688) iprot.readListEnd() else: iprot.skip(ftype) @@ -15858,8 +16586,8 @@ if self.new_parts is not None: oprot.writeFieldBegin('new_parts', TType.LIST, 3) oprot.writeListBegin(TType.STRUCT, len(self.new_parts)) - for iter638 in self.new_parts: - iter638.write(oprot) + for iter689 in self.new_parts: + iter689.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -16171,10 +16899,10 @@ elif fid == 3: if ftype == TType.LIST: self.part_vals = [] - (_etype642, _size639) = iprot.readListBegin() - for _i643 in xrange(_size639): - _elem644 = iprot.readString(); - self.part_vals.append(_elem644) + (_etype693, _size690) = iprot.readListBegin() + for _i694 in xrange(_size690): + _elem695 = iprot.readString(); + self.part_vals.append(_elem695) iprot.readListEnd() else: iprot.skip(ftype) @@ -16205,8 +16933,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter645 in self.part_vals: - oprot.writeString(iter645) + for iter696 in self.part_vals: + oprot.writeString(iter696) oprot.writeListEnd() oprot.writeFieldEnd() if self.new_part is not None: @@ -16334,10 +17062,10 @@ if fid == 1: if ftype == TType.LIST: self.part_vals = [] - (_etype649, _size646) = iprot.readListBegin() - for _i650 in xrange(_size646): - _elem651 = iprot.readString(); - self.part_vals.append(_elem651) + (_etype700, _size697) = iprot.readListBegin() + for _i701 in xrange(_size697): + _elem702 = iprot.readString(); + self.part_vals.append(_elem702) iprot.readListEnd() else: iprot.skip(ftype) @@ -16359,8 +17087,8 @@ if self.part_vals is not None: oprot.writeFieldBegin('part_vals', TType.LIST, 1) oprot.writeListBegin(TType.STRING, len(self.part_vals)) - for iter652 in self.part_vals: - oprot.writeString(iter652) + for iter703 in self.part_vals: + oprot.writeString(iter703) oprot.writeListEnd() oprot.writeFieldEnd() if self.throw_exception is not None: @@ -16689,10 +17417,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype656, _size653) = iprot.readListBegin() - for _i657 in xrange(_size653): - _elem658 = iprot.readString(); - self.success.append(_elem658) + (_etype707, _size704) = iprot.readListBegin() + for _i708 in xrange(_size704): + _elem709 = iprot.readString(); + self.success.append(_elem709) iprot.readListEnd() else: iprot.skip(ftype) @@ -16715,8 +17443,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter659 in self.success: - oprot.writeString(iter659) + for iter710 in self.success: + oprot.writeString(iter710) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -16829,11 +17557,11 @@ if fid == 0: if ftype == TType.MAP: self.success = {} - (_ktype661, _vtype662, _size660 ) = iprot.readMapBegin() - for _i664 in xrange(_size660): - _key665 = iprot.readString(); - _val666 = iprot.readString(); - self.success[_key665] = _val666 + (_ktype712, _vtype713, _size711 ) = iprot.readMapBegin() + for _i715 in xrange(_size711): + _key716 = iprot.readString(); + _val717 = iprot.readString(); + self.success[_key716] = _val717 iprot.readMapEnd() else: iprot.skip(ftype) @@ -16856,9 +17584,9 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.MAP, 0) oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.success)) - for kiter667,viter668 in self.success.items(): - oprot.writeString(kiter667) - oprot.writeString(viter668) + for kiter718,viter719 in self.success.items(): + oprot.writeString(kiter718) + oprot.writeString(viter719) oprot.writeMapEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -16928,11 +17656,11 @@ elif fid == 3: if ftype == TType.MAP: self.part_vals = {} - (_ktype670, _vtype671, _size669 ) = iprot.readMapBegin() - for _i673 in xrange(_size669): - _key674 = iprot.readString(); - _val675 = iprot.readString(); - self.part_vals[_key674] = _val675 + (_ktype721, _vtype722, _size720 ) = iprot.readMapBegin() + for _i724 in xrange(_size720): + _key725 = iprot.readString(); + _val726 = iprot.readString(); + self.part_vals[_key725] = _val726 iprot.readMapEnd() else: iprot.skip(ftype) @@ -16962,9 +17690,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 kiter676,viter677 in self.part_vals.items(): - oprot.writeString(kiter676) - oprot.writeString(viter677) + for kiter727,viter728 in self.part_vals.items(): + oprot.writeString(kiter727) + oprot.writeString(viter728) oprot.writeMapEnd() oprot.writeFieldEnd() if self.eventType is not None: @@ -17160,11 +17888,11 @@ elif fid == 3: if ftype == TType.MAP: self.part_vals = {} - (_ktype679, _vtype680, _size678 ) = iprot.readMapBegin() - for _i682 in xrange(_size678): - _key683 = iprot.readString(); - _val684 = iprot.readString(); - self.part_vals[_key683] = _val684 + (_ktype730, _vtype731, _size729 ) = iprot.readMapBegin() + for _i733 in xrange(_size729): + _key734 = iprot.readString(); + _val735 = iprot.readString(); + self.part_vals[_key734] = _val735 iprot.readMapEnd() else: iprot.skip(ftype) @@ -17194,9 +17922,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 kiter685,viter686 in self.part_vals.items(): - oprot.writeString(kiter685) - oprot.writeString(viter686) + for kiter736,viter737 in self.part_vals.items(): + oprot.writeString(kiter736) + oprot.writeString(viter737) oprot.writeMapEnd() oprot.writeFieldEnd() if self.eventType is not None: @@ -18168,11 +18896,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype690, _size687) = iprot.readListBegin() - for _i691 in xrange(_size687): - _elem692 = Index() - _elem692.read(iprot) - self.success.append(_elem692) + (_etype741, _size738) = iprot.readListBegin() + for _i742 in xrange(_size738): + _elem743 = Index() + _elem743.read(iprot) + self.success.append(_elem743) iprot.readListEnd() else: iprot.skip(ftype) @@ -18201,8 +18929,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter693 in self.success: - iter693.write(oprot) + for iter744 in self.success: + iter744.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -18343,10 +19071,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype697, _size694) = iprot.readListBegin() - for _i698 in xrange(_size694): - _elem699 = iprot.readString(); - self.success.append(_elem699) + (_etype748, _size745) = iprot.readListBegin() + for _i749 in xrange(_size745): + _elem750 = iprot.readString(); + self.success.append(_elem750) iprot.readListEnd() else: iprot.skip(ftype) @@ -18369,8 +19097,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter700 in self.success: - oprot.writeString(iter700) + for iter751 in self.success: + oprot.writeString(iter751) oprot.writeListEnd() oprot.writeFieldEnd() if self.o2 is not None: @@ -20552,10 +21280,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype704, _size701) = iprot.readListBegin() - for _i705 in xrange(_size701): - _elem706 = iprot.readString(); - self.success.append(_elem706) + (_etype755, _size752) = iprot.readListBegin() + for _i756 in xrange(_size752): + _elem757 = iprot.readString(); + self.success.append(_elem757) iprot.readListEnd() else: iprot.skip(ftype) @@ -20578,8 +21306,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter707 in self.success: - oprot.writeString(iter707) + for iter758 in self.success: + oprot.writeString(iter758) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -21097,10 +21825,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype711, _size708) = iprot.readListBegin() - for _i712 in xrange(_size708): - _elem713 = iprot.readString(); - self.success.append(_elem713) + (_etype762, _size759) = iprot.readListBegin() + for _i763 in xrange(_size759): + _elem764 = iprot.readString(); + self.success.append(_elem764) iprot.readListEnd() else: iprot.skip(ftype) @@ -21123,8 +21851,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter714 in self.success: - oprot.writeString(iter714) + for iter765 in self.success: + oprot.writeString(iter765) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -21597,11 +22325,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype718, _size715) = iprot.readListBegin() - for _i719 in xrange(_size715): - _elem720 = Role() - _elem720.read(iprot) - self.success.append(_elem720) + (_etype769, _size766) = iprot.readListBegin() + for _i770 in xrange(_size766): + _elem771 = Role() + _elem771.read(iprot) + self.success.append(_elem771) iprot.readListEnd() else: iprot.skip(ftype) @@ -21624,8 +22352,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter721 in self.success: - iter721.write(oprot) + for iter772 in self.success: + iter772.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -22095,10 +22823,10 @@ elif fid == 3: if ftype == TType.LIST: self.group_names = [] - (_etype725, _size722) = iprot.readListBegin() - for _i726 in xrange(_size722): - _elem727 = iprot.readString(); - self.group_names.append(_elem727) + (_etype776, _size773) = iprot.readListBegin() + for _i777 in xrange(_size773): + _elem778 = iprot.readString(); + self.group_names.append(_elem778) iprot.readListEnd() else: iprot.skip(ftype) @@ -22123,8 +22851,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 3) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter728 in self.group_names: - oprot.writeString(iter728) + for iter779 in self.group_names: + oprot.writeString(iter779) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -22331,11 +23059,11 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype732, _size729) = iprot.readListBegin() - for _i733 in xrange(_size729): - _elem734 = HiveObjectPrivilege() - _elem734.read(iprot) - self.success.append(_elem734) + (_etype783, _size780) = iprot.readListBegin() + for _i784 in xrange(_size780): + _elem785 = HiveObjectPrivilege() + _elem785.read(iprot) + self.success.append(_elem785) iprot.readListEnd() else: iprot.skip(ftype) @@ -22358,8 +23086,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRUCT, len(self.success)) - for iter735 in self.success: - iter735.write(oprot) + for iter786 in self.success: + iter786.write(oprot) oprot.writeListEnd() oprot.writeFieldEnd() if self.o1 is not None: @@ -22818,10 +23546,10 @@ elif fid == 2: if ftype == TType.LIST: self.group_names = [] - (_etype739, _size736) = iprot.readListBegin() - for _i740 in xrange(_size736): - _elem741 = iprot.readString(); - self.group_names.append(_elem741) + (_etype790, _size787) = iprot.readListBegin() + for _i791 in xrange(_size787): + _elem792 = iprot.readString(); + self.group_names.append(_elem792) iprot.readListEnd() else: iprot.skip(ftype) @@ -22842,8 +23570,8 @@ if self.group_names is not None: oprot.writeFieldBegin('group_names', TType.LIST, 2) oprot.writeListBegin(TType.STRING, len(self.group_names)) - for iter742 in self.group_names: - oprot.writeString(iter742) + for iter793 in self.group_names: + oprot.writeString(iter793) oprot.writeListEnd() oprot.writeFieldEnd() oprot.writeFieldStop() @@ -22892,10 +23620,10 @@ if fid == 0: if ftype == TType.LIST: self.success = [] - (_etype746, _size743) = iprot.readListBegin() - for _i747 in xrange(_size743): - _elem748 = iprot.readString(); - self.success.append(_elem748) + (_etype797, _size794) = iprot.readListBegin() + for _i798 in xrange(_size794): + _elem799 = iprot.readString(); + self.success.append(_elem799) iprot.readListEnd() else: iprot.skip(ftype) @@ -22918,8 +23646,8 @@ if self.success is not None: oprot.writeFieldBegin('success', TType.LIST, 0) oprot.writeListBegin(TType.STRING, len(self.success)) - for iter749 in self.success: - oprot.writeString(iter749) + for iter800 in self.success: + oprot.writeString(iter800) 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 1619008) +++ metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote (working copy) @@ -51,6 +51,7 @@ print ' Partition add_partition(Partition new_part)' print ' Partition add_partition_with_environment_context(Partition new_part, EnvironmentContext environment_context)' print ' i32 add_partitions( new_parts)' + print ' i32 add_partitions_pspec( new_parts)' print ' Partition append_partition(string db_name, string tbl_name, part_vals)' print ' AddPartitionsResult add_partitions_req(AddPartitionsRequest request)' print ' Partition append_partition_with_environment_context(string db_name, string tbl_name, part_vals, EnvironmentContext environment_context)' @@ -67,11 +68,13 @@ 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)' print ' get_partitions_with_auth(string db_name, string tbl_name, i16 max_parts, string user_name, group_names)' + print ' get_partitions_pspec(string db_name, string tbl_name, i32 max_parts)' print ' get_partition_names(string db_name, string tbl_name, i16 max_parts)' print ' get_partitions_ps(string db_name, string tbl_name, part_vals, i16 max_parts)' print ' get_partitions_ps_with_auth(string db_name, string tbl_name, part_vals, i16 max_parts, string user_name, group_names)' print ' get_partition_names_ps(string db_name, string tbl_name, part_vals, i16 max_parts)' print ' get_partitions_by_filter(string db_name, string tbl_name, string filter, i16 max_parts)' + print ' get_part_specs_by_filter(string db_name, string tbl_name, string filter, i32 max_parts)' print ' PartitionsByExprResult get_partitions_by_expr(PartitionsByExprRequest req)' print ' get_partitions_by_names(string db_name, string tbl_name, names)' print ' void alter_partition(string db_name, string tbl_name, Partition new_part)' @@ -354,6 +357,12 @@ sys.exit(1) pp.pprint(client.add_partitions(eval(args[0]),)) +elif cmd == 'add_partitions_pspec': + if len(args) != 1: + print 'add_partitions_pspec requires 1 args' + sys.exit(1) + pp.pprint(client.add_partitions_pspec(eval(args[0]),)) + elif cmd == 'append_partition': if len(args) != 3: print 'append_partition requires 3 args' @@ -450,6 +459,12 @@ sys.exit(1) pp.pprint(client.get_partitions_with_auth(args[0],args[1],eval(args[2]),args[3],eval(args[4]),)) +elif cmd == 'get_partitions_pspec': + if len(args) != 3: + print 'get_partitions_pspec requires 3 args' + sys.exit(1) + pp.pprint(client.get_partitions_pspec(args[0],args[1],eval(args[2]),)) + elif cmd == 'get_partition_names': if len(args) != 3: print 'get_partition_names requires 3 args' @@ -480,6 +495,12 @@ sys.exit(1) pp.pprint(client.get_partitions_by_filter(args[0],args[1],args[2],eval(args[3]),)) +elif cmd == 'get_part_specs_by_filter': + if len(args) != 4: + print 'get_part_specs_by_filter requires 4 args' + sys.exit(1) + pp.pprint(client.get_part_specs_by_filter(args[0],args[1],args[2],eval(args[3]),)) + elif cmd == 'get_partitions_by_expr': if len(args) != 1: print 'get_partitions_by_expr requires 1 args' Index: metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp =================================================================== --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp (revision 1619008) +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp (working copy) @@ -1096,14 +1096,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size369; - ::apache::thrift::protocol::TType _etype372; - xfer += iprot->readListBegin(_etype372, _size369); - this->success.resize(_size369); - uint32_t _i373; - for (_i373 = 0; _i373 < _size369; ++_i373) + uint32_t _size395; + ::apache::thrift::protocol::TType _etype398; + xfer += iprot->readListBegin(_etype398, _size395); + this->success.resize(_size395); + uint32_t _i399; + for (_i399 = 0; _i399 < _size395; ++_i399) { - xfer += iprot->readString(this->success[_i373]); + xfer += iprot->readString(this->success[_i399]); } xfer += iprot->readListEnd(); } @@ -1142,10 +1142,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 _iter374; - for (_iter374 = this->success.begin(); _iter374 != this->success.end(); ++_iter374) + std::vector ::const_iterator _iter400; + for (_iter400 = this->success.begin(); _iter400 != this->success.end(); ++_iter400) { - xfer += oprot->writeString((*_iter374)); + xfer += oprot->writeString((*_iter400)); } xfer += oprot->writeListEnd(); } @@ -1184,14 +1184,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size375; - ::apache::thrift::protocol::TType _etype378; - xfer += iprot->readListBegin(_etype378, _size375); - (*(this->success)).resize(_size375); - uint32_t _i379; - for (_i379 = 0; _i379 < _size375; ++_i379) + uint32_t _size401; + ::apache::thrift::protocol::TType _etype404; + xfer += iprot->readListBegin(_etype404, _size401); + (*(this->success)).resize(_size401); + uint32_t _i405; + for (_i405 = 0; _i405 < _size401; ++_i405) { - xfer += iprot->readString((*(this->success))[_i379]); + xfer += iprot->readString((*(this->success))[_i405]); } xfer += iprot->readListEnd(); } @@ -1289,14 +1289,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size380; - ::apache::thrift::protocol::TType _etype383; - xfer += iprot->readListBegin(_etype383, _size380); - this->success.resize(_size380); - uint32_t _i384; - for (_i384 = 0; _i384 < _size380; ++_i384) + uint32_t _size406; + ::apache::thrift::protocol::TType _etype409; + xfer += iprot->readListBegin(_etype409, _size406); + this->success.resize(_size406); + uint32_t _i410; + for (_i410 = 0; _i410 < _size406; ++_i410) { - xfer += iprot->readString(this->success[_i384]); + xfer += iprot->readString(this->success[_i410]); } xfer += iprot->readListEnd(); } @@ -1335,10 +1335,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 _iter385; - for (_iter385 = this->success.begin(); _iter385 != this->success.end(); ++_iter385) + std::vector ::const_iterator _iter411; + for (_iter411 = this->success.begin(); _iter411 != this->success.end(); ++_iter411) { - xfer += oprot->writeString((*_iter385)); + xfer += oprot->writeString((*_iter411)); } xfer += oprot->writeListEnd(); } @@ -1377,14 +1377,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size386; - ::apache::thrift::protocol::TType _etype389; - xfer += iprot->readListBegin(_etype389, _size386); - (*(this->success)).resize(_size386); - uint32_t _i390; - for (_i390 = 0; _i390 < _size386; ++_i390) + uint32_t _size412; + ::apache::thrift::protocol::TType _etype415; + xfer += iprot->readListBegin(_etype415, _size412); + (*(this->success)).resize(_size412); + uint32_t _i416; + for (_i416 = 0; _i416 < _size412; ++_i416) { - xfer += iprot->readString((*(this->success))[_i390]); + xfer += iprot->readString((*(this->success))[_i416]); } xfer += iprot->readListEnd(); } @@ -2327,17 +2327,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->success.clear(); - uint32_t _size391; - ::apache::thrift::protocol::TType _ktype392; - ::apache::thrift::protocol::TType _vtype393; - xfer += iprot->readMapBegin(_ktype392, _vtype393, _size391); - uint32_t _i395; - for (_i395 = 0; _i395 < _size391; ++_i395) + uint32_t _size417; + ::apache::thrift::protocol::TType _ktype418; + ::apache::thrift::protocol::TType _vtype419; + xfer += iprot->readMapBegin(_ktype418, _vtype419, _size417); + uint32_t _i421; + for (_i421 = 0; _i421 < _size417; ++_i421) { - std::string _key396; - xfer += iprot->readString(_key396); - Type& _val397 = this->success[_key396]; - xfer += _val397.read(iprot); + std::string _key422; + xfer += iprot->readString(_key422); + Type& _val423 = this->success[_key422]; + xfer += _val423.read(iprot); } xfer += iprot->readMapEnd(); } @@ -2376,11 +2376,11 @@ xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_MAP, 0); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRUCT, static_cast(this->success.size())); - std::map ::const_iterator _iter398; - for (_iter398 = this->success.begin(); _iter398 != this->success.end(); ++_iter398) + std::map ::const_iterator _iter424; + for (_iter424 = this->success.begin(); _iter424 != this->success.end(); ++_iter424) { - xfer += oprot->writeString(_iter398->first); - xfer += _iter398->second.write(oprot); + xfer += oprot->writeString(_iter424->first); + xfer += _iter424->second.write(oprot); } xfer += oprot->writeMapEnd(); } @@ -2419,17 +2419,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { (*(this->success)).clear(); - uint32_t _size399; - ::apache::thrift::protocol::TType _ktype400; - ::apache::thrift::protocol::TType _vtype401; - xfer += iprot->readMapBegin(_ktype400, _vtype401, _size399); - uint32_t _i403; - for (_i403 = 0; _i403 < _size399; ++_i403) + uint32_t _size425; + ::apache::thrift::protocol::TType _ktype426; + ::apache::thrift::protocol::TType _vtype427; + xfer += iprot->readMapBegin(_ktype426, _vtype427, _size425); + uint32_t _i429; + for (_i429 = 0; _i429 < _size425; ++_i429) { - std::string _key404; - xfer += iprot->readString(_key404); - Type& _val405 = (*(this->success))[_key404]; - xfer += _val405.read(iprot); + std::string _key430; + xfer += iprot->readString(_key430); + Type& _val431 = (*(this->success))[_key430]; + xfer += _val431.read(iprot); } xfer += iprot->readMapEnd(); } @@ -2564,14 +2564,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size406; - ::apache::thrift::protocol::TType _etype409; - xfer += iprot->readListBegin(_etype409, _size406); - this->success.resize(_size406); - uint32_t _i410; - for (_i410 = 0; _i410 < _size406; ++_i410) + uint32_t _size432; + ::apache::thrift::protocol::TType _etype435; + xfer += iprot->readListBegin(_etype435, _size432); + this->success.resize(_size432); + uint32_t _i436; + for (_i436 = 0; _i436 < _size432; ++_i436) { - xfer += this->success[_i410].read(iprot); + xfer += this->success[_i436].read(iprot); } xfer += iprot->readListEnd(); } @@ -2626,10 +2626,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 _iter411; - for (_iter411 = this->success.begin(); _iter411 != this->success.end(); ++_iter411) + std::vector ::const_iterator _iter437; + for (_iter437 = this->success.begin(); _iter437 != this->success.end(); ++_iter437) { - xfer += (*_iter411).write(oprot); + xfer += (*_iter437).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2676,14 +2676,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size412; - ::apache::thrift::protocol::TType _etype415; - xfer += iprot->readListBegin(_etype415, _size412); - (*(this->success)).resize(_size412); - uint32_t _i416; - for (_i416 = 0; _i416 < _size412; ++_i416) + uint32_t _size438; + ::apache::thrift::protocol::TType _etype441; + xfer += iprot->readListBegin(_etype441, _size438); + (*(this->success)).resize(_size438); + uint32_t _i442; + for (_i442 = 0; _i442 < _size438; ++_i442) { - xfer += (*(this->success))[_i416].read(iprot); + xfer += (*(this->success))[_i442].read(iprot); } xfer += iprot->readListEnd(); } @@ -2834,14 +2834,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size417; - ::apache::thrift::protocol::TType _etype420; - xfer += iprot->readListBegin(_etype420, _size417); - this->success.resize(_size417); - uint32_t _i421; - for (_i421 = 0; _i421 < _size417; ++_i421) + uint32_t _size443; + ::apache::thrift::protocol::TType _etype446; + xfer += iprot->readListBegin(_etype446, _size443); + this->success.resize(_size443); + uint32_t _i447; + for (_i447 = 0; _i447 < _size443; ++_i447) { - xfer += this->success[_i421].read(iprot); + xfer += this->success[_i447].read(iprot); } xfer += iprot->readListEnd(); } @@ -2896,10 +2896,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 _iter422; - for (_iter422 = this->success.begin(); _iter422 != this->success.end(); ++_iter422) + std::vector ::const_iterator _iter448; + for (_iter448 = this->success.begin(); _iter448 != this->success.end(); ++_iter448) { - xfer += (*_iter422).write(oprot); + xfer += (*_iter448).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2946,14 +2946,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - 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) + uint32_t _size449; + ::apache::thrift::protocol::TType _etype452; + xfer += iprot->readListBegin(_etype452, _size449); + (*(this->success)).resize(_size449); + uint32_t _i453; + for (_i453 = 0; _i453 < _size449; ++_i453) { - xfer += (*(this->success))[_i427].read(iprot); + xfer += (*(this->success))[_i453].read(iprot); } xfer += iprot->readListEnd(); } @@ -4008,14 +4008,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size428; - ::apache::thrift::protocol::TType _etype431; - xfer += iprot->readListBegin(_etype431, _size428); - this->success.resize(_size428); - uint32_t _i432; - for (_i432 = 0; _i432 < _size428; ++_i432) + 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 += iprot->readString(this->success[_i432]); + xfer += iprot->readString(this->success[_i458]); } xfer += iprot->readListEnd(); } @@ -4054,10 +4054,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 _iter433; - for (_iter433 = this->success.begin(); _iter433 != this->success.end(); ++_iter433) + std::vector ::const_iterator _iter459; + for (_iter459 = this->success.begin(); _iter459 != this->success.end(); ++_iter459) { - xfer += oprot->writeString((*_iter433)); + xfer += oprot->writeString((*_iter459)); } xfer += oprot->writeListEnd(); } @@ -4096,14 +4096,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size434; - ::apache::thrift::protocol::TType _etype437; - xfer += iprot->readListBegin(_etype437, _size434); - (*(this->success)).resize(_size434); - uint32_t _i438; - for (_i438 = 0; _i438 < _size434; ++_i438) + uint32_t _size460; + ::apache::thrift::protocol::TType _etype463; + xfer += iprot->readListBegin(_etype463, _size460); + (*(this->success)).resize(_size460); + uint32_t _i464; + for (_i464 = 0; _i464 < _size460; ++_i464) { - xfer += iprot->readString((*(this->success))[_i438]); + xfer += iprot->readString((*(this->success))[_i464]); } xfer += iprot->readListEnd(); } @@ -4222,14 +4222,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 _size465; + ::apache::thrift::protocol::TType _etype468; + xfer += iprot->readListBegin(_etype468, _size465); + this->success.resize(_size465); + uint32_t _i469; + for (_i469 = 0; _i469 < _size465; ++_i469) { - xfer += iprot->readString(this->success[_i443]); + xfer += iprot->readString(this->success[_i469]); } xfer += iprot->readListEnd(); } @@ -4268,10 +4268,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 _iter444; - for (_iter444 = this->success.begin(); _iter444 != this->success.end(); ++_iter444) + std::vector ::const_iterator _iter470; + for (_iter470 = this->success.begin(); _iter470 != this->success.end(); ++_iter470) { - xfer += oprot->writeString((*_iter444)); + xfer += oprot->writeString((*_iter470)); } xfer += oprot->writeListEnd(); } @@ -4310,14 +4310,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 _size471; + ::apache::thrift::protocol::TType _etype474; + xfer += iprot->readListBegin(_etype474, _size471); + (*(this->success)).resize(_size471); + uint32_t _i475; + for (_i475 = 0; _i475 < _size471; ++_i475) { - xfer += iprot->readString((*(this->success))[_i449]); + xfer += iprot->readString((*(this->success))[_i475]); } xfer += iprot->readListEnd(); } @@ -4596,14 +4596,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->tbl_names.clear(); - uint32_t _size450; - ::apache::thrift::protocol::TType _etype453; - xfer += iprot->readListBegin(_etype453, _size450); - this->tbl_names.resize(_size450); - uint32_t _i454; - for (_i454 = 0; _i454 < _size450; ++_i454) + uint32_t _size476; + ::apache::thrift::protocol::TType _etype479; + xfer += iprot->readListBegin(_etype479, _size476); + this->tbl_names.resize(_size476); + uint32_t _i480; + for (_i480 = 0; _i480 < _size476; ++_i480) { - xfer += iprot->readString(this->tbl_names[_i454]); + xfer += iprot->readString(this->tbl_names[_i480]); } xfer += iprot->readListEnd(); } @@ -4635,10 +4635,10 @@ xfer += oprot->writeFieldBegin("tbl_names", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->tbl_names.size())); - std::vector ::const_iterator _iter455; - for (_iter455 = this->tbl_names.begin(); _iter455 != this->tbl_names.end(); ++_iter455) + std::vector ::const_iterator _iter481; + for (_iter481 = this->tbl_names.begin(); _iter481 != this->tbl_names.end(); ++_iter481) { - xfer += oprot->writeString((*_iter455)); + xfer += oprot->writeString((*_iter481)); } xfer += oprot->writeListEnd(); } @@ -4660,10 +4660,10 @@ xfer += oprot->writeFieldBegin("tbl_names", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->tbl_names)).size())); - std::vector ::const_iterator _iter456; - for (_iter456 = (*(this->tbl_names)).begin(); _iter456 != (*(this->tbl_names)).end(); ++_iter456) + std::vector ::const_iterator _iter482; + for (_iter482 = (*(this->tbl_names)).begin(); _iter482 != (*(this->tbl_names)).end(); ++_iter482) { - xfer += oprot->writeString((*_iter456)); + xfer += oprot->writeString((*_iter482)); } xfer += oprot->writeListEnd(); } @@ -4698,14 +4698,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 _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[_i461].read(iprot); + xfer += this->success[_i487].read(iprot); } xfer += iprot->readListEnd(); } @@ -4760,10 +4760,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 _iter462; - for (_iter462 = this->success.begin(); _iter462 != this->success.end(); ++_iter462) + std::vector
::const_iterator _iter488; + for (_iter488 = this->success.begin(); _iter488 != this->success.end(); ++_iter488) { - xfer += (*_iter462).write(oprot); + xfer += (*_iter488).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4810,14 +4810,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 _size489; + ::apache::thrift::protocol::TType _etype492; + xfer += iprot->readListBegin(_etype492, _size489); + (*(this->success)).resize(_size489); + uint32_t _i493; + for (_i493 = 0; _i493 < _size489; ++_i493) { - xfer += (*(this->success))[_i467].read(iprot); + xfer += (*(this->success))[_i493].read(iprot); } xfer += iprot->readListEnd(); } @@ -4984,14 +4984,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 _size494; + ::apache::thrift::protocol::TType _etype497; + xfer += iprot->readListBegin(_etype497, _size494); + this->success.resize(_size494); + uint32_t _i498; + for (_i498 = 0; _i498 < _size494; ++_i498) { - xfer += iprot->readString(this->success[_i472]); + xfer += iprot->readString(this->success[_i498]); } xfer += iprot->readListEnd(); } @@ -5046,10 +5046,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 _iter473; - for (_iter473 = this->success.begin(); _iter473 != this->success.end(); ++_iter473) + std::vector ::const_iterator _iter499; + for (_iter499 = this->success.begin(); _iter499 != this->success.end(); ++_iter499) { - xfer += oprot->writeString((*_iter473)); + xfer += oprot->writeString((*_iter499)); } xfer += oprot->writeListEnd(); } @@ -5096,14 +5096,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 _size500; + ::apache::thrift::protocol::TType _etype503; + xfer += iprot->readListBegin(_etype503, _size500); + (*(this->success)).resize(_size500); + uint32_t _i504; + for (_i504 = 0; _i504 < _size500; ++_i504) { - xfer += iprot->readString((*(this->success))[_i478]); + xfer += iprot->readString((*(this->success))[_i504]); } xfer += iprot->readListEnd(); } @@ -6076,14 +6076,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->new_parts.clear(); - uint32_t _size479; - ::apache::thrift::protocol::TType _etype482; - xfer += iprot->readListBegin(_etype482, _size479); - this->new_parts.resize(_size479); - uint32_t _i483; - for (_i483 = 0; _i483 < _size479; ++_i483) + uint32_t _size505; + ::apache::thrift::protocol::TType _etype508; + xfer += iprot->readListBegin(_etype508, _size505); + this->new_parts.resize(_size505); + uint32_t _i509; + for (_i509 = 0; _i509 < _size505; ++_i509) { - xfer += this->new_parts[_i483].read(iprot); + xfer += this->new_parts[_i509].read(iprot); } xfer += iprot->readListEnd(); } @@ -6111,10 +6111,10 @@ xfer += oprot->writeFieldBegin("new_parts", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->new_parts.size())); - std::vector ::const_iterator _iter484; - for (_iter484 = this->new_parts.begin(); _iter484 != this->new_parts.end(); ++_iter484) + std::vector ::const_iterator _iter510; + for (_iter510 = this->new_parts.begin(); _iter510 != this->new_parts.end(); ++_iter510) { - xfer += (*_iter484).write(oprot); + xfer += (*_iter510).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6132,10 +6132,10 @@ xfer += oprot->writeFieldBegin("new_parts", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast((*(this->new_parts)).size())); - std::vector ::const_iterator _iter485; - for (_iter485 = (*(this->new_parts)).begin(); _iter485 != (*(this->new_parts)).end(); ++_iter485) + std::vector ::const_iterator _iter511; + for (_iter511 = (*(this->new_parts)).begin(); _iter511 != (*(this->new_parts)).end(); ++_iter511) { - xfer += (*_iter485).write(oprot); + xfer += (*_iter511).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6302,6 +6302,256 @@ return xfer; } +uint32_t ThriftHiveMetastore_add_partitions_pspec_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_LIST) { + { + this->new_parts.clear(); + uint32_t _size512; + ::apache::thrift::protocol::TType _etype515; + xfer += iprot->readListBegin(_etype515, _size512); + this->new_parts.resize(_size512); + uint32_t _i516; + for (_i516 = 0; _i516 < _size512; ++_i516) + { + xfer += this->new_parts[_i516].read(iprot); + } + xfer += iprot->readListEnd(); + } + this->__isset.new_parts = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_add_partitions_pspec_args::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_add_partitions_pspec_args"); + + xfer += oprot->writeFieldBegin("new_parts", ::apache::thrift::protocol::T_LIST, 1); + { + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->new_parts.size())); + std::vector ::const_iterator _iter517; + for (_iter517 = this->new_parts.begin(); _iter517 != this->new_parts.end(); ++_iter517) + { + xfer += (*_iter517).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_add_partitions_pspec_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_add_partitions_pspec_pargs"); + + xfer += oprot->writeFieldBegin("new_parts", ::apache::thrift::protocol::T_LIST, 1); + { + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast((*(this->new_parts)).size())); + std::vector ::const_iterator _iter518; + for (_iter518 = (*(this->new_parts)).begin(); _iter518 != (*(this->new_parts)).end(); ++_iter518) + { + xfer += (*_iter518).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_add_partitions_pspec_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_I32) { + xfer += iprot->readI32(this->success); + 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; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_add_partitions_pspec_result::write(::apache::thrift::protocol::TProtocol* oprot) const { + + uint32_t xfer = 0; + + xfer += oprot->writeStructBegin("ThriftHiveMetastore_add_partitions_pspec_result"); + + if (this->__isset.success) { + xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_I32, 0); + xfer += oprot->writeI32(this->success); + 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(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_add_partitions_pspec_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_I32) { + xfer += iprot->readI32((*(this->success))); + 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; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + uint32_t ThriftHiveMetastore_append_partition_args::read(::apache::thrift::protocol::TProtocol* iprot) { uint32_t xfer = 0; @@ -6342,14 +6592,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size486; - ::apache::thrift::protocol::TType _etype489; - xfer += iprot->readListBegin(_etype489, _size486); - this->part_vals.resize(_size486); - uint32_t _i490; - for (_i490 = 0; _i490 < _size486; ++_i490) + uint32_t _size519; + ::apache::thrift::protocol::TType _etype522; + xfer += iprot->readListBegin(_etype522, _size519); + this->part_vals.resize(_size519); + uint32_t _i523; + for (_i523 = 0; _i523 < _size519; ++_i523) { - xfer += iprot->readString(this->part_vals[_i490]); + xfer += iprot->readString(this->part_vals[_i523]); } xfer += iprot->readListEnd(); } @@ -6385,10 +6635,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 _iter491; - for (_iter491 = this->part_vals.begin(); _iter491 != this->part_vals.end(); ++_iter491) + std::vector ::const_iterator _iter524; + for (_iter524 = this->part_vals.begin(); _iter524 != this->part_vals.end(); ++_iter524) { - xfer += oprot->writeString((*_iter491)); + xfer += oprot->writeString((*_iter524)); } xfer += oprot->writeListEnd(); } @@ -6414,10 +6664,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 _iter492; - for (_iter492 = (*(this->part_vals)).begin(); _iter492 != (*(this->part_vals)).end(); ++_iter492) + std::vector ::const_iterator _iter525; + for (_iter525 = (*(this->part_vals)).begin(); _iter525 != (*(this->part_vals)).end(); ++_iter525) { - xfer += oprot->writeString((*_iter492)); + xfer += oprot->writeString((*_iter525)); } xfer += oprot->writeListEnd(); } @@ -6846,14 +7096,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size493; - ::apache::thrift::protocol::TType _etype496; - xfer += iprot->readListBegin(_etype496, _size493); - this->part_vals.resize(_size493); - uint32_t _i497; - for (_i497 = 0; _i497 < _size493; ++_i497) + uint32_t _size526; + ::apache::thrift::protocol::TType _etype529; + xfer += iprot->readListBegin(_etype529, _size526); + this->part_vals.resize(_size526); + uint32_t _i530; + for (_i530 = 0; _i530 < _size526; ++_i530) { - xfer += iprot->readString(this->part_vals[_i497]); + xfer += iprot->readString(this->part_vals[_i530]); } xfer += iprot->readListEnd(); } @@ -6897,10 +7147,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 _iter498; - for (_iter498 = this->part_vals.begin(); _iter498 != this->part_vals.end(); ++_iter498) + std::vector ::const_iterator _iter531; + for (_iter531 = this->part_vals.begin(); _iter531 != this->part_vals.end(); ++_iter531) { - xfer += oprot->writeString((*_iter498)); + xfer += oprot->writeString((*_iter531)); } xfer += oprot->writeListEnd(); } @@ -6930,10 +7180,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 _iter499; - for (_iter499 = (*(this->part_vals)).begin(); _iter499 != (*(this->part_vals)).end(); ++_iter499) + std::vector ::const_iterator _iter532; + for (_iter532 = (*(this->part_vals)).begin(); _iter532 != (*(this->part_vals)).end(); ++_iter532) { - xfer += oprot->writeString((*_iter499)); + xfer += oprot->writeString((*_iter532)); } xfer += oprot->writeListEnd(); } @@ -7668,14 +7918,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size500; - ::apache::thrift::protocol::TType _etype503; - xfer += iprot->readListBegin(_etype503, _size500); - this->part_vals.resize(_size500); - uint32_t _i504; - for (_i504 = 0; _i504 < _size500; ++_i504) + uint32_t _size533; + ::apache::thrift::protocol::TType _etype536; + xfer += iprot->readListBegin(_etype536, _size533); + this->part_vals.resize(_size533); + uint32_t _i537; + for (_i537 = 0; _i537 < _size533; ++_i537) { - xfer += iprot->readString(this->part_vals[_i504]); + xfer += iprot->readString(this->part_vals[_i537]); } xfer += iprot->readListEnd(); } @@ -7719,10 +7969,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 _iter505; - for (_iter505 = this->part_vals.begin(); _iter505 != this->part_vals.end(); ++_iter505) + std::vector ::const_iterator _iter538; + for (_iter538 = this->part_vals.begin(); _iter538 != this->part_vals.end(); ++_iter538) { - xfer += oprot->writeString((*_iter505)); + xfer += oprot->writeString((*_iter538)); } xfer += oprot->writeListEnd(); } @@ -7752,10 +8002,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 _iter506; - for (_iter506 = (*(this->part_vals)).begin(); _iter506 != (*(this->part_vals)).end(); ++_iter506) + std::vector ::const_iterator _iter539; + for (_iter539 = (*(this->part_vals)).begin(); _iter539 != (*(this->part_vals)).end(); ++_iter539) { - xfer += oprot->writeString((*_iter506)); + xfer += oprot->writeString((*_iter539)); } xfer += oprot->writeListEnd(); } @@ -7946,14 +8196,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size507; - ::apache::thrift::protocol::TType _etype510; - xfer += iprot->readListBegin(_etype510, _size507); - this->part_vals.resize(_size507); - uint32_t _i511; - for (_i511 = 0; _i511 < _size507; ++_i511) + uint32_t _size540; + ::apache::thrift::protocol::TType _etype543; + xfer += iprot->readListBegin(_etype543, _size540); + this->part_vals.resize(_size540); + uint32_t _i544; + for (_i544 = 0; _i544 < _size540; ++_i544) { - xfer += iprot->readString(this->part_vals[_i511]); + xfer += iprot->readString(this->part_vals[_i544]); } xfer += iprot->readListEnd(); } @@ -8005,10 +8255,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 _iter512; - for (_iter512 = this->part_vals.begin(); _iter512 != this->part_vals.end(); ++_iter512) + std::vector ::const_iterator _iter545; + for (_iter545 = this->part_vals.begin(); _iter545 != this->part_vals.end(); ++_iter545) { - xfer += oprot->writeString((*_iter512)); + xfer += oprot->writeString((*_iter545)); } xfer += oprot->writeListEnd(); } @@ -8042,10 +8292,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 _iter513; - for (_iter513 = (*(this->part_vals)).begin(); _iter513 != (*(this->part_vals)).end(); ++_iter513) + std::vector ::const_iterator _iter546; + for (_iter546 = (*(this->part_vals)).begin(); _iter546 != (*(this->part_vals)).end(); ++_iter546) { - xfer += oprot->writeString((*_iter513)); + xfer += oprot->writeString((*_iter546)); } xfer += oprot->writeListEnd(); } @@ -8958,14 +9208,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size514; - ::apache::thrift::protocol::TType _etype517; - xfer += iprot->readListBegin(_etype517, _size514); - this->part_vals.resize(_size514); - uint32_t _i518; - for (_i518 = 0; _i518 < _size514; ++_i518) + uint32_t _size547; + ::apache::thrift::protocol::TType _etype550; + xfer += iprot->readListBegin(_etype550, _size547); + this->part_vals.resize(_size547); + uint32_t _i551; + for (_i551 = 0; _i551 < _size547; ++_i551) { - xfer += iprot->readString(this->part_vals[_i518]); + xfer += iprot->readString(this->part_vals[_i551]); } xfer += iprot->readListEnd(); } @@ -9001,10 +9251,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 _iter519; - for (_iter519 = this->part_vals.begin(); _iter519 != this->part_vals.end(); ++_iter519) + std::vector ::const_iterator _iter552; + for (_iter552 = this->part_vals.begin(); _iter552 != this->part_vals.end(); ++_iter552) { - xfer += oprot->writeString((*_iter519)); + xfer += oprot->writeString((*_iter552)); } xfer += oprot->writeListEnd(); } @@ -9030,10 +9280,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 _iter520; - for (_iter520 = (*(this->part_vals)).begin(); _iter520 != (*(this->part_vals)).end(); ++_iter520) + std::vector ::const_iterator _iter553; + for (_iter553 = (*(this->part_vals)).begin(); _iter553 != (*(this->part_vals)).end(); ++_iter553) { - xfer += oprot->writeString((*_iter520)); + xfer += oprot->writeString((*_iter553)); } xfer += oprot->writeListEnd(); } @@ -9204,17 +9454,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->partitionSpecs.clear(); - uint32_t _size521; - ::apache::thrift::protocol::TType _ktype522; - ::apache::thrift::protocol::TType _vtype523; - xfer += iprot->readMapBegin(_ktype522, _vtype523, _size521); - uint32_t _i525; - for (_i525 = 0; _i525 < _size521; ++_i525) + 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) { - std::string _key526; - xfer += iprot->readString(_key526); - std::string& _val527 = this->partitionSpecs[_key526]; - xfer += iprot->readString(_val527); + std::string _key559; + xfer += iprot->readString(_key559); + std::string& _val560 = this->partitionSpecs[_key559]; + xfer += iprot->readString(_val560); } xfer += iprot->readMapEnd(); } @@ -9274,11 +9524,11 @@ 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 _iter528; - for (_iter528 = this->partitionSpecs.begin(); _iter528 != this->partitionSpecs.end(); ++_iter528) + std::map ::const_iterator _iter561; + for (_iter561 = this->partitionSpecs.begin(); _iter561 != this->partitionSpecs.end(); ++_iter561) { - xfer += oprot->writeString(_iter528->first); - xfer += oprot->writeString(_iter528->second); + xfer += oprot->writeString(_iter561->first); + xfer += oprot->writeString(_iter561->second); } xfer += oprot->writeMapEnd(); } @@ -9312,11 +9562,11 @@ 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 _iter529; - for (_iter529 = (*(this->partitionSpecs)).begin(); _iter529 != (*(this->partitionSpecs)).end(); ++_iter529) + std::map ::const_iterator _iter562; + for (_iter562 = (*(this->partitionSpecs)).begin(); _iter562 != (*(this->partitionSpecs)).end(); ++_iter562) { - xfer += oprot->writeString(_iter529->first); - xfer += oprot->writeString(_iter529->second); + xfer += oprot->writeString(_iter562->first); + xfer += oprot->writeString(_iter562->second); } xfer += oprot->writeMapEnd(); } @@ -9559,14 +9809,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size530; - ::apache::thrift::protocol::TType _etype533; - xfer += iprot->readListBegin(_etype533, _size530); - this->part_vals.resize(_size530); - uint32_t _i534; - for (_i534 = 0; _i534 < _size530; ++_i534) + uint32_t _size563; + ::apache::thrift::protocol::TType _etype566; + xfer += iprot->readListBegin(_etype566, _size563); + this->part_vals.resize(_size563); + uint32_t _i567; + for (_i567 = 0; _i567 < _size563; ++_i567) { - xfer += iprot->readString(this->part_vals[_i534]); + xfer += iprot->readString(this->part_vals[_i567]); } xfer += iprot->readListEnd(); } @@ -9587,14 +9837,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size535; - ::apache::thrift::protocol::TType _etype538; - xfer += iprot->readListBegin(_etype538, _size535); - this->group_names.resize(_size535); - uint32_t _i539; - for (_i539 = 0; _i539 < _size535; ++_i539) + uint32_t _size568; + ::apache::thrift::protocol::TType _etype571; + xfer += iprot->readListBegin(_etype571, _size568); + this->group_names.resize(_size568); + uint32_t _i572; + for (_i572 = 0; _i572 < _size568; ++_i572) { - xfer += iprot->readString(this->group_names[_i539]); + xfer += iprot->readString(this->group_names[_i572]); } xfer += iprot->readListEnd(); } @@ -9630,10 +9880,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 _iter540; - for (_iter540 = this->part_vals.begin(); _iter540 != this->part_vals.end(); ++_iter540) + std::vector ::const_iterator _iter573; + for (_iter573 = this->part_vals.begin(); _iter573 != this->part_vals.end(); ++_iter573) { - xfer += oprot->writeString((*_iter540)); + xfer += oprot->writeString((*_iter573)); } xfer += oprot->writeListEnd(); } @@ -9646,10 +9896,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 _iter541; - for (_iter541 = this->group_names.begin(); _iter541 != this->group_names.end(); ++_iter541) + std::vector ::const_iterator _iter574; + for (_iter574 = this->group_names.begin(); _iter574 != this->group_names.end(); ++_iter574) { - xfer += oprot->writeString((*_iter541)); + xfer += oprot->writeString((*_iter574)); } xfer += oprot->writeListEnd(); } @@ -9675,10 +9925,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 _iter542; - for (_iter542 = (*(this->part_vals)).begin(); _iter542 != (*(this->part_vals)).end(); ++_iter542) + std::vector ::const_iterator _iter575; + for (_iter575 = (*(this->part_vals)).begin(); _iter575 != (*(this->part_vals)).end(); ++_iter575) { - xfer += oprot->writeString((*_iter542)); + xfer += oprot->writeString((*_iter575)); } xfer += oprot->writeListEnd(); } @@ -9691,10 +9941,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 _iter543; - for (_iter543 = (*(this->group_names)).begin(); _iter543 != (*(this->group_names)).end(); ++_iter543) + std::vector ::const_iterator _iter576; + for (_iter576 = (*(this->group_names)).begin(); _iter576 != (*(this->group_names)).end(); ++_iter576) { - xfer += oprot->writeString((*_iter543)); + xfer += oprot->writeString((*_iter576)); } xfer += oprot->writeListEnd(); } @@ -10197,14 +10447,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size544; - ::apache::thrift::protocol::TType _etype547; - xfer += iprot->readListBegin(_etype547, _size544); - this->success.resize(_size544); - uint32_t _i548; - for (_i548 = 0; _i548 < _size544; ++_i548) + uint32_t _size577; + ::apache::thrift::protocol::TType _etype580; + xfer += iprot->readListBegin(_etype580, _size577); + this->success.resize(_size577); + uint32_t _i581; + for (_i581 = 0; _i581 < _size577; ++_i581) { - xfer += this->success[_i548].read(iprot); + xfer += this->success[_i581].read(iprot); } xfer += iprot->readListEnd(); } @@ -10251,10 +10501,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 _iter549; - for (_iter549 = this->success.begin(); _iter549 != this->success.end(); ++_iter549) + std::vector ::const_iterator _iter582; + for (_iter582 = this->success.begin(); _iter582 != this->success.end(); ++_iter582) { - xfer += (*_iter549).write(oprot); + xfer += (*_iter582).write(oprot); } xfer += oprot->writeListEnd(); } @@ -10297,14 +10547,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size550; - ::apache::thrift::protocol::TType _etype553; - xfer += iprot->readListBegin(_etype553, _size550); - (*(this->success)).resize(_size550); - uint32_t _i554; - for (_i554 = 0; _i554 < _size550; ++_i554) + uint32_t _size583; + ::apache::thrift::protocol::TType _etype586; + xfer += iprot->readListBegin(_etype586, _size583); + (*(this->success)).resize(_size583); + uint32_t _i587; + for (_i587 = 0; _i587 < _size583; ++_i587) { - xfer += (*(this->success))[_i554].read(iprot); + xfer += (*(this->success))[_i587].read(iprot); } xfer += iprot->readListEnd(); } @@ -10397,14 +10647,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size555; - ::apache::thrift::protocol::TType _etype558; - xfer += iprot->readListBegin(_etype558, _size555); - this->group_names.resize(_size555); - uint32_t _i559; - for (_i559 = 0; _i559 < _size555; ++_i559) + uint32_t _size588; + ::apache::thrift::protocol::TType _etype591; + xfer += iprot->readListBegin(_etype591, _size588); + this->group_names.resize(_size588); + uint32_t _i592; + for (_i592 = 0; _i592 < _size588; ++_i592) { - xfer += iprot->readString(this->group_names[_i559]); + xfer += iprot->readString(this->group_names[_i592]); } xfer += iprot->readListEnd(); } @@ -10448,10 +10698,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 _iter560; - for (_iter560 = this->group_names.begin(); _iter560 != this->group_names.end(); ++_iter560) + std::vector ::const_iterator _iter593; + for (_iter593 = this->group_names.begin(); _iter593 != this->group_names.end(); ++_iter593) { - xfer += oprot->writeString((*_iter560)); + xfer += oprot->writeString((*_iter593)); } xfer += oprot->writeListEnd(); } @@ -10485,10 +10735,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 _iter561; - for (_iter561 = (*(this->group_names)).begin(); _iter561 != (*(this->group_names)).end(); ++_iter561) + std::vector ::const_iterator _iter594; + for (_iter594 = (*(this->group_names)).begin(); _iter594 != (*(this->group_names)).end(); ++_iter594) { - xfer += oprot->writeString((*_iter561)); + xfer += oprot->writeString((*_iter594)); } xfer += oprot->writeListEnd(); } @@ -10523,14 +10773,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size562; - ::apache::thrift::protocol::TType _etype565; - xfer += iprot->readListBegin(_etype565, _size562); - this->success.resize(_size562); - uint32_t _i566; - for (_i566 = 0; _i566 < _size562; ++_i566) + 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 += this->success[_i566].read(iprot); + xfer += this->success[_i599].read(iprot); } xfer += iprot->readListEnd(); } @@ -10577,10 +10827,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 _iter567; - for (_iter567 = this->success.begin(); _iter567 != this->success.end(); ++_iter567) + std::vector ::const_iterator _iter600; + for (_iter600 = this->success.begin(); _iter600 != this->success.end(); ++_iter600) { - xfer += (*_iter567).write(oprot); + xfer += (*_iter600).write(oprot); } xfer += oprot->writeListEnd(); } @@ -10623,14 +10873,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size568; - ::apache::thrift::protocol::TType _etype571; - xfer += iprot->readListBegin(_etype571, _size568); - (*(this->success)).resize(_size568); - uint32_t _i572; - for (_i572 = 0; _i572 < _size568; ++_i572) + 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 += (*(this->success))[_i572].read(iprot); + xfer += (*(this->success))[_i605].read(iprot); } xfer += iprot->readListEnd(); } @@ -10667,6 +10917,272 @@ return xfer; } +uint32_t ThriftHiveMetastore_get_partitions_pspec_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_STRING) { + xfer += iprot->readString(this->db_name); + this->__isset.db_name = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->tbl_name); + this->__isset.tbl_name = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->max_parts); + this->__isset.max_parts = 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_partitions_pspec_args::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_get_partitions_pspec_args"); + + xfer += oprot->writeFieldBegin("db_name", ::apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString(this->db_name); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("tbl_name", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->tbl_name); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("max_parts", ::apache::thrift::protocol::T_I32, 3); + xfer += oprot->writeI32(this->max_parts); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_get_partitions_pspec_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_get_partitions_pspec_pargs"); + + xfer += oprot->writeFieldBegin("db_name", ::apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString((*(this->db_name))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("tbl_name", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString((*(this->tbl_name))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("max_parts", ::apache::thrift::protocol::T_I32, 3); + xfer += oprot->writeI32((*(this->max_parts))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_get_partitions_pspec_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_LIST) { + { + this->success.clear(); + uint32_t _size606; + ::apache::thrift::protocol::TType _etype609; + xfer += iprot->readListBegin(_etype609, _size606); + this->success.resize(_size606); + uint32_t _i610; + for (_i610 = 0; _i610 < _size606; ++_i610) + { + xfer += this->success[_i610].read(iprot); + } + xfer += iprot->readListEnd(); + } + 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; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_get_partitions_pspec_result::write(::apache::thrift::protocol::TProtocol* oprot) const { + + uint32_t xfer = 0; + + xfer += oprot->writeStructBegin("ThriftHiveMetastore_get_partitions_pspec_result"); + + if (this->__isset.success) { + 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 _iter611; + for (_iter611 = this->success.begin(); _iter611 != this->success.end(); ++_iter611) + { + xfer += (*_iter611).write(oprot); + } + xfer += oprot->writeListEnd(); + } + 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(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_get_partitions_pspec_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_LIST) { + { + (*(this->success)).clear(); + uint32_t _size612; + ::apache::thrift::protocol::TType _etype615; + xfer += iprot->readListBegin(_etype615, _size612); + (*(this->success)).resize(_size612); + uint32_t _i616; + for (_i616 = 0; _i616 < _size612; ++_i616) + { + xfer += (*(this->success))[_i616].read(iprot); + } + xfer += iprot->readListEnd(); + } + 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; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + uint32_t ThriftHiveMetastore_get_partition_names_args::read(::apache::thrift::protocol::TProtocol* iprot) { uint32_t xfer = 0; @@ -10789,14 +11305,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - 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) + uint32_t _size617; + ::apache::thrift::protocol::TType _etype620; + xfer += iprot->readListBegin(_etype620, _size617); + this->success.resize(_size617); + uint32_t _i621; + for (_i621 = 0; _i621 < _size617; ++_i621) { - xfer += iprot->readString(this->success[_i577]); + xfer += iprot->readString(this->success[_i621]); } xfer += iprot->readListEnd(); } @@ -10835,10 +11351,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 _iter578; - for (_iter578 = this->success.begin(); _iter578 != this->success.end(); ++_iter578) + std::vector ::const_iterator _iter622; + for (_iter622 = this->success.begin(); _iter622 != this->success.end(); ++_iter622) { - xfer += oprot->writeString((*_iter578)); + xfer += oprot->writeString((*_iter622)); } xfer += oprot->writeListEnd(); } @@ -10877,14 +11393,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - 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) + uint32_t _size623; + ::apache::thrift::protocol::TType _etype626; + xfer += iprot->readListBegin(_etype626, _size623); + (*(this->success)).resize(_size623); + uint32_t _i627; + for (_i627 = 0; _i627 < _size623; ++_i627) { - xfer += iprot->readString((*(this->success))[_i583]); + xfer += iprot->readString((*(this->success))[_i627]); } xfer += iprot->readListEnd(); } @@ -10953,14 +11469,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size584; - ::apache::thrift::protocol::TType _etype587; - xfer += iprot->readListBegin(_etype587, _size584); - this->part_vals.resize(_size584); - uint32_t _i588; - for (_i588 = 0; _i588 < _size584; ++_i588) + uint32_t _size628; + ::apache::thrift::protocol::TType _etype631; + xfer += iprot->readListBegin(_etype631, _size628); + this->part_vals.resize(_size628); + uint32_t _i632; + for (_i632 = 0; _i632 < _size628; ++_i632) { - xfer += iprot->readString(this->part_vals[_i588]); + xfer += iprot->readString(this->part_vals[_i632]); } xfer += iprot->readListEnd(); } @@ -11004,10 +11520,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 _iter589; - for (_iter589 = this->part_vals.begin(); _iter589 != this->part_vals.end(); ++_iter589) + std::vector ::const_iterator _iter633; + for (_iter633 = this->part_vals.begin(); _iter633 != this->part_vals.end(); ++_iter633) { - xfer += oprot->writeString((*_iter589)); + xfer += oprot->writeString((*_iter633)); } xfer += oprot->writeListEnd(); } @@ -11037,10 +11553,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 _iter590; - for (_iter590 = (*(this->part_vals)).begin(); _iter590 != (*(this->part_vals)).end(); ++_iter590) + std::vector ::const_iterator _iter634; + for (_iter634 = (*(this->part_vals)).begin(); _iter634 != (*(this->part_vals)).end(); ++_iter634) { - xfer += oprot->writeString((*_iter590)); + xfer += oprot->writeString((*_iter634)); } xfer += oprot->writeListEnd(); } @@ -11079,14 +11595,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size591; - ::apache::thrift::protocol::TType _etype594; - xfer += iprot->readListBegin(_etype594, _size591); - this->success.resize(_size591); - uint32_t _i595; - for (_i595 = 0; _i595 < _size591; ++_i595) + 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[_i595].read(iprot); + xfer += this->success[_i639].read(iprot); } xfer += iprot->readListEnd(); } @@ -11133,10 +11649,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 _iter596; - for (_iter596 = this->success.begin(); _iter596 != this->success.end(); ++_iter596) + std::vector ::const_iterator _iter640; + for (_iter640 = this->success.begin(); _iter640 != this->success.end(); ++_iter640) { - xfer += (*_iter596).write(oprot); + xfer += (*_iter640).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11179,14 +11695,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size597; - ::apache::thrift::protocol::TType _etype600; - xfer += iprot->readListBegin(_etype600, _size597); - (*(this->success)).resize(_size597); - uint32_t _i601; - for (_i601 = 0; _i601 < _size597; ++_i601) + uint32_t _size641; + ::apache::thrift::protocol::TType _etype644; + xfer += iprot->readListBegin(_etype644, _size641); + (*(this->success)).resize(_size641); + uint32_t _i645; + for (_i645 = 0; _i645 < _size641; ++_i645) { - xfer += (*(this->success))[_i601].read(iprot); + xfer += (*(this->success))[_i645].read(iprot); } xfer += iprot->readListEnd(); } @@ -11263,14 +11779,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size602; - ::apache::thrift::protocol::TType _etype605; - xfer += iprot->readListBegin(_etype605, _size602); - this->part_vals.resize(_size602); - uint32_t _i606; - for (_i606 = 0; _i606 < _size602; ++_i606) + uint32_t _size646; + ::apache::thrift::protocol::TType _etype649; + xfer += iprot->readListBegin(_etype649, _size646); + this->part_vals.resize(_size646); + uint32_t _i650; + for (_i650 = 0; _i650 < _size646; ++_i650) { - xfer += iprot->readString(this->part_vals[_i606]); + xfer += iprot->readString(this->part_vals[_i650]); } xfer += iprot->readListEnd(); } @@ -11299,14 +11815,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size607; - ::apache::thrift::protocol::TType _etype610; - xfer += iprot->readListBegin(_etype610, _size607); - this->group_names.resize(_size607); - uint32_t _i611; - for (_i611 = 0; _i611 < _size607; ++_i611) + uint32_t _size651; + ::apache::thrift::protocol::TType _etype654; + xfer += iprot->readListBegin(_etype654, _size651); + this->group_names.resize(_size651); + uint32_t _i655; + for (_i655 = 0; _i655 < _size651; ++_i655) { - xfer += iprot->readString(this->group_names[_i611]); + xfer += iprot->readString(this->group_names[_i655]); } xfer += iprot->readListEnd(); } @@ -11342,10 +11858,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 _iter612; - for (_iter612 = this->part_vals.begin(); _iter612 != this->part_vals.end(); ++_iter612) + std::vector ::const_iterator _iter656; + for (_iter656 = this->part_vals.begin(); _iter656 != this->part_vals.end(); ++_iter656) { - xfer += oprot->writeString((*_iter612)); + xfer += oprot->writeString((*_iter656)); } xfer += oprot->writeListEnd(); } @@ -11362,10 +11878,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 _iter613; - for (_iter613 = this->group_names.begin(); _iter613 != this->group_names.end(); ++_iter613) + std::vector ::const_iterator _iter657; + for (_iter657 = this->group_names.begin(); _iter657 != this->group_names.end(); ++_iter657) { - xfer += oprot->writeString((*_iter613)); + xfer += oprot->writeString((*_iter657)); } xfer += oprot->writeListEnd(); } @@ -11391,10 +11907,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 _iter614; - for (_iter614 = (*(this->part_vals)).begin(); _iter614 != (*(this->part_vals)).end(); ++_iter614) + std::vector ::const_iterator _iter658; + for (_iter658 = (*(this->part_vals)).begin(); _iter658 != (*(this->part_vals)).end(); ++_iter658) { - xfer += oprot->writeString((*_iter614)); + xfer += oprot->writeString((*_iter658)); } xfer += oprot->writeListEnd(); } @@ -11411,10 +11927,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 _iter615; - for (_iter615 = (*(this->group_names)).begin(); _iter615 != (*(this->group_names)).end(); ++_iter615) + std::vector ::const_iterator _iter659; + for (_iter659 = (*(this->group_names)).begin(); _iter659 != (*(this->group_names)).end(); ++_iter659) { - xfer += oprot->writeString((*_iter615)); + xfer += oprot->writeString((*_iter659)); } xfer += oprot->writeListEnd(); } @@ -11449,14 +11965,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - 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) + uint32_t _size660; + ::apache::thrift::protocol::TType _etype663; + xfer += iprot->readListBegin(_etype663, _size660); + this->success.resize(_size660); + uint32_t _i664; + for (_i664 = 0; _i664 < _size660; ++_i664) { - xfer += this->success[_i620].read(iprot); + xfer += this->success[_i664].read(iprot); } xfer += iprot->readListEnd(); } @@ -11503,10 +12019,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 _iter621; - for (_iter621 = this->success.begin(); _iter621 != this->success.end(); ++_iter621) + std::vector ::const_iterator _iter665; + for (_iter665 = this->success.begin(); _iter665 != this->success.end(); ++_iter665) { - xfer += (*_iter621).write(oprot); + xfer += (*_iter665).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11549,14 +12065,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size622; - ::apache::thrift::protocol::TType _etype625; - xfer += iprot->readListBegin(_etype625, _size622); - (*(this->success)).resize(_size622); - uint32_t _i626; - for (_i626 = 0; _i626 < _size622; ++_i626) + uint32_t _size666; + ::apache::thrift::protocol::TType _etype669; + xfer += iprot->readListBegin(_etype669, _size666); + (*(this->success)).resize(_size666); + uint32_t _i670; + for (_i670 = 0; _i670 < _size666; ++_i670) { - xfer += (*(this->success))[_i626].read(iprot); + xfer += (*(this->success))[_i670].read(iprot); } xfer += iprot->readListEnd(); } @@ -11633,14 +12149,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size627; - ::apache::thrift::protocol::TType _etype630; - xfer += iprot->readListBegin(_etype630, _size627); - this->part_vals.resize(_size627); - uint32_t _i631; - for (_i631 = 0; _i631 < _size627; ++_i631) + uint32_t _size671; + ::apache::thrift::protocol::TType _etype674; + xfer += iprot->readListBegin(_etype674, _size671); + this->part_vals.resize(_size671); + uint32_t _i675; + for (_i675 = 0; _i675 < _size671; ++_i675) { - xfer += iprot->readString(this->part_vals[_i631]); + xfer += iprot->readString(this->part_vals[_i675]); } xfer += iprot->readListEnd(); } @@ -11684,10 +12200,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 _iter632; - for (_iter632 = this->part_vals.begin(); _iter632 != this->part_vals.end(); ++_iter632) + std::vector ::const_iterator _iter676; + for (_iter676 = this->part_vals.begin(); _iter676 != this->part_vals.end(); ++_iter676) { - xfer += oprot->writeString((*_iter632)); + xfer += oprot->writeString((*_iter676)); } xfer += oprot->writeListEnd(); } @@ -11717,10 +12233,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 _iter633; - for (_iter633 = (*(this->part_vals)).begin(); _iter633 != (*(this->part_vals)).end(); ++_iter633) + std::vector ::const_iterator _iter677; + for (_iter677 = (*(this->part_vals)).begin(); _iter677 != (*(this->part_vals)).end(); ++_iter677) { - xfer += oprot->writeString((*_iter633)); + xfer += oprot->writeString((*_iter677)); } xfer += oprot->writeListEnd(); } @@ -11759,14 +12275,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size634; - ::apache::thrift::protocol::TType _etype637; - xfer += iprot->readListBegin(_etype637, _size634); - this->success.resize(_size634); - uint32_t _i638; - for (_i638 = 0; _i638 < _size634; ++_i638) + uint32_t _size678; + ::apache::thrift::protocol::TType _etype681; + xfer += iprot->readListBegin(_etype681, _size678); + this->success.resize(_size678); + uint32_t _i682; + for (_i682 = 0; _i682 < _size678; ++_i682) { - xfer += iprot->readString(this->success[_i638]); + xfer += iprot->readString(this->success[_i682]); } xfer += iprot->readListEnd(); } @@ -11813,10 +12329,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 _iter639; - for (_iter639 = this->success.begin(); _iter639 != this->success.end(); ++_iter639) + std::vector ::const_iterator _iter683; + for (_iter683 = this->success.begin(); _iter683 != this->success.end(); ++_iter683) { - xfer += oprot->writeString((*_iter639)); + xfer += oprot->writeString((*_iter683)); } xfer += oprot->writeListEnd(); } @@ -11859,14 +12375,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size640; - ::apache::thrift::protocol::TType _etype643; - xfer += iprot->readListBegin(_etype643, _size640); - (*(this->success)).resize(_size640); - uint32_t _i644; - for (_i644 = 0; _i644 < _size640; ++_i644) + uint32_t _size684; + ::apache::thrift::protocol::TType _etype687; + xfer += iprot->readListBegin(_etype687, _size684); + (*(this->success)).resize(_size684); + uint32_t _i688; + for (_i688 = 0; _i688 < _size684; ++_i688) { - xfer += iprot->readString((*(this->success))[_i644]); + xfer += iprot->readString((*(this->success))[_i688]); } xfer += iprot->readListEnd(); } @@ -12041,14 +12557,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size645; - ::apache::thrift::protocol::TType _etype648; - xfer += iprot->readListBegin(_etype648, _size645); - this->success.resize(_size645); - uint32_t _i649; - for (_i649 = 0; _i649 < _size645; ++_i649) + uint32_t _size689; + ::apache::thrift::protocol::TType _etype692; + xfer += iprot->readListBegin(_etype692, _size689); + this->success.resize(_size689); + uint32_t _i693; + for (_i693 = 0; _i693 < _size689; ++_i693) { - xfer += this->success[_i649].read(iprot); + xfer += this->success[_i693].read(iprot); } xfer += iprot->readListEnd(); } @@ -12095,10 +12611,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 _iter650; - for (_iter650 = this->success.begin(); _iter650 != this->success.end(); ++_iter650) + std::vector ::const_iterator _iter694; + for (_iter694 = this->success.begin(); _iter694 != this->success.end(); ++_iter694) { - xfer += (*_iter650).write(oprot); + xfer += (*_iter694).write(oprot); } xfer += oprot->writeListEnd(); } @@ -12141,14 +12657,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size651; - ::apache::thrift::protocol::TType _etype654; - xfer += iprot->readListBegin(_etype654, _size651); - (*(this->success)).resize(_size651); - uint32_t _i655; - for (_i655 = 0; _i655 < _size651; ++_i655) + uint32_t _size695; + ::apache::thrift::protocol::TType _etype698; + xfer += iprot->readListBegin(_etype698, _size695); + (*(this->success)).resize(_size695); + uint32_t _i699; + for (_i699 = 0; _i699 < _size695; ++_i699) { - xfer += (*(this->success))[_i655].read(iprot); + xfer += (*(this->success))[_i699].read(iprot); } xfer += iprot->readListEnd(); } @@ -12185,6 +12701,288 @@ return xfer; } +uint32_t ThriftHiveMetastore_get_part_specs_by_filter_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_STRING) { + xfer += iprot->readString(this->db_name); + this->__isset.db_name = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->tbl_name); + this->__isset.tbl_name = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->filter); + this->__isset.filter = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->max_parts); + this->__isset.max_parts = 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_part_specs_by_filter_args::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_get_part_specs_by_filter_args"); + + xfer += oprot->writeFieldBegin("db_name", ::apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString(this->db_name); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("tbl_name", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->tbl_name); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("filter", ::apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString(this->filter); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("max_parts", ::apache::thrift::protocol::T_I32, 4); + xfer += oprot->writeI32(this->max_parts); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_get_part_specs_by_filter_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_get_part_specs_by_filter_pargs"); + + xfer += oprot->writeFieldBegin("db_name", ::apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString((*(this->db_name))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("tbl_name", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString((*(this->tbl_name))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("filter", ::apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString((*(this->filter))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("max_parts", ::apache::thrift::protocol::T_I32, 4); + xfer += oprot->writeI32((*(this->max_parts))); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_get_part_specs_by_filter_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_LIST) { + { + this->success.clear(); + uint32_t _size700; + ::apache::thrift::protocol::TType _etype703; + xfer += iprot->readListBegin(_etype703, _size700); + this->success.resize(_size700); + uint32_t _i704; + for (_i704 = 0; _i704 < _size700; ++_i704) + { + xfer += this->success[_i704].read(iprot); + } + xfer += iprot->readListEnd(); + } + 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; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_get_part_specs_by_filter_result::write(::apache::thrift::protocol::TProtocol* oprot) const { + + uint32_t xfer = 0; + + xfer += oprot->writeStructBegin("ThriftHiveMetastore_get_part_specs_by_filter_result"); + + if (this->__isset.success) { + 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 _iter705; + for (_iter705 = this->success.begin(); _iter705 != this->success.end(); ++_iter705) + { + xfer += (*_iter705).write(oprot); + } + xfer += oprot->writeListEnd(); + } + 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(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_get_part_specs_by_filter_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_LIST) { + { + (*(this->success)).clear(); + uint32_t _size706; + ::apache::thrift::protocol::TType _etype709; + xfer += iprot->readListBegin(_etype709, _size706); + (*(this->success)).resize(_size706); + uint32_t _i710; + for (_i710 = 0; _i710 < _size706; ++_i710) + { + xfer += (*(this->success))[_i710].read(iprot); + } + xfer += iprot->readListEnd(); + } + 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; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + uint32_t ThriftHiveMetastore_get_partitions_by_expr_args::read(::apache::thrift::protocol::TProtocol* iprot) { uint32_t xfer = 0; @@ -12427,14 +13225,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->names.clear(); - uint32_t _size656; - ::apache::thrift::protocol::TType _etype659; - xfer += iprot->readListBegin(_etype659, _size656); - this->names.resize(_size656); - uint32_t _i660; - for (_i660 = 0; _i660 < _size656; ++_i660) + uint32_t _size711; + ::apache::thrift::protocol::TType _etype714; + xfer += iprot->readListBegin(_etype714, _size711); + this->names.resize(_size711); + uint32_t _i715; + for (_i715 = 0; _i715 < _size711; ++_i715) { - xfer += iprot->readString(this->names[_i660]); + xfer += iprot->readString(this->names[_i715]); } xfer += iprot->readListEnd(); } @@ -12470,10 +13268,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 _iter661; - for (_iter661 = this->names.begin(); _iter661 != this->names.end(); ++_iter661) + std::vector ::const_iterator _iter716; + for (_iter716 = this->names.begin(); _iter716 != this->names.end(); ++_iter716) { - xfer += oprot->writeString((*_iter661)); + xfer += oprot->writeString((*_iter716)); } xfer += oprot->writeListEnd(); } @@ -12499,10 +13297,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 _iter662; - for (_iter662 = (*(this->names)).begin(); _iter662 != (*(this->names)).end(); ++_iter662) + std::vector ::const_iterator _iter717; + for (_iter717 = (*(this->names)).begin(); _iter717 != (*(this->names)).end(); ++_iter717) { - xfer += oprot->writeString((*_iter662)); + xfer += oprot->writeString((*_iter717)); } xfer += oprot->writeListEnd(); } @@ -12537,14 +13335,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size663; - ::apache::thrift::protocol::TType _etype666; - xfer += iprot->readListBegin(_etype666, _size663); - this->success.resize(_size663); - uint32_t _i667; - for (_i667 = 0; _i667 < _size663; ++_i667) + uint32_t _size718; + ::apache::thrift::protocol::TType _etype721; + xfer += iprot->readListBegin(_etype721, _size718); + this->success.resize(_size718); + uint32_t _i722; + for (_i722 = 0; _i722 < _size718; ++_i722) { - xfer += this->success[_i667].read(iprot); + xfer += this->success[_i722].read(iprot); } xfer += iprot->readListEnd(); } @@ -12591,10 +13389,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 _iter668; - for (_iter668 = this->success.begin(); _iter668 != this->success.end(); ++_iter668) + std::vector ::const_iterator _iter723; + for (_iter723 = this->success.begin(); _iter723 != this->success.end(); ++_iter723) { - xfer += (*_iter668).write(oprot); + xfer += (*_iter723).write(oprot); } xfer += oprot->writeListEnd(); } @@ -12637,14 +13435,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size669; - ::apache::thrift::protocol::TType _etype672; - xfer += iprot->readListBegin(_etype672, _size669); - (*(this->success)).resize(_size669); - uint32_t _i673; - for (_i673 = 0; _i673 < _size669; ++_i673) + uint32_t _size724; + ::apache::thrift::protocol::TType _etype727; + xfer += iprot->readListBegin(_etype727, _size724); + (*(this->success)).resize(_size724); + uint32_t _i728; + for (_i728 = 0; _i728 < _size724; ++_i728) { - xfer += (*(this->success))[_i673].read(iprot); + xfer += (*(this->success))[_i728].read(iprot); } xfer += iprot->readListEnd(); } @@ -12935,14 +13733,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->new_parts.clear(); - uint32_t _size674; - ::apache::thrift::protocol::TType _etype677; - xfer += iprot->readListBegin(_etype677, _size674); - this->new_parts.resize(_size674); - uint32_t _i678; - for (_i678 = 0; _i678 < _size674; ++_i678) + uint32_t _size729; + ::apache::thrift::protocol::TType _etype732; + xfer += iprot->readListBegin(_etype732, _size729); + this->new_parts.resize(_size729); + uint32_t _i733; + for (_i733 = 0; _i733 < _size729; ++_i733) { - xfer += this->new_parts[_i678].read(iprot); + xfer += this->new_parts[_i733].read(iprot); } xfer += iprot->readListEnd(); } @@ -12978,10 +13776,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 _iter679; - for (_iter679 = this->new_parts.begin(); _iter679 != this->new_parts.end(); ++_iter679) + std::vector ::const_iterator _iter734; + for (_iter734 = this->new_parts.begin(); _iter734 != this->new_parts.end(); ++_iter734) { - xfer += (*_iter679).write(oprot); + xfer += (*_iter734).write(oprot); } xfer += oprot->writeListEnd(); } @@ -13007,10 +13805,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 _iter680; - for (_iter680 = (*(this->new_parts)).begin(); _iter680 != (*(this->new_parts)).end(); ++_iter680) + std::vector ::const_iterator _iter735; + for (_iter735 = (*(this->new_parts)).begin(); _iter735 != (*(this->new_parts)).end(); ++_iter735) { - xfer += (*_iter680).write(oprot); + xfer += (*_iter735).write(oprot); } xfer += oprot->writeListEnd(); } @@ -13407,14 +14205,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size681; - ::apache::thrift::protocol::TType _etype684; - xfer += iprot->readListBegin(_etype684, _size681); - this->part_vals.resize(_size681); - uint32_t _i685; - for (_i685 = 0; _i685 < _size681; ++_i685) + uint32_t _size736; + ::apache::thrift::protocol::TType _etype739; + xfer += iprot->readListBegin(_etype739, _size736); + this->part_vals.resize(_size736); + uint32_t _i740; + for (_i740 = 0; _i740 < _size736; ++_i740) { - xfer += iprot->readString(this->part_vals[_i685]); + xfer += iprot->readString(this->part_vals[_i740]); } xfer += iprot->readListEnd(); } @@ -13458,10 +14256,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 _iter686; - for (_iter686 = this->part_vals.begin(); _iter686 != this->part_vals.end(); ++_iter686) + std::vector ::const_iterator _iter741; + for (_iter741 = this->part_vals.begin(); _iter741 != this->part_vals.end(); ++_iter741) { - xfer += oprot->writeString((*_iter686)); + xfer += oprot->writeString((*_iter741)); } xfer += oprot->writeListEnd(); } @@ -13491,10 +14289,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 _iter687; - for (_iter687 = (*(this->part_vals)).begin(); _iter687 != (*(this->part_vals)).end(); ++_iter687) + std::vector ::const_iterator _iter742; + for (_iter742 = (*(this->part_vals)).begin(); _iter742 != (*(this->part_vals)).end(); ++_iter742) { - xfer += oprot->writeString((*_iter687)); + xfer += oprot->writeString((*_iter742)); } xfer += oprot->writeListEnd(); } @@ -13649,14 +14447,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size688; - ::apache::thrift::protocol::TType _etype691; - xfer += iprot->readListBegin(_etype691, _size688); - this->part_vals.resize(_size688); - uint32_t _i692; - for (_i692 = 0; _i692 < _size688; ++_i692) + uint32_t _size743; + ::apache::thrift::protocol::TType _etype746; + xfer += iprot->readListBegin(_etype746, _size743); + this->part_vals.resize(_size743); + uint32_t _i747; + for (_i747 = 0; _i747 < _size743; ++_i747) { - xfer += iprot->readString(this->part_vals[_i692]); + xfer += iprot->readString(this->part_vals[_i747]); } xfer += iprot->readListEnd(); } @@ -13692,10 +14490,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 _iter693; - for (_iter693 = this->part_vals.begin(); _iter693 != this->part_vals.end(); ++_iter693) + std::vector ::const_iterator _iter748; + for (_iter748 = this->part_vals.begin(); _iter748 != this->part_vals.end(); ++_iter748) { - xfer += oprot->writeString((*_iter693)); + xfer += oprot->writeString((*_iter748)); } xfer += oprot->writeListEnd(); } @@ -13717,10 +14515,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 _iter694; - for (_iter694 = (*(this->part_vals)).begin(); _iter694 != (*(this->part_vals)).end(); ++_iter694) + std::vector ::const_iterator _iter749; + for (_iter749 = (*(this->part_vals)).begin(); _iter749 != (*(this->part_vals)).end(); ++_iter749) { - xfer += oprot->writeString((*_iter694)); + xfer += oprot->writeString((*_iter749)); } xfer += oprot->writeListEnd(); } @@ -14139,14 +14937,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size695; - ::apache::thrift::protocol::TType _etype698; - xfer += iprot->readListBegin(_etype698, _size695); - this->success.resize(_size695); - uint32_t _i699; - for (_i699 = 0; _i699 < _size695; ++_i699) + uint32_t _size750; + ::apache::thrift::protocol::TType _etype753; + xfer += iprot->readListBegin(_etype753, _size750); + this->success.resize(_size750); + uint32_t _i754; + for (_i754 = 0; _i754 < _size750; ++_i754) { - xfer += iprot->readString(this->success[_i699]); + xfer += iprot->readString(this->success[_i754]); } xfer += iprot->readListEnd(); } @@ -14185,10 +14983,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 _iter700; - for (_iter700 = this->success.begin(); _iter700 != this->success.end(); ++_iter700) + std::vector ::const_iterator _iter755; + for (_iter755 = this->success.begin(); _iter755 != this->success.end(); ++_iter755) { - xfer += oprot->writeString((*_iter700)); + xfer += oprot->writeString((*_iter755)); } xfer += oprot->writeListEnd(); } @@ -14227,14 +15025,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size701; - ::apache::thrift::protocol::TType _etype704; - xfer += iprot->readListBegin(_etype704, _size701); - (*(this->success)).resize(_size701); - uint32_t _i705; - for (_i705 = 0; _i705 < _size701; ++_i705) + uint32_t _size756; + ::apache::thrift::protocol::TType _etype759; + xfer += iprot->readListBegin(_etype759, _size756); + (*(this->success)).resize(_size756); + uint32_t _i760; + for (_i760 = 0; _i760 < _size756; ++_i760) { - xfer += iprot->readString((*(this->success))[_i705]); + xfer += iprot->readString((*(this->success))[_i760]); } xfer += iprot->readListEnd(); } @@ -14353,17 +15151,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->success.clear(); - uint32_t _size706; - ::apache::thrift::protocol::TType _ktype707; - ::apache::thrift::protocol::TType _vtype708; - xfer += iprot->readMapBegin(_ktype707, _vtype708, _size706); - uint32_t _i710; - for (_i710 = 0; _i710 < _size706; ++_i710) + uint32_t _size761; + ::apache::thrift::protocol::TType _ktype762; + ::apache::thrift::protocol::TType _vtype763; + xfer += iprot->readMapBegin(_ktype762, _vtype763, _size761); + uint32_t _i765; + for (_i765 = 0; _i765 < _size761; ++_i765) { - std::string _key711; - xfer += iprot->readString(_key711); - std::string& _val712 = this->success[_key711]; - xfer += iprot->readString(_val712); + std::string _key766; + xfer += iprot->readString(_key766); + std::string& _val767 = this->success[_key766]; + xfer += iprot->readString(_val767); } xfer += iprot->readMapEnd(); } @@ -14402,11 +15200,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 _iter713; - for (_iter713 = this->success.begin(); _iter713 != this->success.end(); ++_iter713) + std::map ::const_iterator _iter768; + for (_iter768 = this->success.begin(); _iter768 != this->success.end(); ++_iter768) { - xfer += oprot->writeString(_iter713->first); - xfer += oprot->writeString(_iter713->second); + xfer += oprot->writeString(_iter768->first); + xfer += oprot->writeString(_iter768->second); } xfer += oprot->writeMapEnd(); } @@ -14445,17 +15243,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { (*(this->success)).clear(); - uint32_t _size714; - ::apache::thrift::protocol::TType _ktype715; - ::apache::thrift::protocol::TType _vtype716; - xfer += iprot->readMapBegin(_ktype715, _vtype716, _size714); - uint32_t _i718; - for (_i718 = 0; _i718 < _size714; ++_i718) + uint32_t _size769; + ::apache::thrift::protocol::TType _ktype770; + ::apache::thrift::protocol::TType _vtype771; + xfer += iprot->readMapBegin(_ktype770, _vtype771, _size769); + uint32_t _i773; + for (_i773 = 0; _i773 < _size769; ++_i773) { - std::string _key719; - xfer += iprot->readString(_key719); - std::string& _val720 = (*(this->success))[_key719]; - xfer += iprot->readString(_val720); + std::string _key774; + xfer += iprot->readString(_key774); + std::string& _val775 = (*(this->success))[_key774]; + xfer += iprot->readString(_val775); } xfer += iprot->readMapEnd(); } @@ -14524,17 +15322,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->part_vals.clear(); - uint32_t _size721; - ::apache::thrift::protocol::TType _ktype722; - ::apache::thrift::protocol::TType _vtype723; - xfer += iprot->readMapBegin(_ktype722, _vtype723, _size721); - uint32_t _i725; - for (_i725 = 0; _i725 < _size721; ++_i725) + uint32_t _size776; + ::apache::thrift::protocol::TType _ktype777; + ::apache::thrift::protocol::TType _vtype778; + xfer += iprot->readMapBegin(_ktype777, _vtype778, _size776); + uint32_t _i780; + for (_i780 = 0; _i780 < _size776; ++_i780) { - std::string _key726; - xfer += iprot->readString(_key726); - std::string& _val727 = this->part_vals[_key726]; - xfer += iprot->readString(_val727); + std::string _key781; + xfer += iprot->readString(_key781); + std::string& _val782 = this->part_vals[_key781]; + xfer += iprot->readString(_val782); } xfer += iprot->readMapEnd(); } @@ -14545,9 +15343,9 @@ break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast728; - xfer += iprot->readI32(ecast728); - this->eventType = (PartitionEventType::type)ecast728; + int32_t ecast783; + xfer += iprot->readI32(ecast783); + this->eventType = (PartitionEventType::type)ecast783; this->__isset.eventType = true; } else { xfer += iprot->skip(ftype); @@ -14580,11 +15378,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 _iter729; - for (_iter729 = this->part_vals.begin(); _iter729 != this->part_vals.end(); ++_iter729) + std::map ::const_iterator _iter784; + for (_iter784 = this->part_vals.begin(); _iter784 != this->part_vals.end(); ++_iter784) { - xfer += oprot->writeString(_iter729->first); - xfer += oprot->writeString(_iter729->second); + xfer += oprot->writeString(_iter784->first); + xfer += oprot->writeString(_iter784->second); } xfer += oprot->writeMapEnd(); } @@ -14614,11 +15412,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 _iter730; - for (_iter730 = (*(this->part_vals)).begin(); _iter730 != (*(this->part_vals)).end(); ++_iter730) + std::map ::const_iterator _iter785; + for (_iter785 = (*(this->part_vals)).begin(); _iter785 != (*(this->part_vals)).end(); ++_iter785) { - xfer += oprot->writeString(_iter730->first); - xfer += oprot->writeString(_iter730->second); + xfer += oprot->writeString(_iter785->first); + xfer += oprot->writeString(_iter785->second); } xfer += oprot->writeMapEnd(); } @@ -14869,17 +15667,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->part_vals.clear(); - uint32_t _size731; - ::apache::thrift::protocol::TType _ktype732; - ::apache::thrift::protocol::TType _vtype733; - xfer += iprot->readMapBegin(_ktype732, _vtype733, _size731); - uint32_t _i735; - for (_i735 = 0; _i735 < _size731; ++_i735) + uint32_t _size786; + ::apache::thrift::protocol::TType _ktype787; + ::apache::thrift::protocol::TType _vtype788; + xfer += iprot->readMapBegin(_ktype787, _vtype788, _size786); + uint32_t _i790; + for (_i790 = 0; _i790 < _size786; ++_i790) { - std::string _key736; - xfer += iprot->readString(_key736); - std::string& _val737 = this->part_vals[_key736]; - xfer += iprot->readString(_val737); + std::string _key791; + xfer += iprot->readString(_key791); + std::string& _val792 = this->part_vals[_key791]; + xfer += iprot->readString(_val792); } xfer += iprot->readMapEnd(); } @@ -14890,9 +15688,9 @@ break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast738; - xfer += iprot->readI32(ecast738); - this->eventType = (PartitionEventType::type)ecast738; + int32_t ecast793; + xfer += iprot->readI32(ecast793); + this->eventType = (PartitionEventType::type)ecast793; this->__isset.eventType = true; } else { xfer += iprot->skip(ftype); @@ -14925,11 +15723,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 _iter739; - for (_iter739 = this->part_vals.begin(); _iter739 != this->part_vals.end(); ++_iter739) + std::map ::const_iterator _iter794; + for (_iter794 = this->part_vals.begin(); _iter794 != this->part_vals.end(); ++_iter794) { - xfer += oprot->writeString(_iter739->first); - xfer += oprot->writeString(_iter739->second); + xfer += oprot->writeString(_iter794->first); + xfer += oprot->writeString(_iter794->second); } xfer += oprot->writeMapEnd(); } @@ -14959,11 +15757,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 _iter740; - for (_iter740 = (*(this->part_vals)).begin(); _iter740 != (*(this->part_vals)).end(); ++_iter740) + std::map ::const_iterator _iter795; + for (_iter795 = (*(this->part_vals)).begin(); _iter795 != (*(this->part_vals)).end(); ++_iter795) { - xfer += oprot->writeString(_iter740->first); - xfer += oprot->writeString(_iter740->second); + xfer += oprot->writeString(_iter795->first); + xfer += oprot->writeString(_iter795->second); } xfer += oprot->writeMapEnd(); } @@ -16268,14 +17066,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size741; - ::apache::thrift::protocol::TType _etype744; - xfer += iprot->readListBegin(_etype744, _size741); - this->success.resize(_size741); - uint32_t _i745; - for (_i745 = 0; _i745 < _size741; ++_i745) + uint32_t _size796; + ::apache::thrift::protocol::TType _etype799; + xfer += iprot->readListBegin(_etype799, _size796); + this->success.resize(_size796); + uint32_t _i800; + for (_i800 = 0; _i800 < _size796; ++_i800) { - xfer += this->success[_i745].read(iprot); + xfer += this->success[_i800].read(iprot); } xfer += iprot->readListEnd(); } @@ -16322,10 +17120,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 _iter746; - for (_iter746 = this->success.begin(); _iter746 != this->success.end(); ++_iter746) + std::vector ::const_iterator _iter801; + for (_iter801 = this->success.begin(); _iter801 != this->success.end(); ++_iter801) { - xfer += (*_iter746).write(oprot); + xfer += (*_iter801).write(oprot); } xfer += oprot->writeListEnd(); } @@ -16368,14 +17166,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size747; - ::apache::thrift::protocol::TType _etype750; - xfer += iprot->readListBegin(_etype750, _size747); - (*(this->success)).resize(_size747); - uint32_t _i751; - for (_i751 = 0; _i751 < _size747; ++_i751) + uint32_t _size802; + ::apache::thrift::protocol::TType _etype805; + xfer += iprot->readListBegin(_etype805, _size802); + (*(this->success)).resize(_size802); + uint32_t _i806; + for (_i806 = 0; _i806 < _size802; ++_i806) { - xfer += (*(this->success))[_i751].read(iprot); + xfer += (*(this->success))[_i806].read(iprot); } xfer += iprot->readListEnd(); } @@ -16534,14 +17332,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size752; - ::apache::thrift::protocol::TType _etype755; - xfer += iprot->readListBegin(_etype755, _size752); - this->success.resize(_size752); - uint32_t _i756; - for (_i756 = 0; _i756 < _size752; ++_i756) + uint32_t _size807; + ::apache::thrift::protocol::TType _etype810; + xfer += iprot->readListBegin(_etype810, _size807); + this->success.resize(_size807); + uint32_t _i811; + for (_i811 = 0; _i811 < _size807; ++_i811) { - xfer += iprot->readString(this->success[_i756]); + xfer += iprot->readString(this->success[_i811]); } xfer += iprot->readListEnd(); } @@ -16580,10 +17378,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 _iter757; - for (_iter757 = this->success.begin(); _iter757 != this->success.end(); ++_iter757) + std::vector ::const_iterator _iter812; + for (_iter812 = this->success.begin(); _iter812 != this->success.end(); ++_iter812) { - xfer += oprot->writeString((*_iter757)); + xfer += oprot->writeString((*_iter812)); } xfer += oprot->writeListEnd(); } @@ -16622,14 +17420,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size758; - ::apache::thrift::protocol::TType _etype761; - xfer += iprot->readListBegin(_etype761, _size758); - (*(this->success)).resize(_size758); - uint32_t _i762; - for (_i762 = 0; _i762 < _size758; ++_i762) + uint32_t _size813; + ::apache::thrift::protocol::TType _etype816; + xfer += iprot->readListBegin(_etype816, _size813); + (*(this->success)).resize(_size813); + uint32_t _i817; + for (_i817 = 0; _i817 < _size813; ++_i817) { - xfer += iprot->readString((*(this->success))[_i762]); + xfer += iprot->readString((*(this->success))[_i817]); } xfer += iprot->readListEnd(); } @@ -19616,14 +20414,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size763; - ::apache::thrift::protocol::TType _etype766; - xfer += iprot->readListBegin(_etype766, _size763); - this->success.resize(_size763); - uint32_t _i767; - for (_i767 = 0; _i767 < _size763; ++_i767) + uint32_t _size818; + ::apache::thrift::protocol::TType _etype821; + xfer += iprot->readListBegin(_etype821, _size818); + this->success.resize(_size818); + uint32_t _i822; + for (_i822 = 0; _i822 < _size818; ++_i822) { - xfer += iprot->readString(this->success[_i767]); + xfer += iprot->readString(this->success[_i822]); } xfer += iprot->readListEnd(); } @@ -19662,10 +20460,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 _iter768; - for (_iter768 = this->success.begin(); _iter768 != this->success.end(); ++_iter768) + std::vector ::const_iterator _iter823; + for (_iter823 = this->success.begin(); _iter823 != this->success.end(); ++_iter823) { - xfer += oprot->writeString((*_iter768)); + xfer += oprot->writeString((*_iter823)); } xfer += oprot->writeListEnd(); } @@ -19704,14 +20502,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size769; - ::apache::thrift::protocol::TType _etype772; - xfer += iprot->readListBegin(_etype772, _size769); - (*(this->success)).resize(_size769); - uint32_t _i773; - for (_i773 = 0; _i773 < _size769; ++_i773) + uint32_t _size824; + ::apache::thrift::protocol::TType _etype827; + xfer += iprot->readListBegin(_etype827, _size824); + (*(this->success)).resize(_size824); + uint32_t _i828; + for (_i828 = 0; _i828 < _size824; ++_i828) { - xfer += iprot->readString((*(this->success))[_i773]); + xfer += iprot->readString((*(this->success))[_i828]); } xfer += iprot->readListEnd(); } @@ -20391,14 +21189,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size774; - ::apache::thrift::protocol::TType _etype777; - xfer += iprot->readListBegin(_etype777, _size774); - this->success.resize(_size774); - uint32_t _i778; - for (_i778 = 0; _i778 < _size774; ++_i778) + uint32_t _size829; + ::apache::thrift::protocol::TType _etype832; + xfer += iprot->readListBegin(_etype832, _size829); + this->success.resize(_size829); + uint32_t _i833; + for (_i833 = 0; _i833 < _size829; ++_i833) { - xfer += iprot->readString(this->success[_i778]); + xfer += iprot->readString(this->success[_i833]); } xfer += iprot->readListEnd(); } @@ -20437,10 +21235,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 _iter779; - for (_iter779 = this->success.begin(); _iter779 != this->success.end(); ++_iter779) + std::vector ::const_iterator _iter834; + for (_iter834 = this->success.begin(); _iter834 != this->success.end(); ++_iter834) { - xfer += oprot->writeString((*_iter779)); + xfer += oprot->writeString((*_iter834)); } xfer += oprot->writeListEnd(); } @@ -20479,14 +21277,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size780; - ::apache::thrift::protocol::TType _etype783; - xfer += iprot->readListBegin(_etype783, _size780); - (*(this->success)).resize(_size780); - uint32_t _i784; - for (_i784 = 0; _i784 < _size780; ++_i784) + uint32_t _size835; + ::apache::thrift::protocol::TType _etype838; + xfer += iprot->readListBegin(_etype838, _size835); + (*(this->success)).resize(_size835); + uint32_t _i839; + for (_i839 = 0; _i839 < _size835; ++_i839) { - xfer += iprot->readString((*(this->success))[_i784]); + xfer += iprot->readString((*(this->success))[_i839]); } xfer += iprot->readListEnd(); } @@ -20553,9 +21351,9 @@ break; case 3: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast785; - xfer += iprot->readI32(ecast785); - this->principal_type = (PrincipalType::type)ecast785; + int32_t ecast840; + xfer += iprot->readI32(ecast840); + this->principal_type = (PrincipalType::type)ecast840; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -20571,9 +21369,9 @@ break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast786; - xfer += iprot->readI32(ecast786); - this->grantorType = (PrincipalType::type)ecast786; + int32_t ecast841; + xfer += iprot->readI32(ecast841); + this->grantorType = (PrincipalType::type)ecast841; this->__isset.grantorType = true; } else { xfer += iprot->skip(ftype); @@ -20819,9 +21617,9 @@ break; case 3: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast787; - xfer += iprot->readI32(ecast787); - this->principal_type = (PrincipalType::type)ecast787; + int32_t ecast842; + xfer += iprot->readI32(ecast842); + this->principal_type = (PrincipalType::type)ecast842; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -21027,9 +21825,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast788; - xfer += iprot->readI32(ecast788); - this->principal_type = (PrincipalType::type)ecast788; + int32_t ecast843; + xfer += iprot->readI32(ecast843); + this->principal_type = (PrincipalType::type)ecast843; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -21105,14 +21903,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size789; - ::apache::thrift::protocol::TType _etype792; - xfer += iprot->readListBegin(_etype792, _size789); - this->success.resize(_size789); - uint32_t _i793; - for (_i793 = 0; _i793 < _size789; ++_i793) + uint32_t _size844; + ::apache::thrift::protocol::TType _etype847; + xfer += iprot->readListBegin(_etype847, _size844); + this->success.resize(_size844); + uint32_t _i848; + for (_i848 = 0; _i848 < _size844; ++_i848) { - xfer += this->success[_i793].read(iprot); + xfer += this->success[_i848].read(iprot); } xfer += iprot->readListEnd(); } @@ -21151,10 +21949,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 _iter794; - for (_iter794 = this->success.begin(); _iter794 != this->success.end(); ++_iter794) + std::vector ::const_iterator _iter849; + for (_iter849 = this->success.begin(); _iter849 != this->success.end(); ++_iter849) { - xfer += (*_iter794).write(oprot); + xfer += (*_iter849).write(oprot); } xfer += oprot->writeListEnd(); } @@ -21193,14 +21991,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size795; - ::apache::thrift::protocol::TType _etype798; - xfer += iprot->readListBegin(_etype798, _size795); - (*(this->success)).resize(_size795); - uint32_t _i799; - for (_i799 = 0; _i799 < _size795; ++_i799) + uint32_t _size850; + ::apache::thrift::protocol::TType _etype853; + xfer += iprot->readListBegin(_etype853, _size850); + (*(this->success)).resize(_size850); + uint32_t _i854; + for (_i854 = 0; _i854 < _size850; ++_i854) { - xfer += (*(this->success))[_i799].read(iprot); + xfer += (*(this->success))[_i854].read(iprot); } xfer += iprot->readListEnd(); } @@ -21815,14 +22613,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size800; - ::apache::thrift::protocol::TType _etype803; - xfer += iprot->readListBegin(_etype803, _size800); - this->group_names.resize(_size800); - uint32_t _i804; - for (_i804 = 0; _i804 < _size800; ++_i804) + uint32_t _size855; + ::apache::thrift::protocol::TType _etype858; + xfer += iprot->readListBegin(_etype858, _size855); + this->group_names.resize(_size855); + uint32_t _i859; + for (_i859 = 0; _i859 < _size855; ++_i859) { - xfer += iprot->readString(this->group_names[_i804]); + xfer += iprot->readString(this->group_names[_i859]); } xfer += iprot->readListEnd(); } @@ -21858,10 +22656,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 _iter805; - for (_iter805 = this->group_names.begin(); _iter805 != this->group_names.end(); ++_iter805) + std::vector ::const_iterator _iter860; + for (_iter860 = this->group_names.begin(); _iter860 != this->group_names.end(); ++_iter860) { - xfer += oprot->writeString((*_iter805)); + xfer += oprot->writeString((*_iter860)); } xfer += oprot->writeListEnd(); } @@ -21887,10 +22685,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 _iter806; - for (_iter806 = (*(this->group_names)).begin(); _iter806 != (*(this->group_names)).end(); ++_iter806) + std::vector ::const_iterator _iter861; + for (_iter861 = (*(this->group_names)).begin(); _iter861 != (*(this->group_names)).end(); ++_iter861) { - xfer += oprot->writeString((*_iter806)); + xfer += oprot->writeString((*_iter861)); } xfer += oprot->writeListEnd(); } @@ -22047,9 +22845,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast807; - xfer += iprot->readI32(ecast807); - this->principal_type = (PrincipalType::type)ecast807; + int32_t ecast862; + xfer += iprot->readI32(ecast862); + this->principal_type = (PrincipalType::type)ecast862; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -22141,14 +22939,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size808; - ::apache::thrift::protocol::TType _etype811; - xfer += iprot->readListBegin(_etype811, _size808); - this->success.resize(_size808); - uint32_t _i812; - for (_i812 = 0; _i812 < _size808; ++_i812) + uint32_t _size863; + ::apache::thrift::protocol::TType _etype866; + xfer += iprot->readListBegin(_etype866, _size863); + this->success.resize(_size863); + uint32_t _i867; + for (_i867 = 0; _i867 < _size863; ++_i867) { - xfer += this->success[_i812].read(iprot); + xfer += this->success[_i867].read(iprot); } xfer += iprot->readListEnd(); } @@ -22187,10 +22985,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 _iter813; - for (_iter813 = this->success.begin(); _iter813 != this->success.end(); ++_iter813) + std::vector ::const_iterator _iter868; + for (_iter868 = this->success.begin(); _iter868 != this->success.end(); ++_iter868) { - xfer += (*_iter813).write(oprot); + xfer += (*_iter868).write(oprot); } xfer += oprot->writeListEnd(); } @@ -22229,14 +23027,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size814; - ::apache::thrift::protocol::TType _etype817; - xfer += iprot->readListBegin(_etype817, _size814); - (*(this->success)).resize(_size814); - uint32_t _i818; - for (_i818 = 0; _i818 < _size814; ++_i818) + uint32_t _size869; + ::apache::thrift::protocol::TType _etype872; + xfer += iprot->readListBegin(_etype872, _size869); + (*(this->success)).resize(_size869); + uint32_t _i873; + for (_i873 = 0; _i873 < _size869; ++_i873) { - xfer += (*(this->success))[_i818].read(iprot); + xfer += (*(this->success))[_i873].read(iprot); } xfer += iprot->readListEnd(); } @@ -22843,14 +23641,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size819; - ::apache::thrift::protocol::TType _etype822; - xfer += iprot->readListBegin(_etype822, _size819); - this->group_names.resize(_size819); - uint32_t _i823; - for (_i823 = 0; _i823 < _size819; ++_i823) + uint32_t _size874; + ::apache::thrift::protocol::TType _etype877; + xfer += iprot->readListBegin(_etype877, _size874); + this->group_names.resize(_size874); + uint32_t _i878; + for (_i878 = 0; _i878 < _size874; ++_i878) { - xfer += iprot->readString(this->group_names[_i823]); + xfer += iprot->readString(this->group_names[_i878]); } xfer += iprot->readListEnd(); } @@ -22882,10 +23680,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 _iter824; - for (_iter824 = this->group_names.begin(); _iter824 != this->group_names.end(); ++_iter824) + std::vector ::const_iterator _iter879; + for (_iter879 = this->group_names.begin(); _iter879 != this->group_names.end(); ++_iter879) { - xfer += oprot->writeString((*_iter824)); + xfer += oprot->writeString((*_iter879)); } xfer += oprot->writeListEnd(); } @@ -22907,10 +23705,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 _iter825; - for (_iter825 = (*(this->group_names)).begin(); _iter825 != (*(this->group_names)).end(); ++_iter825) + std::vector ::const_iterator _iter880; + for (_iter880 = (*(this->group_names)).begin(); _iter880 != (*(this->group_names)).end(); ++_iter880) { - xfer += oprot->writeString((*_iter825)); + xfer += oprot->writeString((*_iter880)); } xfer += oprot->writeListEnd(); } @@ -22945,14 +23743,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size826; - ::apache::thrift::protocol::TType _etype829; - xfer += iprot->readListBegin(_etype829, _size826); - this->success.resize(_size826); - uint32_t _i830; - for (_i830 = 0; _i830 < _size826; ++_i830) + uint32_t _size881; + ::apache::thrift::protocol::TType _etype884; + xfer += iprot->readListBegin(_etype884, _size881); + this->success.resize(_size881); + uint32_t _i885; + for (_i885 = 0; _i885 < _size881; ++_i885) { - xfer += iprot->readString(this->success[_i830]); + xfer += iprot->readString(this->success[_i885]); } xfer += iprot->readListEnd(); } @@ -22991,10 +23789,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 _iter831; - for (_iter831 = this->success.begin(); _iter831 != this->success.end(); ++_iter831) + std::vector ::const_iterator _iter886; + for (_iter886 = this->success.begin(); _iter886 != this->success.end(); ++_iter886) { - xfer += oprot->writeString((*_iter831)); + xfer += oprot->writeString((*_iter886)); } xfer += oprot->writeListEnd(); } @@ -23033,14 +23831,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size832; - ::apache::thrift::protocol::TType _etype835; - xfer += iprot->readListBegin(_etype835, _size832); - (*(this->success)).resize(_size832); - uint32_t _i836; - for (_i836 = 0; _i836 < _size832; ++_i836) + uint32_t _size887; + ::apache::thrift::protocol::TType _etype890; + xfer += iprot->readListBegin(_etype890, _size887); + (*(this->success)).resize(_size887); + uint32_t _i891; + for (_i891 = 0; _i891 < _size887; ++_i891) { - xfer += iprot->readString((*(this->success))[_i836]); + xfer += iprot->readString((*(this->success))[_i891]); } xfer += iprot->readListEnd(); } @@ -27609,6 +28407,73 @@ throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "add_partitions failed: unknown result"); } +int32_t ThriftHiveMetastoreClient::add_partitions_pspec(const std::vector & new_parts) +{ + send_add_partitions_pspec(new_parts); + return recv_add_partitions_pspec(); +} + +void ThriftHiveMetastoreClient::send_add_partitions_pspec(const std::vector & new_parts) +{ + int32_t cseqid = 0; + oprot_->writeMessageBegin("add_partitions_pspec", ::apache::thrift::protocol::T_CALL, cseqid); + + ThriftHiveMetastore_add_partitions_pspec_pargs args; + args.new_parts = &new_parts; + args.write(oprot_); + + oprot_->writeMessageEnd(); + oprot_->getTransport()->writeEnd(); + oprot_->getTransport()->flush(); +} + +int32_t ThriftHiveMetastoreClient::recv_add_partitions_pspec() +{ + + 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("add_partitions_pspec") != 0) { + iprot_->skip(::apache::thrift::protocol::T_STRUCT); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + } + int32_t _return; + ThriftHiveMetastore_add_partitions_pspec_presult result; + result.success = &_return; + result.read(iprot_); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + + if (result.__isset.success) { + return _return; + } + if (result.__isset.o1) { + throw result.o1; + } + if (result.__isset.o2) { + throw result.o2; + } + if (result.__isset.o3) { + throw result.o3; + } + throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "add_partitions_pspec failed: unknown result"); +} + void ThriftHiveMetastoreClient::append_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals) { send_append_partition(db_name, tbl_name, part_vals); @@ -28696,6 +29561,72 @@ throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_partitions_with_auth failed: unknown result"); } +void ThriftHiveMetastoreClient::get_partitions_pspec(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int32_t max_parts) +{ + send_get_partitions_pspec(db_name, tbl_name, max_parts); + recv_get_partitions_pspec(_return); +} + +void ThriftHiveMetastoreClient::send_get_partitions_pspec(const std::string& db_name, const std::string& tbl_name, const int32_t max_parts) +{ + int32_t cseqid = 0; + oprot_->writeMessageBegin("get_partitions_pspec", ::apache::thrift::protocol::T_CALL, cseqid); + + ThriftHiveMetastore_get_partitions_pspec_pargs args; + args.db_name = &db_name; + args.tbl_name = &tbl_name; + args.max_parts = &max_parts; + args.write(oprot_); + + oprot_->writeMessageEnd(); + oprot_->getTransport()->writeEnd(); + oprot_->getTransport()->flush(); +} + +void ThriftHiveMetastoreClient::recv_get_partitions_pspec(std::vector & _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("get_partitions_pspec") != 0) { + iprot_->skip(::apache::thrift::protocol::T_STRUCT); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + } + ThriftHiveMetastore_get_partitions_pspec_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; + } + throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_partitions_pspec failed: unknown result"); +} + void ThriftHiveMetastoreClient::get_partition_names(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts) { send_get_partition_names(db_name, tbl_name, max_parts); @@ -29029,6 +29960,73 @@ throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_partitions_by_filter failed: unknown result"); } +void ThriftHiveMetastoreClient::get_part_specs_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts) +{ + send_get_part_specs_by_filter(db_name, tbl_name, filter, max_parts); + recv_get_part_specs_by_filter(_return); +} + +void ThriftHiveMetastoreClient::send_get_part_specs_by_filter(const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts) +{ + int32_t cseqid = 0; + oprot_->writeMessageBegin("get_part_specs_by_filter", ::apache::thrift::protocol::T_CALL, cseqid); + + ThriftHiveMetastore_get_part_specs_by_filter_pargs args; + args.db_name = &db_name; + args.tbl_name = &tbl_name; + args.filter = &filter; + args.max_parts = &max_parts; + args.write(oprot_); + + oprot_->writeMessageEnd(); + oprot_->getTransport()->writeEnd(); + oprot_->getTransport()->flush(); +} + +void ThriftHiveMetastoreClient::recv_get_part_specs_by_filter(std::vector & _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("get_part_specs_by_filter") != 0) { + iprot_->skip(::apache::thrift::protocol::T_STRUCT); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + } + ThriftHiveMetastore_get_part_specs_by_filter_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; + } + throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "get_part_specs_by_filter failed: unknown result"); +} + void ThriftHiveMetastoreClient::get_partitions_by_expr(PartitionsByExprResult& _return, const PartitionsByExprRequest& req) { send_get_partitions_by_expr(req); @@ -34704,6 +35702,69 @@ } } +void ThriftHiveMetastoreProcessor::process_add_partitions_pspec(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.add_partitions_pspec", callContext); + } + ::apache::thrift::TProcessorContextFreer freer(this->eventHandler_.get(), ctx, "ThriftHiveMetastore.add_partitions_pspec"); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->preRead(ctx, "ThriftHiveMetastore.add_partitions_pspec"); + } + + ThriftHiveMetastore_add_partitions_pspec_args args; + args.read(iprot); + iprot->readMessageEnd(); + uint32_t bytes = iprot->getTransport()->readEnd(); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->postRead(ctx, "ThriftHiveMetastore.add_partitions_pspec", bytes); + } + + ThriftHiveMetastore_add_partitions_pspec_result result; + try { + result.success = iface_->add_partitions_pspec(args.new_parts); + result.__isset.success = true; + } catch (InvalidObjectException &o1) { + result.o1 = o1; + result.__isset.o1 = true; + } catch (AlreadyExistsException &o2) { + result.o2 = o2; + result.__isset.o2 = true; + } catch (MetaException &o3) { + result.o3 = o3; + result.__isset.o3 = true; + } catch (const std::exception& e) { + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->handlerError(ctx, "ThriftHiveMetastore.add_partitions_pspec"); + } + + ::apache::thrift::TApplicationException x(e.what()); + oprot->writeMessageBegin("add_partitions_pspec", ::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.add_partitions_pspec"); + } + + oprot->writeMessageBegin("add_partitions_pspec", ::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.add_partitions_pspec", bytes); + } +} + void ThriftHiveMetastoreProcessor::process_append_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext) { void* ctx = NULL; @@ -35685,6 +36746,66 @@ } } +void ThriftHiveMetastoreProcessor::process_get_partitions_pspec(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.get_partitions_pspec", callContext); + } + ::apache::thrift::TProcessorContextFreer freer(this->eventHandler_.get(), ctx, "ThriftHiveMetastore.get_partitions_pspec"); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->preRead(ctx, "ThriftHiveMetastore.get_partitions_pspec"); + } + + ThriftHiveMetastore_get_partitions_pspec_args args; + args.read(iprot); + iprot->readMessageEnd(); + uint32_t bytes = iprot->getTransport()->readEnd(); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->postRead(ctx, "ThriftHiveMetastore.get_partitions_pspec", bytes); + } + + ThriftHiveMetastore_get_partitions_pspec_result result; + try { + iface_->get_partitions_pspec(result.success, args.db_name, args.tbl_name, args.max_parts); + result.__isset.success = true; + } catch (NoSuchObjectException &o1) { + result.o1 = o1; + result.__isset.o1 = true; + } catch (MetaException &o2) { + result.o2 = o2; + result.__isset.o2 = true; + } catch (const std::exception& e) { + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->handlerError(ctx, "ThriftHiveMetastore.get_partitions_pspec"); + } + + ::apache::thrift::TApplicationException x(e.what()); + oprot->writeMessageBegin("get_partitions_pspec", ::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.get_partitions_pspec"); + } + + oprot->writeMessageBegin("get_partitions_pspec", ::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.get_partitions_pspec", bytes); + } +} + void ThriftHiveMetastoreProcessor::process_get_partition_names(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext) { void* ctx = NULL; @@ -35982,6 +37103,66 @@ } } +void ThriftHiveMetastoreProcessor::process_get_part_specs_by_filter(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.get_part_specs_by_filter", callContext); + } + ::apache::thrift::TProcessorContextFreer freer(this->eventHandler_.get(), ctx, "ThriftHiveMetastore.get_part_specs_by_filter"); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->preRead(ctx, "ThriftHiveMetastore.get_part_specs_by_filter"); + } + + ThriftHiveMetastore_get_part_specs_by_filter_args args; + args.read(iprot); + iprot->readMessageEnd(); + uint32_t bytes = iprot->getTransport()->readEnd(); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->postRead(ctx, "ThriftHiveMetastore.get_part_specs_by_filter", bytes); + } + + ThriftHiveMetastore_get_part_specs_by_filter_result result; + try { + iface_->get_part_specs_by_filter(result.success, args.db_name, args.tbl_name, args.filter, args.max_parts); + 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 (const std::exception& e) { + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->handlerError(ctx, "ThriftHiveMetastore.get_part_specs_by_filter"); + } + + ::apache::thrift::TApplicationException x(e.what()); + oprot->writeMessageBegin("get_part_specs_by_filter", ::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.get_part_specs_by_filter"); + } + + oprot->writeMessageBegin("get_part_specs_by_filter", ::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.get_part_specs_by_filter", bytes); + } +} + void ThriftHiveMetastoreProcessor::process_get_partitions_by_expr(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/hive_metastore_types.cpp =================================================================== --- metastore/src/gen/thrift/gen-cpp/hive_metastore_types.cpp (revision 1619008) +++ metastore/src/gen/thrift/gen-cpp/hive_metastore_types.cpp (working copy) @@ -3306,6 +3306,471 @@ swap(a.__isset, b.__isset); } +const char* PartitionWithoutSD::ascii_fingerprint = "D79FA44499888D0E50B5625E0C536DEA"; +const uint8_t PartitionWithoutSD::binary_fingerprint[16] = {0xD7,0x9F,0xA4,0x44,0x99,0x88,0x8D,0x0E,0x50,0xB5,0x62,0x5E,0x0C,0x53,0x6D,0xEA}; + +uint32_t PartitionWithoutSD::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_LIST) { + { + this->values.clear(); + uint32_t _size185; + ::apache::thrift::protocol::TType _etype188; + xfer += iprot->readListBegin(_etype188, _size185); + this->values.resize(_size185); + uint32_t _i189; + for (_i189 = 0; _i189 < _size185; ++_i189) + { + xfer += iprot->readString(this->values[_i189]); + } + xfer += iprot->readListEnd(); + } + this->__isset.values = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->createTime); + this->__isset.createTime = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_I32) { + xfer += iprot->readI32(this->lastAccessTime); + this->__isset.lastAccessTime = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->relativePath); + this->__isset.relativePath = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == ::apache::thrift::protocol::T_MAP) { + { + this->parameters.clear(); + uint32_t _size190; + ::apache::thrift::protocol::TType _ktype191; + ::apache::thrift::protocol::TType _vtype192; + xfer += iprot->readMapBegin(_ktype191, _vtype192, _size190); + uint32_t _i194; + for (_i194 = 0; _i194 < _size190; ++_i194) + { + std::string _key195; + xfer += iprot->readString(_key195); + std::string& _val196 = this->parameters[_key195]; + xfer += iprot->readString(_val196); + } + xfer += iprot->readMapEnd(); + } + this->__isset.parameters = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 6: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->privileges.read(iprot); + this->__isset.privileges = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t PartitionWithoutSD::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("PartitionWithoutSD"); + + xfer += oprot->writeFieldBegin("values", ::apache::thrift::protocol::T_LIST, 1); + { + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->values.size())); + std::vector ::const_iterator _iter197; + for (_iter197 = this->values.begin(); _iter197 != this->values.end(); ++_iter197) + { + xfer += oprot->writeString((*_iter197)); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("createTime", ::apache::thrift::protocol::T_I32, 2); + xfer += oprot->writeI32(this->createTime); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("lastAccessTime", ::apache::thrift::protocol::T_I32, 3); + xfer += oprot->writeI32(this->lastAccessTime); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("relativePath", ::apache::thrift::protocol::T_STRING, 4); + xfer += oprot->writeString(this->relativePath); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_MAP, 5); + { + xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); + std::map ::const_iterator _iter198; + for (_iter198 = this->parameters.begin(); _iter198 != this->parameters.end(); ++_iter198) + { + xfer += oprot->writeString(_iter198->first); + xfer += oprot->writeString(_iter198->second); + } + xfer += oprot->writeMapEnd(); + } + xfer += oprot->writeFieldEnd(); + + if (this->__isset.privileges) { + xfer += oprot->writeFieldBegin("privileges", ::apache::thrift::protocol::T_STRUCT, 6); + xfer += this->privileges.write(oprot); + xfer += oprot->writeFieldEnd(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +void swap(PartitionWithoutSD &a, PartitionWithoutSD &b) { + using ::std::swap; + swap(a.values, b.values); + swap(a.createTime, b.createTime); + swap(a.lastAccessTime, b.lastAccessTime); + swap(a.relativePath, b.relativePath); + swap(a.parameters, b.parameters); + swap(a.privileges, b.privileges); + swap(a.__isset, b.__isset); +} + +const char* PartitionSpecWithSharedSD::ascii_fingerprint = "7BEE9305B42DCD083FF06BEE6DDC61CF"; +const uint8_t PartitionSpecWithSharedSD::binary_fingerprint[16] = {0x7B,0xEE,0x93,0x05,0xB4,0x2D,0xCD,0x08,0x3F,0xF0,0x6B,0xEE,0x6D,0xDC,0x61,0xCF}; + +uint32_t PartitionSpecWithSharedSD::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_LIST) { + { + this->partitions.clear(); + uint32_t _size199; + ::apache::thrift::protocol::TType _etype202; + xfer += iprot->readListBegin(_etype202, _size199); + this->partitions.resize(_size199); + uint32_t _i203; + for (_i203 = 0; _i203 < _size199; ++_i203) + { + xfer += this->partitions[_i203].read(iprot); + } + xfer += iprot->readListEnd(); + } + this->__isset.partitions = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->sd.read(iprot); + this->__isset.sd = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t PartitionSpecWithSharedSD::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("PartitionSpecWithSharedSD"); + + xfer += oprot->writeFieldBegin("partitions", ::apache::thrift::protocol::T_LIST, 1); + { + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->partitions.size())); + std::vector ::const_iterator _iter204; + for (_iter204 = this->partitions.begin(); _iter204 != this->partitions.end(); ++_iter204) + { + xfer += (*_iter204).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("sd", ::apache::thrift::protocol::T_STRUCT, 2); + xfer += this->sd.write(oprot); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +void swap(PartitionSpecWithSharedSD &a, PartitionSpecWithSharedSD &b) { + using ::std::swap; + swap(a.partitions, b.partitions); + swap(a.sd, b.sd); + swap(a.__isset, b.__isset); +} + +const char* PartitionListComposingSpec::ascii_fingerprint = "A048235CB9A257C8A74E3691BEFE0674"; +const uint8_t PartitionListComposingSpec::binary_fingerprint[16] = {0xA0,0x48,0x23,0x5C,0xB9,0xA2,0x57,0xC8,0xA7,0x4E,0x36,0x91,0xBE,0xFE,0x06,0x74}; + +uint32_t PartitionListComposingSpec::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_LIST) { + { + this->partitions.clear(); + uint32_t _size205; + ::apache::thrift::protocol::TType _etype208; + xfer += iprot->readListBegin(_etype208, _size205); + this->partitions.resize(_size205); + uint32_t _i209; + for (_i209 = 0; _i209 < _size205; ++_i209) + { + xfer += this->partitions[_i209].read(iprot); + } + xfer += iprot->readListEnd(); + } + this->__isset.partitions = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t PartitionListComposingSpec::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("PartitionListComposingSpec"); + + xfer += oprot->writeFieldBegin("partitions", ::apache::thrift::protocol::T_LIST, 1); + { + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->partitions.size())); + std::vector ::const_iterator _iter210; + for (_iter210 = this->partitions.begin(); _iter210 != this->partitions.end(); ++_iter210) + { + xfer += (*_iter210).write(oprot); + } + xfer += oprot->writeListEnd(); + } + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +void swap(PartitionListComposingSpec &a, PartitionListComposingSpec &b) { + using ::std::swap; + swap(a.partitions, b.partitions); + swap(a.__isset, b.__isset); +} + +const char* PartitionSpec::ascii_fingerprint = "C3F548C24D072CF6422F25096143E3E8"; +const uint8_t PartitionSpec::binary_fingerprint[16] = {0xC3,0xF5,0x48,0xC2,0x4D,0x07,0x2C,0xF6,0x42,0x2F,0x25,0x09,0x61,0x43,0xE3,0xE8}; + +uint32_t PartitionSpec::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_STRING) { + xfer += iprot->readString(this->dbName); + this->__isset.dbName = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->tableName); + this->__isset.tableName = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->rootPath); + this->__isset.rootPath = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->sharedSDPartitionSpec.read(iprot); + this->__isset.sharedSDPartitionSpec = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->partitionList.read(iprot); + this->__isset.partitionList = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t PartitionSpec::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("PartitionSpec"); + + xfer += oprot->writeFieldBegin("dbName", ::apache::thrift::protocol::T_STRING, 1); + xfer += oprot->writeString(this->dbName); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("tableName", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->tableName); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldBegin("rootPath", ::apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString(this->rootPath); + xfer += oprot->writeFieldEnd(); + + if (this->__isset.sharedSDPartitionSpec) { + xfer += oprot->writeFieldBegin("sharedSDPartitionSpec", ::apache::thrift::protocol::T_STRUCT, 4); + xfer += this->sharedSDPartitionSpec.write(oprot); + xfer += oprot->writeFieldEnd(); + } + if (this->__isset.partitionList) { + xfer += oprot->writeFieldBegin("partitionList", ::apache::thrift::protocol::T_STRUCT, 5); + xfer += this->partitionList.write(oprot); + xfer += oprot->writeFieldEnd(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +void swap(PartitionSpec &a, PartitionSpec &b) { + using ::std::swap; + swap(a.dbName, b.dbName); + swap(a.tableName, b.tableName); + swap(a.rootPath, b.rootPath); + swap(a.sharedSDPartitionSpec, b.sharedSDPartitionSpec); + swap(a.partitionList, b.partitionList); + swap(a.__isset, b.__isset); +} + const char* Index::ascii_fingerprint = "09EEF655216AC81802850988D6C470A6"; const uint8_t Index::binary_fingerprint[16] = {0x09,0xEE,0xF6,0x55,0x21,0x6A,0xC8,0x18,0x02,0x85,0x09,0x88,0xD6,0xC4,0x70,0xA6}; @@ -3397,17 +3862,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size185; - ::apache::thrift::protocol::TType _ktype186; - ::apache::thrift::protocol::TType _vtype187; - xfer += iprot->readMapBegin(_ktype186, _vtype187, _size185); - uint32_t _i189; - for (_i189 = 0; _i189 < _size185; ++_i189) + uint32_t _size211; + ::apache::thrift::protocol::TType _ktype212; + ::apache::thrift::protocol::TType _vtype213; + xfer += iprot->readMapBegin(_ktype212, _vtype213, _size211); + uint32_t _i215; + for (_i215 = 0; _i215 < _size211; ++_i215) { - std::string _key190; - xfer += iprot->readString(_key190); - std::string& _val191 = this->parameters[_key190]; - xfer += iprot->readString(_val191); + std::string _key216; + xfer += iprot->readString(_key216); + std::string& _val217 = this->parameters[_key216]; + xfer += iprot->readString(_val217); } xfer += iprot->readMapEnd(); } @@ -3475,11 +3940,11 @@ xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_MAP, 9); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); - std::map ::const_iterator _iter192; - for (_iter192 = this->parameters.begin(); _iter192 != this->parameters.end(); ++_iter192) + std::map ::const_iterator _iter218; + for (_iter218 = this->parameters.begin(); _iter218 != this->parameters.end(); ++_iter218) { - xfer += oprot->writeString(_iter192->first); - xfer += oprot->writeString(_iter192->second); + xfer += oprot->writeString(_iter218->first); + xfer += oprot->writeString(_iter218->second); } xfer += oprot->writeMapEnd(); } @@ -4605,14 +5070,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->statsObj.clear(); - uint32_t _size193; - ::apache::thrift::protocol::TType _etype196; - xfer += iprot->readListBegin(_etype196, _size193); - this->statsObj.resize(_size193); - uint32_t _i197; - for (_i197 = 0; _i197 < _size193; ++_i197) + uint32_t _size219; + ::apache::thrift::protocol::TType _etype222; + xfer += iprot->readListBegin(_etype222, _size219); + this->statsObj.resize(_size219); + uint32_t _i223; + for (_i223 = 0; _i223 < _size219; ++_i223) { - xfer += this->statsObj[_i197].read(iprot); + xfer += this->statsObj[_i223].read(iprot); } xfer += iprot->readListEnd(); } @@ -4648,10 +5113,10 @@ xfer += oprot->writeFieldBegin("statsObj", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->statsObj.size())); - std::vector ::const_iterator _iter198; - for (_iter198 = this->statsObj.begin(); _iter198 != this->statsObj.end(); ++_iter198) + std::vector ::const_iterator _iter224; + for (_iter224 = this->statsObj.begin(); _iter224 != this->statsObj.end(); ++_iter224) { - xfer += (*_iter198).write(oprot); + xfer += (*_iter224).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4697,14 +5162,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->colStats.clear(); - uint32_t _size199; - ::apache::thrift::protocol::TType _etype202; - xfer += iprot->readListBegin(_etype202, _size199); - this->colStats.resize(_size199); - uint32_t _i203; - for (_i203 = 0; _i203 < _size199; ++_i203) + uint32_t _size225; + ::apache::thrift::protocol::TType _etype228; + xfer += iprot->readListBegin(_etype228, _size225); + this->colStats.resize(_size225); + uint32_t _i229; + for (_i229 = 0; _i229 < _size225; ++_i229) { - xfer += this->colStats[_i203].read(iprot); + xfer += this->colStats[_i229].read(iprot); } xfer += iprot->readListEnd(); } @@ -4744,10 +5209,10 @@ xfer += oprot->writeFieldBegin("colStats", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->colStats.size())); - std::vector ::const_iterator _iter204; - for (_iter204 = this->colStats.begin(); _iter204 != this->colStats.end(); ++_iter204) + std::vector ::const_iterator _iter230; + for (_iter230 = this->colStats.begin(); _iter230 != this->colStats.end(); ++_iter230) { - xfer += (*_iter204).write(oprot); + xfer += (*_iter230).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4795,14 +5260,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->fieldSchemas.clear(); - uint32_t _size205; - ::apache::thrift::protocol::TType _etype208; - xfer += iprot->readListBegin(_etype208, _size205); - this->fieldSchemas.resize(_size205); - uint32_t _i209; - for (_i209 = 0; _i209 < _size205; ++_i209) + uint32_t _size231; + ::apache::thrift::protocol::TType _etype234; + xfer += iprot->readListBegin(_etype234, _size231); + this->fieldSchemas.resize(_size231); + uint32_t _i235; + for (_i235 = 0; _i235 < _size231; ++_i235) { - xfer += this->fieldSchemas[_i209].read(iprot); + xfer += this->fieldSchemas[_i235].read(iprot); } xfer += iprot->readListEnd(); } @@ -4815,17 +5280,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->properties.clear(); - uint32_t _size210; - ::apache::thrift::protocol::TType _ktype211; - ::apache::thrift::protocol::TType _vtype212; - xfer += iprot->readMapBegin(_ktype211, _vtype212, _size210); - uint32_t _i214; - for (_i214 = 0; _i214 < _size210; ++_i214) + uint32_t _size236; + ::apache::thrift::protocol::TType _ktype237; + ::apache::thrift::protocol::TType _vtype238; + xfer += iprot->readMapBegin(_ktype237, _vtype238, _size236); + uint32_t _i240; + for (_i240 = 0; _i240 < _size236; ++_i240) { - std::string _key215; - xfer += iprot->readString(_key215); - std::string& _val216 = this->properties[_key215]; - xfer += iprot->readString(_val216); + std::string _key241; + xfer += iprot->readString(_key241); + std::string& _val242 = this->properties[_key241]; + xfer += iprot->readString(_val242); } xfer += iprot->readMapEnd(); } @@ -4853,10 +5318,10 @@ xfer += oprot->writeFieldBegin("fieldSchemas", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->fieldSchemas.size())); - std::vector ::const_iterator _iter217; - for (_iter217 = this->fieldSchemas.begin(); _iter217 != this->fieldSchemas.end(); ++_iter217) + std::vector ::const_iterator _iter243; + for (_iter243 = this->fieldSchemas.begin(); _iter243 != this->fieldSchemas.end(); ++_iter243) { - xfer += (*_iter217).write(oprot); + xfer += (*_iter243).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4865,11 +5330,11 @@ xfer += oprot->writeFieldBegin("properties", ::apache::thrift::protocol::T_MAP, 2); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->properties.size())); - std::map ::const_iterator _iter218; - for (_iter218 = this->properties.begin(); _iter218 != this->properties.end(); ++_iter218) + std::map ::const_iterator _iter244; + for (_iter244 = this->properties.begin(); _iter244 != this->properties.end(); ++_iter244) { - xfer += oprot->writeString(_iter218->first); - xfer += oprot->writeString(_iter218->second); + xfer += oprot->writeString(_iter244->first); + xfer += oprot->writeString(_iter244->second); } xfer += oprot->writeMapEnd(); } @@ -4914,17 +5379,17 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->properties.clear(); - uint32_t _size219; - ::apache::thrift::protocol::TType _ktype220; - ::apache::thrift::protocol::TType _vtype221; - xfer += iprot->readMapBegin(_ktype220, _vtype221, _size219); - uint32_t _i223; - for (_i223 = 0; _i223 < _size219; ++_i223) + uint32_t _size245; + ::apache::thrift::protocol::TType _ktype246; + ::apache::thrift::protocol::TType _vtype247; + xfer += iprot->readMapBegin(_ktype246, _vtype247, _size245); + uint32_t _i249; + for (_i249 = 0; _i249 < _size245; ++_i249) { - std::string _key224; - xfer += iprot->readString(_key224); - std::string& _val225 = this->properties[_key224]; - xfer += iprot->readString(_val225); + std::string _key250; + xfer += iprot->readString(_key250); + std::string& _val251 = this->properties[_key250]; + xfer += iprot->readString(_val251); } xfer += iprot->readMapEnd(); } @@ -4952,11 +5417,11 @@ xfer += oprot->writeFieldBegin("properties", ::apache::thrift::protocol::T_MAP, 1); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->properties.size())); - std::map ::const_iterator _iter226; - for (_iter226 = this->properties.begin(); _iter226 != this->properties.end(); ++_iter226) + std::map ::const_iterator _iter252; + for (_iter252 = this->properties.begin(); _iter252 != this->properties.end(); ++_iter252) { - xfer += oprot->writeString(_iter226->first); - xfer += oprot->writeString(_iter226->second); + xfer += oprot->writeString(_iter252->first); + xfer += oprot->writeString(_iter252->second); } xfer += oprot->writeMapEnd(); } @@ -5002,14 +5467,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitions.clear(); - uint32_t _size227; - ::apache::thrift::protocol::TType _etype230; - xfer += iprot->readListBegin(_etype230, _size227); - this->partitions.resize(_size227); - uint32_t _i231; - for (_i231 = 0; _i231 < _size227; ++_i231) + uint32_t _size253; + ::apache::thrift::protocol::TType _etype256; + xfer += iprot->readListBegin(_etype256, _size253); + this->partitions.resize(_size253); + uint32_t _i257; + for (_i257 = 0; _i257 < _size253; ++_i257) { - xfer += this->partitions[_i231].read(iprot); + xfer += this->partitions[_i257].read(iprot); } xfer += iprot->readListEnd(); } @@ -5049,10 +5514,10 @@ xfer += oprot->writeFieldBegin("partitions", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->partitions.size())); - std::vector ::const_iterator _iter232; - for (_iter232 = this->partitions.begin(); _iter232 != this->partitions.end(); ++_iter232) + std::vector ::const_iterator _iter258; + for (_iter258 = this->partitions.begin(); _iter258 != this->partitions.end(); ++_iter258) { - xfer += (*_iter232).write(oprot); + xfer += (*_iter258).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5226,14 +5691,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->tableStats.clear(); - uint32_t _size233; - ::apache::thrift::protocol::TType _etype236; - xfer += iprot->readListBegin(_etype236, _size233); - this->tableStats.resize(_size233); - uint32_t _i237; - for (_i237 = 0; _i237 < _size233; ++_i237) + uint32_t _size259; + ::apache::thrift::protocol::TType _etype262; + xfer += iprot->readListBegin(_etype262, _size259); + this->tableStats.resize(_size259); + uint32_t _i263; + for (_i263 = 0; _i263 < _size259; ++_i263) { - xfer += this->tableStats[_i237].read(iprot); + xfer += this->tableStats[_i263].read(iprot); } xfer += iprot->readListEnd(); } @@ -5263,10 +5728,10 @@ xfer += oprot->writeFieldBegin("tableStats", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->tableStats.size())); - std::vector ::const_iterator _iter238; - for (_iter238 = this->tableStats.begin(); _iter238 != this->tableStats.end(); ++_iter238) + std::vector ::const_iterator _iter264; + for (_iter264 = this->tableStats.begin(); _iter264 != this->tableStats.end(); ++_iter264) { - xfer += (*_iter238).write(oprot); + xfer += (*_iter264).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5310,26 +5775,26 @@ if (ftype == ::apache::thrift::protocol::T_MAP) { { this->partStats.clear(); - uint32_t _size239; - ::apache::thrift::protocol::TType _ktype240; - ::apache::thrift::protocol::TType _vtype241; - xfer += iprot->readMapBegin(_ktype240, _vtype241, _size239); - uint32_t _i243; - for (_i243 = 0; _i243 < _size239; ++_i243) + uint32_t _size265; + ::apache::thrift::protocol::TType _ktype266; + ::apache::thrift::protocol::TType _vtype267; + xfer += iprot->readMapBegin(_ktype266, _vtype267, _size265); + uint32_t _i269; + for (_i269 = 0; _i269 < _size265; ++_i269) { - std::string _key244; - xfer += iprot->readString(_key244); - std::vector & _val245 = this->partStats[_key244]; + std::string _key270; + xfer += iprot->readString(_key270); + std::vector & _val271 = this->partStats[_key270]; { - _val245.clear(); - uint32_t _size246; - ::apache::thrift::protocol::TType _etype249; - xfer += iprot->readListBegin(_etype249, _size246); - _val245.resize(_size246); - uint32_t _i250; - for (_i250 = 0; _i250 < _size246; ++_i250) + _val271.clear(); + uint32_t _size272; + ::apache::thrift::protocol::TType _etype275; + xfer += iprot->readListBegin(_etype275, _size272); + _val271.resize(_size272); + uint32_t _i276; + for (_i276 = 0; _i276 < _size272; ++_i276) { - xfer += _val245[_i250].read(iprot); + xfer += _val271[_i276].read(iprot); } xfer += iprot->readListEnd(); } @@ -5362,16 +5827,16 @@ xfer += oprot->writeFieldBegin("partStats", ::apache::thrift::protocol::T_MAP, 1); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_LIST, static_cast(this->partStats.size())); - std::map > ::const_iterator _iter251; - for (_iter251 = this->partStats.begin(); _iter251 != this->partStats.end(); ++_iter251) + std::map > ::const_iterator _iter277; + for (_iter277 = this->partStats.begin(); _iter277 != this->partStats.end(); ++_iter277) { - xfer += oprot->writeString(_iter251->first); + xfer += oprot->writeString(_iter277->first); { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(_iter251->second.size())); - std::vector ::const_iterator _iter252; - for (_iter252 = _iter251->second.begin(); _iter252 != _iter251->second.end(); ++_iter252) + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(_iter277->second.size())); + std::vector ::const_iterator _iter278; + for (_iter278 = _iter277->second.begin(); _iter278 != _iter277->second.end(); ++_iter278) { - xfer += (*_iter252).write(oprot); + xfer += (*_iter278).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5436,14 +5901,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->colNames.clear(); - uint32_t _size253; - ::apache::thrift::protocol::TType _etype256; - xfer += iprot->readListBegin(_etype256, _size253); - this->colNames.resize(_size253); - uint32_t _i257; - for (_i257 = 0; _i257 < _size253; ++_i257) + uint32_t _size279; + ::apache::thrift::protocol::TType _etype282; + xfer += iprot->readListBegin(_etype282, _size279); + this->colNames.resize(_size279); + uint32_t _i283; + for (_i283 = 0; _i283 < _size279; ++_i283) { - xfer += iprot->readString(this->colNames[_i257]); + xfer += iprot->readString(this->colNames[_i283]); } xfer += iprot->readListEnd(); } @@ -5485,10 +5950,10 @@ xfer += oprot->writeFieldBegin("colNames", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->colNames.size())); - std::vector ::const_iterator _iter258; - for (_iter258 = this->colNames.begin(); _iter258 != this->colNames.end(); ++_iter258) + std::vector ::const_iterator _iter284; + for (_iter284 = this->colNames.begin(); _iter284 != this->colNames.end(); ++_iter284) { - xfer += oprot->writeString((*_iter258)); + xfer += oprot->writeString((*_iter284)); } xfer += oprot->writeListEnd(); } @@ -5553,14 +6018,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->colNames.clear(); - uint32_t _size259; - ::apache::thrift::protocol::TType _etype262; - xfer += iprot->readListBegin(_etype262, _size259); - this->colNames.resize(_size259); - uint32_t _i263; - for (_i263 = 0; _i263 < _size259; ++_i263) + uint32_t _size285; + ::apache::thrift::protocol::TType _etype288; + xfer += iprot->readListBegin(_etype288, _size285); + this->colNames.resize(_size285); + uint32_t _i289; + for (_i289 = 0; _i289 < _size285; ++_i289) { - xfer += iprot->readString(this->colNames[_i263]); + xfer += iprot->readString(this->colNames[_i289]); } xfer += iprot->readListEnd(); } @@ -5573,14 +6038,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partNames.clear(); - uint32_t _size264; - ::apache::thrift::protocol::TType _etype267; - xfer += iprot->readListBegin(_etype267, _size264); - this->partNames.resize(_size264); - uint32_t _i268; - for (_i268 = 0; _i268 < _size264; ++_i268) + uint32_t _size290; + ::apache::thrift::protocol::TType _etype293; + xfer += iprot->readListBegin(_etype293, _size290); + this->partNames.resize(_size290); + uint32_t _i294; + for (_i294 = 0; _i294 < _size290; ++_i294) { - xfer += iprot->readString(this->partNames[_i268]); + xfer += iprot->readString(this->partNames[_i294]); } xfer += iprot->readListEnd(); } @@ -5624,10 +6089,10 @@ xfer += oprot->writeFieldBegin("colNames", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->colNames.size())); - std::vector ::const_iterator _iter269; - for (_iter269 = this->colNames.begin(); _iter269 != this->colNames.end(); ++_iter269) + std::vector ::const_iterator _iter295; + for (_iter295 = this->colNames.begin(); _iter295 != this->colNames.end(); ++_iter295) { - xfer += oprot->writeString((*_iter269)); + xfer += oprot->writeString((*_iter295)); } xfer += oprot->writeListEnd(); } @@ -5636,10 +6101,10 @@ xfer += oprot->writeFieldBegin("partNames", ::apache::thrift::protocol::T_LIST, 4); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->partNames.size())); - std::vector ::const_iterator _iter270; - for (_iter270 = this->partNames.begin(); _iter270 != this->partNames.end(); ++_iter270) + std::vector ::const_iterator _iter296; + for (_iter296 = this->partNames.begin(); _iter296 != this->partNames.end(); ++_iter296) { - xfer += oprot->writeString((*_iter270)); + xfer += oprot->writeString((*_iter296)); } xfer += oprot->writeListEnd(); } @@ -5685,14 +6150,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitions.clear(); - uint32_t _size271; - ::apache::thrift::protocol::TType _etype274; - xfer += iprot->readListBegin(_etype274, _size271); - this->partitions.resize(_size271); - uint32_t _i275; - for (_i275 = 0; _i275 < _size271; ++_i275) + uint32_t _size297; + ::apache::thrift::protocol::TType _etype300; + xfer += iprot->readListBegin(_etype300, _size297); + this->partitions.resize(_size297); + uint32_t _i301; + for (_i301 = 0; _i301 < _size297; ++_i301) { - xfer += this->partitions[_i275].read(iprot); + xfer += this->partitions[_i301].read(iprot); } xfer += iprot->readListEnd(); } @@ -5721,10 +6186,10 @@ xfer += oprot->writeFieldBegin("partitions", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->partitions.size())); - std::vector ::const_iterator _iter276; - for (_iter276 = this->partitions.begin(); _iter276 != this->partitions.end(); ++_iter276) + std::vector ::const_iterator _iter302; + for (_iter302 = this->partitions.begin(); _iter302 != this->partitions.end(); ++_iter302) { - xfer += (*_iter276).write(oprot); + xfer += (*_iter302).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5788,14 +6253,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->parts.clear(); - uint32_t _size277; - ::apache::thrift::protocol::TType _etype280; - xfer += iprot->readListBegin(_etype280, _size277); - this->parts.resize(_size277); - uint32_t _i281; - for (_i281 = 0; _i281 < _size277; ++_i281) + uint32_t _size303; + ::apache::thrift::protocol::TType _etype306; + xfer += iprot->readListBegin(_etype306, _size303); + this->parts.resize(_size303); + uint32_t _i307; + for (_i307 = 0; _i307 < _size303; ++_i307) { - xfer += this->parts[_i281].read(iprot); + xfer += this->parts[_i307].read(iprot); } xfer += iprot->readListEnd(); } @@ -5855,10 +6320,10 @@ xfer += oprot->writeFieldBegin("parts", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->parts.size())); - std::vector ::const_iterator _iter282; - for (_iter282 = this->parts.begin(); _iter282 != this->parts.end(); ++_iter282) + std::vector ::const_iterator _iter308; + for (_iter308 = this->parts.begin(); _iter308 != this->parts.end(); ++_iter308) { - xfer += (*_iter282).write(oprot); + xfer += (*_iter308).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5915,14 +6380,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitions.clear(); - uint32_t _size283; - ::apache::thrift::protocol::TType _etype286; - xfer += iprot->readListBegin(_etype286, _size283); - this->partitions.resize(_size283); - uint32_t _i287; - for (_i287 = 0; _i287 < _size283; ++_i287) + uint32_t _size309; + ::apache::thrift::protocol::TType _etype312; + xfer += iprot->readListBegin(_etype312, _size309); + this->partitions.resize(_size309); + uint32_t _i313; + for (_i313 = 0; _i313 < _size309; ++_i313) { - xfer += this->partitions[_i287].read(iprot); + xfer += this->partitions[_i313].read(iprot); } xfer += iprot->readListEnd(); } @@ -5951,10 +6416,10 @@ xfer += oprot->writeFieldBegin("partitions", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->partitions.size())); - std::vector ::const_iterator _iter288; - for (_iter288 = this->partitions.begin(); _iter288 != this->partitions.end(); ++_iter288) + std::vector ::const_iterator _iter314; + for (_iter314 = this->partitions.begin(); _iter314 != this->partitions.end(); ++_iter314) { - xfer += (*_iter288).write(oprot); + xfer += (*_iter314).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6077,14 +6542,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->names.clear(); - uint32_t _size289; - ::apache::thrift::protocol::TType _etype292; - xfer += iprot->readListBegin(_etype292, _size289); - this->names.resize(_size289); - uint32_t _i293; - for (_i293 = 0; _i293 < _size289; ++_i293) + uint32_t _size315; + ::apache::thrift::protocol::TType _etype318; + xfer += iprot->readListBegin(_etype318, _size315); + this->names.resize(_size315); + uint32_t _i319; + for (_i319 = 0; _i319 < _size315; ++_i319) { - xfer += iprot->readString(this->names[_i293]); + xfer += iprot->readString(this->names[_i319]); } xfer += iprot->readListEnd(); } @@ -6097,14 +6562,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->exprs.clear(); - uint32_t _size294; - ::apache::thrift::protocol::TType _etype297; - xfer += iprot->readListBegin(_etype297, _size294); - this->exprs.resize(_size294); - uint32_t _i298; - for (_i298 = 0; _i298 < _size294; ++_i298) + uint32_t _size320; + ::apache::thrift::protocol::TType _etype323; + xfer += iprot->readListBegin(_etype323, _size320); + this->exprs.resize(_size320); + uint32_t _i324; + for (_i324 = 0; _i324 < _size320; ++_i324) { - xfer += this->exprs[_i298].read(iprot); + xfer += this->exprs[_i324].read(iprot); } xfer += iprot->readListEnd(); } @@ -6132,10 +6597,10 @@ xfer += oprot->writeFieldBegin("names", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->names.size())); - std::vector ::const_iterator _iter299; - for (_iter299 = this->names.begin(); _iter299 != this->names.end(); ++_iter299) + std::vector ::const_iterator _iter325; + for (_iter325 = this->names.begin(); _iter325 != this->names.end(); ++_iter325) { - xfer += oprot->writeString((*_iter299)); + xfer += oprot->writeString((*_iter325)); } xfer += oprot->writeListEnd(); } @@ -6144,10 +6609,10 @@ xfer += oprot->writeFieldBegin("exprs", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->exprs.size())); - std::vector ::const_iterator _iter300; - for (_iter300 = this->exprs.begin(); _iter300 != this->exprs.end(); ++_iter300) + std::vector ::const_iterator _iter326; + for (_iter326 = this->exprs.begin(); _iter326 != this->exprs.end(); ++_iter326) { - xfer += (*_iter300).write(oprot); + xfer += (*_iter326).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6357,9 +6822,9 @@ { case 1: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast301; - xfer += iprot->readI32(ecast301); - this->resourceType = (ResourceType::type)ecast301; + int32_t ecast327; + xfer += iprot->readI32(ecast327); + this->resourceType = (ResourceType::type)ecast327; this->__isset.resourceType = true; } else { xfer += iprot->skip(ftype); @@ -6466,9 +6931,9 @@ break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast302; - xfer += iprot->readI32(ecast302); - this->ownerType = (PrincipalType::type)ecast302; + int32_t ecast328; + xfer += iprot->readI32(ecast328); + this->ownerType = (PrincipalType::type)ecast328; this->__isset.ownerType = true; } else { xfer += iprot->skip(ftype); @@ -6484,9 +6949,9 @@ break; case 7: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast303; - xfer += iprot->readI32(ecast303); - this->functionType = (FunctionType::type)ecast303; + int32_t ecast329; + xfer += iprot->readI32(ecast329); + this->functionType = (FunctionType::type)ecast329; this->__isset.functionType = true; } else { xfer += iprot->skip(ftype); @@ -6496,14 +6961,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->resourceUris.clear(); - uint32_t _size304; - ::apache::thrift::protocol::TType _etype307; - xfer += iprot->readListBegin(_etype307, _size304); - this->resourceUris.resize(_size304); - uint32_t _i308; - for (_i308 = 0; _i308 < _size304; ++_i308) + uint32_t _size330; + ::apache::thrift::protocol::TType _etype333; + xfer += iprot->readListBegin(_etype333, _size330); + this->resourceUris.resize(_size330); + uint32_t _i334; + for (_i334 = 0; _i334 < _size330; ++_i334) { - xfer += this->resourceUris[_i308].read(iprot); + xfer += this->resourceUris[_i334].read(iprot); } xfer += iprot->readListEnd(); } @@ -6559,10 +7024,10 @@ xfer += oprot->writeFieldBegin("resourceUris", ::apache::thrift::protocol::T_LIST, 8); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->resourceUris.size())); - std::vector ::const_iterator _iter309; - for (_iter309 = this->resourceUris.begin(); _iter309 != this->resourceUris.end(); ++_iter309) + std::vector ::const_iterator _iter335; + for (_iter335 = this->resourceUris.begin(); _iter335 != this->resourceUris.end(); ++_iter335) { - xfer += (*_iter309).write(oprot); + xfer += (*_iter335).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6623,9 +7088,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast310; - xfer += iprot->readI32(ecast310); - this->state = (TxnState::type)ecast310; + int32_t ecast336; + xfer += iprot->readI32(ecast336); + this->state = (TxnState::type)ecast336; isset_state = true; } else { xfer += iprot->skip(ftype); @@ -6737,14 +7202,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->open_txns.clear(); - uint32_t _size311; - ::apache::thrift::protocol::TType _etype314; - xfer += iprot->readListBegin(_etype314, _size311); - this->open_txns.resize(_size311); - uint32_t _i315; - for (_i315 = 0; _i315 < _size311; ++_i315) + uint32_t _size337; + ::apache::thrift::protocol::TType _etype340; + xfer += iprot->readListBegin(_etype340, _size337); + this->open_txns.resize(_size337); + uint32_t _i341; + for (_i341 = 0; _i341 < _size337; ++_i341) { - xfer += this->open_txns[_i315].read(iprot); + xfer += this->open_txns[_i341].read(iprot); } xfer += iprot->readListEnd(); } @@ -6780,10 +7245,10 @@ xfer += oprot->writeFieldBegin("open_txns", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->open_txns.size())); - std::vector ::const_iterator _iter316; - for (_iter316 = this->open_txns.begin(); _iter316 != this->open_txns.end(); ++_iter316) + std::vector ::const_iterator _iter342; + for (_iter342 = this->open_txns.begin(); _iter342 != this->open_txns.end(); ++_iter342) { - xfer += (*_iter316).write(oprot); + xfer += (*_iter342).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6837,15 +7302,15 @@ if (ftype == ::apache::thrift::protocol::T_SET) { { this->open_txns.clear(); - uint32_t _size317; - ::apache::thrift::protocol::TType _etype320; - xfer += iprot->readSetBegin(_etype320, _size317); - uint32_t _i321; - for (_i321 = 0; _i321 < _size317; ++_i321) + uint32_t _size343; + ::apache::thrift::protocol::TType _etype346; + xfer += iprot->readSetBegin(_etype346, _size343); + uint32_t _i347; + for (_i347 = 0; _i347 < _size343; ++_i347) { - int64_t _elem322; - xfer += iprot->readI64(_elem322); - this->open_txns.insert(_elem322); + int64_t _elem348; + xfer += iprot->readI64(_elem348); + this->open_txns.insert(_elem348); } xfer += iprot->readSetEnd(); } @@ -6881,10 +7346,10 @@ xfer += oprot->writeFieldBegin("open_txns", ::apache::thrift::protocol::T_SET, 2); { xfer += oprot->writeSetBegin(::apache::thrift::protocol::T_I64, static_cast(this->open_txns.size())); - std::set ::const_iterator _iter323; - for (_iter323 = this->open_txns.begin(); _iter323 != this->open_txns.end(); ++_iter323) + std::set ::const_iterator _iter349; + for (_iter349 = this->open_txns.begin(); _iter349 != this->open_txns.end(); ++_iter349) { - xfer += oprot->writeI64((*_iter323)); + xfer += oprot->writeI64((*_iter349)); } xfer += oprot->writeSetEnd(); } @@ -7025,14 +7490,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->txn_ids.clear(); - uint32_t _size324; - ::apache::thrift::protocol::TType _etype327; - xfer += iprot->readListBegin(_etype327, _size324); - this->txn_ids.resize(_size324); - uint32_t _i328; - for (_i328 = 0; _i328 < _size324; ++_i328) + uint32_t _size350; + ::apache::thrift::protocol::TType _etype353; + xfer += iprot->readListBegin(_etype353, _size350); + this->txn_ids.resize(_size350); + uint32_t _i354; + for (_i354 = 0; _i354 < _size350; ++_i354) { - xfer += iprot->readI64(this->txn_ids[_i328]); + xfer += iprot->readI64(this->txn_ids[_i354]); } xfer += iprot->readListEnd(); } @@ -7062,10 +7527,10 @@ xfer += oprot->writeFieldBegin("txn_ids", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_I64, static_cast(this->txn_ids.size())); - std::vector ::const_iterator _iter329; - for (_iter329 = this->txn_ids.begin(); _iter329 != this->txn_ids.end(); ++_iter329) + std::vector ::const_iterator _iter355; + for (_iter355 = this->txn_ids.begin(); _iter355 != this->txn_ids.end(); ++_iter355) { - xfer += oprot->writeI64((*_iter329)); + xfer += oprot->writeI64((*_iter355)); } xfer += oprot->writeListEnd(); } @@ -7237,9 +7702,9 @@ { case 1: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast330; - xfer += iprot->readI32(ecast330); - this->type = (LockType::type)ecast330; + int32_t ecast356; + xfer += iprot->readI32(ecast356); + this->type = (LockType::type)ecast356; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -7247,9 +7712,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast331; - xfer += iprot->readI32(ecast331); - this->level = (LockLevel::type)ecast331; + int32_t ecast357; + xfer += iprot->readI32(ecast357); + this->level = (LockLevel::type)ecast357; isset_level = true; } else { xfer += iprot->skip(ftype); @@ -7368,14 +7833,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->component.clear(); - uint32_t _size332; - ::apache::thrift::protocol::TType _etype335; - xfer += iprot->readListBegin(_etype335, _size332); - this->component.resize(_size332); - uint32_t _i336; - for (_i336 = 0; _i336 < _size332; ++_i336) + uint32_t _size358; + ::apache::thrift::protocol::TType _etype361; + xfer += iprot->readListBegin(_etype361, _size358); + this->component.resize(_size358); + uint32_t _i362; + for (_i362 = 0; _i362 < _size358; ++_i362) { - xfer += this->component[_i336].read(iprot); + xfer += this->component[_i362].read(iprot); } xfer += iprot->readListEnd(); } @@ -7433,10 +7898,10 @@ xfer += oprot->writeFieldBegin("component", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->component.size())); - std::vector ::const_iterator _iter337; - for (_iter337 = this->component.begin(); _iter337 != this->component.end(); ++_iter337) + std::vector ::const_iterator _iter363; + for (_iter363 = this->component.begin(); _iter363 != this->component.end(); ++_iter363) { - xfer += (*_iter337).write(oprot); + xfer += (*_iter363).write(oprot); } xfer += oprot->writeListEnd(); } @@ -7504,9 +7969,9 @@ break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast338; - xfer += iprot->readI32(ecast338); - this->state = (LockState::type)ecast338; + int32_t ecast364; + xfer += iprot->readI32(ecast364); + this->state = (LockState::type)ecast364; isset_state = true; } else { xfer += iprot->skip(ftype); @@ -7788,9 +8253,9 @@ break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast339; - xfer += iprot->readI32(ecast339); - this->state = (LockState::type)ecast339; + int32_t ecast365; + xfer += iprot->readI32(ecast365); + this->state = (LockState::type)ecast365; isset_state = true; } else { xfer += iprot->skip(ftype); @@ -7798,9 +8263,9 @@ break; case 6: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast340; - xfer += iprot->readI32(ecast340); - this->type = (LockType::type)ecast340; + int32_t ecast366; + xfer += iprot->readI32(ecast366); + this->type = (LockType::type)ecast366; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -7972,14 +8437,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->locks.clear(); - uint32_t _size341; - ::apache::thrift::protocol::TType _etype344; - xfer += iprot->readListBegin(_etype344, _size341); - this->locks.resize(_size341); - uint32_t _i345; - for (_i345 = 0; _i345 < _size341; ++_i345) + uint32_t _size367; + ::apache::thrift::protocol::TType _etype370; + xfer += iprot->readListBegin(_etype370, _size367); + this->locks.resize(_size367); + uint32_t _i371; + for (_i371 = 0; _i371 < _size367; ++_i371) { - xfer += this->locks[_i345].read(iprot); + xfer += this->locks[_i371].read(iprot); } xfer += iprot->readListEnd(); } @@ -8007,10 +8472,10 @@ xfer += oprot->writeFieldBegin("locks", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->locks.size())); - std::vector ::const_iterator _iter346; - for (_iter346 = this->locks.begin(); _iter346 != this->locks.end(); ++_iter346) + std::vector ::const_iterator _iter372; + for (_iter372 = this->locks.begin(); _iter372 != this->locks.end(); ++_iter372) { - xfer += (*_iter346).write(oprot); + xfer += (*_iter372).write(oprot); } xfer += oprot->writeListEnd(); } @@ -8213,15 +8678,15 @@ if (ftype == ::apache::thrift::protocol::T_SET) { { this->aborted.clear(); - uint32_t _size347; - ::apache::thrift::protocol::TType _etype350; - xfer += iprot->readSetBegin(_etype350, _size347); - uint32_t _i351; - for (_i351 = 0; _i351 < _size347; ++_i351) + uint32_t _size373; + ::apache::thrift::protocol::TType _etype376; + xfer += iprot->readSetBegin(_etype376, _size373); + uint32_t _i377; + for (_i377 = 0; _i377 < _size373; ++_i377) { - int64_t _elem352; - xfer += iprot->readI64(_elem352); - this->aborted.insert(_elem352); + int64_t _elem378; + xfer += iprot->readI64(_elem378); + this->aborted.insert(_elem378); } xfer += iprot->readSetEnd(); } @@ -8234,15 +8699,15 @@ if (ftype == ::apache::thrift::protocol::T_SET) { { this->nosuch.clear(); - uint32_t _size353; - ::apache::thrift::protocol::TType _etype356; - xfer += iprot->readSetBegin(_etype356, _size353); - uint32_t _i357; - for (_i357 = 0; _i357 < _size353; ++_i357) + uint32_t _size379; + ::apache::thrift::protocol::TType _etype382; + xfer += iprot->readSetBegin(_etype382, _size379); + uint32_t _i383; + for (_i383 = 0; _i383 < _size379; ++_i383) { - int64_t _elem358; - xfer += iprot->readI64(_elem358); - this->nosuch.insert(_elem358); + int64_t _elem384; + xfer += iprot->readI64(_elem384); + this->nosuch.insert(_elem384); } xfer += iprot->readSetEnd(); } @@ -8274,10 +8739,10 @@ xfer += oprot->writeFieldBegin("aborted", ::apache::thrift::protocol::T_SET, 1); { xfer += oprot->writeSetBegin(::apache::thrift::protocol::T_I64, static_cast(this->aborted.size())); - std::set ::const_iterator _iter359; - for (_iter359 = this->aborted.begin(); _iter359 != this->aborted.end(); ++_iter359) + std::set ::const_iterator _iter385; + for (_iter385 = this->aborted.begin(); _iter385 != this->aborted.end(); ++_iter385) { - xfer += oprot->writeI64((*_iter359)); + xfer += oprot->writeI64((*_iter385)); } xfer += oprot->writeSetEnd(); } @@ -8286,10 +8751,10 @@ xfer += oprot->writeFieldBegin("nosuch", ::apache::thrift::protocol::T_SET, 2); { xfer += oprot->writeSetBegin(::apache::thrift::protocol::T_I64, static_cast(this->nosuch.size())); - std::set ::const_iterator _iter360; - for (_iter360 = this->nosuch.begin(); _iter360 != this->nosuch.end(); ++_iter360) + std::set ::const_iterator _iter386; + for (_iter386 = this->nosuch.begin(); _iter386 != this->nosuch.end(); ++_iter386) { - xfer += oprot->writeI64((*_iter360)); + xfer += oprot->writeI64((*_iter386)); } xfer += oprot->writeSetEnd(); } @@ -8358,9 +8823,9 @@ break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast361; - xfer += iprot->readI32(ecast361); - this->type = (CompactionType::type)ecast361; + int32_t ecast387; + xfer += iprot->readI32(ecast387); + this->type = (CompactionType::type)ecast387; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -8535,9 +9000,9 @@ break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast362; - xfer += iprot->readI32(ecast362); - this->type = (CompactionType::type)ecast362; + int32_t ecast388; + xfer += iprot->readI32(ecast388); + this->type = (CompactionType::type)ecast388; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -8684,14 +9149,14 @@ if (ftype == ::apache::thrift::protocol::T_LIST) { { this->compacts.clear(); - uint32_t _size363; - ::apache::thrift::protocol::TType _etype366; - xfer += iprot->readListBegin(_etype366, _size363); - this->compacts.resize(_size363); - uint32_t _i367; - for (_i367 = 0; _i367 < _size363; ++_i367) + uint32_t _size389; + ::apache::thrift::protocol::TType _etype392; + xfer += iprot->readListBegin(_etype392, _size389); + this->compacts.resize(_size389); + uint32_t _i393; + for (_i393 = 0; _i393 < _size389; ++_i393) { - xfer += this->compacts[_i367].read(iprot); + xfer += this->compacts[_i393].read(iprot); } xfer += iprot->readListEnd(); } @@ -8721,10 +9186,10 @@ xfer += oprot->writeFieldBegin("compacts", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->compacts.size())); - std::vector ::const_iterator _iter368; - for (_iter368 = this->compacts.begin(); _iter368 != this->compacts.end(); ++_iter368) + std::vector ::const_iterator _iter394; + for (_iter394 = this->compacts.begin(); _iter394 != this->compacts.end(); ++_iter394) { - xfer += (*_iter368).write(oprot); + xfer += (*_iter394).write(oprot); } xfer += oprot->writeListEnd(); } Index: metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h =================================================================== --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h (revision 1619008) +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h (working copy) @@ -44,6 +44,7 @@ virtual void add_partition(Partition& _return, const Partition& new_part) = 0; virtual void add_partition_with_environment_context(Partition& _return, const Partition& new_part, const EnvironmentContext& environment_context) = 0; virtual int32_t add_partitions(const std::vector & new_parts) = 0; + virtual int32_t add_partitions_pspec(const std::vector & new_parts) = 0; virtual void append_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals) = 0; virtual void add_partitions_req(AddPartitionsResult& _return, const AddPartitionsRequest& request) = 0; virtual void append_partition_with_environment_context(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const EnvironmentContext& environment_context) = 0; @@ -60,11 +61,13 @@ 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; virtual void get_partitions_with_auth(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts, const std::string& user_name, const std::vector & group_names) = 0; + virtual void get_partitions_pspec(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int32_t max_parts) = 0; virtual void get_partition_names(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts) = 0; virtual void get_partitions_ps(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const int16_t max_parts) = 0; virtual void get_partitions_ps_with_auth(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const int16_t max_parts, const std::string& user_name, const std::vector & group_names) = 0; virtual void get_partition_names_ps(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals, const int16_t max_parts) = 0; virtual void get_partitions_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int16_t max_parts) = 0; + virtual void get_part_specs_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts) = 0; virtual void get_partitions_by_expr(PartitionsByExprResult& _return, const PartitionsByExprRequest& req) = 0; virtual void get_partitions_by_names(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::vector & names) = 0; virtual void alter_partition(const std::string& db_name, const std::string& tbl_name, const Partition& new_part) = 0; @@ -244,6 +247,10 @@ int32_t _return = 0; return _return; } + int32_t add_partitions_pspec(const std::vector & /* new_parts */) { + int32_t _return = 0; + return _return; + } void append_partition(Partition& /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const std::vector & /* part_vals */) { return; } @@ -296,6 +303,9 @@ void get_partitions_with_auth(std::vector & /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const int16_t /* max_parts */, const std::string& /* user_name */, const std::vector & /* group_names */) { return; } + void get_partitions_pspec(std::vector & /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const int32_t /* max_parts */) { + return; + } void get_partition_names(std::vector & /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const int16_t /* max_parts */) { return; } @@ -311,6 +321,9 @@ void get_partitions_by_filter(std::vector & /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const std::string& /* filter */, const int16_t /* max_parts */) { return; } + void get_part_specs_by_filter(std::vector & /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const std::string& /* filter */, const int32_t /* max_parts */) { + return; + } void get_partitions_by_expr(PartitionsByExprResult& /* _return */, const PartitionsByExprRequest& /* req */) { return; } @@ -4263,6 +4276,144 @@ }; +typedef struct _ThriftHiveMetastore_add_partitions_pspec_args__isset { + _ThriftHiveMetastore_add_partitions_pspec_args__isset() : new_parts(false) {} + bool new_parts; +} _ThriftHiveMetastore_add_partitions_pspec_args__isset; + +class ThriftHiveMetastore_add_partitions_pspec_args { + public: + + ThriftHiveMetastore_add_partitions_pspec_args() { + } + + virtual ~ThriftHiveMetastore_add_partitions_pspec_args() throw() {} + + std::vector new_parts; + + _ThriftHiveMetastore_add_partitions_pspec_args__isset __isset; + + void __set_new_parts(const std::vector & val) { + new_parts = val; + } + + bool operator == (const ThriftHiveMetastore_add_partitions_pspec_args & rhs) const + { + if (!(new_parts == rhs.new_parts)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_add_partitions_pspec_args &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_add_partitions_pspec_args & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + + +class ThriftHiveMetastore_add_partitions_pspec_pargs { + public: + + + virtual ~ThriftHiveMetastore_add_partitions_pspec_pargs() throw() {} + + const std::vector * new_parts; + + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_add_partitions_pspec_result__isset { + _ThriftHiveMetastore_add_partitions_pspec_result__isset() : success(false), o1(false), o2(false), o3(false) {} + bool success; + bool o1; + bool o2; + bool o3; +} _ThriftHiveMetastore_add_partitions_pspec_result__isset; + +class ThriftHiveMetastore_add_partitions_pspec_result { + public: + + ThriftHiveMetastore_add_partitions_pspec_result() : success(0) { + } + + virtual ~ThriftHiveMetastore_add_partitions_pspec_result() throw() {} + + int32_t success; + InvalidObjectException o1; + AlreadyExistsException o2; + MetaException o3; + + _ThriftHiveMetastore_add_partitions_pspec_result__isset __isset; + + void __set_success(const int32_t val) { + success = val; + } + + void __set_o1(const InvalidObjectException& val) { + o1 = val; + } + + void __set_o2(const AlreadyExistsException& val) { + o2 = val; + } + + void __set_o3(const MetaException& val) { + o3 = val; + } + + bool operator == (const ThriftHiveMetastore_add_partitions_pspec_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; + return true; + } + bool operator != (const ThriftHiveMetastore_add_partitions_pspec_result &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_add_partitions_pspec_result & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_add_partitions_pspec_presult__isset { + _ThriftHiveMetastore_add_partitions_pspec_presult__isset() : success(false), o1(false), o2(false), o3(false) {} + bool success; + bool o1; + bool o2; + bool o3; +} _ThriftHiveMetastore_add_partitions_pspec_presult__isset; + +class ThriftHiveMetastore_add_partitions_pspec_presult { + public: + + + virtual ~ThriftHiveMetastore_add_partitions_pspec_presult() throw() {} + + int32_t* success; + InvalidObjectException o1; + AlreadyExistsException o2; + MetaException o3; + + _ThriftHiveMetastore_add_partitions_pspec_presult__isset __isset; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + +}; + typedef struct _ThriftHiveMetastore_append_partition_args__isset { _ThriftHiveMetastore_append_partition_args__isset() : db_name(false), tbl_name(false), part_vals(false) {} bool db_name; @@ -6759,6 +6910,152 @@ }; +typedef struct _ThriftHiveMetastore_get_partitions_pspec_args__isset { + _ThriftHiveMetastore_get_partitions_pspec_args__isset() : db_name(false), tbl_name(false), max_parts(true) {} + bool db_name; + bool tbl_name; + bool max_parts; +} _ThriftHiveMetastore_get_partitions_pspec_args__isset; + +class ThriftHiveMetastore_get_partitions_pspec_args { + public: + + ThriftHiveMetastore_get_partitions_pspec_args() : db_name(), tbl_name(), max_parts(-1) { + } + + virtual ~ThriftHiveMetastore_get_partitions_pspec_args() throw() {} + + std::string db_name; + std::string tbl_name; + int32_t max_parts; + + _ThriftHiveMetastore_get_partitions_pspec_args__isset __isset; + + void __set_db_name(const std::string& val) { + db_name = val; + } + + void __set_tbl_name(const std::string& val) { + tbl_name = val; + } + + void __set_max_parts(const int32_t val) { + max_parts = val; + } + + bool operator == (const ThriftHiveMetastore_get_partitions_pspec_args & rhs) const + { + if (!(db_name == rhs.db_name)) + return false; + if (!(tbl_name == rhs.tbl_name)) + return false; + if (!(max_parts == rhs.max_parts)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_get_partitions_pspec_args &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_get_partitions_pspec_args & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + + +class ThriftHiveMetastore_get_partitions_pspec_pargs { + public: + + + virtual ~ThriftHiveMetastore_get_partitions_pspec_pargs() throw() {} + + const std::string* db_name; + const std::string* tbl_name; + const int32_t* max_parts; + + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_get_partitions_pspec_result__isset { + _ThriftHiveMetastore_get_partitions_pspec_result__isset() : success(false), o1(false), o2(false) {} + bool success; + bool o1; + bool o2; +} _ThriftHiveMetastore_get_partitions_pspec_result__isset; + +class ThriftHiveMetastore_get_partitions_pspec_result { + public: + + ThriftHiveMetastore_get_partitions_pspec_result() { + } + + virtual ~ThriftHiveMetastore_get_partitions_pspec_result() throw() {} + + std::vector success; + NoSuchObjectException o1; + MetaException o2; + + _ThriftHiveMetastore_get_partitions_pspec_result__isset __isset; + + void __set_success(const std::vector & val) { + success = val; + } + + void __set_o1(const NoSuchObjectException& val) { + o1 = val; + } + + void __set_o2(const MetaException& val) { + o2 = val; + } + + bool operator == (const ThriftHiveMetastore_get_partitions_pspec_result & rhs) const + { + if (!(success == rhs.success)) + return false; + if (!(o1 == rhs.o1)) + return false; + if (!(o2 == rhs.o2)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_get_partitions_pspec_result &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_get_partitions_pspec_result & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_get_partitions_pspec_presult__isset { + _ThriftHiveMetastore_get_partitions_pspec_presult__isset() : success(false), o1(false), o2(false) {} + bool success; + bool o1; + bool o2; +} _ThriftHiveMetastore_get_partitions_pspec_presult__isset; + +class ThriftHiveMetastore_get_partitions_pspec_presult { + public: + + + virtual ~ThriftHiveMetastore_get_partitions_pspec_presult() throw() {} + + std::vector * success; + NoSuchObjectException o1; + MetaException o2; + + _ThriftHiveMetastore_get_partitions_pspec_presult__isset __isset; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + +}; + typedef struct _ThriftHiveMetastore_get_partition_names_args__isset { _ThriftHiveMetastore_get_partition_names_args__isset() : db_name(false), tbl_name(false), max_parts(true) {} bool db_name; @@ -7533,6 +7830,161 @@ }; +typedef struct _ThriftHiveMetastore_get_part_specs_by_filter_args__isset { + _ThriftHiveMetastore_get_part_specs_by_filter_args__isset() : db_name(false), tbl_name(false), filter(false), max_parts(true) {} + bool db_name; + bool tbl_name; + bool filter; + bool max_parts; +} _ThriftHiveMetastore_get_part_specs_by_filter_args__isset; + +class ThriftHiveMetastore_get_part_specs_by_filter_args { + public: + + ThriftHiveMetastore_get_part_specs_by_filter_args() : db_name(), tbl_name(), filter(), max_parts(-1) { + } + + virtual ~ThriftHiveMetastore_get_part_specs_by_filter_args() throw() {} + + std::string db_name; + std::string tbl_name; + std::string filter; + int32_t max_parts; + + _ThriftHiveMetastore_get_part_specs_by_filter_args__isset __isset; + + void __set_db_name(const std::string& val) { + db_name = val; + } + + void __set_tbl_name(const std::string& val) { + tbl_name = val; + } + + void __set_filter(const std::string& val) { + filter = val; + } + + void __set_max_parts(const int32_t val) { + max_parts = val; + } + + bool operator == (const ThriftHiveMetastore_get_part_specs_by_filter_args & rhs) const + { + if (!(db_name == rhs.db_name)) + return false; + if (!(tbl_name == rhs.tbl_name)) + return false; + if (!(filter == rhs.filter)) + return false; + if (!(max_parts == rhs.max_parts)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_get_part_specs_by_filter_args &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_get_part_specs_by_filter_args & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + + +class ThriftHiveMetastore_get_part_specs_by_filter_pargs { + public: + + + virtual ~ThriftHiveMetastore_get_part_specs_by_filter_pargs() throw() {} + + const std::string* db_name; + const std::string* tbl_name; + const std::string* filter; + const int32_t* max_parts; + + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_get_part_specs_by_filter_result__isset { + _ThriftHiveMetastore_get_part_specs_by_filter_result__isset() : success(false), o1(false), o2(false) {} + bool success; + bool o1; + bool o2; +} _ThriftHiveMetastore_get_part_specs_by_filter_result__isset; + +class ThriftHiveMetastore_get_part_specs_by_filter_result { + public: + + ThriftHiveMetastore_get_part_specs_by_filter_result() { + } + + virtual ~ThriftHiveMetastore_get_part_specs_by_filter_result() throw() {} + + std::vector success; + MetaException o1; + NoSuchObjectException o2; + + _ThriftHiveMetastore_get_part_specs_by_filter_result__isset __isset; + + void __set_success(const std::vector & val) { + success = val; + } + + void __set_o1(const MetaException& val) { + o1 = val; + } + + void __set_o2(const NoSuchObjectException& val) { + o2 = val; + } + + bool operator == (const ThriftHiveMetastore_get_part_specs_by_filter_result & rhs) const + { + if (!(success == rhs.success)) + return false; + if (!(o1 == rhs.o1)) + return false; + if (!(o2 == rhs.o2)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_get_part_specs_by_filter_result &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_get_part_specs_by_filter_result & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_get_part_specs_by_filter_presult__isset { + _ThriftHiveMetastore_get_part_specs_by_filter_presult__isset() : success(false), o1(false), o2(false) {} + bool success; + bool o1; + bool o2; +} _ThriftHiveMetastore_get_part_specs_by_filter_presult__isset; + +class ThriftHiveMetastore_get_part_specs_by_filter_presult { + public: + + + virtual ~ThriftHiveMetastore_get_part_specs_by_filter_presult() throw() {} + + std::vector * success; + MetaException o1; + NoSuchObjectException o2; + + _ThriftHiveMetastore_get_part_specs_by_filter_presult__isset __isset; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + +}; + typedef struct _ThriftHiveMetastore_get_partitions_by_expr_args__isset { _ThriftHiveMetastore_get_partitions_by_expr_args__isset() : req(false) {} bool req; @@ -15909,6 +16361,9 @@ int32_t add_partitions(const std::vector & new_parts); void send_add_partitions(const std::vector & new_parts); int32_t recv_add_partitions(); + int32_t add_partitions_pspec(const std::vector & new_parts); + void send_add_partitions_pspec(const std::vector & new_parts); + int32_t recv_add_partitions_pspec(); void append_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals); void send_append_partition(const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals); void recv_append_partition(Partition& _return); @@ -15957,6 +16412,9 @@ void get_partitions_with_auth(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts, const std::string& user_name, const std::vector & group_names); void send_get_partitions_with_auth(const std::string& db_name, const std::string& tbl_name, const int16_t max_parts, const std::string& user_name, const std::vector & group_names); void recv_get_partitions_with_auth(std::vector & _return); + void get_partitions_pspec(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int32_t max_parts); + void send_get_partitions_pspec(const std::string& db_name, const std::string& tbl_name, const int32_t max_parts); + void recv_get_partitions_pspec(std::vector & _return); void get_partition_names(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts); void send_get_partition_names(const std::string& db_name, const std::string& tbl_name, const int16_t max_parts); void recv_get_partition_names(std::vector & _return); @@ -15972,6 +16430,9 @@ void get_partitions_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int16_t max_parts); void send_get_partitions_by_filter(const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int16_t max_parts); void recv_get_partitions_by_filter(std::vector & _return); + void get_part_specs_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts); + void send_get_part_specs_by_filter(const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts); + void recv_get_part_specs_by_filter(std::vector & _return); void get_partitions_by_expr(PartitionsByExprResult& _return, const PartitionsByExprRequest& req); void send_get_partitions_by_expr(const PartitionsByExprRequest& req); void recv_get_partitions_by_expr(PartitionsByExprResult& _return); @@ -16199,6 +16660,7 @@ void process_add_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_add_partition_with_environment_context(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_add_partitions(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); + void process_add_partitions_pspec(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_append_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_add_partitions_req(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_append_partition_with_environment_context(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); @@ -16215,11 +16677,13 @@ 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); void process_get_partitions_with_auth(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); + void process_get_partitions_pspec(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partition_names(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partitions_ps(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partitions_ps_with_auth(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partition_names_ps(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partitions_by_filter(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); + void process_get_part_specs_by_filter(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partitions_by_expr(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_partitions_by_names(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_alter_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); @@ -16315,6 +16779,7 @@ processMap_["add_partition"] = &ThriftHiveMetastoreProcessor::process_add_partition; processMap_["add_partition_with_environment_context"] = &ThriftHiveMetastoreProcessor::process_add_partition_with_environment_context; processMap_["add_partitions"] = &ThriftHiveMetastoreProcessor::process_add_partitions; + processMap_["add_partitions_pspec"] = &ThriftHiveMetastoreProcessor::process_add_partitions_pspec; processMap_["append_partition"] = &ThriftHiveMetastoreProcessor::process_append_partition; processMap_["add_partitions_req"] = &ThriftHiveMetastoreProcessor::process_add_partitions_req; processMap_["append_partition_with_environment_context"] = &ThriftHiveMetastoreProcessor::process_append_partition_with_environment_context; @@ -16331,11 +16796,13 @@ processMap_["get_partition_by_name"] = &ThriftHiveMetastoreProcessor::process_get_partition_by_name; processMap_["get_partitions"] = &ThriftHiveMetastoreProcessor::process_get_partitions; processMap_["get_partitions_with_auth"] = &ThriftHiveMetastoreProcessor::process_get_partitions_with_auth; + processMap_["get_partitions_pspec"] = &ThriftHiveMetastoreProcessor::process_get_partitions_pspec; processMap_["get_partition_names"] = &ThriftHiveMetastoreProcessor::process_get_partition_names; processMap_["get_partitions_ps"] = &ThriftHiveMetastoreProcessor::process_get_partitions_ps; processMap_["get_partitions_ps_with_auth"] = &ThriftHiveMetastoreProcessor::process_get_partitions_ps_with_auth; processMap_["get_partition_names_ps"] = &ThriftHiveMetastoreProcessor::process_get_partition_names_ps; processMap_["get_partitions_by_filter"] = &ThriftHiveMetastoreProcessor::process_get_partitions_by_filter; + processMap_["get_part_specs_by_filter"] = &ThriftHiveMetastoreProcessor::process_get_part_specs_by_filter; processMap_["get_partitions_by_expr"] = &ThriftHiveMetastoreProcessor::process_get_partitions_by_expr; processMap_["get_partitions_by_names"] = &ThriftHiveMetastoreProcessor::process_get_partitions_by_names; processMap_["alter_partition"] = &ThriftHiveMetastoreProcessor::process_alter_partition; @@ -16699,6 +17166,15 @@ return ifaces_[i]->add_partitions(new_parts); } + int32_t add_partitions_pspec(const std::vector & new_parts) { + size_t sz = ifaces_.size(); + size_t i = 0; + for (; i < (sz - 1); ++i) { + ifaces_[i]->add_partitions_pspec(new_parts); + } + return ifaces_[i]->add_partitions_pspec(new_parts); + } + void append_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals) { size_t sz = ifaces_.size(); size_t i = 0; @@ -16855,6 +17331,16 @@ return; } + void get_partitions_pspec(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int32_t max_parts) { + size_t sz = ifaces_.size(); + size_t i = 0; + for (; i < (sz - 1); ++i) { + ifaces_[i]->get_partitions_pspec(_return, db_name, tbl_name, max_parts); + } + ifaces_[i]->get_partitions_pspec(_return, db_name, tbl_name, max_parts); + return; + } + void get_partition_names(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts) { size_t sz = ifaces_.size(); size_t i = 0; @@ -16905,6 +17391,16 @@ return; } + void get_part_specs_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts) { + size_t sz = ifaces_.size(); + size_t i = 0; + for (; i < (sz - 1); ++i) { + ifaces_[i]->get_part_specs_by_filter(_return, db_name, tbl_name, filter, max_parts); + } + ifaces_[i]->get_part_specs_by_filter(_return, db_name, tbl_name, filter, max_parts); + return; + } + void get_partitions_by_expr(PartitionsByExprResult& _return, const PartitionsByExprRequest& req) { size_t sz = ifaces_.size(); size_t i = 0; Index: metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h =================================================================== --- metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h (revision 1619008) +++ metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h (working copy) @@ -1849,6 +1849,267 @@ void swap(Partition &a, Partition &b); +typedef struct _PartitionWithoutSD__isset { + _PartitionWithoutSD__isset() : values(false), createTime(false), lastAccessTime(false), relativePath(false), parameters(false), privileges(false) {} + bool values; + bool createTime; + bool lastAccessTime; + bool relativePath; + bool parameters; + bool privileges; +} _PartitionWithoutSD__isset; + +class PartitionWithoutSD { + public: + + static const char* ascii_fingerprint; // = "D79FA44499888D0E50B5625E0C536DEA"; + static const uint8_t binary_fingerprint[16]; // = {0xD7,0x9F,0xA4,0x44,0x99,0x88,0x8D,0x0E,0x50,0xB5,0x62,0x5E,0x0C,0x53,0x6D,0xEA}; + + PartitionWithoutSD() : createTime(0), lastAccessTime(0), relativePath() { + } + + virtual ~PartitionWithoutSD() throw() {} + + std::vector values; + int32_t createTime; + int32_t lastAccessTime; + std::string relativePath; + std::map parameters; + PrincipalPrivilegeSet privileges; + + _PartitionWithoutSD__isset __isset; + + void __set_values(const std::vector & val) { + values = val; + } + + void __set_createTime(const int32_t val) { + createTime = val; + } + + void __set_lastAccessTime(const int32_t val) { + lastAccessTime = val; + } + + void __set_relativePath(const std::string& val) { + relativePath = val; + } + + void __set_parameters(const std::map & val) { + parameters = val; + } + + void __set_privileges(const PrincipalPrivilegeSet& val) { + privileges = val; + __isset.privileges = true; + } + + bool operator == (const PartitionWithoutSD & rhs) const + { + if (!(values == rhs.values)) + return false; + if (!(createTime == rhs.createTime)) + return false; + if (!(lastAccessTime == rhs.lastAccessTime)) + return false; + if (!(relativePath == rhs.relativePath)) + return false; + if (!(parameters == rhs.parameters)) + return false; + if (__isset.privileges != rhs.__isset.privileges) + return false; + else if (__isset.privileges && !(privileges == rhs.privileges)) + return false; + return true; + } + bool operator != (const PartitionWithoutSD &rhs) const { + return !(*this == rhs); + } + + bool operator < (const PartitionWithoutSD & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +void swap(PartitionWithoutSD &a, PartitionWithoutSD &b); + +typedef struct _PartitionSpecWithSharedSD__isset { + _PartitionSpecWithSharedSD__isset() : partitions(false), sd(false) {} + bool partitions; + bool sd; +} _PartitionSpecWithSharedSD__isset; + +class PartitionSpecWithSharedSD { + public: + + static const char* ascii_fingerprint; // = "7BEE9305B42DCD083FF06BEE6DDC61CF"; + static const uint8_t binary_fingerprint[16]; // = {0x7B,0xEE,0x93,0x05,0xB4,0x2D,0xCD,0x08,0x3F,0xF0,0x6B,0xEE,0x6D,0xDC,0x61,0xCF}; + + PartitionSpecWithSharedSD() { + } + + virtual ~PartitionSpecWithSharedSD() throw() {} + + std::vector partitions; + StorageDescriptor sd; + + _PartitionSpecWithSharedSD__isset __isset; + + void __set_partitions(const std::vector & val) { + partitions = val; + } + + void __set_sd(const StorageDescriptor& val) { + sd = val; + } + + bool operator == (const PartitionSpecWithSharedSD & rhs) const + { + if (!(partitions == rhs.partitions)) + return false; + if (!(sd == rhs.sd)) + return false; + return true; + } + bool operator != (const PartitionSpecWithSharedSD &rhs) const { + return !(*this == rhs); + } + + bool operator < (const PartitionSpecWithSharedSD & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +void swap(PartitionSpecWithSharedSD &a, PartitionSpecWithSharedSD &b); + +typedef struct _PartitionListComposingSpec__isset { + _PartitionListComposingSpec__isset() : partitions(false) {} + bool partitions; +} _PartitionListComposingSpec__isset; + +class PartitionListComposingSpec { + public: + + static const char* ascii_fingerprint; // = "A048235CB9A257C8A74E3691BEFE0674"; + static const uint8_t binary_fingerprint[16]; // = {0xA0,0x48,0x23,0x5C,0xB9,0xA2,0x57,0xC8,0xA7,0x4E,0x36,0x91,0xBE,0xFE,0x06,0x74}; + + PartitionListComposingSpec() { + } + + virtual ~PartitionListComposingSpec() throw() {} + + std::vector partitions; + + _PartitionListComposingSpec__isset __isset; + + void __set_partitions(const std::vector & val) { + partitions = val; + } + + bool operator == (const PartitionListComposingSpec & rhs) const + { + if (!(partitions == rhs.partitions)) + return false; + return true; + } + bool operator != (const PartitionListComposingSpec &rhs) const { + return !(*this == rhs); + } + + bool operator < (const PartitionListComposingSpec & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +void swap(PartitionListComposingSpec &a, PartitionListComposingSpec &b); + +typedef struct _PartitionSpec__isset { + _PartitionSpec__isset() : dbName(false), tableName(false), rootPath(false), sharedSDPartitionSpec(false), partitionList(false) {} + bool dbName; + bool tableName; + bool rootPath; + bool sharedSDPartitionSpec; + bool partitionList; +} _PartitionSpec__isset; + +class PartitionSpec { + public: + + static const char* ascii_fingerprint; // = "C3F548C24D072CF6422F25096143E3E8"; + static const uint8_t binary_fingerprint[16]; // = {0xC3,0xF5,0x48,0xC2,0x4D,0x07,0x2C,0xF6,0x42,0x2F,0x25,0x09,0x61,0x43,0xE3,0xE8}; + + PartitionSpec() : dbName(), tableName(), rootPath() { + } + + virtual ~PartitionSpec() throw() {} + + std::string dbName; + std::string tableName; + std::string rootPath; + PartitionSpecWithSharedSD sharedSDPartitionSpec; + PartitionListComposingSpec partitionList; + + _PartitionSpec__isset __isset; + + void __set_dbName(const std::string& val) { + dbName = val; + } + + void __set_tableName(const std::string& val) { + tableName = val; + } + + void __set_rootPath(const std::string& val) { + rootPath = val; + } + + void __set_sharedSDPartitionSpec(const PartitionSpecWithSharedSD& val) { + sharedSDPartitionSpec = val; + __isset.sharedSDPartitionSpec = true; + } + + void __set_partitionList(const PartitionListComposingSpec& val) { + partitionList = val; + __isset.partitionList = true; + } + + bool operator == (const PartitionSpec & rhs) const + { + if (!(dbName == rhs.dbName)) + return false; + if (!(tableName == rhs.tableName)) + return false; + if (!(rootPath == rhs.rootPath)) + return false; + if (__isset.sharedSDPartitionSpec != rhs.__isset.sharedSDPartitionSpec) + return false; + else if (__isset.sharedSDPartitionSpec && !(sharedSDPartitionSpec == rhs.sharedSDPartitionSpec)) + return false; + if (__isset.partitionList != rhs.__isset.partitionList) + return false; + else if (__isset.partitionList && !(partitionList == rhs.partitionList)) + return false; + return true; + } + bool operator != (const PartitionSpec &rhs) const { + return !(*this == rhs); + } + + bool operator < (const PartitionSpec & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +void swap(PartitionSpec &a, PartitionSpec &b); + typedef struct _Index__isset { _Index__isset() : indexName(false), indexHandlerClass(false), dbName(false), origTableName(false), createTime(false), lastAccessTime(false), indexTableName(false), sd(false), parameters(false), deferredRebuild(false) {} bool indexName; Index: metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp =================================================================== --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp (revision 1619008) +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp (working copy) @@ -162,6 +162,11 @@ printf("add_partitions\n"); } + int32_t add_partitions_pspec(const std::vector & new_parts) { + // Your implementation goes here + printf("add_partitions_pspec\n"); + } + void append_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector & part_vals) { // Your implementation goes here printf("append_partition\n"); @@ -242,6 +247,11 @@ printf("get_partitions_with_auth\n"); } + void get_partitions_pspec(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int32_t max_parts) { + // Your implementation goes here + printf("get_partitions_pspec\n"); + } + void get_partition_names(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts) { // Your implementation goes here printf("get_partition_names\n"); @@ -267,6 +277,11 @@ printf("get_partitions_by_filter\n"); } + void get_part_specs_by_filter(std::vector & _return, const std::string& db_name, const std::string& tbl_name, const std::string& filter, const int32_t max_parts) { + // Your implementation goes here + printf("get_part_specs_by_filter\n"); + } + void get_partitions_by_expr(PartitionsByExprResult& _return, const PartitionsByExprRequest& req) { // Your implementation goes here printf("get_partitions_by_expr\n"); Index: metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb =================================================================== --- metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb (revision 1619008) +++ metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb (working copy) @@ -485,6 +485,24 @@ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'add_partitions failed: unknown result') end + def add_partitions_pspec(new_parts) + send_add_partitions_pspec(new_parts) + return recv_add_partitions_pspec() + end + + def send_add_partitions_pspec(new_parts) + send_message('add_partitions_pspec', Add_partitions_pspec_args, :new_parts => new_parts) + end + + def recv_add_partitions_pspec() + result = receive_message(Add_partitions_pspec_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 ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'add_partitions_pspec failed: unknown result') + end + def append_partition(db_name, tbl_name, part_vals) send_append_partition(db_name, tbl_name, part_vals) return recv_append_partition() @@ -764,6 +782,23 @@ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'get_partitions_with_auth failed: unknown result') end + def get_partitions_pspec(db_name, tbl_name, max_parts) + send_get_partitions_pspec(db_name, tbl_name, max_parts) + return recv_get_partitions_pspec() + end + + def send_get_partitions_pspec(db_name, tbl_name, max_parts) + send_message('get_partitions_pspec', Get_partitions_pspec_args, :db_name => db_name, :tbl_name => tbl_name, :max_parts => max_parts) + end + + def recv_get_partitions_pspec() + result = receive_message(Get_partitions_pspec_result) + return result.success unless result.success.nil? + raise result.o1 unless result.o1.nil? + raise result.o2 unless result.o2.nil? + raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'get_partitions_pspec failed: unknown result') + end + def get_partition_names(db_name, tbl_name, max_parts) send_get_partition_names(db_name, tbl_name, max_parts) return recv_get_partition_names() @@ -848,6 +883,23 @@ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'get_partitions_by_filter failed: unknown result') end + def get_part_specs_by_filter(db_name, tbl_name, filter, max_parts) + send_get_part_specs_by_filter(db_name, tbl_name, filter, max_parts) + return recv_get_part_specs_by_filter() + end + + def send_get_part_specs_by_filter(db_name, tbl_name, filter, max_parts) + send_message('get_part_specs_by_filter', Get_part_specs_by_filter_args, :db_name => db_name, :tbl_name => tbl_name, :filter => filter, :max_parts => max_parts) + end + + def recv_get_part_specs_by_filter() + result = receive_message(Get_part_specs_by_filter_result) + return result.success unless result.success.nil? + raise result.o1 unless result.o1.nil? + raise result.o2 unless result.o2.nil? + raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'get_part_specs_by_filter failed: unknown result') + end + def get_partitions_by_expr(req) send_get_partitions_by_expr(req) return recv_get_partitions_by_expr() @@ -2273,6 +2325,21 @@ write_result(result, oprot, 'add_partitions', seqid) end + def process_add_partitions_pspec(seqid, iprot, oprot) + args = read_args(iprot, Add_partitions_pspec_args) + result = Add_partitions_pspec_result.new() + begin + result.success = @handler.add_partitions_pspec(args.new_parts) + rescue ::InvalidObjectException => o1 + result.o1 = o1 + rescue ::AlreadyExistsException => o2 + result.o2 = o2 + rescue ::MetaException => o3 + result.o3 = o3 + end + write_result(result, oprot, 'add_partitions_pspec', seqid) + end + def process_append_partition(seqid, iprot, oprot) args = read_args(iprot, Append_partition_args) result = Append_partition_result.new() @@ -2495,6 +2562,19 @@ write_result(result, oprot, 'get_partitions_with_auth', seqid) end + def process_get_partitions_pspec(seqid, iprot, oprot) + args = read_args(iprot, Get_partitions_pspec_args) + result = Get_partitions_pspec_result.new() + begin + result.success = @handler.get_partitions_pspec(args.db_name, args.tbl_name, args.max_parts) + rescue ::NoSuchObjectException => o1 + result.o1 = o1 + rescue ::MetaException => o2 + result.o2 = o2 + end + write_result(result, oprot, 'get_partitions_pspec', seqid) + end + def process_get_partition_names(seqid, iprot, oprot) args = read_args(iprot, Get_partition_names_args) result = Get_partition_names_result.new() @@ -2558,6 +2638,19 @@ write_result(result, oprot, 'get_partitions_by_filter', seqid) end + def process_get_part_specs_by_filter(seqid, iprot, oprot) + args = read_args(iprot, Get_part_specs_by_filter_args) + result = Get_part_specs_by_filter_result.new() + begin + result.success = @handler.get_part_specs_by_filter(args.db_name, args.tbl_name, args.filter, args.max_parts) + rescue ::MetaException => o1 + result.o1 = o1 + rescue ::NoSuchObjectException => o2 + result.o2 = o2 + end + write_result(result, oprot, 'get_part_specs_by_filter', seqid) + end + def process_get_partitions_by_expr(seqid, iprot, oprot) args = read_args(iprot, Get_partitions_by_expr_args) result = Get_partitions_by_expr_result.new() @@ -4386,6 +4479,44 @@ ::Thrift::Struct.generate_accessors self end + class Add_partitions_pspec_args + include ::Thrift::Struct, ::Thrift::Struct_Union + NEW_PARTS = 1 + + FIELDS = { + NEW_PARTS => {:type => ::Thrift::Types::LIST, :name => 'new_parts', :element => {:type => ::Thrift::Types::STRUCT, :class => ::PartitionSpec}} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + + class Add_partitions_pspec_result + include ::Thrift::Struct, ::Thrift::Struct_Union + SUCCESS = 0 + O1 = 1 + O2 = 2 + O3 = 3 + + FIELDS = { + SUCCESS => {:type => ::Thrift::Types::I32, :name => 'success'}, + O1 => {:type => ::Thrift::Types::STRUCT, :name => 'o1', :class => ::InvalidObjectException}, + O2 => {:type => ::Thrift::Types::STRUCT, :name => 'o2', :class => ::AlreadyExistsException}, + O3 => {:type => ::Thrift::Types::STRUCT, :name => 'o3', :class => ::MetaException} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + class Append_partition_args include ::Thrift::Struct, ::Thrift::Struct_Union DB_NAME = 1 @@ -5060,6 +5191,46 @@ ::Thrift::Struct.generate_accessors self end + class Get_partitions_pspec_args + include ::Thrift::Struct, ::Thrift::Struct_Union + DB_NAME = 1 + TBL_NAME = 2 + MAX_PARTS = 3 + + FIELDS = { + DB_NAME => {:type => ::Thrift::Types::STRING, :name => 'db_name'}, + TBL_NAME => {:type => ::Thrift::Types::STRING, :name => 'tbl_name'}, + MAX_PARTS => {:type => ::Thrift::Types::I32, :name => 'max_parts', :default => -1} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + + class Get_partitions_pspec_result + include ::Thrift::Struct, ::Thrift::Struct_Union + SUCCESS = 0 + O1 = 1 + O2 = 2 + + FIELDS = { + SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => ::PartitionSpec}}, + O1 => {:type => ::Thrift::Types::STRUCT, :name => 'o1', :class => ::NoSuchObjectException}, + O2 => {:type => ::Thrift::Types::STRUCT, :name => 'o2', :class => ::MetaException} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + class Get_partition_names_args include ::Thrift::Struct, ::Thrift::Struct_Union DB_NAME = 1 @@ -5270,6 +5441,48 @@ ::Thrift::Struct.generate_accessors self end + class Get_part_specs_by_filter_args + include ::Thrift::Struct, ::Thrift::Struct_Union + DB_NAME = 1 + TBL_NAME = 2 + FILTER = 3 + MAX_PARTS = 4 + + FIELDS = { + DB_NAME => {:type => ::Thrift::Types::STRING, :name => 'db_name'}, + TBL_NAME => {:type => ::Thrift::Types::STRING, :name => 'tbl_name'}, + FILTER => {:type => ::Thrift::Types::STRING, :name => 'filter'}, + MAX_PARTS => {:type => ::Thrift::Types::I32, :name => 'max_parts', :default => -1} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + + class Get_part_specs_by_filter_result + include ::Thrift::Struct, ::Thrift::Struct_Union + SUCCESS = 0 + O1 = 1 + O2 = 2 + + FIELDS = { + SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => ::PartitionSpec}}, + O1 => {:type => ::Thrift::Types::STRUCT, :name => 'o1', :class => ::MetaException}, + O2 => {:type => ::Thrift::Types::STRUCT, :name => 'o2', :class => ::NoSuchObjectException} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + class Get_partitions_by_expr_args include ::Thrift::Struct, ::Thrift::Struct_Union REQ = 1 Index: metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb =================================================================== --- metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb (revision 1619008) +++ metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb (working copy) @@ -687,6 +687,90 @@ ::Thrift::Struct.generate_accessors self end +class PartitionWithoutSD + include ::Thrift::Struct, ::Thrift::Struct_Union + VALUES = 1 + CREATETIME = 2 + LASTACCESSTIME = 3 + RELATIVEPATH = 4 + PARAMETERS = 5 + PRIVILEGES = 6 + + FIELDS = { + VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::STRING}}, + CREATETIME => {:type => ::Thrift::Types::I32, :name => 'createTime'}, + LASTACCESSTIME => {:type => ::Thrift::Types::I32, :name => 'lastAccessTime'}, + RELATIVEPATH => {:type => ::Thrift::Types::STRING, :name => 'relativePath'}, + PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}, + PRIVILEGES => {:type => ::Thrift::Types::STRUCT, :name => 'privileges', :class => ::PrincipalPrivilegeSet, :optional => true} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self +end + +class PartitionSpecWithSharedSD + include ::Thrift::Struct, ::Thrift::Struct_Union + PARTITIONS = 1 + SD = 2 + + FIELDS = { + PARTITIONS => {:type => ::Thrift::Types::LIST, :name => 'partitions', :element => {:type => ::Thrift::Types::STRUCT, :class => ::PartitionWithoutSD}}, + SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => ::StorageDescriptor} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self +end + +class PartitionListComposingSpec + include ::Thrift::Struct, ::Thrift::Struct_Union + PARTITIONS = 1 + + FIELDS = { + PARTITIONS => {:type => ::Thrift::Types::LIST, :name => 'partitions', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Partition}} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self +end + +class PartitionSpec + include ::Thrift::Struct, ::Thrift::Struct_Union + DBNAME = 1 + TABLENAME = 2 + ROOTPATH = 3 + SHAREDSDPARTITIONSPEC = 4 + PARTITIONLIST = 5 + + FIELDS = { + DBNAME => {:type => ::Thrift::Types::STRING, :name => 'dbName'}, + TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName'}, + ROOTPATH => {:type => ::Thrift::Types::STRING, :name => 'rootPath'}, + SHAREDSDPARTITIONSPEC => {:type => ::Thrift::Types::STRUCT, :name => 'sharedSDPartitionSpec', :class => ::PartitionSpecWithSharedSD, :optional => true}, + PARTITIONLIST => {:type => ::Thrift::Types::STRUCT, :name => 'partitionList', :class => ::PartitionListComposingSpec, :optional => true} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self +end + class Index include ::Thrift::Struct, ::Thrift::Struct_Union INDEXNAME = 1 Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AggrStats.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AggrStats.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AggrStats.java (working copy) @@ -435,14 +435,14 @@ case 1: // COL_STATS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list244 = iprot.readListBegin(); - struct.colStats = new ArrayList(_list244.size); - for (int _i245 = 0; _i245 < _list244.size; ++_i245) + org.apache.thrift.protocol.TList _list278 = iprot.readListBegin(); + struct.colStats = new ArrayList(_list278.size); + for (int _i279 = 0; _i279 < _list278.size; ++_i279) { - ColumnStatisticsObj _elem246; // required - _elem246 = new ColumnStatisticsObj(); - _elem246.read(iprot); - struct.colStats.add(_elem246); + ColumnStatisticsObj _elem280; // required + _elem280 = new ColumnStatisticsObj(); + _elem280.read(iprot); + struct.colStats.add(_elem280); } iprot.readListEnd(); } @@ -476,9 +476,9 @@ oprot.writeFieldBegin(COL_STATS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.colStats.size())); - for (ColumnStatisticsObj _iter247 : struct.colStats) + for (ColumnStatisticsObj _iter281 : struct.colStats) { - _iter247.write(oprot); + _iter281.write(oprot); } oprot.writeListEnd(); } @@ -506,9 +506,9 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.colStats.size()); - for (ColumnStatisticsObj _iter248 : struct.colStats) + for (ColumnStatisticsObj _iter282 : struct.colStats) { - _iter248.write(oprot); + _iter282.write(oprot); } } oprot.writeI64(struct.partsFound); @@ -518,14 +518,14 @@ public void read(org.apache.thrift.protocol.TProtocol prot, AggrStats struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TList _list249 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.colStats = new ArrayList(_list249.size); - for (int _i250 = 0; _i250 < _list249.size; ++_i250) + org.apache.thrift.protocol.TList _list283 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.colStats = new ArrayList(_list283.size); + for (int _i284 = 0; _i284 < _list283.size; ++_i284) { - ColumnStatisticsObj _elem251; // required - _elem251 = new ColumnStatisticsObj(); - _elem251.read(iprot); - struct.colStats.add(_elem251); + ColumnStatisticsObj _elem285; // required + _elem285 = new ColumnStatisticsObj(); + _elem285.read(iprot); + struct.colStats.add(_elem285); } } struct.setColStatsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ColumnStatistics.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ColumnStatistics.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ColumnStatistics.java (working copy) @@ -447,14 +447,14 @@ case 2: // STATS_OBJ if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list236 = iprot.readListBegin(); - struct.statsObj = new ArrayList(_list236.size); - for (int _i237 = 0; _i237 < _list236.size; ++_i237) + org.apache.thrift.protocol.TList _list270 = iprot.readListBegin(); + struct.statsObj = new ArrayList(_list270.size); + for (int _i271 = 0; _i271 < _list270.size; ++_i271) { - ColumnStatisticsObj _elem238; // required - _elem238 = new ColumnStatisticsObj(); - _elem238.read(iprot); - struct.statsObj.add(_elem238); + ColumnStatisticsObj _elem272; // required + _elem272 = new ColumnStatisticsObj(); + _elem272.read(iprot); + struct.statsObj.add(_elem272); } iprot.readListEnd(); } @@ -485,9 +485,9 @@ oprot.writeFieldBegin(STATS_OBJ_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.statsObj.size())); - for (ColumnStatisticsObj _iter239 : struct.statsObj) + for (ColumnStatisticsObj _iter273 : struct.statsObj) { - _iter239.write(oprot); + _iter273.write(oprot); } oprot.writeListEnd(); } @@ -513,9 +513,9 @@ struct.statsDesc.write(oprot); { oprot.writeI32(struct.statsObj.size()); - for (ColumnStatisticsObj _iter240 : struct.statsObj) + for (ColumnStatisticsObj _iter274 : struct.statsObj) { - _iter240.write(oprot); + _iter274.write(oprot); } } } @@ -527,14 +527,14 @@ struct.statsDesc.read(iprot); struct.setStatsDescIsSet(true); { - org.apache.thrift.protocol.TList _list241 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.statsObj = new ArrayList(_list241.size); - for (int _i242 = 0; _i242 < _list241.size; ++_i242) + org.apache.thrift.protocol.TList _list275 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.statsObj = new ArrayList(_list275.size); + for (int _i276 = 0; _i276 < _list275.size; ++_i276) { - ColumnStatisticsObj _elem243; // required - _elem243 = new ColumnStatisticsObj(); - _elem243.read(iprot); - struct.statsObj.add(_elem243); + ColumnStatisticsObj _elem277; // required + _elem277 = new ColumnStatisticsObj(); + _elem277.read(iprot); + struct.statsObj.add(_elem277); } } struct.setStatsObjIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsRequest.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsRequest.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsRequest.java (working copy) @@ -641,13 +641,13 @@ case 3: // COL_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list322 = iprot.readListBegin(); - struct.colNames = new ArrayList(_list322.size); - for (int _i323 = 0; _i323 < _list322.size; ++_i323) + org.apache.thrift.protocol.TList _list356 = iprot.readListBegin(); + struct.colNames = new ArrayList(_list356.size); + for (int _i357 = 0; _i357 < _list356.size; ++_i357) { - String _elem324; // required - _elem324 = iprot.readString(); - struct.colNames.add(_elem324); + String _elem358; // required + _elem358 = iprot.readString(); + struct.colNames.add(_elem358); } iprot.readListEnd(); } @@ -659,13 +659,13 @@ case 4: // PART_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list325 = iprot.readListBegin(); - struct.partNames = new ArrayList(_list325.size); - for (int _i326 = 0; _i326 < _list325.size; ++_i326) + org.apache.thrift.protocol.TList _list359 = iprot.readListBegin(); + struct.partNames = new ArrayList(_list359.size); + for (int _i360 = 0; _i360 < _list359.size; ++_i360) { - String _elem327; // required - _elem327 = iprot.readString(); - struct.partNames.add(_elem327); + String _elem361; // required + _elem361 = iprot.readString(); + struct.partNames.add(_elem361); } iprot.readListEnd(); } @@ -701,9 +701,9 @@ oprot.writeFieldBegin(COL_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.colNames.size())); - for (String _iter328 : struct.colNames) + for (String _iter362 : struct.colNames) { - oprot.writeString(_iter328); + oprot.writeString(_iter362); } oprot.writeListEnd(); } @@ -713,9 +713,9 @@ oprot.writeFieldBegin(PART_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.partNames.size())); - for (String _iter329 : struct.partNames) + for (String _iter363 : struct.partNames) { - oprot.writeString(_iter329); + oprot.writeString(_iter363); } oprot.writeListEnd(); } @@ -742,16 +742,16 @@ oprot.writeString(struct.tblName); { oprot.writeI32(struct.colNames.size()); - for (String _iter330 : struct.colNames) + for (String _iter364 : struct.colNames) { - oprot.writeString(_iter330); + oprot.writeString(_iter364); } } { oprot.writeI32(struct.partNames.size()); - for (String _iter331 : struct.partNames) + for (String _iter365 : struct.partNames) { - oprot.writeString(_iter331); + oprot.writeString(_iter365); } } } @@ -764,24 +764,24 @@ struct.tblName = iprot.readString(); struct.setTblNameIsSet(true); { - org.apache.thrift.protocol.TList _list332 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.colNames = new ArrayList(_list332.size); - for (int _i333 = 0; _i333 < _list332.size; ++_i333) + org.apache.thrift.protocol.TList _list366 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.colNames = new ArrayList(_list366.size); + for (int _i367 = 0; _i367 < _list366.size; ++_i367) { - String _elem334; // required - _elem334 = iprot.readString(); - struct.colNames.add(_elem334); + String _elem368; // required + _elem368 = iprot.readString(); + struct.colNames.add(_elem368); } } struct.setColNamesIsSet(true); { - org.apache.thrift.protocol.TList _list335 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.partNames = new ArrayList(_list335.size); - for (int _i336 = 0; _i336 < _list335.size; ++_i336) + org.apache.thrift.protocol.TList _list369 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.partNames = new ArrayList(_list369.size); + for (int _i370 = 0; _i370 < _list369.size; ++_i370) { - String _elem337; // required - _elem337 = iprot.readString(); - struct.partNames.add(_elem337); + String _elem371; // required + _elem371 = iprot.readString(); + struct.partNames.add(_elem371); } } struct.setPartNamesIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ShowCompactResponse.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ShowCompactResponse.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ShowCompactResponse.java (working copy) @@ -350,14 +350,14 @@ case 1: // COMPACTS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list442 = iprot.readListBegin(); - struct.compacts = new ArrayList(_list442.size); - for (int _i443 = 0; _i443 < _list442.size; ++_i443) + org.apache.thrift.protocol.TList _list476 = iprot.readListBegin(); + struct.compacts = new ArrayList(_list476.size); + for (int _i477 = 0; _i477 < _list476.size; ++_i477) { - ShowCompactResponseElement _elem444; // required - _elem444 = new ShowCompactResponseElement(); - _elem444.read(iprot); - struct.compacts.add(_elem444); + ShowCompactResponseElement _elem478; // required + _elem478 = new ShowCompactResponseElement(); + _elem478.read(iprot); + struct.compacts.add(_elem478); } iprot.readListEnd(); } @@ -383,9 +383,9 @@ oprot.writeFieldBegin(COMPACTS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.compacts.size())); - for (ShowCompactResponseElement _iter445 : struct.compacts) + for (ShowCompactResponseElement _iter479 : struct.compacts) { - _iter445.write(oprot); + _iter479.write(oprot); } oprot.writeListEnd(); } @@ -410,9 +410,9 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.compacts.size()); - for (ShowCompactResponseElement _iter446 : struct.compacts) + for (ShowCompactResponseElement _iter480 : struct.compacts) { - _iter446.write(oprot); + _iter480.write(oprot); } } } @@ -421,14 +421,14 @@ public void read(org.apache.thrift.protocol.TProtocol prot, ShowCompactResponse struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TList _list447 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.compacts = new ArrayList(_list447.size); - for (int _i448 = 0; _i448 < _list447.size; ++_i448) + org.apache.thrift.protocol.TList _list481 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.compacts = new ArrayList(_list481.size); + for (int _i482 = 0; _i482 < _list481.size; ++_i482) { - ShowCompactResponseElement _elem449; // required - _elem449 = new ShowCompactResponseElement(); - _elem449.read(iprot); - struct.compacts.add(_elem449); + ShowCompactResponseElement _elem483; // required + _elem483 = new ShowCompactResponseElement(); + _elem483.read(iprot); + struct.compacts.add(_elem483); } } struct.setCompactsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/EnvironmentContext.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/EnvironmentContext.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/EnvironmentContext.java (working copy) @@ -351,15 +351,15 @@ case 1: // PROPERTIES if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map270 = iprot.readMapBegin(); - struct.properties = new HashMap(2*_map270.size); - for (int _i271 = 0; _i271 < _map270.size; ++_i271) + org.apache.thrift.protocol.TMap _map304 = iprot.readMapBegin(); + struct.properties = new HashMap(2*_map304.size); + for (int _i305 = 0; _i305 < _map304.size; ++_i305) { - String _key272; // required - String _val273; // required - _key272 = iprot.readString(); - _val273 = iprot.readString(); - struct.properties.put(_key272, _val273); + String _key306; // required + String _val307; // required + _key306 = iprot.readString(); + _val307 = iprot.readString(); + struct.properties.put(_key306, _val307); } iprot.readMapEnd(); } @@ -385,10 +385,10 @@ oprot.writeFieldBegin(PROPERTIES_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.properties.size())); - for (Map.Entry _iter274 : struct.properties.entrySet()) + for (Map.Entry _iter308 : struct.properties.entrySet()) { - oprot.writeString(_iter274.getKey()); - oprot.writeString(_iter274.getValue()); + oprot.writeString(_iter308.getKey()); + oprot.writeString(_iter308.getValue()); } oprot.writeMapEnd(); } @@ -419,10 +419,10 @@ if (struct.isSetProperties()) { { oprot.writeI32(struct.properties.size()); - for (Map.Entry _iter275 : struct.properties.entrySet()) + for (Map.Entry _iter309 : struct.properties.entrySet()) { - oprot.writeString(_iter275.getKey()); - oprot.writeString(_iter275.getValue()); + oprot.writeString(_iter309.getKey()); + oprot.writeString(_iter309.getValue()); } } } @@ -434,15 +434,15 @@ BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { - org.apache.thrift.protocol.TMap _map276 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.properties = new HashMap(2*_map276.size); - for (int _i277 = 0; _i277 < _map276.size; ++_i277) + org.apache.thrift.protocol.TMap _map310 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.properties = new HashMap(2*_map310.size); + for (int _i311 = 0; _i311 < _map310.size; ++_i311) { - String _key278; // required - String _val279; // required - _key278 = iprot.readString(); - _val279 = iprot.readString(); - struct.properties.put(_key278, _val279); + String _key312; // required + String _val313; // required + _key312 = iprot.readString(); + _val313 = iprot.readString(); + struct.properties.put(_key312, _val313); } } struct.setPropertiesIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/RequestPartsSpec.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/RequestPartsSpec.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/RequestPartsSpec.java (working copy) @@ -165,13 +165,13 @@ if (field.type == NAMES_FIELD_DESC.type) { List names; { - org.apache.thrift.protocol.TList _list362 = iprot.readListBegin(); - names = new ArrayList(_list362.size); - for (int _i363 = 0; _i363 < _list362.size; ++_i363) + org.apache.thrift.protocol.TList _list396 = iprot.readListBegin(); + names = new ArrayList(_list396.size); + for (int _i397 = 0; _i397 < _list396.size; ++_i397) { - String _elem364; // required - _elem364 = iprot.readString(); - names.add(_elem364); + String _elem398; // required + _elem398 = iprot.readString(); + names.add(_elem398); } iprot.readListEnd(); } @@ -184,14 +184,14 @@ if (field.type == EXPRS_FIELD_DESC.type) { List exprs; { - org.apache.thrift.protocol.TList _list365 = iprot.readListBegin(); - exprs = new ArrayList(_list365.size); - for (int _i366 = 0; _i366 < _list365.size; ++_i366) + org.apache.thrift.protocol.TList _list399 = iprot.readListBegin(); + exprs = new ArrayList(_list399.size); + for (int _i400 = 0; _i400 < _list399.size; ++_i400) { - DropPartitionsExpr _elem367; // required - _elem367 = new DropPartitionsExpr(); - _elem367.read(iprot); - exprs.add(_elem367); + DropPartitionsExpr _elem401; // required + _elem401 = new DropPartitionsExpr(); + _elem401.read(iprot); + exprs.add(_elem401); } iprot.readListEnd(); } @@ -215,9 +215,9 @@ List names = (List)value_; { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, names.size())); - for (String _iter368 : names) + for (String _iter402 : names) { - oprot.writeString(_iter368); + oprot.writeString(_iter402); } oprot.writeListEnd(); } @@ -226,9 +226,9 @@ List exprs = (List)value_; { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, exprs.size())); - for (DropPartitionsExpr _iter369 : exprs) + for (DropPartitionsExpr _iter403 : exprs) { - _iter369.write(oprot); + _iter403.write(oprot); } oprot.writeListEnd(); } @@ -246,13 +246,13 @@ case NAMES: List names; { - org.apache.thrift.protocol.TList _list370 = iprot.readListBegin(); - names = new ArrayList(_list370.size); - for (int _i371 = 0; _i371 < _list370.size; ++_i371) + org.apache.thrift.protocol.TList _list404 = iprot.readListBegin(); + names = new ArrayList(_list404.size); + for (int _i405 = 0; _i405 < _list404.size; ++_i405) { - String _elem372; // required - _elem372 = iprot.readString(); - names.add(_elem372); + String _elem406; // required + _elem406 = iprot.readString(); + names.add(_elem406); } iprot.readListEnd(); } @@ -260,14 +260,14 @@ case EXPRS: List exprs; { - org.apache.thrift.protocol.TList _list373 = iprot.readListBegin(); - exprs = new ArrayList(_list373.size); - for (int _i374 = 0; _i374 < _list373.size; ++_i374) + org.apache.thrift.protocol.TList _list407 = iprot.readListBegin(); + exprs = new ArrayList(_list407.size); + for (int _i408 = 0; _i408 < _list407.size; ++_i408) { - DropPartitionsExpr _elem375; // required - _elem375 = new DropPartitionsExpr(); - _elem375.read(iprot); - exprs.add(_elem375); + DropPartitionsExpr _elem409; // required + _elem409 = new DropPartitionsExpr(); + _elem409.read(iprot); + exprs.add(_elem409); } iprot.readListEnd(); } @@ -287,9 +287,9 @@ List names = (List)value_; { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, names.size())); - for (String _iter376 : names) + for (String _iter410 : names) { - oprot.writeString(_iter376); + oprot.writeString(_iter410); } oprot.writeListEnd(); } @@ -298,9 +298,9 @@ List exprs = (List)value_; { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, exprs.size())); - for (DropPartitionsExpr _iter377 : exprs) + for (DropPartitionsExpr _iter411 : exprs) { - _iter377.write(oprot); + _iter411.write(oprot); } oprot.writeListEnd(); } Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AddPartitionsRequest.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AddPartitionsRequest.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AddPartitionsRequest.java (working copy) @@ -700,14 +700,14 @@ case 3: // PARTS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list346 = iprot.readListBegin(); - struct.parts = new ArrayList(_list346.size); - for (int _i347 = 0; _i347 < _list346.size; ++_i347) + org.apache.thrift.protocol.TList _list380 = iprot.readListBegin(); + struct.parts = new ArrayList(_list380.size); + for (int _i381 = 0; _i381 < _list380.size; ++_i381) { - Partition _elem348; // required - _elem348 = new Partition(); - _elem348.read(iprot); - struct.parts.add(_elem348); + Partition _elem382; // required + _elem382 = new Partition(); + _elem382.read(iprot); + struct.parts.add(_elem382); } iprot.readListEnd(); } @@ -759,9 +759,9 @@ oprot.writeFieldBegin(PARTS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.parts.size())); - for (Partition _iter349 : struct.parts) + for (Partition _iter383 : struct.parts) { - _iter349.write(oprot); + _iter383.write(oprot); } oprot.writeListEnd(); } @@ -796,9 +796,9 @@ oprot.writeString(struct.tblName); { oprot.writeI32(struct.parts.size()); - for (Partition _iter350 : struct.parts) + for (Partition _iter384 : struct.parts) { - _iter350.write(oprot); + _iter384.write(oprot); } } oprot.writeBool(struct.ifNotExists); @@ -820,14 +820,14 @@ struct.tblName = iprot.readString(); struct.setTblNameIsSet(true); { - org.apache.thrift.protocol.TList _list351 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.parts = new ArrayList(_list351.size); - for (int _i352 = 0; _i352 < _list351.size; ++_i352) + org.apache.thrift.protocol.TList _list385 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.parts = new ArrayList(_list385.size); + for (int _i386 = 0; _i386 < _list385.size; ++_i386) { - Partition _elem353; // required - _elem353 = new Partition(); - _elem353.read(iprot); - struct.parts.add(_elem353); + Partition _elem387; // required + _elem387 = new Partition(); + _elem387.read(iprot); + struct.parts.add(_elem387); } } struct.setPartsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java (revision 0) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java (revision 0) @@ -0,0 +1,822 @@ +/** + * Autogenerated by Thrift Compiler (0.9.0) + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package org.apache.hadoop.hive.metastore.api; + +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.thrift.scheme.IScheme; +import org.apache.thrift.scheme.SchemeFactory; +import org.apache.thrift.scheme.StandardScheme; + +import org.apache.thrift.scheme.TupleScheme; +import org.apache.thrift.protocol.TTupleProtocol; +import org.apache.thrift.protocol.TProtocolException; +import org.apache.thrift.EncodingUtils; +import org.apache.thrift.TException; +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.EnumMap; +import java.util.Set; +import java.util.HashSet; +import java.util.EnumSet; +import java.util.Collections; +import java.util.BitSet; +import java.nio.ByteBuffer; +import java.util.Arrays; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class PartitionSpec 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("PartitionSpec"); + + private static final org.apache.thrift.protocol.TField DB_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("dbName", org.apache.thrift.protocol.TType.STRING, (short)1); + private static final org.apache.thrift.protocol.TField TABLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("tableName", org.apache.thrift.protocol.TType.STRING, (short)2); + private static final org.apache.thrift.protocol.TField ROOT_PATH_FIELD_DESC = new org.apache.thrift.protocol.TField("rootPath", org.apache.thrift.protocol.TType.STRING, (short)3); + private static final org.apache.thrift.protocol.TField SHARED_SDPARTITION_SPEC_FIELD_DESC = new org.apache.thrift.protocol.TField("sharedSDPartitionSpec", org.apache.thrift.protocol.TType.STRUCT, (short)4); + private static final org.apache.thrift.protocol.TField PARTITION_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("partitionList", org.apache.thrift.protocol.TType.STRUCT, (short)5); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new PartitionSpecStandardSchemeFactory()); + schemes.put(TupleScheme.class, new PartitionSpecTupleSchemeFactory()); + } + + private String dbName; // required + private String tableName; // required + private String rootPath; // required + private PartitionSpecWithSharedSD sharedSDPartitionSpec; // optional + private PartitionListComposingSpec partitionList; // optional + + /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ + public enum _Fields implements org.apache.thrift.TFieldIdEnum { + DB_NAME((short)1, "dbName"), + TABLE_NAME((short)2, "tableName"), + ROOT_PATH((short)3, "rootPath"), + SHARED_SDPARTITION_SPEC((short)4, "sharedSDPartitionSpec"), + PARTITION_LIST((short)5, "partitionList"); + + 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: // DB_NAME + return DB_NAME; + case 2: // TABLE_NAME + return TABLE_NAME; + case 3: // ROOT_PATH + return ROOT_PATH; + case 4: // SHARED_SDPARTITION_SPEC + return SHARED_SDPARTITION_SPEC; + case 5: // PARTITION_LIST + return PARTITION_LIST; + 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 + private _Fields optionals[] = {_Fields.SHARED_SDPARTITION_SPEC,_Fields.PARTITION_LIST}; + 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("dbName", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.TABLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("tableName", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.ROOT_PATH, new org.apache.thrift.meta_data.FieldMetaData("rootPath", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.SHARED_SDPARTITION_SPEC, new org.apache.thrift.meta_data.FieldMetaData("sharedSDPartitionSpec", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionSpecWithSharedSD.class))); + tmpMap.put(_Fields.PARTITION_LIST, new org.apache.thrift.meta_data.FieldMetaData("partitionList", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionListComposingSpec.class))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PartitionSpec.class, metaDataMap); + } + + public PartitionSpec() { + } + + public PartitionSpec( + String dbName, + String tableName, + String rootPath) + { + this(); + this.dbName = dbName; + this.tableName = tableName; + this.rootPath = rootPath; + } + + /** + * Performs a deep copy on other. + */ + public PartitionSpec(PartitionSpec other) { + if (other.isSetDbName()) { + this.dbName = other.dbName; + } + if (other.isSetTableName()) { + this.tableName = other.tableName; + } + if (other.isSetRootPath()) { + this.rootPath = other.rootPath; + } + if (other.isSetSharedSDPartitionSpec()) { + this.sharedSDPartitionSpec = new PartitionSpecWithSharedSD(other.sharedSDPartitionSpec); + } + if (other.isSetPartitionList()) { + this.partitionList = new PartitionListComposingSpec(other.partitionList); + } + } + + public PartitionSpec deepCopy() { + return new PartitionSpec(this); + } + + @Override + public void clear() { + this.dbName = null; + this.tableName = null; + this.rootPath = null; + this.sharedSDPartitionSpec = null; + this.partitionList = null; + } + + public String getDbName() { + return this.dbName; + } + + public void setDbName(String dbName) { + this.dbName = dbName; + } + + public void unsetDbName() { + this.dbName = null; + } + + /** Returns true if field dbName is set (has been assigned a value) and false otherwise */ + public boolean isSetDbName() { + return this.dbName != null; + } + + public void setDbNameIsSet(boolean value) { + if (!value) { + this.dbName = null; + } + } + + public String getTableName() { + return this.tableName; + } + + public void setTableName(String tableName) { + this.tableName = tableName; + } + + public void unsetTableName() { + this.tableName = null; + } + + /** Returns true if field tableName is set (has been assigned a value) and false otherwise */ + public boolean isSetTableName() { + return this.tableName != null; + } + + public void setTableNameIsSet(boolean value) { + if (!value) { + this.tableName = null; + } + } + + public String getRootPath() { + return this.rootPath; + } + + public void setRootPath(String rootPath) { + this.rootPath = rootPath; + } + + public void unsetRootPath() { + this.rootPath = null; + } + + /** Returns true if field rootPath is set (has been assigned a value) and false otherwise */ + public boolean isSetRootPath() { + return this.rootPath != null; + } + + public void setRootPathIsSet(boolean value) { + if (!value) { + this.rootPath = null; + } + } + + public PartitionSpecWithSharedSD getSharedSDPartitionSpec() { + return this.sharedSDPartitionSpec; + } + + public void setSharedSDPartitionSpec(PartitionSpecWithSharedSD sharedSDPartitionSpec) { + this.sharedSDPartitionSpec = sharedSDPartitionSpec; + } + + public void unsetSharedSDPartitionSpec() { + this.sharedSDPartitionSpec = null; + } + + /** Returns true if field sharedSDPartitionSpec is set (has been assigned a value) and false otherwise */ + public boolean isSetSharedSDPartitionSpec() { + return this.sharedSDPartitionSpec != null; + } + + public void setSharedSDPartitionSpecIsSet(boolean value) { + if (!value) { + this.sharedSDPartitionSpec = null; + } + } + + public PartitionListComposingSpec getPartitionList() { + return this.partitionList; + } + + public void setPartitionList(PartitionListComposingSpec partitionList) { + this.partitionList = partitionList; + } + + public void unsetPartitionList() { + this.partitionList = null; + } + + /** Returns true if field partitionList is set (has been assigned a value) and false otherwise */ + public boolean isSetPartitionList() { + return this.partitionList != null; + } + + public void setPartitionListIsSet(boolean value) { + if (!value) { + this.partitionList = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case DB_NAME: + if (value == null) { + unsetDbName(); + } else { + setDbName((String)value); + } + break; + + case TABLE_NAME: + if (value == null) { + unsetTableName(); + } else { + setTableName((String)value); + } + break; + + case ROOT_PATH: + if (value == null) { + unsetRootPath(); + } else { + setRootPath((String)value); + } + break; + + case SHARED_SDPARTITION_SPEC: + if (value == null) { + unsetSharedSDPartitionSpec(); + } else { + setSharedSDPartitionSpec((PartitionSpecWithSharedSD)value); + } + break; + + case PARTITION_LIST: + if (value == null) { + unsetPartitionList(); + } else { + setPartitionList((PartitionListComposingSpec)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case DB_NAME: + return getDbName(); + + case TABLE_NAME: + return getTableName(); + + case ROOT_PATH: + return getRootPath(); + + case SHARED_SDPARTITION_SPEC: + return getSharedSDPartitionSpec(); + + case PARTITION_LIST: + return getPartitionList(); + + } + 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 DB_NAME: + return isSetDbName(); + case TABLE_NAME: + return isSetTableName(); + case ROOT_PATH: + return isSetRootPath(); + case SHARED_SDPARTITION_SPEC: + return isSetSharedSDPartitionSpec(); + case PARTITION_LIST: + return isSetPartitionList(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof PartitionSpec) + return this.equals((PartitionSpec)that); + return false; + } + + public boolean equals(PartitionSpec that) { + if (that == null) + return false; + + boolean this_present_dbName = true && this.isSetDbName(); + boolean that_present_dbName = true && that.isSetDbName(); + if (this_present_dbName || that_present_dbName) { + if (!(this_present_dbName && that_present_dbName)) + return false; + if (!this.dbName.equals(that.dbName)) + return false; + } + + boolean this_present_tableName = true && this.isSetTableName(); + boolean that_present_tableName = true && that.isSetTableName(); + if (this_present_tableName || that_present_tableName) { + if (!(this_present_tableName && that_present_tableName)) + return false; + if (!this.tableName.equals(that.tableName)) + return false; + } + + boolean this_present_rootPath = true && this.isSetRootPath(); + boolean that_present_rootPath = true && that.isSetRootPath(); + if (this_present_rootPath || that_present_rootPath) { + if (!(this_present_rootPath && that_present_rootPath)) + return false; + if (!this.rootPath.equals(that.rootPath)) + return false; + } + + boolean this_present_sharedSDPartitionSpec = true && this.isSetSharedSDPartitionSpec(); + boolean that_present_sharedSDPartitionSpec = true && that.isSetSharedSDPartitionSpec(); + if (this_present_sharedSDPartitionSpec || that_present_sharedSDPartitionSpec) { + if (!(this_present_sharedSDPartitionSpec && that_present_sharedSDPartitionSpec)) + return false; + if (!this.sharedSDPartitionSpec.equals(that.sharedSDPartitionSpec)) + return false; + } + + boolean this_present_partitionList = true && this.isSetPartitionList(); + boolean that_present_partitionList = true && that.isSetPartitionList(); + if (this_present_partitionList || that_present_partitionList) { + if (!(this_present_partitionList && that_present_partitionList)) + return false; + if (!this.partitionList.equals(that.partitionList)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_dbName = true && (isSetDbName()); + builder.append(present_dbName); + if (present_dbName) + builder.append(dbName); + + boolean present_tableName = true && (isSetTableName()); + builder.append(present_tableName); + if (present_tableName) + builder.append(tableName); + + boolean present_rootPath = true && (isSetRootPath()); + builder.append(present_rootPath); + if (present_rootPath) + builder.append(rootPath); + + boolean present_sharedSDPartitionSpec = true && (isSetSharedSDPartitionSpec()); + builder.append(present_sharedSDPartitionSpec); + if (present_sharedSDPartitionSpec) + builder.append(sharedSDPartitionSpec); + + boolean present_partitionList = true && (isSetPartitionList()); + builder.append(present_partitionList); + if (present_partitionList) + builder.append(partitionList); + + return builder.toHashCode(); + } + + public int compareTo(PartitionSpec other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + PartitionSpec typedOther = (PartitionSpec)other; + + lastComparison = Boolean.valueOf(isSetDbName()).compareTo(typedOther.isSetDbName()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetDbName()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dbName, typedOther.dbName); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetTableName()).compareTo(typedOther.isSetTableName()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetTableName()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tableName, typedOther.tableName); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetRootPath()).compareTo(typedOther.isSetRootPath()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetRootPath()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rootPath, typedOther.rootPath); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetSharedSDPartitionSpec()).compareTo(typedOther.isSetSharedSDPartitionSpec()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetSharedSDPartitionSpec()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sharedSDPartitionSpec, typedOther.sharedSDPartitionSpec); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetPartitionList()).compareTo(typedOther.isSetPartitionList()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPartitionList()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.partitionList, typedOther.partitionList); + 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("PartitionSpec("); + boolean first = true; + + sb.append("dbName:"); + if (this.dbName == null) { + sb.append("null"); + } else { + sb.append(this.dbName); + } + first = false; + if (!first) sb.append(", "); + sb.append("tableName:"); + if (this.tableName == null) { + sb.append("null"); + } else { + sb.append(this.tableName); + } + first = false; + if (!first) sb.append(", "); + sb.append("rootPath:"); + if (this.rootPath == null) { + sb.append("null"); + } else { + sb.append(this.rootPath); + } + first = false; + if (isSetSharedSDPartitionSpec()) { + if (!first) sb.append(", "); + sb.append("sharedSDPartitionSpec:"); + if (this.sharedSDPartitionSpec == null) { + sb.append("null"); + } else { + sb.append(this.sharedSDPartitionSpec); + } + first = false; + } + if (isSetPartitionList()) { + if (!first) sb.append(", "); + sb.append("partitionList:"); + if (this.partitionList == null) { + sb.append("null"); + } else { + sb.append(this.partitionList); + } + 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 (sharedSDPartitionSpec != null) { + sharedSDPartitionSpec.validate(); + } + if (partitionList != null) { + partitionList.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 PartitionSpecStandardSchemeFactory implements SchemeFactory { + public PartitionSpecStandardScheme getScheme() { + return new PartitionSpecStandardScheme(); + } + } + + private static class PartitionSpecStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionSpec 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: // DB_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.dbName = iprot.readString(); + struct.setDbNameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // TABLE_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.tableName = iprot.readString(); + struct.setTableNameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // ROOT_PATH + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.rootPath = iprot.readString(); + struct.setRootPathIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // SHARED_SDPARTITION_SPEC + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.sharedSDPartitionSpec = new PartitionSpecWithSharedSD(); + struct.sharedSDPartitionSpec.read(iprot); + struct.setSharedSDPartitionSpecIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 5: // PARTITION_LIST + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.partitionList = new PartitionListComposingSpec(); + struct.partitionList.read(iprot); + struct.setPartitionListIsSet(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, PartitionSpec struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.dbName != null) { + oprot.writeFieldBegin(DB_NAME_FIELD_DESC); + oprot.writeString(struct.dbName); + oprot.writeFieldEnd(); + } + if (struct.tableName != null) { + oprot.writeFieldBegin(TABLE_NAME_FIELD_DESC); + oprot.writeString(struct.tableName); + oprot.writeFieldEnd(); + } + if (struct.rootPath != null) { + oprot.writeFieldBegin(ROOT_PATH_FIELD_DESC); + oprot.writeString(struct.rootPath); + oprot.writeFieldEnd(); + } + if (struct.sharedSDPartitionSpec != null) { + if (struct.isSetSharedSDPartitionSpec()) { + oprot.writeFieldBegin(SHARED_SDPARTITION_SPEC_FIELD_DESC); + struct.sharedSDPartitionSpec.write(oprot); + oprot.writeFieldEnd(); + } + } + if (struct.partitionList != null) { + if (struct.isSetPartitionList()) { + oprot.writeFieldBegin(PARTITION_LIST_FIELD_DESC); + struct.partitionList.write(oprot); + oprot.writeFieldEnd(); + } + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class PartitionSpecTupleSchemeFactory implements SchemeFactory { + public PartitionSpecTupleScheme getScheme() { + return new PartitionSpecTupleScheme(); + } + } + + private static class PartitionSpecTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, PartitionSpec struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetDbName()) { + optionals.set(0); + } + if (struct.isSetTableName()) { + optionals.set(1); + } + if (struct.isSetRootPath()) { + optionals.set(2); + } + if (struct.isSetSharedSDPartitionSpec()) { + optionals.set(3); + } + if (struct.isSetPartitionList()) { + optionals.set(4); + } + oprot.writeBitSet(optionals, 5); + if (struct.isSetDbName()) { + oprot.writeString(struct.dbName); + } + if (struct.isSetTableName()) { + oprot.writeString(struct.tableName); + } + if (struct.isSetRootPath()) { + oprot.writeString(struct.rootPath); + } + if (struct.isSetSharedSDPartitionSpec()) { + struct.sharedSDPartitionSpec.write(oprot); + } + if (struct.isSetPartitionList()) { + struct.partitionList.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, PartitionSpec struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(5); + if (incoming.get(0)) { + struct.dbName = iprot.readString(); + struct.setDbNameIsSet(true); + } + if (incoming.get(1)) { + struct.tableName = iprot.readString(); + struct.setTableNameIsSet(true); + } + if (incoming.get(2)) { + struct.rootPath = iprot.readString(); + struct.setRootPathIsSet(true); + } + if (incoming.get(3)) { + struct.sharedSDPartitionSpec = new PartitionSpecWithSharedSD(); + struct.sharedSDPartitionSpec.read(iprot); + struct.setSharedSDPartitionSpecIsSet(true); + } + if (incoming.get(4)) { + struct.partitionList = new PartitionListComposingSpec(); + struct.partitionList.read(iprot); + struct.setPartitionListIsSet(true); + } + } + } + +} + Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HeartbeatTxnRangeResponse.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HeartbeatTxnRangeResponse.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HeartbeatTxnRangeResponse.java (working copy) @@ -455,13 +455,13 @@ case 1: // ABORTED if (schemeField.type == org.apache.thrift.protocol.TType.SET) { { - org.apache.thrift.protocol.TSet _set426 = iprot.readSetBegin(); - struct.aborted = new HashSet(2*_set426.size); - for (int _i427 = 0; _i427 < _set426.size; ++_i427) + org.apache.thrift.protocol.TSet _set460 = iprot.readSetBegin(); + struct.aborted = new HashSet(2*_set460.size); + for (int _i461 = 0; _i461 < _set460.size; ++_i461) { - long _elem428; // required - _elem428 = iprot.readI64(); - struct.aborted.add(_elem428); + long _elem462; // required + _elem462 = iprot.readI64(); + struct.aborted.add(_elem462); } iprot.readSetEnd(); } @@ -473,13 +473,13 @@ case 2: // NOSUCH if (schemeField.type == org.apache.thrift.protocol.TType.SET) { { - org.apache.thrift.protocol.TSet _set429 = iprot.readSetBegin(); - struct.nosuch = new HashSet(2*_set429.size); - for (int _i430 = 0; _i430 < _set429.size; ++_i430) + org.apache.thrift.protocol.TSet _set463 = iprot.readSetBegin(); + struct.nosuch = new HashSet(2*_set463.size); + for (int _i464 = 0; _i464 < _set463.size; ++_i464) { - long _elem431; // required - _elem431 = iprot.readI64(); - struct.nosuch.add(_elem431); + long _elem465; // required + _elem465 = iprot.readI64(); + struct.nosuch.add(_elem465); } iprot.readSetEnd(); } @@ -505,9 +505,9 @@ oprot.writeFieldBegin(ABORTED_FIELD_DESC); { oprot.writeSetBegin(new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, struct.aborted.size())); - for (long _iter432 : struct.aborted) + for (long _iter466 : struct.aborted) { - oprot.writeI64(_iter432); + oprot.writeI64(_iter466); } oprot.writeSetEnd(); } @@ -517,9 +517,9 @@ oprot.writeFieldBegin(NOSUCH_FIELD_DESC); { oprot.writeSetBegin(new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, struct.nosuch.size())); - for (long _iter433 : struct.nosuch) + for (long _iter467 : struct.nosuch) { - oprot.writeI64(_iter433); + oprot.writeI64(_iter467); } oprot.writeSetEnd(); } @@ -544,16 +544,16 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.aborted.size()); - for (long _iter434 : struct.aborted) + for (long _iter468 : struct.aborted) { - oprot.writeI64(_iter434); + oprot.writeI64(_iter468); } } { oprot.writeI32(struct.nosuch.size()); - for (long _iter435 : struct.nosuch) + for (long _iter469 : struct.nosuch) { - oprot.writeI64(_iter435); + oprot.writeI64(_iter469); } } } @@ -562,24 +562,24 @@ public void read(org.apache.thrift.protocol.TProtocol prot, HeartbeatTxnRangeResponse struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TSet _set436 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, iprot.readI32()); - struct.aborted = new HashSet(2*_set436.size); - for (int _i437 = 0; _i437 < _set436.size; ++_i437) + org.apache.thrift.protocol.TSet _set470 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, iprot.readI32()); + struct.aborted = new HashSet(2*_set470.size); + for (int _i471 = 0; _i471 < _set470.size; ++_i471) { - long _elem438; // required - _elem438 = iprot.readI64(); - struct.aborted.add(_elem438); + long _elem472; // required + _elem472 = iprot.readI64(); + struct.aborted.add(_elem472); } } struct.setAbortedIsSet(true); { - org.apache.thrift.protocol.TSet _set439 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, iprot.readI32()); - struct.nosuch = new HashSet(2*_set439.size); - for (int _i440 = 0; _i440 < _set439.size; ++_i440) + org.apache.thrift.protocol.TSet _set473 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, iprot.readI32()); + struct.nosuch = new HashSet(2*_set473.size); + for (int _i474 = 0; _i474 < _set473.size; ++_i474) { - long _elem441; // required - _elem441 = iprot.readI64(); - struct.nosuch.add(_elem441); + long _elem475; // required + _elem475 = iprot.readI64(); + struct.nosuch.add(_elem475); } } struct.setNosuchIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ShowLocksResponse.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ShowLocksResponse.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ShowLocksResponse.java (working copy) @@ -346,14 +346,14 @@ case 1: // LOCKS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list418 = iprot.readListBegin(); - struct.locks = new ArrayList(_list418.size); - for (int _i419 = 0; _i419 < _list418.size; ++_i419) + org.apache.thrift.protocol.TList _list452 = iprot.readListBegin(); + struct.locks = new ArrayList(_list452.size); + for (int _i453 = 0; _i453 < _list452.size; ++_i453) { - ShowLocksResponseElement _elem420; // required - _elem420 = new ShowLocksResponseElement(); - _elem420.read(iprot); - struct.locks.add(_elem420); + ShowLocksResponseElement _elem454; // required + _elem454 = new ShowLocksResponseElement(); + _elem454.read(iprot); + struct.locks.add(_elem454); } iprot.readListEnd(); } @@ -379,9 +379,9 @@ oprot.writeFieldBegin(LOCKS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.locks.size())); - for (ShowLocksResponseElement _iter421 : struct.locks) + for (ShowLocksResponseElement _iter455 : struct.locks) { - _iter421.write(oprot); + _iter455.write(oprot); } oprot.writeListEnd(); } @@ -412,9 +412,9 @@ if (struct.isSetLocks()) { { oprot.writeI32(struct.locks.size()); - for (ShowLocksResponseElement _iter422 : struct.locks) + for (ShowLocksResponseElement _iter456 : struct.locks) { - _iter422.write(oprot); + _iter456.write(oprot); } } } @@ -426,14 +426,14 @@ BitSet incoming = iprot.readBitSet(1); 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.locks = new ArrayList(_list423.size); - for (int _i424 = 0; _i424 < _list423.size; ++_i424) + org.apache.thrift.protocol.TList _list457 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.locks = new ArrayList(_list457.size); + for (int _i458 = 0; _i458 < _list457.size; ++_i458) { - ShowLocksResponseElement _elem425; // required - _elem425 = new ShowLocksResponseElement(); - _elem425.read(iprot); - struct.locks.add(_elem425); + ShowLocksResponseElement _elem459; // required + _elem459 = new ShowLocksResponseElement(); + _elem459.read(iprot); + struct.locks.add(_elem459); } } struct.setLocksIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/OpenTxnsResponse.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/OpenTxnsResponse.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/OpenTxnsResponse.java (working copy) @@ -350,13 +350,13 @@ case 1: // TXN_IDS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list402 = iprot.readListBegin(); - struct.txn_ids = new ArrayList(_list402.size); - for (int _i403 = 0; _i403 < _list402.size; ++_i403) + org.apache.thrift.protocol.TList _list436 = iprot.readListBegin(); + struct.txn_ids = new ArrayList(_list436.size); + for (int _i437 = 0; _i437 < _list436.size; ++_i437) { - long _elem404; // required - _elem404 = iprot.readI64(); - struct.txn_ids.add(_elem404); + long _elem438; // required + _elem438 = iprot.readI64(); + struct.txn_ids.add(_elem438); } iprot.readListEnd(); } @@ -382,9 +382,9 @@ oprot.writeFieldBegin(TXN_IDS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, struct.txn_ids.size())); - for (long _iter405 : struct.txn_ids) + for (long _iter439 : struct.txn_ids) { - oprot.writeI64(_iter405); + oprot.writeI64(_iter439); } oprot.writeListEnd(); } @@ -409,9 +409,9 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.txn_ids.size()); - for (long _iter406 : struct.txn_ids) + for (long _iter440 : struct.txn_ids) { - oprot.writeI64(_iter406); + oprot.writeI64(_iter440); } } } @@ -420,13 +420,13 @@ public void read(org.apache.thrift.protocol.TProtocol prot, OpenTxnsResponse struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TList _list407 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, iprot.readI32()); - struct.txn_ids = new ArrayList(_list407.size); - for (int _i408 = 0; _i408 < _list407.size; ++_i408) + org.apache.thrift.protocol.TList _list441 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, iprot.readI32()); + struct.txn_ids = new ArrayList(_list441.size); + for (int _i442 = 0; _i442 < _list441.size; ++_i442) { - long _elem409; // required - _elem409 = iprot.readI64(); - struct.txn_ids.add(_elem409); + long _elem443; // required + _elem443 = iprot.readI64(); + struct.txn_ids.add(_elem443); } } struct.setTxn_idsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetOpenTxnsResponse.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetOpenTxnsResponse.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetOpenTxnsResponse.java (working copy) @@ -443,13 +443,13 @@ case 2: // OPEN_TXNS if (schemeField.type == org.apache.thrift.protocol.TType.SET) { { - org.apache.thrift.protocol.TSet _set394 = iprot.readSetBegin(); - struct.open_txns = new HashSet(2*_set394.size); - for (int _i395 = 0; _i395 < _set394.size; ++_i395) + org.apache.thrift.protocol.TSet _set428 = iprot.readSetBegin(); + struct.open_txns = new HashSet(2*_set428.size); + for (int _i429 = 0; _i429 < _set428.size; ++_i429) { - long _elem396; // required - _elem396 = iprot.readI64(); - struct.open_txns.add(_elem396); + long _elem430; // required + _elem430 = iprot.readI64(); + struct.open_txns.add(_elem430); } iprot.readSetEnd(); } @@ -478,9 +478,9 @@ oprot.writeFieldBegin(OPEN_TXNS_FIELD_DESC); { oprot.writeSetBegin(new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, struct.open_txns.size())); - for (long _iter397 : struct.open_txns) + for (long _iter431 : struct.open_txns) { - oprot.writeI64(_iter397); + oprot.writeI64(_iter431); } oprot.writeSetEnd(); } @@ -506,9 +506,9 @@ oprot.writeI64(struct.txn_high_water_mark); { oprot.writeI32(struct.open_txns.size()); - for (long _iter398 : struct.open_txns) + for (long _iter432 : struct.open_txns) { - oprot.writeI64(_iter398); + oprot.writeI64(_iter432); } } } @@ -519,13 +519,13 @@ struct.txn_high_water_mark = iprot.readI64(); struct.setTxn_high_water_markIsSet(true); { - org.apache.thrift.protocol.TSet _set399 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, iprot.readI32()); - struct.open_txns = new HashSet(2*_set399.size); - for (int _i400 = 0; _i400 < _set399.size; ++_i400) + org.apache.thrift.protocol.TSet _set433 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.I64, iprot.readI32()); + struct.open_txns = new HashSet(2*_set433.size); + for (int _i434 = 0; _i434 < _set433.size; ++_i434) { - long _elem401; // required - _elem401 = iprot.readI64(); - struct.open_txns.add(_elem401); + long _elem435; // required + _elem435 = iprot.readI64(); + struct.open_txns.add(_elem435); } } struct.setOpen_txnsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionListComposingSpec.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionListComposingSpec.java (revision 0) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionListComposingSpec.java (revision 0) @@ -0,0 +1,445 @@ +/** + * Autogenerated by Thrift Compiler (0.9.0) + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package org.apache.hadoop.hive.metastore.api; + +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.thrift.scheme.IScheme; +import org.apache.thrift.scheme.SchemeFactory; +import org.apache.thrift.scheme.StandardScheme; + +import org.apache.thrift.scheme.TupleScheme; +import org.apache.thrift.protocol.TTupleProtocol; +import org.apache.thrift.protocol.TProtocolException; +import org.apache.thrift.EncodingUtils; +import org.apache.thrift.TException; +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.EnumMap; +import java.util.Set; +import java.util.HashSet; +import java.util.EnumSet; +import java.util.Collections; +import java.util.BitSet; +import java.nio.ByteBuffer; +import java.util.Arrays; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class PartitionListComposingSpec 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("PartitionListComposingSpec"); + + private static final org.apache.thrift.protocol.TField PARTITIONS_FIELD_DESC = new org.apache.thrift.protocol.TField("partitions", org.apache.thrift.protocol.TType.LIST, (short)1); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new PartitionListComposingSpecStandardSchemeFactory()); + schemes.put(TupleScheme.class, new PartitionListComposingSpecTupleSchemeFactory()); + } + + private List partitions; // 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 { + PARTITIONS((short)1, "partitions"); + + 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: // PARTITIONS + return PARTITIONS; + 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.PARTITIONS, new org.apache.thrift.meta_data.FieldMetaData("partitions", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Partition.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PartitionListComposingSpec.class, metaDataMap); + } + + public PartitionListComposingSpec() { + } + + public PartitionListComposingSpec( + List partitions) + { + this(); + this.partitions = partitions; + } + + /** + * Performs a deep copy on other. + */ + public PartitionListComposingSpec(PartitionListComposingSpec other) { + if (other.isSetPartitions()) { + List __this__partitions = new ArrayList(); + for (Partition other_element : other.partitions) { + __this__partitions.add(new Partition(other_element)); + } + this.partitions = __this__partitions; + } + } + + public PartitionListComposingSpec deepCopy() { + return new PartitionListComposingSpec(this); + } + + @Override + public void clear() { + this.partitions = null; + } + + public int getPartitionsSize() { + return (this.partitions == null) ? 0 : this.partitions.size(); + } + + public java.util.Iterator getPartitionsIterator() { + return (this.partitions == null) ? null : this.partitions.iterator(); + } + + public void addToPartitions(Partition elem) { + if (this.partitions == null) { + this.partitions = new ArrayList(); + } + this.partitions.add(elem); + } + + public List getPartitions() { + return this.partitions; + } + + public void setPartitions(List partitions) { + this.partitions = partitions; + } + + public void unsetPartitions() { + this.partitions = null; + } + + /** Returns true if field partitions is set (has been assigned a value) and false otherwise */ + public boolean isSetPartitions() { + return this.partitions != null; + } + + public void setPartitionsIsSet(boolean value) { + if (!value) { + this.partitions = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case PARTITIONS: + if (value == null) { + unsetPartitions(); + } else { + setPartitions((List)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case PARTITIONS: + return getPartitions(); + + } + 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 PARTITIONS: + return isSetPartitions(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof PartitionListComposingSpec) + return this.equals((PartitionListComposingSpec)that); + return false; + } + + public boolean equals(PartitionListComposingSpec that) { + if (that == null) + return false; + + boolean this_present_partitions = true && this.isSetPartitions(); + boolean that_present_partitions = true && that.isSetPartitions(); + if (this_present_partitions || that_present_partitions) { + if (!(this_present_partitions && that_present_partitions)) + return false; + if (!this.partitions.equals(that.partitions)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_partitions = true && (isSetPartitions()); + builder.append(present_partitions); + if (present_partitions) + builder.append(partitions); + + return builder.toHashCode(); + } + + public int compareTo(PartitionListComposingSpec other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + PartitionListComposingSpec typedOther = (PartitionListComposingSpec)other; + + lastComparison = Boolean.valueOf(isSetPartitions()).compareTo(typedOther.isSetPartitions()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPartitions()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.partitions, typedOther.partitions); + 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("PartitionListComposingSpec("); + boolean first = true; + + sb.append("partitions:"); + if (this.partitions == null) { + sb.append("null"); + } else { + sb.append(this.partitions); + } + 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 PartitionListComposingSpecStandardSchemeFactory implements SchemeFactory { + public PartitionListComposingSpecStandardScheme getScheme() { + return new PartitionListComposingSpecStandardScheme(); + } + } + + private static class PartitionListComposingSpecStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionListComposingSpec 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: // PARTITIONS + if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { + { + org.apache.thrift.protocol.TList _list252 = iprot.readListBegin(); + struct.partitions = new ArrayList(_list252.size); + for (int _i253 = 0; _i253 < _list252.size; ++_i253) + { + Partition _elem254; // required + _elem254 = new Partition(); + _elem254.read(iprot); + struct.partitions.add(_elem254); + } + iprot.readListEnd(); + } + struct.setPartitionsIsSet(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, PartitionListComposingSpec struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.partitions != null) { + oprot.writeFieldBegin(PARTITIONS_FIELD_DESC); + { + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.partitions.size())); + for (Partition _iter255 : struct.partitions) + { + _iter255.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class PartitionListComposingSpecTupleSchemeFactory implements SchemeFactory { + public PartitionListComposingSpecTupleScheme getScheme() { + return new PartitionListComposingSpecTupleScheme(); + } + } + + private static class PartitionListComposingSpecTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, PartitionListComposingSpec struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetPartitions()) { + optionals.set(0); + } + oprot.writeBitSet(optionals, 1); + if (struct.isSetPartitions()) { + { + oprot.writeI32(struct.partitions.size()); + for (Partition _iter256 : struct.partitions) + { + _iter256.write(oprot); + } + } + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, PartitionListComposingSpec struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(1); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TList _list257 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.partitions = new ArrayList(_list257.size); + for (int _i258 = 0; _i258 < _list257.size; ++_i258) + { + Partition _elem259; // required + _elem259 = new Partition(); + _elem259.read(iprot); + struct.partitions.add(_elem259); + } + } + struct.setPartitionsIsSet(true); + } + } + } + +} + 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 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/ThriftHiveMetastore.java (working copy) @@ -94,6 +94,8 @@ public int add_partitions(List new_parts) throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException; + public int add_partitions_pspec(List new_parts) throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException; + public Partition append_partition(String db_name, String tbl_name, List part_vals) throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException; public AddPartitionsResult add_partitions_req(AddPartitionsRequest request) throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException; @@ -126,6 +128,8 @@ public List get_partitions_with_auth(String db_name, String tbl_name, short max_parts, String user_name, List group_names) throws NoSuchObjectException, MetaException, org.apache.thrift.TException; + public List get_partitions_pspec(String db_name, String tbl_name, int max_parts) throws NoSuchObjectException, MetaException, org.apache.thrift.TException; + public List get_partition_names(String db_name, String tbl_name, short max_parts) throws MetaException, org.apache.thrift.TException; public List get_partitions_ps(String db_name, String tbl_name, List part_vals, short max_parts) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; @@ -136,6 +140,8 @@ public List get_partitions_by_filter(String db_name, String tbl_name, String filter, short max_parts) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; + public List get_part_specs_by_filter(String db_name, String tbl_name, String filter, int max_parts) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; + public PartitionsByExprResult get_partitions_by_expr(PartitionsByExprRequest req) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; public List get_partitions_by_names(String db_name, String tbl_name, List names) throws MetaException, NoSuchObjectException, org.apache.thrift.TException; @@ -322,6 +328,8 @@ public void add_partitions(List new_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void add_partitions_pspec(List new_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void append_partition(String db_name, String tbl_name, List part_vals, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; public void add_partitions_req(AddPartitionsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; @@ -354,6 +362,8 @@ public void get_partitions_with_auth(String db_name, String tbl_name, short max_parts, String user_name, List group_names, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void get_partitions_pspec(String db_name, String tbl_name, int max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void get_partition_names(String db_name, String tbl_name, short max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; public void get_partitions_ps(String db_name, String tbl_name, List part_vals, short max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; @@ -364,6 +374,8 @@ public void get_partitions_by_filter(String db_name, String tbl_name, String filter, short max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void get_part_specs_by_filter(String db_name, String tbl_name, String filter, int max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void get_partitions_by_expr(PartitionsByExprRequest req, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; public void get_partitions_by_names(String db_name, String tbl_name, List names, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; @@ -1337,6 +1349,38 @@ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "add_partitions failed: unknown result"); } + public int add_partitions_pspec(List new_parts) throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException + { + send_add_partitions_pspec(new_parts); + return recv_add_partitions_pspec(); + } + + public void send_add_partitions_pspec(List new_parts) throws org.apache.thrift.TException + { + add_partitions_pspec_args args = new add_partitions_pspec_args(); + args.setNew_parts(new_parts); + sendBase("add_partitions_pspec", args); + } + + public int recv_add_partitions_pspec() throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException + { + add_partitions_pspec_result result = new add_partitions_pspec_result(); + receiveBase(result, "add_partitions_pspec"); + 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; + } + throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "add_partitions_pspec failed: unknown result"); + } + public Partition append_partition(String db_name, String tbl_name, List part_vals) throws InvalidObjectException, AlreadyExistsException, MetaException, org.apache.thrift.TException { send_append_partition(db_name, tbl_name, part_vals); @@ -1864,6 +1908,37 @@ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "get_partitions_with_auth failed: unknown result"); } + public List get_partitions_pspec(String db_name, String tbl_name, int max_parts) throws NoSuchObjectException, MetaException, org.apache.thrift.TException + { + send_get_partitions_pspec(db_name, tbl_name, max_parts); + return recv_get_partitions_pspec(); + } + + public void send_get_partitions_pspec(String db_name, String tbl_name, int max_parts) throws org.apache.thrift.TException + { + get_partitions_pspec_args args = new get_partitions_pspec_args(); + args.setDb_name(db_name); + args.setTbl_name(tbl_name); + args.setMax_parts(max_parts); + sendBase("get_partitions_pspec", args); + } + + public List recv_get_partitions_pspec() throws NoSuchObjectException, MetaException, org.apache.thrift.TException + { + get_partitions_pspec_result result = new get_partitions_pspec_result(); + receiveBase(result, "get_partitions_pspec"); + if (result.isSetSuccess()) { + return result.success; + } + if (result.o1 != null) { + throw result.o1; + } + if (result.o2 != null) { + throw result.o2; + } + throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "get_partitions_pspec failed: unknown result"); + } + public List get_partition_names(String db_name, String tbl_name, short max_parts) throws MetaException, org.apache.thrift.TException { send_get_partition_names(db_name, tbl_name, max_parts); @@ -2022,6 +2097,38 @@ throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "get_partitions_by_filter failed: unknown result"); } + public List get_part_specs_by_filter(String db_name, String tbl_name, String filter, int max_parts) throws MetaException, NoSuchObjectException, org.apache.thrift.TException + { + send_get_part_specs_by_filter(db_name, tbl_name, filter, max_parts); + return recv_get_part_specs_by_filter(); + } + + public void send_get_part_specs_by_filter(String db_name, String tbl_name, String filter, int max_parts) throws org.apache.thrift.TException + { + get_part_specs_by_filter_args args = new get_part_specs_by_filter_args(); + args.setDb_name(db_name); + args.setTbl_name(tbl_name); + args.setFilter(filter); + args.setMax_parts(max_parts); + sendBase("get_part_specs_by_filter", args); + } + + public List recv_get_part_specs_by_filter() throws MetaException, NoSuchObjectException, org.apache.thrift.TException + { + get_part_specs_by_filter_result result = new get_part_specs_by_filter_result(); + receiveBase(result, "get_part_specs_by_filter"); + if (result.isSetSuccess()) { + return result.success; + } + if (result.o1 != null) { + throw result.o1; + } + if (result.o2 != null) { + throw result.o2; + } + throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "get_part_specs_by_filter failed: unknown result"); + } + public PartitionsByExprResult get_partitions_by_expr(PartitionsByExprRequest req) throws MetaException, NoSuchObjectException, org.apache.thrift.TException { send_get_partitions_by_expr(req); @@ -4801,6 +4908,38 @@ } } + public void add_partitions_pspec(List new_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { + checkReady(); + add_partitions_pspec_call method_call = new add_partitions_pspec_call(new_parts, resultHandler, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class add_partitions_pspec_call extends org.apache.thrift.async.TAsyncMethodCall { + private List new_parts; + public add_partitions_pspec_call(List new_parts, 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.new_parts = new_parts; + } + + public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException { + prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("add_partitions_pspec", org.apache.thrift.protocol.TMessageType.CALL, 0)); + add_partitions_pspec_args args = new add_partitions_pspec_args(); + args.setNew_parts(new_parts); + args.write(prot); + prot.writeMessageEnd(); + } + + public int getResult() throws InvalidObjectException, AlreadyExistsException, MetaException, 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_add_partitions_pspec(); + } + } + public void append_partition(String db_name, String tbl_name, List part_vals, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); append_partition_call method_call = new append_partition_call(db_name, tbl_name, part_vals, resultHandler, this, ___protocolFactory, ___transport); @@ -5439,6 +5578,44 @@ } } + public void get_partitions_pspec(String db_name, String tbl_name, int max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { + checkReady(); + get_partitions_pspec_call method_call = new get_partitions_pspec_call(db_name, tbl_name, max_parts, resultHandler, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class get_partitions_pspec_call extends org.apache.thrift.async.TAsyncMethodCall { + private String db_name; + private String tbl_name; + private int max_parts; + public get_partitions_pspec_call(String db_name, String tbl_name, int max_parts, 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.db_name = db_name; + this.tbl_name = tbl_name; + this.max_parts = max_parts; + } + + public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException { + prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("get_partitions_pspec", org.apache.thrift.protocol.TMessageType.CALL, 0)); + get_partitions_pspec_args args = new get_partitions_pspec_args(); + args.setDb_name(db_name); + args.setTbl_name(tbl_name); + args.setMax_parts(max_parts); + args.write(prot); + prot.writeMessageEnd(); + } + + public List getResult() throws NoSuchObjectException, MetaException, 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_get_partitions_pspec(); + } + } + public void get_partition_names(String db_name, String tbl_name, short max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); get_partition_names_call method_call = new get_partition_names_call(db_name, tbl_name, max_parts, resultHandler, this, ___protocolFactory, ___transport); @@ -5647,6 +5824,47 @@ } } + public void get_part_specs_by_filter(String db_name, String tbl_name, String filter, int max_parts, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { + checkReady(); + get_part_specs_by_filter_call method_call = new get_part_specs_by_filter_call(db_name, tbl_name, filter, max_parts, resultHandler, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class get_part_specs_by_filter_call extends org.apache.thrift.async.TAsyncMethodCall { + private String db_name; + private String tbl_name; + private String filter; + private int max_parts; + public get_part_specs_by_filter_call(String db_name, String tbl_name, String filter, int max_parts, 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.db_name = db_name; + this.tbl_name = tbl_name; + this.filter = filter; + this.max_parts = max_parts; + } + + public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException { + prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("get_part_specs_by_filter", org.apache.thrift.protocol.TMessageType.CALL, 0)); + get_part_specs_by_filter_args args = new get_part_specs_by_filter_args(); + args.setDb_name(db_name); + args.setTbl_name(tbl_name); + args.setFilter(filter); + args.setMax_parts(max_parts); + args.write(prot); + prot.writeMessageEnd(); + } + + public List getResult() throws MetaException, NoSuchObjectException, 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_get_part_specs_by_filter(); + } + } + public void get_partitions_by_expr(PartitionsByExprRequest req, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); get_partitions_by_expr_call method_call = new get_partitions_by_expr_call(req, resultHandler, this, ___protocolFactory, ___transport); @@ -7881,6 +8099,7 @@ processMap.put("add_partition", new add_partition()); processMap.put("add_partition_with_environment_context", new add_partition_with_environment_context()); processMap.put("add_partitions", new add_partitions()); + processMap.put("add_partitions_pspec", new add_partitions_pspec()); processMap.put("append_partition", new append_partition()); processMap.put("add_partitions_req", new add_partitions_req()); processMap.put("append_partition_with_environment_context", new append_partition_with_environment_context()); @@ -7897,11 +8116,13 @@ processMap.put("get_partition_by_name", new get_partition_by_name()); processMap.put("get_partitions", new get_partitions()); processMap.put("get_partitions_with_auth", new get_partitions_with_auth()); + processMap.put("get_partitions_pspec", new get_partitions_pspec()); processMap.put("get_partition_names", new get_partition_names()); processMap.put("get_partitions_ps", new get_partitions_ps()); processMap.put("get_partitions_ps_with_auth", new get_partitions_ps_with_auth()); processMap.put("get_partition_names_ps", new get_partition_names_ps()); processMap.put("get_partitions_by_filter", new get_partitions_by_filter()); + processMap.put("get_part_specs_by_filter", new get_part_specs_by_filter()); processMap.put("get_partitions_by_expr", new get_partitions_by_expr()); processMap.put("get_partitions_by_names", new get_partitions_by_names()); processMap.put("alter_partition", new alter_partition()); @@ -8713,6 +8934,35 @@ } } + public static class add_partitions_pspec extends org.apache.thrift.ProcessFunction { + public add_partitions_pspec() { + super("add_partitions_pspec"); + } + + public add_partitions_pspec_args getEmptyArgsInstance() { + return new add_partitions_pspec_args(); + } + + protected boolean isOneway() { + return false; + } + + public add_partitions_pspec_result getResult(I iface, add_partitions_pspec_args args) throws org.apache.thrift.TException { + add_partitions_pspec_result result = new add_partitions_pspec_result(); + try { + result.success = iface.add_partitions_pspec(args.new_parts); + result.setSuccessIsSet(true); + } catch (InvalidObjectException o1) { + result.o1 = o1; + } catch (AlreadyExistsException o2) { + result.o2 = o2; + } catch (MetaException o3) { + result.o3 = o3; + } + return result; + } + } + public static class append_partition extends org.apache.thrift.ProcessFunction { public append_partition() { super("append_partition"); @@ -9147,6 +9397,32 @@ } } + public static class get_partitions_pspec extends org.apache.thrift.ProcessFunction { + public get_partitions_pspec() { + super("get_partitions_pspec"); + } + + public get_partitions_pspec_args getEmptyArgsInstance() { + return new get_partitions_pspec_args(); + } + + protected boolean isOneway() { + return false; + } + + public get_partitions_pspec_result getResult(I iface, get_partitions_pspec_args args) throws org.apache.thrift.TException { + get_partitions_pspec_result result = new get_partitions_pspec_result(); + try { + result.success = iface.get_partitions_pspec(args.db_name, args.tbl_name, args.max_parts); + } catch (NoSuchObjectException o1) { + result.o1 = o1; + } catch (MetaException o2) { + result.o2 = o2; + } + return result; + } + } + public static class get_partition_names extends org.apache.thrift.ProcessFunction { public get_partition_names() { super("get_partition_names"); @@ -9275,6 +9551,32 @@ } } + public static class get_part_specs_by_filter extends org.apache.thrift.ProcessFunction { + public get_part_specs_by_filter() { + super("get_part_specs_by_filter"); + } + + public get_part_specs_by_filter_args getEmptyArgsInstance() { + return new get_part_specs_by_filter_args(); + } + + protected boolean isOneway() { + return false; + } + + public get_part_specs_by_filter_result getResult(I iface, get_part_specs_by_filter_args args) throws org.apache.thrift.TException { + get_part_specs_by_filter_result result = new get_part_specs_by_filter_result(); + try { + result.success = iface.get_part_specs_by_filter(args.db_name, args.tbl_name, args.filter, args.max_parts); + } catch (MetaException o1) { + result.o1 = o1; + } catch (NoSuchObjectException o2) { + result.o2 = o2; + } + return result; + } + } + public static class get_partitions_by_expr extends org.apache.thrift.ProcessFunction { public get_partitions_by_expr() { super("get_partitions_by_expr"); @@ -16283,13 +16585,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list450 = iprot.readListBegin(); - struct.success = new ArrayList(_list450.size); - for (int _i451 = 0; _i451 < _list450.size; ++_i451) + org.apache.thrift.protocol.TList _list484 = iprot.readListBegin(); + struct.success = new ArrayList(_list484.size); + for (int _i485 = 0; _i485 < _list484.size; ++_i485) { - String _elem452; // required - _elem452 = iprot.readString(); - struct.success.add(_elem452); + String _elem486; // required + _elem486 = iprot.readString(); + struct.success.add(_elem486); } iprot.readListEnd(); } @@ -16324,9 +16626,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 _iter453 : struct.success) + for (String _iter487 : struct.success) { - oprot.writeString(_iter453); + oprot.writeString(_iter487); } oprot.writeListEnd(); } @@ -16365,9 +16667,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter454 : struct.success) + for (String _iter488 : struct.success) { - oprot.writeString(_iter454); + oprot.writeString(_iter488); } } } @@ -16382,13 +16684,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list455 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list455.size); - for (int _i456 = 0; _i456 < _list455.size; ++_i456) + org.apache.thrift.protocol.TList _list489 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list489.size); + for (int _i490 = 0; _i490 < _list489.size; ++_i490) { - String _elem457; // required - _elem457 = iprot.readString(); - struct.success.add(_elem457); + String _elem491; // required + _elem491 = iprot.readString(); + struct.success.add(_elem491); } } struct.setSuccessIsSet(true); @@ -17045,13 +17347,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list458 = iprot.readListBegin(); - struct.success = new ArrayList(_list458.size); - for (int _i459 = 0; _i459 < _list458.size; ++_i459) + org.apache.thrift.protocol.TList _list492 = iprot.readListBegin(); + struct.success = new ArrayList(_list492.size); + for (int _i493 = 0; _i493 < _list492.size; ++_i493) { - String _elem460; // required - _elem460 = iprot.readString(); - struct.success.add(_elem460); + String _elem494; // required + _elem494 = iprot.readString(); + struct.success.add(_elem494); } iprot.readListEnd(); } @@ -17086,9 +17388,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 _iter461 : struct.success) + for (String _iter495 : struct.success) { - oprot.writeString(_iter461); + oprot.writeString(_iter495); } oprot.writeListEnd(); } @@ -17127,9 +17429,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter462 : struct.success) + for (String _iter496 : struct.success) { - oprot.writeString(_iter462); + oprot.writeString(_iter496); } } } @@ -17144,13 +17446,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list463 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list463.size); - for (int _i464 = 0; _i464 < _list463.size; ++_i464) + 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 _elem465; // required - _elem465 = iprot.readString(); - struct.success.add(_elem465); + String _elem499; // required + _elem499 = iprot.readString(); + struct.success.add(_elem499); } } struct.setSuccessIsSet(true); @@ -21757,16 +22059,16 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map466 = iprot.readMapBegin(); - struct.success = new HashMap(2*_map466.size); - for (int _i467 = 0; _i467 < _map466.size; ++_i467) + org.apache.thrift.protocol.TMap _map500 = iprot.readMapBegin(); + struct.success = new HashMap(2*_map500.size); + for (int _i501 = 0; _i501 < _map500.size; ++_i501) { - String _key468; // required - Type _val469; // required - _key468 = iprot.readString(); - _val469 = new Type(); - _val469.read(iprot); - struct.success.put(_key468, _val469); + String _key502; // required + Type _val503; // required + _key502 = iprot.readString(); + _val503 = new Type(); + _val503.read(iprot); + struct.success.put(_key502, _val503); } iprot.readMapEnd(); } @@ -21801,10 +22103,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.STRUCT, struct.success.size())); - for (Map.Entry _iter470 : struct.success.entrySet()) + for (Map.Entry _iter504 : struct.success.entrySet()) { - oprot.writeString(_iter470.getKey()); - _iter470.getValue().write(oprot); + oprot.writeString(_iter504.getKey()); + _iter504.getValue().write(oprot); } oprot.writeMapEnd(); } @@ -21843,10 +22145,10 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Map.Entry _iter471 : struct.success.entrySet()) + for (Map.Entry _iter505 : struct.success.entrySet()) { - oprot.writeString(_iter471.getKey()); - _iter471.getValue().write(oprot); + oprot.writeString(_iter505.getKey()); + _iter505.getValue().write(oprot); } } } @@ -21861,16 +22163,16 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TMap _map472 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new HashMap(2*_map472.size); - for (int _i473 = 0; _i473 < _map472.size; ++_i473) + org.apache.thrift.protocol.TMap _map506 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new HashMap(2*_map506.size); + for (int _i507 = 0; _i507 < _map506.size; ++_i507) { - String _key474; // required - Type _val475; // required - _key474 = iprot.readString(); - _val475 = new Type(); - _val475.read(iprot); - struct.success.put(_key474, _val475); + String _key508; // required + Type _val509; // required + _key508 = iprot.readString(); + _val509 = new Type(); + _val509.read(iprot); + struct.success.put(_key508, _val509); } } struct.setSuccessIsSet(true); @@ -22905,14 +23207,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list476 = iprot.readListBegin(); - struct.success = new ArrayList(_list476.size); - for (int _i477 = 0; _i477 < _list476.size; ++_i477) + org.apache.thrift.protocol.TList _list510 = iprot.readListBegin(); + struct.success = new ArrayList(_list510.size); + for (int _i511 = 0; _i511 < _list510.size; ++_i511) { - FieldSchema _elem478; // required - _elem478 = new FieldSchema(); - _elem478.read(iprot); - struct.success.add(_elem478); + FieldSchema _elem512; // required + _elem512 = new FieldSchema(); + _elem512.read(iprot); + struct.success.add(_elem512); } iprot.readListEnd(); } @@ -22965,9 +23267,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (FieldSchema _iter479 : struct.success) + for (FieldSchema _iter513 : struct.success) { - _iter479.write(oprot); + _iter513.write(oprot); } oprot.writeListEnd(); } @@ -23022,9 +23324,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (FieldSchema _iter480 : struct.success) + for (FieldSchema _iter514 : struct.success) { - _iter480.write(oprot); + _iter514.write(oprot); } } } @@ -23045,14 +23347,14 @@ BitSet incoming = iprot.readBitSet(4); if (incoming.get(0)) { { - 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) + org.apache.thrift.protocol.TList _list515 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list515.size); + for (int _i516 = 0; _i516 < _list515.size; ++_i516) { - FieldSchema _elem483; // required - _elem483 = new FieldSchema(); - _elem483.read(iprot); - struct.success.add(_elem483); + FieldSchema _elem517; // required + _elem517 = new FieldSchema(); + _elem517.read(iprot); + struct.success.add(_elem517); } } struct.setSuccessIsSet(true); @@ -24097,14 +24399,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list484 = iprot.readListBegin(); - struct.success = new ArrayList(_list484.size); - for (int _i485 = 0; _i485 < _list484.size; ++_i485) + org.apache.thrift.protocol.TList _list518 = iprot.readListBegin(); + struct.success = new ArrayList(_list518.size); + for (int _i519 = 0; _i519 < _list518.size; ++_i519) { - FieldSchema _elem486; // required - _elem486 = new FieldSchema(); - _elem486.read(iprot); - struct.success.add(_elem486); + FieldSchema _elem520; // required + _elem520 = new FieldSchema(); + _elem520.read(iprot); + struct.success.add(_elem520); } iprot.readListEnd(); } @@ -24157,9 +24459,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (FieldSchema _iter487 : struct.success) + for (FieldSchema _iter521 : struct.success) { - _iter487.write(oprot); + _iter521.write(oprot); } oprot.writeListEnd(); } @@ -24214,9 +24516,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (FieldSchema _iter488 : struct.success) + for (FieldSchema _iter522 : struct.success) { - _iter488.write(oprot); + _iter522.write(oprot); } } } @@ -24237,14 +24539,14 @@ BitSet incoming = iprot.readBitSet(4); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list489 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list489.size); - for (int _i490 = 0; _i490 < _list489.size; ++_i490) + org.apache.thrift.protocol.TList _list523 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list523.size); + for (int _i524 = 0; _i524 < _list523.size; ++_i524) { - FieldSchema _elem491; // required - _elem491 = new FieldSchema(); - _elem491.read(iprot); - struct.success.add(_elem491); + FieldSchema _elem525; // required + _elem525 = new FieldSchema(); + _elem525.read(iprot); + struct.success.add(_elem525); } } struct.setSuccessIsSet(true); @@ -29487,13 +29789,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list492 = iprot.readListBegin(); - struct.success = new ArrayList(_list492.size); - for (int _i493 = 0; _i493 < _list492.size; ++_i493) + org.apache.thrift.protocol.TList _list526 = iprot.readListBegin(); + struct.success = new ArrayList(_list526.size); + for (int _i527 = 0; _i527 < _list526.size; ++_i527) { - String _elem494; // required - _elem494 = iprot.readString(); - struct.success.add(_elem494); + String _elem528; // required + _elem528 = iprot.readString(); + struct.success.add(_elem528); } iprot.readListEnd(); } @@ -29528,9 +29830,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 _iter495 : struct.success) + for (String _iter529 : struct.success) { - oprot.writeString(_iter495); + oprot.writeString(_iter529); } oprot.writeListEnd(); } @@ -29569,9 +29871,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter496 : struct.success) + for (String _iter530 : struct.success) { - oprot.writeString(_iter496); + oprot.writeString(_iter530); } } } @@ -29586,13 +29888,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - 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) + org.apache.thrift.protocol.TList _list531 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list531.size); + for (int _i532 = 0; _i532 < _list531.size; ++_i532) { - String _elem499; // required - _elem499 = iprot.readString(); - struct.success.add(_elem499); + String _elem533; // required + _elem533 = iprot.readString(); + struct.success.add(_elem533); } } struct.setSuccessIsSet(true); @@ -30361,13 +30663,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list500 = iprot.readListBegin(); - struct.success = new ArrayList(_list500.size); - for (int _i501 = 0; _i501 < _list500.size; ++_i501) + org.apache.thrift.protocol.TList _list534 = iprot.readListBegin(); + struct.success = new ArrayList(_list534.size); + for (int _i535 = 0; _i535 < _list534.size; ++_i535) { - String _elem502; // required - _elem502 = iprot.readString(); - struct.success.add(_elem502); + String _elem536; // required + _elem536 = iprot.readString(); + struct.success.add(_elem536); } iprot.readListEnd(); } @@ -30402,9 +30704,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 _iter503 : struct.success) + for (String _iter537 : struct.success) { - oprot.writeString(_iter503); + oprot.writeString(_iter537); } oprot.writeListEnd(); } @@ -30443,9 +30745,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter504 : struct.success) + for (String _iter538 : struct.success) { - oprot.writeString(_iter504); + oprot.writeString(_iter538); } } } @@ -30460,13 +30762,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list505 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list505.size); - for (int _i506 = 0; _i506 < _list505.size; ++_i506) + org.apache.thrift.protocol.TList _list539 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list539.size); + for (int _i540 = 0; _i540 < _list539.size; ++_i540) { - String _elem507; // required - _elem507 = iprot.readString(); - struct.success.add(_elem507); + String _elem541; // required + _elem541 = iprot.readString(); + struct.success.add(_elem541); } } struct.setSuccessIsSet(true); @@ -31922,13 +32224,13 @@ case 2: // TBL_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list508 = iprot.readListBegin(); - struct.tbl_names = new ArrayList(_list508.size); - for (int _i509 = 0; _i509 < _list508.size; ++_i509) + org.apache.thrift.protocol.TList _list542 = iprot.readListBegin(); + struct.tbl_names = new ArrayList(_list542.size); + for (int _i543 = 0; _i543 < _list542.size; ++_i543) { - String _elem510; // required - _elem510 = iprot.readString(); - struct.tbl_names.add(_elem510); + String _elem544; // required + _elem544 = iprot.readString(); + struct.tbl_names.add(_elem544); } iprot.readListEnd(); } @@ -31959,9 +32261,9 @@ oprot.writeFieldBegin(TBL_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.tbl_names.size())); - for (String _iter511 : struct.tbl_names) + for (String _iter545 : struct.tbl_names) { - oprot.writeString(_iter511); + oprot.writeString(_iter545); } oprot.writeListEnd(); } @@ -31998,9 +32300,9 @@ if (struct.isSetTbl_names()) { { oprot.writeI32(struct.tbl_names.size()); - for (String _iter512 : struct.tbl_names) + for (String _iter546 : struct.tbl_names) { - oprot.writeString(_iter512); + oprot.writeString(_iter546); } } } @@ -32016,13 +32318,13 @@ } if (incoming.get(1)) { { - org.apache.thrift.protocol.TList _list513 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.tbl_names = new ArrayList(_list513.size); - for (int _i514 = 0; _i514 < _list513.size; ++_i514) + org.apache.thrift.protocol.TList _list547 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.tbl_names = new ArrayList(_list547.size); + for (int _i548 = 0; _i548 < _list547.size; ++_i548) { - String _elem515; // required - _elem515 = iprot.readString(); - struct.tbl_names.add(_elem515); + String _elem549; // required + _elem549 = iprot.readString(); + struct.tbl_names.add(_elem549); } } struct.setTbl_namesIsSet(true); @@ -32590,14 +32892,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list516 = iprot.readListBegin(); - struct.success = new ArrayList
(_list516.size); - for (int _i517 = 0; _i517 < _list516.size; ++_i517) + org.apache.thrift.protocol.TList _list550 = iprot.readListBegin(); + struct.success = new ArrayList
(_list550.size); + for (int _i551 = 0; _i551 < _list550.size; ++_i551) { - Table _elem518; // required - _elem518 = new Table(); - _elem518.read(iprot); - struct.success.add(_elem518); + Table _elem552; // required + _elem552 = new Table(); + _elem552.read(iprot); + struct.success.add(_elem552); } iprot.readListEnd(); } @@ -32650,9 +32952,9 @@ oprot.writeFieldBegin(SUCCESS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); - for (Table _iter519 : struct.success) + for (Table _iter553 : struct.success) { - _iter519.write(oprot); + _iter553.write(oprot); } oprot.writeListEnd(); } @@ -32707,9 +33009,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Table _iter520 : struct.success) + for (Table _iter554 : struct.success) { - _iter520.write(oprot); + _iter554.write(oprot); } } } @@ -32730,14 +33032,14 @@ BitSet incoming = iprot.readBitSet(4); if (incoming.get(0)) { { - 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) + org.apache.thrift.protocol.TList _list555 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList
(_list555.size); + for (int _i556 = 0; _i556 < _list555.size; ++_i556) { - Table _elem523; // required - _elem523 = new Table(); - _elem523.read(iprot); - struct.success.add(_elem523); + Table _elem557; // required + _elem557 = new Table(); + _elem557.read(iprot); + struct.success.add(_elem557); } } struct.setSuccessIsSet(true); @@ -33886,13 +34188,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list524 = iprot.readListBegin(); - struct.success = new ArrayList(_list524.size); - for (int _i525 = 0; _i525 < _list524.size; ++_i525) + org.apache.thrift.protocol.TList _list558 = iprot.readListBegin(); + struct.success = new ArrayList(_list558.size); + for (int _i559 = 0; _i559 < _list558.size; ++_i559) { - String _elem526; // required - _elem526 = iprot.readString(); - struct.success.add(_elem526); + String _elem560; // required + _elem560 = iprot.readString(); + struct.success.add(_elem560); } iprot.readListEnd(); } @@ -33945,9 +34247,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 _iter527 : struct.success) + for (String _iter561 : struct.success) { - oprot.writeString(_iter527); + oprot.writeString(_iter561); } oprot.writeListEnd(); } @@ -34002,9 +34304,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter528 : struct.success) + for (String _iter562 : struct.success) { - oprot.writeString(_iter528); + oprot.writeString(_iter562); } } } @@ -34025,13 +34327,13 @@ BitSet incoming = iprot.readBitSet(4); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list529 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list529.size); - for (int _i530 = 0; _i530 < _list529.size; ++_i530) + org.apache.thrift.protocol.TList _list563 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list563.size); + for (int _i564 = 0; _i564 < _list563.size; ++_i564) { - String _elem531; // required - _elem531 = iprot.readString(); - struct.success.add(_elem531); + String _elem565; // required + _elem565 = iprot.readString(); + struct.success.add(_elem565); } } struct.setSuccessIsSet(true); @@ -38751,14 +39053,14 @@ case 1: // NEW_PARTS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list532 = iprot.readListBegin(); - struct.new_parts = new ArrayList(_list532.size); - for (int _i533 = 0; _i533 < _list532.size; ++_i533) + org.apache.thrift.protocol.TList _list566 = iprot.readListBegin(); + struct.new_parts = new ArrayList(_list566.size); + for (int _i567 = 0; _i567 < _list566.size; ++_i567) { - Partition _elem534; // required - _elem534 = new Partition(); - _elem534.read(iprot); - struct.new_parts.add(_elem534); + Partition _elem568; // required + _elem568 = new Partition(); + _elem568.read(iprot); + struct.new_parts.add(_elem568); } iprot.readListEnd(); } @@ -38784,9 +39086,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 _iter535 : struct.new_parts) + for (Partition _iter569 : struct.new_parts) { - _iter535.write(oprot); + _iter569.write(oprot); } oprot.writeListEnd(); } @@ -38817,9 +39119,9 @@ if (struct.isSetNew_parts()) { { oprot.writeI32(struct.new_parts.size()); - for (Partition _iter536 : struct.new_parts) + for (Partition _iter570 : struct.new_parts) { - _iter536.write(oprot); + _iter570.write(oprot); } } } @@ -38831,14 +39133,14 @@ BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list537 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.new_parts = new ArrayList(_list537.size); - for (int _i538 = 0; _i538 < _list537.size; ++_i538) + org.apache.thrift.protocol.TList _list571 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.new_parts = new ArrayList(_list571.size); + for (int _i572 = 0; _i572 < _list571.size; ++_i572) { - Partition _elem539; // required - _elem539 = new Partition(); - _elem539.read(iprot); - struct.new_parts.add(_elem539); + Partition _elem573; // required + _elem573 = new Partition(); + _elem573.read(iprot); + struct.new_parts.add(_elem573); } } struct.setNew_partsIsSet(true); @@ -39524,6 +39826,1094 @@ } + public static class add_partitions_pspec_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("add_partitions_pspec_args"); + + private static final org.apache.thrift.protocol.TField NEW_PARTS_FIELD_DESC = new org.apache.thrift.protocol.TField("new_parts", org.apache.thrift.protocol.TType.LIST, (short)1); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new add_partitions_pspec_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new add_partitions_pspec_argsTupleSchemeFactory()); + } + + private List new_parts; // 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 { + NEW_PARTS((short)1, "new_parts"); + + 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: // NEW_PARTS + return NEW_PARTS; + 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.NEW_PARTS, new org.apache.thrift.meta_data.FieldMetaData("new_parts", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionSpec.class)))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(add_partitions_pspec_args.class, metaDataMap); + } + + public add_partitions_pspec_args() { + } + + public add_partitions_pspec_args( + List new_parts) + { + this(); + this.new_parts = new_parts; + } + + /** + * Performs a deep copy on other. + */ + public add_partitions_pspec_args(add_partitions_pspec_args other) { + if (other.isSetNew_parts()) { + List __this__new_parts = new ArrayList(); + for (PartitionSpec other_element : other.new_parts) { + __this__new_parts.add(new PartitionSpec(other_element)); + } + this.new_parts = __this__new_parts; + } + } + + public add_partitions_pspec_args deepCopy() { + return new add_partitions_pspec_args(this); + } + + @Override + public void clear() { + this.new_parts = null; + } + + public int getNew_partsSize() { + return (this.new_parts == null) ? 0 : this.new_parts.size(); + } + + public java.util.Iterator getNew_partsIterator() { + return (this.new_parts == null) ? null : this.new_parts.iterator(); + } + + public void addToNew_parts(PartitionSpec elem) { + if (this.new_parts == null) { + this.new_parts = new ArrayList(); + } + this.new_parts.add(elem); + } + + public List getNew_parts() { + return this.new_parts; + } + + public void setNew_parts(List new_parts) { + this.new_parts = new_parts; + } + + public void unsetNew_parts() { + this.new_parts = null; + } + + /** Returns true if field new_parts is set (has been assigned a value) and false otherwise */ + public boolean isSetNew_parts() { + return this.new_parts != null; + } + + public void setNew_partsIsSet(boolean value) { + if (!value) { + this.new_parts = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case NEW_PARTS: + if (value == null) { + unsetNew_parts(); + } else { + setNew_parts((List)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case NEW_PARTS: + return getNew_parts(); + + } + 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 NEW_PARTS: + return isSetNew_parts(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof add_partitions_pspec_args) + return this.equals((add_partitions_pspec_args)that); + return false; + } + + public boolean equals(add_partitions_pspec_args that) { + if (that == null) + return false; + + boolean this_present_new_parts = true && this.isSetNew_parts(); + boolean that_present_new_parts = true && that.isSetNew_parts(); + if (this_present_new_parts || that_present_new_parts) { + if (!(this_present_new_parts && that_present_new_parts)) + return false; + if (!this.new_parts.equals(that.new_parts)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_new_parts = true && (isSetNew_parts()); + builder.append(present_new_parts); + if (present_new_parts) + builder.append(new_parts); + + return builder.toHashCode(); + } + + public int compareTo(add_partitions_pspec_args other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + add_partitions_pspec_args typedOther = (add_partitions_pspec_args)other; + + lastComparison = Boolean.valueOf(isSetNew_parts()).compareTo(typedOther.isSetNew_parts()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetNew_parts()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.new_parts, typedOther.new_parts); + 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("add_partitions_pspec_args("); + boolean first = true; + + sb.append("new_parts:"); + if (this.new_parts == null) { + sb.append("null"); + } else { + sb.append(this.new_parts); + } + 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 add_partitions_pspec_argsStandardSchemeFactory implements SchemeFactory { + public add_partitions_pspec_argsStandardScheme getScheme() { + return new add_partitions_pspec_argsStandardScheme(); + } + } + + private static class add_partitions_pspec_argsStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, add_partitions_pspec_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: // NEW_PARTS + if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { + { + org.apache.thrift.protocol.TList _list574 = iprot.readListBegin(); + struct.new_parts = new ArrayList(_list574.size); + for (int _i575 = 0; _i575 < _list574.size; ++_i575) + { + PartitionSpec _elem576; // required + _elem576 = new PartitionSpec(); + _elem576.read(iprot); + struct.new_parts.add(_elem576); + } + iprot.readListEnd(); + } + struct.setNew_partsIsSet(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, add_partitions_pspec_args struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.new_parts != null) { + 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 (PartitionSpec _iter577 : struct.new_parts) + { + _iter577.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class add_partitions_pspec_argsTupleSchemeFactory implements SchemeFactory { + public add_partitions_pspec_argsTupleScheme getScheme() { + return new add_partitions_pspec_argsTupleScheme(); + } + } + + private static class add_partitions_pspec_argsTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, add_partitions_pspec_args struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetNew_parts()) { + optionals.set(0); + } + oprot.writeBitSet(optionals, 1); + if (struct.isSetNew_parts()) { + { + oprot.writeI32(struct.new_parts.size()); + for (PartitionSpec _iter578 : struct.new_parts) + { + _iter578.write(oprot); + } + } + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, add_partitions_pspec_args struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(1); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TList _list579 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.new_parts = new ArrayList(_list579.size); + for (int _i580 = 0; _i580 < _list579.size; ++_i580) + { + PartitionSpec _elem581; // required + _elem581 = new PartitionSpec(); + _elem581.read(iprot); + struct.new_parts.add(_elem581); + } + } + struct.setNew_partsIsSet(true); + } + } + } + + } + + public static class add_partitions_pspec_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("add_partitions_pspec_result"); + + private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (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 Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new add_partitions_pspec_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new add_partitions_pspec_resultTupleSchemeFactory()); + } + + private int success; // required + private InvalidObjectException o1; // required + private AlreadyExistsException o2; // required + private MetaException o3; // 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"); + + 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; + 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 + private static final int __SUCCESS_ISSET_ID = 0; + private byte __isset_bitfield = 0; + 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.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); + 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))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(add_partitions_pspec_result.class, metaDataMap); + } + + public add_partitions_pspec_result() { + } + + public add_partitions_pspec_result( + int success, + InvalidObjectException o1, + AlreadyExistsException o2, + MetaException o3) + { + this(); + this.success = success; + setSuccessIsSet(true); + this.o1 = o1; + this.o2 = o2; + this.o3 = o3; + } + + /** + * Performs a deep copy on other. + */ + public add_partitions_pspec_result(add_partitions_pspec_result other) { + __isset_bitfield = other.__isset_bitfield; + this.success = other.success; + if (other.isSetO1()) { + this.o1 = new InvalidObjectException(other.o1); + } + if (other.isSetO2()) { + this.o2 = new AlreadyExistsException(other.o2); + } + if (other.isSetO3()) { + this.o3 = new MetaException(other.o3); + } + } + + public add_partitions_pspec_result deepCopy() { + return new add_partitions_pspec_result(this); + } + + @Override + public void clear() { + setSuccessIsSet(false); + this.success = 0; + this.o1 = null; + this.o2 = null; + this.o3 = null; + } + + public int getSuccess() { + return this.success; + } + + public void setSuccess(int success) { + this.success = success; + setSuccessIsSet(true); + } + + public void unsetSuccess() { + __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID); + } + + /** Returns true if field success is set (has been assigned a value) and false otherwise */ + public boolean isSetSuccess() { + return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID); + } + + public void setSuccessIsSet(boolean value) { + __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value); + } + + public InvalidObjectException getO1() { + return this.o1; + } + + public void setO1(InvalidObjectException 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 AlreadyExistsException getO2() { + return this.o2; + } + + public void setO2(AlreadyExistsException 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 MetaException getO3() { + return this.o3; + } + + public void setO3(MetaException 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 void setFieldValue(_Fields field, Object value) { + switch (field) { + case SUCCESS: + if (value == null) { + unsetSuccess(); + } else { + setSuccess((Integer)value); + } + break; + + case O1: + if (value == null) { + unsetO1(); + } else { + setO1((InvalidObjectException)value); + } + break; + + case O2: + if (value == null) { + unsetO2(); + } else { + setO2((AlreadyExistsException)value); + } + break; + + case O3: + if (value == null) { + unsetO3(); + } else { + setO3((MetaException)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case SUCCESS: + return Integer.valueOf(getSuccess()); + + case O1: + return getO1(); + + case O2: + return getO2(); + + case O3: + return getO3(); + + } + 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(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof add_partitions_pspec_result) + return this.equals((add_partitions_pspec_result)that); + return false; + } + + public boolean equals(add_partitions_pspec_result that) { + if (that == null) + return false; + + boolean this_present_success = true; + boolean that_present_success = true; + if (this_present_success || that_present_success) { + if (!(this_present_success && that_present_success)) + return false; + if (this.success != 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; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_success = true; + 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); + + return builder.toHashCode(); + } + + public int compareTo(add_partitions_pspec_result other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + add_partitions_pspec_result typedOther = (add_partitions_pspec_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; + } + } + 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("add_partitions_pspec_result("); + boolean first = true; + + sb.append("success:"); + 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; + 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 { + // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor. + __isset_bitfield = 0; + 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 add_partitions_pspec_resultStandardSchemeFactory implements SchemeFactory { + public add_partitions_pspec_resultStandardScheme getScheme() { + return new add_partitions_pspec_resultStandardScheme(); + } + } + + private static class add_partitions_pspec_resultStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, add_partitions_pspec_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.I32) { + struct.success = iprot.readI32(); + 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 InvalidObjectException(); + 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 AlreadyExistsException(); + 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 MetaException(); + struct.o3.read(iprot); + struct.setO3IsSet(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, add_partitions_pspec_result struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + oprot.writeI32(struct.success); + 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(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class add_partitions_pspec_resultTupleSchemeFactory implements SchemeFactory { + public add_partitions_pspec_resultTupleScheme getScheme() { + return new add_partitions_pspec_resultTupleScheme(); + } + } + + private static class add_partitions_pspec_resultTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, add_partitions_pspec_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); + } + oprot.writeBitSet(optionals, 4); + if (struct.isSetSuccess()) { + oprot.writeI32(struct.success); + } + if (struct.isSetO1()) { + struct.o1.write(oprot); + } + if (struct.isSetO2()) { + struct.o2.write(oprot); + } + if (struct.isSetO3()) { + struct.o3.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, add_partitions_pspec_result struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(4); + if (incoming.get(0)) { + struct.success = iprot.readI32(); + struct.setSuccessIsSet(true); + } + if (incoming.get(1)) { + struct.o1 = new InvalidObjectException(); + struct.o1.read(iprot); + struct.setO1IsSet(true); + } + if (incoming.get(2)) { + struct.o2 = new AlreadyExistsException(); + struct.o2.read(iprot); + struct.setO2IsSet(true); + } + if (incoming.get(3)) { + struct.o3 = new MetaException(); + struct.o3.read(iprot); + struct.setO3IsSet(true); + } + } + } + + } + public static class append_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("append_partition_args"); @@ -40017,13 +41407,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list540 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list540.size); - for (int _i541 = 0; _i541 < _list540.size; ++_i541) + org.apache.thrift.protocol.TList _list582 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list582.size); + for (int _i583 = 0; _i583 < _list582.size; ++_i583) { - String _elem542; // required - _elem542 = iprot.readString(); - struct.part_vals.add(_elem542); + String _elem584; // required + _elem584 = iprot.readString(); + struct.part_vals.add(_elem584); } iprot.readListEnd(); } @@ -40059,9 +41449,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 _iter543 : struct.part_vals) + for (String _iter585 : struct.part_vals) { - oprot.writeString(_iter543); + oprot.writeString(_iter585); } oprot.writeListEnd(); } @@ -40104,9 +41494,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter544 : struct.part_vals) + for (String _iter586 : struct.part_vals) { - oprot.writeString(_iter544); + oprot.writeString(_iter586); } } } @@ -40126,13 +41516,13 @@ } if (incoming.get(2)) { { - 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) + org.apache.thrift.protocol.TList _list587 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list587.size); + for (int _i588 = 0; _i588 < _list587.size; ++_i588) { - String _elem547; // required - _elem547 = iprot.readString(); - struct.part_vals.add(_elem547); + String _elem589; // required + _elem589 = iprot.readString(); + struct.part_vals.add(_elem589); } } struct.setPart_valsIsSet(true); @@ -42444,13 +43834,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list548 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list548.size); - for (int _i549 = 0; _i549 < _list548.size; ++_i549) + org.apache.thrift.protocol.TList _list590 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list590.size); + for (int _i591 = 0; _i591 < _list590.size; ++_i591) { - String _elem550; // required - _elem550 = iprot.readString(); - struct.part_vals.add(_elem550); + String _elem592; // required + _elem592 = iprot.readString(); + struct.part_vals.add(_elem592); } iprot.readListEnd(); } @@ -42495,9 +43885,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 _iter551 : struct.part_vals) + for (String _iter593 : struct.part_vals) { - oprot.writeString(_iter551); + oprot.writeString(_iter593); } oprot.writeListEnd(); } @@ -42548,9 +43938,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter552 : struct.part_vals) + for (String _iter594 : struct.part_vals) { - oprot.writeString(_iter552); + oprot.writeString(_iter594); } } } @@ -42573,13 +43963,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list553 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list553.size); - for (int _i554 = 0; _i554 < _list553.size; ++_i554) + org.apache.thrift.protocol.TList _list595 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list595.size); + for (int _i596 = 0; _i596 < _list595.size; ++_i596) { - String _elem555; // required - _elem555 = iprot.readString(); - struct.part_vals.add(_elem555); + String _elem597; // required + _elem597 = iprot.readString(); + struct.part_vals.add(_elem597); } } struct.setPart_valsIsSet(true); @@ -46452,13 +47842,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list556 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list556.size); - for (int _i557 = 0; _i557 < _list556.size; ++_i557) + org.apache.thrift.protocol.TList _list598 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list598.size); + for (int _i599 = 0; _i599 < _list598.size; ++_i599) { - String _elem558; // required - _elem558 = iprot.readString(); - struct.part_vals.add(_elem558); + String _elem600; // required + _elem600 = iprot.readString(); + struct.part_vals.add(_elem600); } iprot.readListEnd(); } @@ -46502,9 +47892,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 _iter559 : struct.part_vals) + for (String _iter601 : struct.part_vals) { - oprot.writeString(_iter559); + oprot.writeString(_iter601); } oprot.writeListEnd(); } @@ -46553,9 +47943,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter560 : struct.part_vals) + for (String _iter602 : struct.part_vals) { - oprot.writeString(_iter560); + oprot.writeString(_iter602); } } } @@ -46578,13 +47968,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list561 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list561.size); - for (int _i562 = 0; _i562 < _list561.size; ++_i562) + org.apache.thrift.protocol.TList _list603 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list603.size); + for (int _i604 = 0; _i604 < _list603.size; ++_i604) { - String _elem563; // required - _elem563 = iprot.readString(); - struct.part_vals.add(_elem563); + String _elem605; // required + _elem605 = iprot.readString(); + struct.part_vals.add(_elem605); } } struct.setPart_valsIsSet(true); @@ -47826,13 +49216,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list564 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list564.size); - for (int _i565 = 0; _i565 < _list564.size; ++_i565) + org.apache.thrift.protocol.TList _list606 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list606.size); + for (int _i607 = 0; _i607 < _list606.size; ++_i607) { - String _elem566; // required - _elem566 = iprot.readString(); - struct.part_vals.add(_elem566); + String _elem608; // required + _elem608 = iprot.readString(); + struct.part_vals.add(_elem608); } iprot.readListEnd(); } @@ -47885,9 +49275,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 _iter567 : struct.part_vals) + for (String _iter609 : struct.part_vals) { - oprot.writeString(_iter567); + oprot.writeString(_iter609); } oprot.writeListEnd(); } @@ -47944,9 +49334,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter568 : struct.part_vals) + for (String _iter610 : struct.part_vals) { - oprot.writeString(_iter568); + oprot.writeString(_iter610); } } } @@ -47972,13 +49362,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list569 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list569.size); - for (int _i570 = 0; _i570 < _list569.size; ++_i570) + org.apache.thrift.protocol.TList _list611 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list611.size); + for (int _i612 = 0; _i612 < _list611.size; ++_i612) { - String _elem571; // required - _elem571 = iprot.readString(); - struct.part_vals.add(_elem571); + String _elem613; // required + _elem613 = iprot.readString(); + struct.part_vals.add(_elem613); } } struct.setPart_valsIsSet(true); @@ -52583,13 +53973,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list572 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list572.size); - for (int _i573 = 0; _i573 < _list572.size; ++_i573) + org.apache.thrift.protocol.TList _list614 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list614.size); + for (int _i615 = 0; _i615 < _list614.size; ++_i615) { - String _elem574; // required - _elem574 = iprot.readString(); - struct.part_vals.add(_elem574); + String _elem616; // required + _elem616 = iprot.readString(); + struct.part_vals.add(_elem616); } iprot.readListEnd(); } @@ -52625,9 +54015,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 _iter575 : struct.part_vals) + for (String _iter617 : struct.part_vals) { - oprot.writeString(_iter575); + oprot.writeString(_iter617); } oprot.writeListEnd(); } @@ -52670,9 +54060,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter576 : struct.part_vals) + for (String _iter618 : struct.part_vals) { - oprot.writeString(_iter576); + oprot.writeString(_iter618); } } } @@ -52692,13 +54082,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list577 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list577.size); - for (int _i578 = 0; _i578 < _list577.size; ++_i578) + org.apache.thrift.protocol.TList _list619 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list619.size); + for (int _i620 = 0; _i620 < _list619.size; ++_i620) { - String _elem579; // required - _elem579 = iprot.readString(); - struct.part_vals.add(_elem579); + String _elem621; // required + _elem621 = iprot.readString(); + struct.part_vals.add(_elem621); } } struct.setPart_valsIsSet(true); @@ -53927,15 +55317,15 @@ case 1: // PARTITION_SPECS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map580 = iprot.readMapBegin(); - struct.partitionSpecs = new HashMap(2*_map580.size); - for (int _i581 = 0; _i581 < _map580.size; ++_i581) + org.apache.thrift.protocol.TMap _map622 = iprot.readMapBegin(); + struct.partitionSpecs = new HashMap(2*_map622.size); + for (int _i623 = 0; _i623 < _map622.size; ++_i623) { - String _key582; // required - String _val583; // required - _key582 = iprot.readString(); - _val583 = iprot.readString(); - struct.partitionSpecs.put(_key582, _val583); + String _key624; // required + String _val625; // required + _key624 = iprot.readString(); + _val625 = iprot.readString(); + struct.partitionSpecs.put(_key624, _val625); } iprot.readMapEnd(); } @@ -53993,10 +55383,10 @@ 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 _iter584 : struct.partitionSpecs.entrySet()) + for (Map.Entry _iter626 : struct.partitionSpecs.entrySet()) { - oprot.writeString(_iter584.getKey()); - oprot.writeString(_iter584.getValue()); + oprot.writeString(_iter626.getKey()); + oprot.writeString(_iter626.getValue()); } oprot.writeMapEnd(); } @@ -54059,10 +55449,10 @@ if (struct.isSetPartitionSpecs()) { { oprot.writeI32(struct.partitionSpecs.size()); - for (Map.Entry _iter585 : struct.partitionSpecs.entrySet()) + for (Map.Entry _iter627 : struct.partitionSpecs.entrySet()) { - oprot.writeString(_iter585.getKey()); - oprot.writeString(_iter585.getValue()); + oprot.writeString(_iter627.getKey()); + oprot.writeString(_iter627.getValue()); } } } @@ -54086,15 +55476,15 @@ BitSet incoming = iprot.readBitSet(5); if (incoming.get(0)) { { - org.apache.thrift.protocol.TMap _map586 = 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*_map586.size); - for (int _i587 = 0; _i587 < _map586.size; ++_i587) + org.apache.thrift.protocol.TMap _map628 = 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*_map628.size); + for (int _i629 = 0; _i629 < _map628.size; ++_i629) { - String _key588; // required - String _val589; // required - _key588 = iprot.readString(); - _val589 = iprot.readString(); - struct.partitionSpecs.put(_key588, _val589); + String _key630; // required + String _val631; // required + _key630 = iprot.readString(); + _val631 = iprot.readString(); + struct.partitionSpecs.put(_key630, _val631); } } struct.setPartitionSpecsIsSet(true); @@ -55582,13 +56972,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list590 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list590.size); - for (int _i591 = 0; _i591 < _list590.size; ++_i591) + org.apache.thrift.protocol.TList _list632 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list632.size); + for (int _i633 = 0; _i633 < _list632.size; ++_i633) { - String _elem592; // required - _elem592 = iprot.readString(); - struct.part_vals.add(_elem592); + String _elem634; // required + _elem634 = iprot.readString(); + struct.part_vals.add(_elem634); } iprot.readListEnd(); } @@ -55608,13 +56998,13 @@ case 5: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list593 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list593.size); - for (int _i594 = 0; _i594 < _list593.size; ++_i594) + org.apache.thrift.protocol.TList _list635 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list635.size); + for (int _i636 = 0; _i636 < _list635.size; ++_i636) { - String _elem595; // required - _elem595 = iprot.readString(); - struct.group_names.add(_elem595); + String _elem637; // required + _elem637 = iprot.readString(); + struct.group_names.add(_elem637); } iprot.readListEnd(); } @@ -55650,9 +57040,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 _iter596 : struct.part_vals) + for (String _iter638 : struct.part_vals) { - oprot.writeString(_iter596); + oprot.writeString(_iter638); } oprot.writeListEnd(); } @@ -55667,9 +57057,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 _iter597 : struct.group_names) + for (String _iter639 : struct.group_names) { - oprot.writeString(_iter597); + oprot.writeString(_iter639); } oprot.writeListEnd(); } @@ -55718,9 +57108,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter598 : struct.part_vals) + for (String _iter640 : struct.part_vals) { - oprot.writeString(_iter598); + oprot.writeString(_iter640); } } } @@ -55730,9 +57120,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter599 : struct.group_names) + for (String _iter641 : struct.group_names) { - oprot.writeString(_iter599); + oprot.writeString(_iter641); } } } @@ -55752,13 +57142,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list600 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list600.size); - for (int _i601 = 0; _i601 < _list600.size; ++_i601) + org.apache.thrift.protocol.TList _list642 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list642.size); + for (int _i643 = 0; _i643 < _list642.size; ++_i643) { - String _elem602; // required - _elem602 = iprot.readString(); - struct.part_vals.add(_elem602); + String _elem644; // required + _elem644 = iprot.readString(); + struct.part_vals.add(_elem644); } } struct.setPart_valsIsSet(true); @@ -55769,13 +57159,13 @@ } if (incoming.get(4)) { { - org.apache.thrift.protocol.TList _list603 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list603.size); - for (int _i604 = 0; _i604 < _list603.size; ++_i604) + org.apache.thrift.protocol.TList _list645 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list645.size); + for (int _i646 = 0; _i646 < _list645.size; ++_i646) { - String _elem605; // required - _elem605 = iprot.readString(); - struct.group_names.add(_elem605); + String _elem647; // required + _elem647 = iprot.readString(); + struct.group_names.add(_elem647); } } struct.setGroup_namesIsSet(true); @@ -58544,14 +59934,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list606 = iprot.readListBegin(); - struct.success = new ArrayList(_list606.size); - for (int _i607 = 0; _i607 < _list606.size; ++_i607) + org.apache.thrift.protocol.TList _list648 = iprot.readListBegin(); + struct.success = new ArrayList(_list648.size); + for (int _i649 = 0; _i649 < _list648.size; ++_i649) { - Partition _elem608; // required - _elem608 = new Partition(); - _elem608.read(iprot); - struct.success.add(_elem608); + Partition _elem650; // required + _elem650 = new Partition(); + _elem650.read(iprot); + struct.success.add(_elem650); } iprot.readListEnd(); } @@ -58595,9 +59985,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 _iter609 : struct.success) + for (Partition _iter651 : struct.success) { - _iter609.write(oprot); + _iter651.write(oprot); } oprot.writeListEnd(); } @@ -58644,9 +60034,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter610 : struct.success) + for (Partition _iter652 : struct.success) { - _iter610.write(oprot); + _iter652.write(oprot); } } } @@ -58664,14 +60054,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list611 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list611.size); - for (int _i612 = 0; _i612 < _list611.size; ++_i612) + org.apache.thrift.protocol.TList _list653 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list653.size); + for (int _i654 = 0; _i654 < _list653.size; ++_i654) { - Partition _elem613; // required - _elem613 = new Partition(); - _elem613.read(iprot); - struct.success.add(_elem613); + Partition _elem655; // required + _elem655 = new Partition(); + _elem655.read(iprot); + struct.success.add(_elem655); } } struct.setSuccessIsSet(true); @@ -59364,13 +60754,13 @@ case 5: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list614 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list614.size); - for (int _i615 = 0; _i615 < _list614.size; ++_i615) + org.apache.thrift.protocol.TList _list656 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list656.size); + for (int _i657 = 0; _i657 < _list656.size; ++_i657) { - String _elem616; // required - _elem616 = iprot.readString(); - struct.group_names.add(_elem616); + String _elem658; // required + _elem658 = iprot.readString(); + struct.group_names.add(_elem658); } iprot.readListEnd(); } @@ -59414,9 +60804,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 _iter617 : struct.group_names) + for (String _iter659 : struct.group_names) { - oprot.writeString(_iter617); + oprot.writeString(_iter659); } oprot.writeListEnd(); } @@ -59471,9 +60861,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter618 : struct.group_names) + for (String _iter660 : struct.group_names) { - oprot.writeString(_iter618); + oprot.writeString(_iter660); } } } @@ -59501,13 +60891,13 @@ } if (incoming.get(4)) { { - org.apache.thrift.protocol.TList _list619 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list619.size); - for (int _i620 = 0; _i620 < _list619.size; ++_i620) + org.apache.thrift.protocol.TList _list661 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list661.size); + for (int _i662 = 0; _i662 < _list661.size; ++_i662) { - String _elem621; // required - _elem621 = iprot.readString(); - struct.group_names.add(_elem621); + String _elem663; // required + _elem663 = iprot.readString(); + struct.group_names.add(_elem663); } } struct.setGroup_namesIsSet(true); @@ -59994,14 +61384,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list622 = iprot.readListBegin(); - struct.success = new ArrayList(_list622.size); - for (int _i623 = 0; _i623 < _list622.size; ++_i623) + org.apache.thrift.protocol.TList _list664 = iprot.readListBegin(); + struct.success = new ArrayList(_list664.size); + for (int _i665 = 0; _i665 < _list664.size; ++_i665) { - Partition _elem624; // required - _elem624 = new Partition(); - _elem624.read(iprot); - struct.success.add(_elem624); + Partition _elem666; // required + _elem666 = new Partition(); + _elem666.read(iprot); + struct.success.add(_elem666); } iprot.readListEnd(); } @@ -60045,9 +61435,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 _iter625 : struct.success) + for (Partition _iter667 : struct.success) { - _iter625.write(oprot); + _iter667.write(oprot); } oprot.writeListEnd(); } @@ -60094,9 +61484,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter626 : struct.success) + for (Partition _iter668 : struct.success) { - _iter626.write(oprot); + _iter668.write(oprot); } } } @@ -60114,14 +61504,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list627 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list627.size); - for (int _i628 = 0; _i628 < _list627.size; ++_i628) + org.apache.thrift.protocol.TList _list669 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list669.size); + for (int _i670 = 0; _i670 < _list669.size; ++_i670) { - Partition _elem629; // required - _elem629 = new Partition(); - _elem629.read(iprot); - struct.success.add(_elem629); + Partition _elem671; // required + _elem671 = new Partition(); + _elem671.read(iprot); + struct.success.add(_elem671); } } struct.setSuccessIsSet(true); @@ -60141,6 +61531,1196 @@ } + public static class get_partitions_pspec_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_partitions_pspec_args"); + + private static final org.apache.thrift.protocol.TField DB_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("db_name", org.apache.thrift.protocol.TType.STRING, (short)1); + private static final org.apache.thrift.protocol.TField TBL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("tbl_name", org.apache.thrift.protocol.TType.STRING, (short)2); + private static final org.apache.thrift.protocol.TField MAX_PARTS_FIELD_DESC = new org.apache.thrift.protocol.TField("max_parts", org.apache.thrift.protocol.TType.I32, (short)3); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new get_partitions_pspec_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new get_partitions_pspec_argsTupleSchemeFactory()); + } + + private String db_name; // required + private String tbl_name; // required + private int max_parts; // 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 { + DB_NAME((short)1, "db_name"), + TBL_NAME((short)2, "tbl_name"), + MAX_PARTS((short)3, "max_parts"); + + 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: // DB_NAME + return DB_NAME; + case 2: // TBL_NAME + return TBL_NAME; + case 3: // MAX_PARTS + return MAX_PARTS; + 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 + private static final int __MAX_PARTS_ISSET_ID = 0; + private byte __isset_bitfield = 0; + 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, + 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, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.MAX_PARTS, new org.apache.thrift.meta_data.FieldMetaData("max_parts", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(get_partitions_pspec_args.class, metaDataMap); + } + + public get_partitions_pspec_args() { + this.max_parts = -1; + + } + + public get_partitions_pspec_args( + String db_name, + String tbl_name, + int max_parts) + { + this(); + this.db_name = db_name; + this.tbl_name = tbl_name; + this.max_parts = max_parts; + setMax_partsIsSet(true); + } + + /** + * Performs a deep copy on other. + */ + public get_partitions_pspec_args(get_partitions_pspec_args other) { + __isset_bitfield = other.__isset_bitfield; + if (other.isSetDb_name()) { + this.db_name = other.db_name; + } + if (other.isSetTbl_name()) { + this.tbl_name = other.tbl_name; + } + this.max_parts = other.max_parts; + } + + public get_partitions_pspec_args deepCopy() { + return new get_partitions_pspec_args(this); + } + + @Override + public void clear() { + this.db_name = null; + this.tbl_name = null; + this.max_parts = -1; + + } + + public String getDb_name() { + return this.db_name; + } + + public void setDb_name(String db_name) { + this.db_name = db_name; + } + + public void unsetDb_name() { + this.db_name = null; + } + + /** Returns true if field db_name is set (has been assigned a value) and false otherwise */ + public boolean isSetDb_name() { + return this.db_name != null; + } + + public void setDb_nameIsSet(boolean value) { + if (!value) { + this.db_name = null; + } + } + + public String getTbl_name() { + return this.tbl_name; + } + + public void setTbl_name(String tbl_name) { + this.tbl_name = tbl_name; + } + + public void unsetTbl_name() { + this.tbl_name = null; + } + + /** Returns true if field tbl_name is set (has been assigned a value) and false otherwise */ + public boolean isSetTbl_name() { + return this.tbl_name != null; + } + + public void setTbl_nameIsSet(boolean value) { + if (!value) { + this.tbl_name = null; + } + } + + public int getMax_parts() { + return this.max_parts; + } + + public void setMax_parts(int max_parts) { + this.max_parts = max_parts; + setMax_partsIsSet(true); + } + + public void unsetMax_parts() { + __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAX_PARTS_ISSET_ID); + } + + /** Returns true if field max_parts is set (has been assigned a value) and false otherwise */ + public boolean isSetMax_parts() { + return EncodingUtils.testBit(__isset_bitfield, __MAX_PARTS_ISSET_ID); + } + + public void setMax_partsIsSet(boolean value) { + __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAX_PARTS_ISSET_ID, value); + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case DB_NAME: + if (value == null) { + unsetDb_name(); + } else { + setDb_name((String)value); + } + break; + + case TBL_NAME: + if (value == null) { + unsetTbl_name(); + } else { + setTbl_name((String)value); + } + break; + + case MAX_PARTS: + if (value == null) { + unsetMax_parts(); + } else { + setMax_parts((Integer)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case DB_NAME: + return getDb_name(); + + case TBL_NAME: + return getTbl_name(); + + case MAX_PARTS: + return Integer.valueOf(getMax_parts()); + + } + 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 DB_NAME: + return isSetDb_name(); + case TBL_NAME: + return isSetTbl_name(); + case MAX_PARTS: + return isSetMax_parts(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof get_partitions_pspec_args) + return this.equals((get_partitions_pspec_args)that); + return false; + } + + public boolean equals(get_partitions_pspec_args that) { + if (that == null) + return false; + + boolean this_present_db_name = true && this.isSetDb_name(); + boolean that_present_db_name = true && that.isSetDb_name(); + if (this_present_db_name || that_present_db_name) { + if (!(this_present_db_name && that_present_db_name)) + return false; + if (!this.db_name.equals(that.db_name)) + return false; + } + + boolean this_present_tbl_name = true && this.isSetTbl_name(); + boolean that_present_tbl_name = true && that.isSetTbl_name(); + if (this_present_tbl_name || that_present_tbl_name) { + if (!(this_present_tbl_name && that_present_tbl_name)) + return false; + if (!this.tbl_name.equals(that.tbl_name)) + return false; + } + + boolean this_present_max_parts = true; + boolean that_present_max_parts = true; + if (this_present_max_parts || that_present_max_parts) { + if (!(this_present_max_parts && that_present_max_parts)) + return false; + if (this.max_parts != that.max_parts) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_db_name = true && (isSetDb_name()); + builder.append(present_db_name); + if (present_db_name) + builder.append(db_name); + + boolean present_tbl_name = true && (isSetTbl_name()); + builder.append(present_tbl_name); + if (present_tbl_name) + builder.append(tbl_name); + + boolean present_max_parts = true; + builder.append(present_max_parts); + if (present_max_parts) + builder.append(max_parts); + + return builder.toHashCode(); + } + + public int compareTo(get_partitions_pspec_args other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + get_partitions_pspec_args typedOther = (get_partitions_pspec_args)other; + + lastComparison = Boolean.valueOf(isSetDb_name()).compareTo(typedOther.isSetDb_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetDb_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.db_name, typedOther.db_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetTbl_name()).compareTo(typedOther.isSetTbl_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetTbl_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tbl_name, typedOther.tbl_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetMax_parts()).compareTo(typedOther.isSetMax_parts()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetMax_parts()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.max_parts, typedOther.max_parts); + 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("get_partitions_pspec_args("); + boolean first = true; + + sb.append("db_name:"); + if (this.db_name == null) { + sb.append("null"); + } else { + sb.append(this.db_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("tbl_name:"); + if (this.tbl_name == null) { + sb.append("null"); + } else { + sb.append(this.tbl_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("max_parts:"); + sb.append(this.max_parts); + 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 { + // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor. + __isset_bitfield = 0; + 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 get_partitions_pspec_argsStandardSchemeFactory implements SchemeFactory { + public get_partitions_pspec_argsStandardScheme getScheme() { + return new get_partitions_pspec_argsStandardScheme(); + } + } + + private static class get_partitions_pspec_argsStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_pspec_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: // DB_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.db_name = iprot.readString(); + struct.setDb_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // TBL_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.tbl_name = iprot.readString(); + struct.setTbl_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // MAX_PARTS + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.max_parts = iprot.readI32(); + struct.setMax_partsIsSet(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, get_partitions_pspec_args struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.db_name != null) { + oprot.writeFieldBegin(DB_NAME_FIELD_DESC); + oprot.writeString(struct.db_name); + oprot.writeFieldEnd(); + } + if (struct.tbl_name != null) { + oprot.writeFieldBegin(TBL_NAME_FIELD_DESC); + oprot.writeString(struct.tbl_name); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(MAX_PARTS_FIELD_DESC); + oprot.writeI32(struct.max_parts); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class get_partitions_pspec_argsTupleSchemeFactory implements SchemeFactory { + public get_partitions_pspec_argsTupleScheme getScheme() { + return new get_partitions_pspec_argsTupleScheme(); + } + } + + private static class get_partitions_pspec_argsTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, get_partitions_pspec_args struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetDb_name()) { + optionals.set(0); + } + if (struct.isSetTbl_name()) { + optionals.set(1); + } + if (struct.isSetMax_parts()) { + optionals.set(2); + } + oprot.writeBitSet(optionals, 3); + if (struct.isSetDb_name()) { + oprot.writeString(struct.db_name); + } + if (struct.isSetTbl_name()) { + oprot.writeString(struct.tbl_name); + } + if (struct.isSetMax_parts()) { + oprot.writeI32(struct.max_parts); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_pspec_args struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(3); + if (incoming.get(0)) { + struct.db_name = iprot.readString(); + struct.setDb_nameIsSet(true); + } + if (incoming.get(1)) { + struct.tbl_name = iprot.readString(); + struct.setTbl_nameIsSet(true); + } + if (incoming.get(2)) { + struct.max_parts = iprot.readI32(); + struct.setMax_partsIsSet(true); + } + } + } + + } + + public static class get_partitions_pspec_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("get_partitions_pspec_result"); + + private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (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 Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new get_partitions_pspec_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new get_partitions_pspec_resultTupleSchemeFactory()); + } + + private List success; // required + private NoSuchObjectException o1; // required + private MetaException o2; // 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"); + + 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; + 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.ListMetaData(org.apache.thrift.protocol.TType.LIST, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionSpec.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))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(get_partitions_pspec_result.class, metaDataMap); + } + + public get_partitions_pspec_result() { + } + + public get_partitions_pspec_result( + List success, + NoSuchObjectException o1, + MetaException o2) + { + this(); + this.success = success; + this.o1 = o1; + this.o2 = o2; + } + + /** + * Performs a deep copy on other. + */ + public get_partitions_pspec_result(get_partitions_pspec_result other) { + if (other.isSetSuccess()) { + List __this__success = new ArrayList(); + for (PartitionSpec other_element : other.success) { + __this__success.add(new PartitionSpec(other_element)); + } + this.success = __this__success; + } + if (other.isSetO1()) { + this.o1 = new NoSuchObjectException(other.o1); + } + if (other.isSetO2()) { + this.o2 = new MetaException(other.o2); + } + } + + public get_partitions_pspec_result deepCopy() { + return new get_partitions_pspec_result(this); + } + + @Override + public void clear() { + this.success = null; + this.o1 = null; + this.o2 = null; + } + + public int getSuccessSize() { + return (this.success == null) ? 0 : this.success.size(); + } + + public java.util.Iterator getSuccessIterator() { + return (this.success == null) ? null : this.success.iterator(); + } + + public void addToSuccess(PartitionSpec elem) { + if (this.success == null) { + this.success = new ArrayList(); + } + this.success.add(elem); + } + + public List getSuccess() { + return this.success; + } + + public void setSuccess(List 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 NoSuchObjectException getO1() { + return this.o1; + } + + public void setO1(NoSuchObjectException 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 MetaException getO2() { + return this.o2; + } + + public void setO2(MetaException 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 void setFieldValue(_Fields field, Object value) { + switch (field) { + case SUCCESS: + if (value == null) { + unsetSuccess(); + } else { + setSuccess((List)value); + } + break; + + case O1: + if (value == null) { + unsetO1(); + } else { + setO1((NoSuchObjectException)value); + } + break; + + case O2: + if (value == null) { + unsetO2(); + } else { + setO2((MetaException)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case SUCCESS: + return getSuccess(); + + case O1: + return getO1(); + + case O2: + return getO2(); + + } + 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(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof get_partitions_pspec_result) + return this.equals((get_partitions_pspec_result)that); + return false; + } + + public boolean equals(get_partitions_pspec_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; + } + + 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); + + return builder.toHashCode(); + } + + public int compareTo(get_partitions_pspec_result other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + get_partitions_pspec_result typedOther = (get_partitions_pspec_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; + } + } + 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("get_partitions_pspec_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; + 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 get_partitions_pspec_resultStandardSchemeFactory implements SchemeFactory { + public get_partitions_pspec_resultStandardScheme getScheme() { + return new get_partitions_pspec_resultStandardScheme(); + } + } + + private static class get_partitions_pspec_resultStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_pspec_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.LIST) { + { + org.apache.thrift.protocol.TList _list672 = iprot.readListBegin(); + struct.success = new ArrayList(_list672.size); + for (int _i673 = 0; _i673 < _list672.size; ++_i673) + { + PartitionSpec _elem674; // required + _elem674 = new PartitionSpec(); + _elem674.read(iprot); + struct.success.add(_elem674); + } + iprot.readListEnd(); + } + 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 NoSuchObjectException(); + 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 MetaException(); + struct.o2.read(iprot); + struct.setO2IsSet(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, get_partitions_pspec_result struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.success != null) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + { + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); + for (PartitionSpec _iter675 : struct.success) + { + _iter675.write(oprot); + } + oprot.writeListEnd(); + } + 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(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class get_partitions_pspec_resultTupleSchemeFactory implements SchemeFactory { + public get_partitions_pspec_resultTupleScheme getScheme() { + return new get_partitions_pspec_resultTupleScheme(); + } + } + + private static class get_partitions_pspec_resultTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, get_partitions_pspec_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); + } + oprot.writeBitSet(optionals, 3); + if (struct.isSetSuccess()) { + { + oprot.writeI32(struct.success.size()); + for (PartitionSpec _iter676 : struct.success) + { + _iter676.write(oprot); + } + } + } + if (struct.isSetO1()) { + struct.o1.write(oprot); + } + if (struct.isSetO2()) { + struct.o2.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_pspec_result struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(3); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TList _list677 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list677.size); + for (int _i678 = 0; _i678 < _list677.size; ++_i678) + { + PartitionSpec _elem679; // required + _elem679 = new PartitionSpec(); + _elem679.read(iprot); + struct.success.add(_elem679); + } + } + struct.setSuccessIsSet(true); + } + if (incoming.get(1)) { + struct.o1 = new NoSuchObjectException(); + struct.o1.read(iprot); + struct.setO1IsSet(true); + } + if (incoming.get(2)) { + struct.o2 = new MetaException(); + struct.o2.read(iprot); + struct.setO2IsSet(true); + } + } + } + + } + public static class get_partition_names_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_names_args"); @@ -61103,13 +63683,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list630 = iprot.readListBegin(); - struct.success = new ArrayList(_list630.size); - for (int _i631 = 0; _i631 < _list630.size; ++_i631) + org.apache.thrift.protocol.TList _list680 = iprot.readListBegin(); + struct.success = new ArrayList(_list680.size); + for (int _i681 = 0; _i681 < _list680.size; ++_i681) { - String _elem632; // required - _elem632 = iprot.readString(); - struct.success.add(_elem632); + String _elem682; // required + _elem682 = iprot.readString(); + struct.success.add(_elem682); } iprot.readListEnd(); } @@ -61144,9 +63724,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 _iter633 : struct.success) + for (String _iter683 : struct.success) { - oprot.writeString(_iter633); + oprot.writeString(_iter683); } oprot.writeListEnd(); } @@ -61185,9 +63765,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter634 : struct.success) + for (String _iter684 : struct.success) { - oprot.writeString(_iter634); + oprot.writeString(_iter684); } } } @@ -61202,13 +63782,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list635 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list635.size); - for (int _i636 = 0; _i636 < _list635.size; ++_i636) + org.apache.thrift.protocol.TList _list685 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list685.size); + for (int _i686 = 0; _i686 < _list685.size; ++_i686) { - String _elem637; // required - _elem637 = iprot.readString(); - struct.success.add(_elem637); + String _elem687; // required + _elem687 = iprot.readString(); + struct.success.add(_elem687); } } struct.setSuccessIsSet(true); @@ -61799,13 +64379,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list638 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list638.size); - for (int _i639 = 0; _i639 < _list638.size; ++_i639) + org.apache.thrift.protocol.TList _list688 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list688.size); + for (int _i689 = 0; _i689 < _list688.size; ++_i689) { - String _elem640; // required - _elem640 = iprot.readString(); - struct.part_vals.add(_elem640); + String _elem690; // required + _elem690 = iprot.readString(); + struct.part_vals.add(_elem690); } iprot.readListEnd(); } @@ -61849,9 +64429,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 _iter641 : struct.part_vals) + for (String _iter691 : struct.part_vals) { - oprot.writeString(_iter641); + oprot.writeString(_iter691); } oprot.writeListEnd(); } @@ -61900,9 +64480,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter642 : struct.part_vals) + for (String _iter692 : struct.part_vals) { - oprot.writeString(_iter642); + oprot.writeString(_iter692); } } } @@ -61925,13 +64505,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list643 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list643.size); - for (int _i644 = 0; _i644 < _list643.size; ++_i644) + org.apache.thrift.protocol.TList _list693 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list693.size); + for (int _i694 = 0; _i694 < _list693.size; ++_i694) { - String _elem645; // required - _elem645 = iprot.readString(); - struct.part_vals.add(_elem645); + String _elem695; // required + _elem695 = iprot.readString(); + struct.part_vals.add(_elem695); } } struct.setPart_valsIsSet(true); @@ -62422,14 +65002,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list646 = iprot.readListBegin(); - struct.success = new ArrayList(_list646.size); - for (int _i647 = 0; _i647 < _list646.size; ++_i647) + org.apache.thrift.protocol.TList _list696 = iprot.readListBegin(); + struct.success = new ArrayList(_list696.size); + for (int _i697 = 0; _i697 < _list696.size; ++_i697) { - Partition _elem648; // required - _elem648 = new Partition(); - _elem648.read(iprot); - struct.success.add(_elem648); + Partition _elem698; // required + _elem698 = new Partition(); + _elem698.read(iprot); + struct.success.add(_elem698); } iprot.readListEnd(); } @@ -62473,9 +65053,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 _iter649 : struct.success) + for (Partition _iter699 : struct.success) { - _iter649.write(oprot); + _iter699.write(oprot); } oprot.writeListEnd(); } @@ -62522,9 +65102,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter650 : struct.success) + for (Partition _iter700 : struct.success) { - _iter650.write(oprot); + _iter700.write(oprot); } } } @@ -62542,14 +65122,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list651 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list651.size); - for (int _i652 = 0; _i652 < _list651.size; ++_i652) + org.apache.thrift.protocol.TList _list701 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list701.size); + for (int _i702 = 0; _i702 < _list701.size; ++_i702) { - Partition _elem653; // required - _elem653 = new Partition(); - _elem653.read(iprot); - struct.success.add(_elem653); + Partition _elem703; // required + _elem703 = new Partition(); + _elem703.read(iprot); + struct.success.add(_elem703); } } struct.setSuccessIsSet(true); @@ -63327,13 +65907,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list654 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list654.size); - for (int _i655 = 0; _i655 < _list654.size; ++_i655) + org.apache.thrift.protocol.TList _list704 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list704.size); + for (int _i705 = 0; _i705 < _list704.size; ++_i705) { - String _elem656; // required - _elem656 = iprot.readString(); - struct.part_vals.add(_elem656); + String _elem706; // required + _elem706 = iprot.readString(); + struct.part_vals.add(_elem706); } iprot.readListEnd(); } @@ -63361,13 +65941,13 @@ case 6: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list657 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list657.size); - for (int _i658 = 0; _i658 < _list657.size; ++_i658) + org.apache.thrift.protocol.TList _list707 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list707.size); + for (int _i708 = 0; _i708 < _list707.size; ++_i708) { - String _elem659; // required - _elem659 = iprot.readString(); - struct.group_names.add(_elem659); + String _elem709; // required + _elem709 = iprot.readString(); + struct.group_names.add(_elem709); } iprot.readListEnd(); } @@ -63403,9 +65983,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 _iter660 : struct.part_vals) + for (String _iter710 : struct.part_vals) { - oprot.writeString(_iter660); + oprot.writeString(_iter710); } oprot.writeListEnd(); } @@ -63423,9 +66003,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 _iter661 : struct.group_names) + for (String _iter711 : struct.group_names) { - oprot.writeString(_iter661); + oprot.writeString(_iter711); } oprot.writeListEnd(); } @@ -63477,9 +66057,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter662 : struct.part_vals) + for (String _iter712 : struct.part_vals) { - oprot.writeString(_iter662); + oprot.writeString(_iter712); } } } @@ -63492,9 +66072,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter663 : struct.group_names) + for (String _iter713 : struct.group_names) { - oprot.writeString(_iter663); + oprot.writeString(_iter713); } } } @@ -63514,13 +66094,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list664 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list664.size); - for (int _i665 = 0; _i665 < _list664.size; ++_i665) + org.apache.thrift.protocol.TList _list714 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list714.size); + for (int _i715 = 0; _i715 < _list714.size; ++_i715) { - String _elem666; // required - _elem666 = iprot.readString(); - struct.part_vals.add(_elem666); + String _elem716; // required + _elem716 = iprot.readString(); + struct.part_vals.add(_elem716); } } struct.setPart_valsIsSet(true); @@ -63535,13 +66115,13 @@ } if (incoming.get(5)) { { - org.apache.thrift.protocol.TList _list667 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list667.size); - for (int _i668 = 0; _i668 < _list667.size; ++_i668) + org.apache.thrift.protocol.TList _list717 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list717.size); + for (int _i718 = 0; _i718 < _list717.size; ++_i718) { - String _elem669; // required - _elem669 = iprot.readString(); - struct.group_names.add(_elem669); + String _elem719; // required + _elem719 = iprot.readString(); + struct.group_names.add(_elem719); } } struct.setGroup_namesIsSet(true); @@ -64028,14 +66608,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list670 = iprot.readListBegin(); - struct.success = new ArrayList(_list670.size); - for (int _i671 = 0; _i671 < _list670.size; ++_i671) + org.apache.thrift.protocol.TList _list720 = iprot.readListBegin(); + struct.success = new ArrayList(_list720.size); + for (int _i721 = 0; _i721 < _list720.size; ++_i721) { - Partition _elem672; // required - _elem672 = new Partition(); - _elem672.read(iprot); - struct.success.add(_elem672); + Partition _elem722; // required + _elem722 = new Partition(); + _elem722.read(iprot); + struct.success.add(_elem722); } iprot.readListEnd(); } @@ -64079,9 +66659,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 _iter673 : struct.success) + for (Partition _iter723 : struct.success) { - _iter673.write(oprot); + _iter723.write(oprot); } oprot.writeListEnd(); } @@ -64128,9 +66708,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter674 : struct.success) + for (Partition _iter724 : struct.success) { - _iter674.write(oprot); + _iter724.write(oprot); } } } @@ -64148,14 +66728,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list675 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list675.size); - for (int _i676 = 0; _i676 < _list675.size; ++_i676) + org.apache.thrift.protocol.TList _list725 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list725.size); + for (int _i726 = 0; _i726 < _list725.size; ++_i726) { - Partition _elem677; // required - _elem677 = new Partition(); - _elem677.read(iprot); - struct.success.add(_elem677); + Partition _elem727; // required + _elem727 = new Partition(); + _elem727.read(iprot); + struct.success.add(_elem727); } } struct.setSuccessIsSet(true); @@ -64751,13 +67331,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list678 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list678.size); - for (int _i679 = 0; _i679 < _list678.size; ++_i679) + org.apache.thrift.protocol.TList _list728 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list728.size); + for (int _i729 = 0; _i729 < _list728.size; ++_i729) { - String _elem680; // required - _elem680 = iprot.readString(); - struct.part_vals.add(_elem680); + String _elem730; // required + _elem730 = iprot.readString(); + struct.part_vals.add(_elem730); } iprot.readListEnd(); } @@ -64801,9 +67381,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 _iter681 : struct.part_vals) + for (String _iter731 : struct.part_vals) { - oprot.writeString(_iter681); + oprot.writeString(_iter731); } oprot.writeListEnd(); } @@ -64852,9 +67432,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter682 : struct.part_vals) + for (String _iter732 : struct.part_vals) { - oprot.writeString(_iter682); + oprot.writeString(_iter732); } } } @@ -64877,13 +67457,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list683 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list683.size); - for (int _i684 = 0; _i684 < _list683.size; ++_i684) + org.apache.thrift.protocol.TList _list733 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list733.size); + for (int _i734 = 0; _i734 < _list733.size; ++_i734) { - String _elem685; // required - _elem685 = iprot.readString(); - struct.part_vals.add(_elem685); + String _elem735; // required + _elem735 = iprot.readString(); + struct.part_vals.add(_elem735); } } struct.setPart_valsIsSet(true); @@ -65374,13 +67954,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list686 = iprot.readListBegin(); - struct.success = new ArrayList(_list686.size); - for (int _i687 = 0; _i687 < _list686.size; ++_i687) + org.apache.thrift.protocol.TList _list736 = iprot.readListBegin(); + struct.success = new ArrayList(_list736.size); + for (int _i737 = 0; _i737 < _list736.size; ++_i737) { - String _elem688; // required - _elem688 = iprot.readString(); - struct.success.add(_elem688); + String _elem738; // required + _elem738 = iprot.readString(); + struct.success.add(_elem738); } iprot.readListEnd(); } @@ -65424,9 +68004,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 _iter689 : struct.success) + for (String _iter739 : struct.success) { - oprot.writeString(_iter689); + oprot.writeString(_iter739); } oprot.writeListEnd(); } @@ -65473,9 +68053,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter690 : struct.success) + for (String _iter740 : struct.success) { - oprot.writeString(_iter690); + oprot.writeString(_iter740); } } } @@ -65493,13 +68073,13 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list691 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list691.size); - for (int _i692 = 0; _i692 < _list691.size; ++_i692) + org.apache.thrift.protocol.TList _list741 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list741.size); + for (int _i742 = 0; _i742 < _list741.size; ++_i742) { - String _elem693; // required - _elem693 = iprot.readString(); - struct.success.add(_elem693); + String _elem743; // required + _elem743 = iprot.readString(); + struct.success.add(_elem743); } } struct.setSuccessIsSet(true); @@ -66666,14 +69246,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list694 = iprot.readListBegin(); - struct.success = new ArrayList(_list694.size); - for (int _i695 = 0; _i695 < _list694.size; ++_i695) + org.apache.thrift.protocol.TList _list744 = iprot.readListBegin(); + struct.success = new ArrayList(_list744.size); + for (int _i745 = 0; _i745 < _list744.size; ++_i745) { - Partition _elem696; // required - _elem696 = new Partition(); - _elem696.read(iprot); - struct.success.add(_elem696); + Partition _elem746; // required + _elem746 = new Partition(); + _elem746.read(iprot); + struct.success.add(_elem746); } iprot.readListEnd(); } @@ -66717,9 +69297,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 _iter697 : struct.success) + for (Partition _iter747 : struct.success) { - _iter697.write(oprot); + _iter747.write(oprot); } oprot.writeListEnd(); } @@ -66766,9 +69346,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter698 : struct.success) + for (Partition _iter748 : struct.success) { - _iter698.write(oprot); + _iter748.write(oprot); } } } @@ -66786,14 +69366,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list699 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list699.size); - for (int _i700 = 0; _i700 < _list699.size; ++_i700) + org.apache.thrift.protocol.TList _list749 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list749.size); + for (int _i750 = 0; _i750 < _list749.size; ++_i750) { - Partition _elem701; // required - _elem701 = new Partition(); - _elem701.read(iprot); - struct.success.add(_elem701); + Partition _elem751; // required + _elem751 = new Partition(); + _elem751.read(iprot); + struct.success.add(_elem751); } } struct.setSuccessIsSet(true); @@ -66813,6 +69393,1300 @@ } + public static class get_part_specs_by_filter_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_part_specs_by_filter_args"); + + private static final org.apache.thrift.protocol.TField DB_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("db_name", org.apache.thrift.protocol.TType.STRING, (short)1); + private static final org.apache.thrift.protocol.TField TBL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("tbl_name", org.apache.thrift.protocol.TType.STRING, (short)2); + private static final org.apache.thrift.protocol.TField FILTER_FIELD_DESC = new org.apache.thrift.protocol.TField("filter", org.apache.thrift.protocol.TType.STRING, (short)3); + private static final org.apache.thrift.protocol.TField MAX_PARTS_FIELD_DESC = new org.apache.thrift.protocol.TField("max_parts", org.apache.thrift.protocol.TType.I32, (short)4); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new get_part_specs_by_filter_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new get_part_specs_by_filter_argsTupleSchemeFactory()); + } + + private String db_name; // required + private String tbl_name; // required + private String filter; // required + private int max_parts; // 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 { + DB_NAME((short)1, "db_name"), + TBL_NAME((short)2, "tbl_name"), + FILTER((short)3, "filter"), + MAX_PARTS((short)4, "max_parts"); + + 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: // DB_NAME + return DB_NAME; + case 2: // TBL_NAME + return TBL_NAME; + case 3: // FILTER + return FILTER; + case 4: // MAX_PARTS + return MAX_PARTS; + 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 + private static final int __MAX_PARTS_ISSET_ID = 0; + private byte __isset_bitfield = 0; + 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, + 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, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.FILTER, new org.apache.thrift.meta_data.FieldMetaData("filter", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.MAX_PARTS, new org.apache.thrift.meta_data.FieldMetaData("max_parts", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(get_part_specs_by_filter_args.class, metaDataMap); + } + + public get_part_specs_by_filter_args() { + this.max_parts = -1; + + } + + public get_part_specs_by_filter_args( + String db_name, + String tbl_name, + String filter, + int max_parts) + { + this(); + this.db_name = db_name; + this.tbl_name = tbl_name; + this.filter = filter; + this.max_parts = max_parts; + setMax_partsIsSet(true); + } + + /** + * Performs a deep copy on other. + */ + public get_part_specs_by_filter_args(get_part_specs_by_filter_args other) { + __isset_bitfield = other.__isset_bitfield; + if (other.isSetDb_name()) { + this.db_name = other.db_name; + } + if (other.isSetTbl_name()) { + this.tbl_name = other.tbl_name; + } + if (other.isSetFilter()) { + this.filter = other.filter; + } + this.max_parts = other.max_parts; + } + + public get_part_specs_by_filter_args deepCopy() { + return new get_part_specs_by_filter_args(this); + } + + @Override + public void clear() { + this.db_name = null; + this.tbl_name = null; + this.filter = null; + this.max_parts = -1; + + } + + public String getDb_name() { + return this.db_name; + } + + public void setDb_name(String db_name) { + this.db_name = db_name; + } + + public void unsetDb_name() { + this.db_name = null; + } + + /** Returns true if field db_name is set (has been assigned a value) and false otherwise */ + public boolean isSetDb_name() { + return this.db_name != null; + } + + public void setDb_nameIsSet(boolean value) { + if (!value) { + this.db_name = null; + } + } + + public String getTbl_name() { + return this.tbl_name; + } + + public void setTbl_name(String tbl_name) { + this.tbl_name = tbl_name; + } + + public void unsetTbl_name() { + this.tbl_name = null; + } + + /** Returns true if field tbl_name is set (has been assigned a value) and false otherwise */ + public boolean isSetTbl_name() { + return this.tbl_name != null; + } + + public void setTbl_nameIsSet(boolean value) { + if (!value) { + this.tbl_name = null; + } + } + + public String getFilter() { + return this.filter; + } + + public void setFilter(String filter) { + this.filter = filter; + } + + public void unsetFilter() { + this.filter = null; + } + + /** Returns true if field filter is set (has been assigned a value) and false otherwise */ + public boolean isSetFilter() { + return this.filter != null; + } + + public void setFilterIsSet(boolean value) { + if (!value) { + this.filter = null; + } + } + + public int getMax_parts() { + return this.max_parts; + } + + public void setMax_parts(int max_parts) { + this.max_parts = max_parts; + setMax_partsIsSet(true); + } + + public void unsetMax_parts() { + __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAX_PARTS_ISSET_ID); + } + + /** Returns true if field max_parts is set (has been assigned a value) and false otherwise */ + public boolean isSetMax_parts() { + return EncodingUtils.testBit(__isset_bitfield, __MAX_PARTS_ISSET_ID); + } + + public void setMax_partsIsSet(boolean value) { + __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAX_PARTS_ISSET_ID, value); + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case DB_NAME: + if (value == null) { + unsetDb_name(); + } else { + setDb_name((String)value); + } + break; + + case TBL_NAME: + if (value == null) { + unsetTbl_name(); + } else { + setTbl_name((String)value); + } + break; + + case FILTER: + if (value == null) { + unsetFilter(); + } else { + setFilter((String)value); + } + break; + + case MAX_PARTS: + if (value == null) { + unsetMax_parts(); + } else { + setMax_parts((Integer)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case DB_NAME: + return getDb_name(); + + case TBL_NAME: + return getTbl_name(); + + case FILTER: + return getFilter(); + + case MAX_PARTS: + return Integer.valueOf(getMax_parts()); + + } + 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 DB_NAME: + return isSetDb_name(); + case TBL_NAME: + return isSetTbl_name(); + case FILTER: + return isSetFilter(); + case MAX_PARTS: + return isSetMax_parts(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof get_part_specs_by_filter_args) + return this.equals((get_part_specs_by_filter_args)that); + return false; + } + + public boolean equals(get_part_specs_by_filter_args that) { + if (that == null) + return false; + + boolean this_present_db_name = true && this.isSetDb_name(); + boolean that_present_db_name = true && that.isSetDb_name(); + if (this_present_db_name || that_present_db_name) { + if (!(this_present_db_name && that_present_db_name)) + return false; + if (!this.db_name.equals(that.db_name)) + return false; + } + + boolean this_present_tbl_name = true && this.isSetTbl_name(); + boolean that_present_tbl_name = true && that.isSetTbl_name(); + if (this_present_tbl_name || that_present_tbl_name) { + if (!(this_present_tbl_name && that_present_tbl_name)) + return false; + if (!this.tbl_name.equals(that.tbl_name)) + return false; + } + + boolean this_present_filter = true && this.isSetFilter(); + boolean that_present_filter = true && that.isSetFilter(); + if (this_present_filter || that_present_filter) { + if (!(this_present_filter && that_present_filter)) + return false; + if (!this.filter.equals(that.filter)) + return false; + } + + boolean this_present_max_parts = true; + boolean that_present_max_parts = true; + if (this_present_max_parts || that_present_max_parts) { + if (!(this_present_max_parts && that_present_max_parts)) + return false; + if (this.max_parts != that.max_parts) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_db_name = true && (isSetDb_name()); + builder.append(present_db_name); + if (present_db_name) + builder.append(db_name); + + boolean present_tbl_name = true && (isSetTbl_name()); + builder.append(present_tbl_name); + if (present_tbl_name) + builder.append(tbl_name); + + boolean present_filter = true && (isSetFilter()); + builder.append(present_filter); + if (present_filter) + builder.append(filter); + + boolean present_max_parts = true; + builder.append(present_max_parts); + if (present_max_parts) + builder.append(max_parts); + + return builder.toHashCode(); + } + + public int compareTo(get_part_specs_by_filter_args other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + get_part_specs_by_filter_args typedOther = (get_part_specs_by_filter_args)other; + + lastComparison = Boolean.valueOf(isSetDb_name()).compareTo(typedOther.isSetDb_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetDb_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.db_name, typedOther.db_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetTbl_name()).compareTo(typedOther.isSetTbl_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetTbl_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tbl_name, typedOther.tbl_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetFilter()).compareTo(typedOther.isSetFilter()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetFilter()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.filter, typedOther.filter); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetMax_parts()).compareTo(typedOther.isSetMax_parts()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetMax_parts()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.max_parts, typedOther.max_parts); + 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("get_part_specs_by_filter_args("); + boolean first = true; + + sb.append("db_name:"); + if (this.db_name == null) { + sb.append("null"); + } else { + sb.append(this.db_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("tbl_name:"); + if (this.tbl_name == null) { + sb.append("null"); + } else { + sb.append(this.tbl_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("filter:"); + if (this.filter == null) { + sb.append("null"); + } else { + sb.append(this.filter); + } + first = false; + if (!first) sb.append(", "); + sb.append("max_parts:"); + sb.append(this.max_parts); + 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 { + // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor. + __isset_bitfield = 0; + 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 get_part_specs_by_filter_argsStandardSchemeFactory implements SchemeFactory { + public get_part_specs_by_filter_argsStandardScheme getScheme() { + return new get_part_specs_by_filter_argsStandardScheme(); + } + } + + private static class get_part_specs_by_filter_argsStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, get_part_specs_by_filter_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: // DB_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.db_name = iprot.readString(); + struct.setDb_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // TBL_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.tbl_name = iprot.readString(); + struct.setTbl_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // FILTER + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.filter = iprot.readString(); + struct.setFilterIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // MAX_PARTS + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.max_parts = iprot.readI32(); + struct.setMax_partsIsSet(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, get_part_specs_by_filter_args struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.db_name != null) { + oprot.writeFieldBegin(DB_NAME_FIELD_DESC); + oprot.writeString(struct.db_name); + oprot.writeFieldEnd(); + } + if (struct.tbl_name != null) { + oprot.writeFieldBegin(TBL_NAME_FIELD_DESC); + oprot.writeString(struct.tbl_name); + oprot.writeFieldEnd(); + } + if (struct.filter != null) { + oprot.writeFieldBegin(FILTER_FIELD_DESC); + oprot.writeString(struct.filter); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(MAX_PARTS_FIELD_DESC); + oprot.writeI32(struct.max_parts); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class get_part_specs_by_filter_argsTupleSchemeFactory implements SchemeFactory { + public get_part_specs_by_filter_argsTupleScheme getScheme() { + return new get_part_specs_by_filter_argsTupleScheme(); + } + } + + private static class get_part_specs_by_filter_argsTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, get_part_specs_by_filter_args struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetDb_name()) { + optionals.set(0); + } + if (struct.isSetTbl_name()) { + optionals.set(1); + } + if (struct.isSetFilter()) { + optionals.set(2); + } + if (struct.isSetMax_parts()) { + optionals.set(3); + } + oprot.writeBitSet(optionals, 4); + if (struct.isSetDb_name()) { + oprot.writeString(struct.db_name); + } + if (struct.isSetTbl_name()) { + oprot.writeString(struct.tbl_name); + } + if (struct.isSetFilter()) { + oprot.writeString(struct.filter); + } + if (struct.isSetMax_parts()) { + oprot.writeI32(struct.max_parts); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, get_part_specs_by_filter_args struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(4); + if (incoming.get(0)) { + struct.db_name = iprot.readString(); + struct.setDb_nameIsSet(true); + } + if (incoming.get(1)) { + struct.tbl_name = iprot.readString(); + struct.setTbl_nameIsSet(true); + } + if (incoming.get(2)) { + struct.filter = iprot.readString(); + struct.setFilterIsSet(true); + } + if (incoming.get(3)) { + struct.max_parts = iprot.readI32(); + struct.setMax_partsIsSet(true); + } + } + } + + } + + public static class get_part_specs_by_filter_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("get_part_specs_by_filter_result"); + + private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (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 Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new get_part_specs_by_filter_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new get_part_specs_by_filter_resultTupleSchemeFactory()); + } + + private List success; // required + private MetaException o1; // required + private NoSuchObjectException o2; // 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"); + + 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; + 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.ListMetaData(org.apache.thrift.protocol.TType.LIST, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionSpec.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))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(get_part_specs_by_filter_result.class, metaDataMap); + } + + public get_part_specs_by_filter_result() { + } + + public get_part_specs_by_filter_result( + List success, + MetaException o1, + NoSuchObjectException o2) + { + this(); + this.success = success; + this.o1 = o1; + this.o2 = o2; + } + + /** + * Performs a deep copy on other. + */ + public get_part_specs_by_filter_result(get_part_specs_by_filter_result other) { + if (other.isSetSuccess()) { + List __this__success = new ArrayList(); + for (PartitionSpec other_element : other.success) { + __this__success.add(new PartitionSpec(other_element)); + } + this.success = __this__success; + } + if (other.isSetO1()) { + this.o1 = new MetaException(other.o1); + } + if (other.isSetO2()) { + this.o2 = new NoSuchObjectException(other.o2); + } + } + + public get_part_specs_by_filter_result deepCopy() { + return new get_part_specs_by_filter_result(this); + } + + @Override + public void clear() { + this.success = null; + this.o1 = null; + this.o2 = null; + } + + public int getSuccessSize() { + return (this.success == null) ? 0 : this.success.size(); + } + + public java.util.Iterator getSuccessIterator() { + return (this.success == null) ? null : this.success.iterator(); + } + + public void addToSuccess(PartitionSpec elem) { + if (this.success == null) { + this.success = new ArrayList(); + } + this.success.add(elem); + } + + public List getSuccess() { + return this.success; + } + + public void setSuccess(List 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 void setFieldValue(_Fields field, Object value) { + switch (field) { + case SUCCESS: + if (value == null) { + unsetSuccess(); + } else { + setSuccess((List)value); + } + break; + + case O1: + if (value == null) { + unsetO1(); + } else { + setO1((MetaException)value); + } + break; + + case O2: + if (value == null) { + unsetO2(); + } else { + setO2((NoSuchObjectException)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case SUCCESS: + return getSuccess(); + + case O1: + return getO1(); + + case O2: + return getO2(); + + } + 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(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof get_part_specs_by_filter_result) + return this.equals((get_part_specs_by_filter_result)that); + return false; + } + + public boolean equals(get_part_specs_by_filter_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; + } + + 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); + + return builder.toHashCode(); + } + + public int compareTo(get_part_specs_by_filter_result other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + get_part_specs_by_filter_result typedOther = (get_part_specs_by_filter_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; + } + } + 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("get_part_specs_by_filter_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; + 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 get_part_specs_by_filter_resultStandardSchemeFactory implements SchemeFactory { + public get_part_specs_by_filter_resultStandardScheme getScheme() { + return new get_part_specs_by_filter_resultStandardScheme(); + } + } + + private static class get_part_specs_by_filter_resultStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, get_part_specs_by_filter_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.LIST) { + { + org.apache.thrift.protocol.TList _list752 = iprot.readListBegin(); + struct.success = new ArrayList(_list752.size); + for (int _i753 = 0; _i753 < _list752.size; ++_i753) + { + PartitionSpec _elem754; // required + _elem754 = new PartitionSpec(); + _elem754.read(iprot); + struct.success.add(_elem754); + } + iprot.readListEnd(); + } + 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; + 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, get_part_specs_by_filter_result struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.success != null) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + { + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); + for (PartitionSpec _iter755 : struct.success) + { + _iter755.write(oprot); + } + oprot.writeListEnd(); + } + 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(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class get_part_specs_by_filter_resultTupleSchemeFactory implements SchemeFactory { + public get_part_specs_by_filter_resultTupleScheme getScheme() { + return new get_part_specs_by_filter_resultTupleScheme(); + } + } + + private static class get_part_specs_by_filter_resultTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, get_part_specs_by_filter_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); + } + oprot.writeBitSet(optionals, 3); + if (struct.isSetSuccess()) { + { + oprot.writeI32(struct.success.size()); + for (PartitionSpec _iter756 : struct.success) + { + _iter756.write(oprot); + } + } + } + if (struct.isSetO1()) { + struct.o1.write(oprot); + } + if (struct.isSetO2()) { + struct.o2.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, get_part_specs_by_filter_result struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(3); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TList _list757 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list757.size); + for (int _i758 = 0; _i758 < _list757.size; ++_i758) + { + PartitionSpec _elem759; // required + _elem759 = new PartitionSpec(); + _elem759.read(iprot); + struct.success.add(_elem759); + } + } + 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); + } + } + } + + } + public static class get_partitions_by_expr_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_partitions_by_expr_args"); @@ -68244,13 +72118,13 @@ case 3: // NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list702 = iprot.readListBegin(); - struct.names = new ArrayList(_list702.size); - for (int _i703 = 0; _i703 < _list702.size; ++_i703) + org.apache.thrift.protocol.TList _list760 = iprot.readListBegin(); + struct.names = new ArrayList(_list760.size); + for (int _i761 = 0; _i761 < _list760.size; ++_i761) { - String _elem704; // required - _elem704 = iprot.readString(); - struct.names.add(_elem704); + String _elem762; // required + _elem762 = iprot.readString(); + struct.names.add(_elem762); } iprot.readListEnd(); } @@ -68286,9 +72160,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 _iter705 : struct.names) + for (String _iter763 : struct.names) { - oprot.writeString(_iter705); + oprot.writeString(_iter763); } oprot.writeListEnd(); } @@ -68331,9 +72205,9 @@ if (struct.isSetNames()) { { oprot.writeI32(struct.names.size()); - for (String _iter706 : struct.names) + for (String _iter764 : struct.names) { - oprot.writeString(_iter706); + oprot.writeString(_iter764); } } } @@ -68353,13 +72227,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list707 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.names = new ArrayList(_list707.size); - for (int _i708 = 0; _i708 < _list707.size; ++_i708) + org.apache.thrift.protocol.TList _list765 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.names = new ArrayList(_list765.size); + for (int _i766 = 0; _i766 < _list765.size; ++_i766) { - String _elem709; // required - _elem709 = iprot.readString(); - struct.names.add(_elem709); + String _elem767; // required + _elem767 = iprot.readString(); + struct.names.add(_elem767); } } struct.setNamesIsSet(true); @@ -68846,14 +72720,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list710 = iprot.readListBegin(); - struct.success = new ArrayList(_list710.size); - for (int _i711 = 0; _i711 < _list710.size; ++_i711) + org.apache.thrift.protocol.TList _list768 = iprot.readListBegin(); + struct.success = new ArrayList(_list768.size); + for (int _i769 = 0; _i769 < _list768.size; ++_i769) { - Partition _elem712; // required - _elem712 = new Partition(); - _elem712.read(iprot); - struct.success.add(_elem712); + Partition _elem770; // required + _elem770 = new Partition(); + _elem770.read(iprot); + struct.success.add(_elem770); } iprot.readListEnd(); } @@ -68897,9 +72771,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 _iter713 : struct.success) + for (Partition _iter771 : struct.success) { - _iter713.write(oprot); + _iter771.write(oprot); } oprot.writeListEnd(); } @@ -68946,9 +72820,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Partition _iter714 : struct.success) + for (Partition _iter772 : struct.success) { - _iter714.write(oprot); + _iter772.write(oprot); } } } @@ -68966,14 +72840,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list715 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list715.size); - for (int _i716 = 0; _i716 < _list715.size; ++_i716) + org.apache.thrift.protocol.TList _list773 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list773.size); + for (int _i774 = 0; _i774 < _list773.size; ++_i774) { - Partition _elem717; // required - _elem717 = new Partition(); - _elem717.read(iprot); - struct.success.add(_elem717); + Partition _elem775; // required + _elem775 = new Partition(); + _elem775.read(iprot); + struct.success.add(_elem775); } } struct.setSuccessIsSet(true); @@ -70523,14 +74397,14 @@ case 3: // NEW_PARTS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list718 = iprot.readListBegin(); - struct.new_parts = new ArrayList(_list718.size); - for (int _i719 = 0; _i719 < _list718.size; ++_i719) + org.apache.thrift.protocol.TList _list776 = iprot.readListBegin(); + struct.new_parts = new ArrayList(_list776.size); + for (int _i777 = 0; _i777 < _list776.size; ++_i777) { - Partition _elem720; // required - _elem720 = new Partition(); - _elem720.read(iprot); - struct.new_parts.add(_elem720); + Partition _elem778; // required + _elem778 = new Partition(); + _elem778.read(iprot); + struct.new_parts.add(_elem778); } iprot.readListEnd(); } @@ -70566,9 +74440,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 _iter721 : struct.new_parts) + for (Partition _iter779 : struct.new_parts) { - _iter721.write(oprot); + _iter779.write(oprot); } oprot.writeListEnd(); } @@ -70611,9 +74485,9 @@ if (struct.isSetNew_parts()) { { oprot.writeI32(struct.new_parts.size()); - for (Partition _iter722 : struct.new_parts) + for (Partition _iter780 : struct.new_parts) { - _iter722.write(oprot); + _iter780.write(oprot); } } } @@ -70633,14 +74507,14 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list723 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.new_parts = new ArrayList(_list723.size); - for (int _i724 = 0; _i724 < _list723.size; ++_i724) + org.apache.thrift.protocol.TList _list781 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.new_parts = new ArrayList(_list781.size); + for (int _i782 = 0; _i782 < _list781.size; ++_i782) { - Partition _elem725; // required - _elem725 = new Partition(); - _elem725.read(iprot); - struct.new_parts.add(_elem725); + Partition _elem783; // required + _elem783 = new Partition(); + _elem783.read(iprot); + struct.new_parts.add(_elem783); } } struct.setNew_partsIsSet(true); @@ -72839,13 +76713,13 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list726 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list726.size); - for (int _i727 = 0; _i727 < _list726.size; ++_i727) + org.apache.thrift.protocol.TList _list784 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list784.size); + for (int _i785 = 0; _i785 < _list784.size; ++_i785) { - String _elem728; // required - _elem728 = iprot.readString(); - struct.part_vals.add(_elem728); + String _elem786; // required + _elem786 = iprot.readString(); + struct.part_vals.add(_elem786); } iprot.readListEnd(); } @@ -72890,9 +76764,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 _iter729 : struct.part_vals) + for (String _iter787 : struct.part_vals) { - oprot.writeString(_iter729); + oprot.writeString(_iter787); } oprot.writeListEnd(); } @@ -72943,9 +76817,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter730 : struct.part_vals) + for (String _iter788 : struct.part_vals) { - oprot.writeString(_iter730); + oprot.writeString(_iter788); } } } @@ -72968,13 +76842,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list731 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list731.size); - for (int _i732 = 0; _i732 < _list731.size; ++_i732) + org.apache.thrift.protocol.TList _list789 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list789.size); + for (int _i790 = 0; _i790 < _list789.size; ++_i790) { - String _elem733; // required - _elem733 = iprot.readString(); - struct.part_vals.add(_elem733); + String _elem791; // required + _elem791 = iprot.readString(); + struct.part_vals.add(_elem791); } } struct.setPart_valsIsSet(true); @@ -73851,13 +77725,13 @@ case 1: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list734 = iprot.readListBegin(); - struct.part_vals = new ArrayList(_list734.size); - for (int _i735 = 0; _i735 < _list734.size; ++_i735) + org.apache.thrift.protocol.TList _list792 = iprot.readListBegin(); + struct.part_vals = new ArrayList(_list792.size); + for (int _i793 = 0; _i793 < _list792.size; ++_i793) { - String _elem736; // required - _elem736 = iprot.readString(); - struct.part_vals.add(_elem736); + String _elem794; // required + _elem794 = iprot.readString(); + struct.part_vals.add(_elem794); } iprot.readListEnd(); } @@ -73891,9 +77765,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 _iter737 : struct.part_vals) + for (String _iter795 : struct.part_vals) { - oprot.writeString(_iter737); + oprot.writeString(_iter795); } oprot.writeListEnd(); } @@ -73930,9 +77804,9 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (String _iter738 : struct.part_vals) + for (String _iter796 : struct.part_vals) { - oprot.writeString(_iter738); + oprot.writeString(_iter796); } } } @@ -73947,13 +77821,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list739 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.part_vals = new ArrayList(_list739.size); - for (int _i740 = 0; _i740 < _list739.size; ++_i740) + org.apache.thrift.protocol.TList _list797 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.part_vals = new ArrayList(_list797.size); + for (int _i798 = 0; _i798 < _list797.size; ++_i798) { - String _elem741; // required - _elem741 = iprot.readString(); - struct.part_vals.add(_elem741); + String _elem799; // required + _elem799 = iprot.readString(); + struct.part_vals.add(_elem799); } } struct.setPart_valsIsSet(true); @@ -76111,13 +79985,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list742 = iprot.readListBegin(); - struct.success = new ArrayList(_list742.size); - for (int _i743 = 0; _i743 < _list742.size; ++_i743) + org.apache.thrift.protocol.TList _list800 = iprot.readListBegin(); + struct.success = new ArrayList(_list800.size); + for (int _i801 = 0; _i801 < _list800.size; ++_i801) { - String _elem744; // required - _elem744 = iprot.readString(); - struct.success.add(_elem744); + String _elem802; // required + _elem802 = iprot.readString(); + struct.success.add(_elem802); } iprot.readListEnd(); } @@ -76152,9 +80026,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 _iter745 : struct.success) + for (String _iter803 : struct.success) { - oprot.writeString(_iter745); + oprot.writeString(_iter803); } oprot.writeListEnd(); } @@ -76193,9 +80067,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter746 : struct.success) + for (String _iter804 : struct.success) { - oprot.writeString(_iter746); + oprot.writeString(_iter804); } } } @@ -76210,13 +80084,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list747 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list747.size); - for (int _i748 = 0; _i748 < _list747.size; ++_i748) + org.apache.thrift.protocol.TList _list805 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list805.size); + for (int _i806 = 0; _i806 < _list805.size; ++_i806) { - String _elem749; // required - _elem749 = iprot.readString(); - struct.success.add(_elem749); + String _elem807; // required + _elem807 = iprot.readString(); + struct.success.add(_elem807); } } struct.setSuccessIsSet(true); @@ -76990,15 +80864,15 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map750 = iprot.readMapBegin(); - struct.success = new HashMap(2*_map750.size); - for (int _i751 = 0; _i751 < _map750.size; ++_i751) + org.apache.thrift.protocol.TMap _map808 = iprot.readMapBegin(); + struct.success = new HashMap(2*_map808.size); + for (int _i809 = 0; _i809 < _map808.size; ++_i809) { - String _key752; // required - String _val753; // required - _key752 = iprot.readString(); - _val753 = iprot.readString(); - struct.success.put(_key752, _val753); + String _key810; // required + String _val811; // required + _key810 = iprot.readString(); + _val811 = iprot.readString(); + struct.success.put(_key810, _val811); } iprot.readMapEnd(); } @@ -77033,10 +80907,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 _iter754 : struct.success.entrySet()) + for (Map.Entry _iter812 : struct.success.entrySet()) { - oprot.writeString(_iter754.getKey()); - oprot.writeString(_iter754.getValue()); + oprot.writeString(_iter812.getKey()); + oprot.writeString(_iter812.getValue()); } oprot.writeMapEnd(); } @@ -77075,10 +80949,10 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Map.Entry _iter755 : struct.success.entrySet()) + for (Map.Entry _iter813 : struct.success.entrySet()) { - oprot.writeString(_iter755.getKey()); - oprot.writeString(_iter755.getValue()); + oprot.writeString(_iter813.getKey()); + oprot.writeString(_iter813.getValue()); } } } @@ -77093,15 +80967,15 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TMap _map756 = 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*_map756.size); - for (int _i757 = 0; _i757 < _map756.size; ++_i757) + org.apache.thrift.protocol.TMap _map814 = 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*_map814.size); + for (int _i815 = 0; _i815 < _map814.size; ++_i815) { - String _key758; // required - String _val759; // required - _key758 = iprot.readString(); - _val759 = iprot.readString(); - struct.success.put(_key758, _val759); + String _key816; // required + String _val817; // required + _key816 = iprot.readString(); + _val817 = iprot.readString(); + struct.success.put(_key816, _val817); } } struct.setSuccessIsSet(true); @@ -77707,15 +81581,15 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map760 = iprot.readMapBegin(); - struct.part_vals = new HashMap(2*_map760.size); - for (int _i761 = 0; _i761 < _map760.size; ++_i761) + org.apache.thrift.protocol.TMap _map818 = iprot.readMapBegin(); + struct.part_vals = new HashMap(2*_map818.size); + for (int _i819 = 0; _i819 < _map818.size; ++_i819) { - String _key762; // required - String _val763; // required - _key762 = iprot.readString(); - _val763 = iprot.readString(); - struct.part_vals.put(_key762, _val763); + String _key820; // required + String _val821; // required + _key820 = iprot.readString(); + _val821 = iprot.readString(); + struct.part_vals.put(_key820, _val821); } iprot.readMapEnd(); } @@ -77759,10 +81633,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 _iter764 : struct.part_vals.entrySet()) + for (Map.Entry _iter822 : struct.part_vals.entrySet()) { - oprot.writeString(_iter764.getKey()); - oprot.writeString(_iter764.getValue()); + oprot.writeString(_iter822.getKey()); + oprot.writeString(_iter822.getValue()); } oprot.writeMapEnd(); } @@ -77813,10 +81687,10 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (Map.Entry _iter765 : struct.part_vals.entrySet()) + for (Map.Entry _iter823 : struct.part_vals.entrySet()) { - oprot.writeString(_iter765.getKey()); - oprot.writeString(_iter765.getValue()); + oprot.writeString(_iter823.getKey()); + oprot.writeString(_iter823.getValue()); } } } @@ -77839,15 +81713,15 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TMap _map766 = 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*_map766.size); - for (int _i767 = 0; _i767 < _map766.size; ++_i767) + org.apache.thrift.protocol.TMap _map824 = 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*_map824.size); + for (int _i825 = 0; _i825 < _map824.size; ++_i825) { - String _key768; // required - String _val769; // required - _key768 = iprot.readString(); - _val769 = iprot.readString(); - struct.part_vals.put(_key768, _val769); + String _key826; // required + String _val827; // required + _key826 = iprot.readString(); + _val827 = iprot.readString(); + struct.part_vals.put(_key826, _val827); } } struct.setPart_valsIsSet(true); @@ -79342,15 +83216,15 @@ case 3: // PART_VALS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map770 = iprot.readMapBegin(); - struct.part_vals = new HashMap(2*_map770.size); - for (int _i771 = 0; _i771 < _map770.size; ++_i771) + org.apache.thrift.protocol.TMap _map828 = iprot.readMapBegin(); + struct.part_vals = new HashMap(2*_map828.size); + for (int _i829 = 0; _i829 < _map828.size; ++_i829) { - String _key772; // required - String _val773; // required - _key772 = iprot.readString(); - _val773 = iprot.readString(); - struct.part_vals.put(_key772, _val773); + String _key830; // required + String _val831; // required + _key830 = iprot.readString(); + _val831 = iprot.readString(); + struct.part_vals.put(_key830, _val831); } iprot.readMapEnd(); } @@ -79394,10 +83268,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 _iter774 : struct.part_vals.entrySet()) + for (Map.Entry _iter832 : struct.part_vals.entrySet()) { - oprot.writeString(_iter774.getKey()); - oprot.writeString(_iter774.getValue()); + oprot.writeString(_iter832.getKey()); + oprot.writeString(_iter832.getValue()); } oprot.writeMapEnd(); } @@ -79448,10 +83322,10 @@ if (struct.isSetPart_vals()) { { oprot.writeI32(struct.part_vals.size()); - for (Map.Entry _iter775 : struct.part_vals.entrySet()) + for (Map.Entry _iter833 : struct.part_vals.entrySet()) { - oprot.writeString(_iter775.getKey()); - oprot.writeString(_iter775.getValue()); + oprot.writeString(_iter833.getKey()); + oprot.writeString(_iter833.getValue()); } } } @@ -79474,15 +83348,15 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TMap _map776 = 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*_map776.size); - for (int _i777 = 0; _i777 < _map776.size; ++_i777) + org.apache.thrift.protocol.TMap _map834 = 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*_map834.size); + for (int _i835 = 0; _i835 < _map834.size; ++_i835) { - String _key778; // required - String _val779; // required - _key778 = iprot.readString(); - _val779 = iprot.readString(); - struct.part_vals.put(_key778, _val779); + String _key836; // required + String _val837; // required + _key836 = iprot.readString(); + _val837 = iprot.readString(); + struct.part_vals.put(_key836, _val837); } } struct.setPart_valsIsSet(true); @@ -86206,14 +90080,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list780 = iprot.readListBegin(); - struct.success = new ArrayList(_list780.size); - for (int _i781 = 0; _i781 < _list780.size; ++_i781) + org.apache.thrift.protocol.TList _list838 = iprot.readListBegin(); + struct.success = new ArrayList(_list838.size); + for (int _i839 = 0; _i839 < _list838.size; ++_i839) { - Index _elem782; // required - _elem782 = new Index(); - _elem782.read(iprot); - struct.success.add(_elem782); + Index _elem840; // required + _elem840 = new Index(); + _elem840.read(iprot); + struct.success.add(_elem840); } iprot.readListEnd(); } @@ -86257,9 +90131,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 _iter783 : struct.success) + for (Index _iter841 : struct.success) { - _iter783.write(oprot); + _iter841.write(oprot); } oprot.writeListEnd(); } @@ -86306,9 +90180,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Index _iter784 : struct.success) + for (Index _iter842 : struct.success) { - _iter784.write(oprot); + _iter842.write(oprot); } } } @@ -86326,14 +90200,14 @@ BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list785 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list785.size); - for (int _i786 = 0; _i786 < _list785.size; ++_i786) + org.apache.thrift.protocol.TList _list843 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list843.size); + for (int _i844 = 0; _i844 < _list843.size; ++_i844) { - Index _elem787; // required - _elem787 = new Index(); - _elem787.read(iprot); - struct.success.add(_elem787); + Index _elem845; // required + _elem845 = new Index(); + _elem845.read(iprot); + struct.success.add(_elem845); } } struct.setSuccessIsSet(true); @@ -87315,13 +91189,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list788 = iprot.readListBegin(); - struct.success = new ArrayList(_list788.size); - for (int _i789 = 0; _i789 < _list788.size; ++_i789) + org.apache.thrift.protocol.TList _list846 = iprot.readListBegin(); + struct.success = new ArrayList(_list846.size); + for (int _i847 = 0; _i847 < _list846.size; ++_i847) { - String _elem790; // required - _elem790 = iprot.readString(); - struct.success.add(_elem790); + String _elem848; // required + _elem848 = iprot.readString(); + struct.success.add(_elem848); } iprot.readListEnd(); } @@ -87356,9 +91230,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 _iter791 : struct.success) + for (String _iter849 : struct.success) { - oprot.writeString(_iter791); + oprot.writeString(_iter849); } oprot.writeListEnd(); } @@ -87397,9 +91271,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter792 : struct.success) + for (String _iter850 : struct.success) { - oprot.writeString(_iter792); + oprot.writeString(_iter850); } } } @@ -87414,13 +91288,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list793 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list793.size); - for (int _i794 = 0; _i794 < _list793.size; ++_i794) + org.apache.thrift.protocol.TList _list851 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list851.size); + for (int _i852 = 0; _i852 < _list851.size; ++_i852) { - String _elem795; // required - _elem795 = iprot.readString(); - struct.success.add(_elem795); + String _elem853; // required + _elem853 = iprot.readString(); + struct.success.add(_elem853); } } struct.setSuccessIsSet(true); @@ -102013,13 +105887,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list796 = iprot.readListBegin(); - struct.success = new ArrayList(_list796.size); - for (int _i797 = 0; _i797 < _list796.size; ++_i797) + org.apache.thrift.protocol.TList _list854 = iprot.readListBegin(); + struct.success = new ArrayList(_list854.size); + for (int _i855 = 0; _i855 < _list854.size; ++_i855) { - String _elem798; // required - _elem798 = iprot.readString(); - struct.success.add(_elem798); + String _elem856; // required + _elem856 = iprot.readString(); + struct.success.add(_elem856); } iprot.readListEnd(); } @@ -102054,9 +105928,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 _iter799 : struct.success) + for (String _iter857 : struct.success) { - oprot.writeString(_iter799); + oprot.writeString(_iter857); } oprot.writeListEnd(); } @@ -102095,9 +105969,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter800 : struct.success) + for (String _iter858 : struct.success) { - oprot.writeString(_iter800); + oprot.writeString(_iter858); } } } @@ -102112,13 +105986,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list801 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list801.size); - for (int _i802 = 0; _i802 < _list801.size; ++_i802) + org.apache.thrift.protocol.TList _list859 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list859.size); + for (int _i860 = 0; _i860 < _list859.size; ++_i860) { - String _elem803; // required - _elem803 = iprot.readString(); - struct.success.add(_elem803); + String _elem861; // required + _elem861 = iprot.readString(); + struct.success.add(_elem861); } } struct.setSuccessIsSet(true); @@ -105461,13 +109335,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list804 = iprot.readListBegin(); - struct.success = new ArrayList(_list804.size); - for (int _i805 = 0; _i805 < _list804.size; ++_i805) + org.apache.thrift.protocol.TList _list862 = iprot.readListBegin(); + struct.success = new ArrayList(_list862.size); + for (int _i863 = 0; _i863 < _list862.size; ++_i863) { - String _elem806; // required - _elem806 = iprot.readString(); - struct.success.add(_elem806); + String _elem864; // required + _elem864 = iprot.readString(); + struct.success.add(_elem864); } iprot.readListEnd(); } @@ -105502,9 +109376,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 _iter807 : struct.success) + for (String _iter865 : struct.success) { - oprot.writeString(_iter807); + oprot.writeString(_iter865); } oprot.writeListEnd(); } @@ -105543,9 +109417,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter808 : struct.success) + for (String _iter866 : struct.success) { - oprot.writeString(_iter808); + oprot.writeString(_iter866); } } } @@ -105560,13 +109434,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list809 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list809.size); - for (int _i810 = 0; _i810 < _list809.size; ++_i810) + org.apache.thrift.protocol.TList _list867 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list867.size); + for (int _i868 = 0; _i868 < _list867.size; ++_i868) { - String _elem811; // required - _elem811 = iprot.readString(); - struct.success.add(_elem811); + String _elem869; // required + _elem869 = iprot.readString(); + struct.success.add(_elem869); } } struct.setSuccessIsSet(true); @@ -108857,14 +112731,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list812 = iprot.readListBegin(); - struct.success = new ArrayList(_list812.size); - for (int _i813 = 0; _i813 < _list812.size; ++_i813) + org.apache.thrift.protocol.TList _list870 = iprot.readListBegin(); + struct.success = new ArrayList(_list870.size); + for (int _i871 = 0; _i871 < _list870.size; ++_i871) { - Role _elem814; // required - _elem814 = new Role(); - _elem814.read(iprot); - struct.success.add(_elem814); + Role _elem872; // required + _elem872 = new Role(); + _elem872.read(iprot); + struct.success.add(_elem872); } iprot.readListEnd(); } @@ -108899,9 +112773,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 _iter815 : struct.success) + for (Role _iter873 : struct.success) { - _iter815.write(oprot); + _iter873.write(oprot); } oprot.writeListEnd(); } @@ -108940,9 +112814,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (Role _iter816 : struct.success) + for (Role _iter874 : struct.success) { - _iter816.write(oprot); + _iter874.write(oprot); } } } @@ -108957,14 +112831,14 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list817 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list817.size); - for (int _i818 = 0; _i818 < _list817.size; ++_i818) + org.apache.thrift.protocol.TList _list875 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list875.size); + for (int _i876 = 0; _i876 < _list875.size; ++_i876) { - Role _elem819; // required - _elem819 = new Role(); - _elem819.read(iprot); - struct.success.add(_elem819); + Role _elem877; // required + _elem877 = new Role(); + _elem877.read(iprot); + struct.success.add(_elem877); } } struct.setSuccessIsSet(true); @@ -111972,13 +115846,13 @@ case 3: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list820 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list820.size); - for (int _i821 = 0; _i821 < _list820.size; ++_i821) + org.apache.thrift.protocol.TList _list878 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list878.size); + for (int _i879 = 0; _i879 < _list878.size; ++_i879) { - String _elem822; // required - _elem822 = iprot.readString(); - struct.group_names.add(_elem822); + String _elem880; // required + _elem880 = iprot.readString(); + struct.group_names.add(_elem880); } iprot.readListEnd(); } @@ -112014,9 +115888,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 _iter823 : struct.group_names) + for (String _iter881 : struct.group_names) { - oprot.writeString(_iter823); + oprot.writeString(_iter881); } oprot.writeListEnd(); } @@ -112059,9 +115933,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter824 : struct.group_names) + for (String _iter882 : struct.group_names) { - oprot.writeString(_iter824); + oprot.writeString(_iter882); } } } @@ -112082,13 +115956,13 @@ } if (incoming.get(2)) { { - org.apache.thrift.protocol.TList _list825 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list825.size); - for (int _i826 = 0; _i826 < _list825.size; ++_i826) + org.apache.thrift.protocol.TList _list883 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list883.size); + for (int _i884 = 0; _i884 < _list883.size; ++_i884) { - String _elem827; // required - _elem827 = iprot.readString(); - struct.group_names.add(_elem827); + String _elem885; // required + _elem885 = iprot.readString(); + struct.group_names.add(_elem885); } } struct.setGroup_namesIsSet(true); @@ -113546,14 +117420,14 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list828 = iprot.readListBegin(); - struct.success = new ArrayList(_list828.size); - for (int _i829 = 0; _i829 < _list828.size; ++_i829) + org.apache.thrift.protocol.TList _list886 = iprot.readListBegin(); + struct.success = new ArrayList(_list886.size); + for (int _i887 = 0; _i887 < _list886.size; ++_i887) { - HiveObjectPrivilege _elem830; // required - _elem830 = new HiveObjectPrivilege(); - _elem830.read(iprot); - struct.success.add(_elem830); + HiveObjectPrivilege _elem888; // required + _elem888 = new HiveObjectPrivilege(); + _elem888.read(iprot); + struct.success.add(_elem888); } iprot.readListEnd(); } @@ -113588,9 +117462,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 _iter831 : struct.success) + for (HiveObjectPrivilege _iter889 : struct.success) { - _iter831.write(oprot); + _iter889.write(oprot); } oprot.writeListEnd(); } @@ -113629,9 +117503,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (HiveObjectPrivilege _iter832 : struct.success) + for (HiveObjectPrivilege _iter890 : struct.success) { - _iter832.write(oprot); + _iter890.write(oprot); } } } @@ -113646,14 +117520,14 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list833 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list833.size); - for (int _i834 = 0; _i834 < _list833.size; ++_i834) + org.apache.thrift.protocol.TList _list891 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list891.size); + for (int _i892 = 0; _i892 < _list891.size; ++_i892) { - HiveObjectPrivilege _elem835; // required - _elem835 = new HiveObjectPrivilege(); - _elem835.read(iprot); - struct.success.add(_elem835); + HiveObjectPrivilege _elem893; // required + _elem893 = new HiveObjectPrivilege(); + _elem893.read(iprot); + struct.success.add(_elem893); } } struct.setSuccessIsSet(true); @@ -116558,13 +120432,13 @@ case 2: // GROUP_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list836 = iprot.readListBegin(); - struct.group_names = new ArrayList(_list836.size); - for (int _i837 = 0; _i837 < _list836.size; ++_i837) + org.apache.thrift.protocol.TList _list894 = iprot.readListBegin(); + struct.group_names = new ArrayList(_list894.size); + for (int _i895 = 0; _i895 < _list894.size; ++_i895) { - String _elem838; // required - _elem838 = iprot.readString(); - struct.group_names.add(_elem838); + String _elem896; // required + _elem896 = iprot.readString(); + struct.group_names.add(_elem896); } iprot.readListEnd(); } @@ -116595,9 +120469,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 _iter839 : struct.group_names) + for (String _iter897 : struct.group_names) { - oprot.writeString(_iter839); + oprot.writeString(_iter897); } oprot.writeListEnd(); } @@ -116634,9 +120508,9 @@ if (struct.isSetGroup_names()) { { oprot.writeI32(struct.group_names.size()); - for (String _iter840 : struct.group_names) + for (String _iter898 : struct.group_names) { - oprot.writeString(_iter840); + oprot.writeString(_iter898); } } } @@ -116652,13 +120526,13 @@ } if (incoming.get(1)) { { - org.apache.thrift.protocol.TList _list841 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.group_names = new ArrayList(_list841.size); - for (int _i842 = 0; _i842 < _list841.size; ++_i842) + org.apache.thrift.protocol.TList _list899 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.group_names = new ArrayList(_list899.size); + for (int _i900 = 0; _i900 < _list899.size; ++_i900) { - String _elem843; // required - _elem843 = iprot.readString(); - struct.group_names.add(_elem843); + String _elem901; // required + _elem901 = iprot.readString(); + struct.group_names.add(_elem901); } } struct.setGroup_namesIsSet(true); @@ -117064,13 +120938,13 @@ case 0: // SUCCESS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list844 = iprot.readListBegin(); - struct.success = new ArrayList(_list844.size); - for (int _i845 = 0; _i845 < _list844.size; ++_i845) + org.apache.thrift.protocol.TList _list902 = iprot.readListBegin(); + struct.success = new ArrayList(_list902.size); + for (int _i903 = 0; _i903 < _list902.size; ++_i903) { - String _elem846; // required - _elem846 = iprot.readString(); - struct.success.add(_elem846); + String _elem904; // required + _elem904 = iprot.readString(); + struct.success.add(_elem904); } iprot.readListEnd(); } @@ -117105,9 +120979,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 _iter847 : struct.success) + for (String _iter905 : struct.success) { - oprot.writeString(_iter847); + oprot.writeString(_iter905); } oprot.writeListEnd(); } @@ -117146,9 +121020,9 @@ if (struct.isSetSuccess()) { { oprot.writeI32(struct.success.size()); - for (String _iter848 : struct.success) + for (String _iter906 : struct.success) { - oprot.writeString(_iter848); + oprot.writeString(_iter906); } } } @@ -117163,13 +121037,13 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list849 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.success = new ArrayList(_list849.size); - for (int _i850 = 0; _i850 < _list849.size; ++_i850) + org.apache.thrift.protocol.TList _list907 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.success = new ArrayList(_list907.size); + for (int _i908 = 0; _i908 < _list907.size; ++_i908) { - String _elem851; // required - _elem851 = iprot.readString(); - struct.success.add(_elem851); + String _elem909; // required + _elem909 = iprot.readString(); + struct.success.add(_elem909); } } struct.setSuccessIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Schema.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Schema.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Schema.java (working copy) @@ -452,14 +452,14 @@ case 1: // FIELD_SCHEMAS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list252 = iprot.readListBegin(); - struct.fieldSchemas = new ArrayList(_list252.size); - for (int _i253 = 0; _i253 < _list252.size; ++_i253) + org.apache.thrift.protocol.TList _list286 = iprot.readListBegin(); + struct.fieldSchemas = new ArrayList(_list286.size); + for (int _i287 = 0; _i287 < _list286.size; ++_i287) { - FieldSchema _elem254; // required - _elem254 = new FieldSchema(); - _elem254.read(iprot); - struct.fieldSchemas.add(_elem254); + FieldSchema _elem288; // required + _elem288 = new FieldSchema(); + _elem288.read(iprot); + struct.fieldSchemas.add(_elem288); } iprot.readListEnd(); } @@ -471,15 +471,15 @@ case 2: // PROPERTIES if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map255 = iprot.readMapBegin(); - struct.properties = new HashMap(2*_map255.size); - for (int _i256 = 0; _i256 < _map255.size; ++_i256) + org.apache.thrift.protocol.TMap _map289 = iprot.readMapBegin(); + struct.properties = new HashMap(2*_map289.size); + for (int _i290 = 0; _i290 < _map289.size; ++_i290) { - String _key257; // required - String _val258; // required - _key257 = iprot.readString(); - _val258 = iprot.readString(); - struct.properties.put(_key257, _val258); + String _key291; // required + String _val292; // required + _key291 = iprot.readString(); + _val292 = iprot.readString(); + struct.properties.put(_key291, _val292); } iprot.readMapEnd(); } @@ -505,9 +505,9 @@ oprot.writeFieldBegin(FIELD_SCHEMAS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.fieldSchemas.size())); - for (FieldSchema _iter259 : struct.fieldSchemas) + for (FieldSchema _iter293 : struct.fieldSchemas) { - _iter259.write(oprot); + _iter293.write(oprot); } oprot.writeListEnd(); } @@ -517,10 +517,10 @@ oprot.writeFieldBegin(PROPERTIES_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.properties.size())); - for (Map.Entry _iter260 : struct.properties.entrySet()) + for (Map.Entry _iter294 : struct.properties.entrySet()) { - oprot.writeString(_iter260.getKey()); - oprot.writeString(_iter260.getValue()); + oprot.writeString(_iter294.getKey()); + oprot.writeString(_iter294.getValue()); } oprot.writeMapEnd(); } @@ -554,19 +554,19 @@ if (struct.isSetFieldSchemas()) { { oprot.writeI32(struct.fieldSchemas.size()); - for (FieldSchema _iter261 : struct.fieldSchemas) + for (FieldSchema _iter295 : struct.fieldSchemas) { - _iter261.write(oprot); + _iter295.write(oprot); } } } if (struct.isSetProperties()) { { oprot.writeI32(struct.properties.size()); - for (Map.Entry _iter262 : struct.properties.entrySet()) + for (Map.Entry _iter296 : struct.properties.entrySet()) { - oprot.writeString(_iter262.getKey()); - oprot.writeString(_iter262.getValue()); + oprot.writeString(_iter296.getKey()); + oprot.writeString(_iter296.getValue()); } } } @@ -578,29 +578,29 @@ BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list263 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.fieldSchemas = new ArrayList(_list263.size); - for (int _i264 = 0; _i264 < _list263.size; ++_i264) + org.apache.thrift.protocol.TList _list297 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.fieldSchemas = new ArrayList(_list297.size); + for (int _i298 = 0; _i298 < _list297.size; ++_i298) { - FieldSchema _elem265; // required - _elem265 = new FieldSchema(); - _elem265.read(iprot); - struct.fieldSchemas.add(_elem265); + FieldSchema _elem299; // required + _elem299 = new FieldSchema(); + _elem299.read(iprot); + struct.fieldSchemas.add(_elem299); } } struct.setFieldSchemasIsSet(true); } if (incoming.get(1)) { { - org.apache.thrift.protocol.TMap _map266 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.properties = new HashMap(2*_map266.size); - for (int _i267 = 0; _i267 < _map266.size; ++_i267) + org.apache.thrift.protocol.TMap _map300 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.properties = new HashMap(2*_map300.size); + for (int _i301 = 0; _i301 < _map300.size; ++_i301) { - String _key268; // required - String _val269; // required - _key268 = iprot.readString(); - _val269 = iprot.readString(); - struct.properties.put(_key268, _val269); + String _key302; // required + String _val303; // required + _key302 = iprot.readString(); + _val303 = iprot.readString(); + struct.properties.put(_key302, _val303); } } struct.setPropertiesIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AddPartitionsResult.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AddPartitionsResult.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/AddPartitionsResult.java (working copy) @@ -342,14 +342,14 @@ case 1: // PARTITIONS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list338 = iprot.readListBegin(); - struct.partitions = new ArrayList(_list338.size); - for (int _i339 = 0; _i339 < _list338.size; ++_i339) + org.apache.thrift.protocol.TList _list372 = iprot.readListBegin(); + struct.partitions = new ArrayList(_list372.size); + for (int _i373 = 0; _i373 < _list372.size; ++_i373) { - Partition _elem340; // required - _elem340 = new Partition(); - _elem340.read(iprot); - struct.partitions.add(_elem340); + Partition _elem374; // required + _elem374 = new Partition(); + _elem374.read(iprot); + struct.partitions.add(_elem374); } iprot.readListEnd(); } @@ -376,9 +376,9 @@ oprot.writeFieldBegin(PARTITIONS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.partitions.size())); - for (Partition _iter341 : struct.partitions) + for (Partition _iter375 : struct.partitions) { - _iter341.write(oprot); + _iter375.write(oprot); } oprot.writeListEnd(); } @@ -410,9 +410,9 @@ if (struct.isSetPartitions()) { { oprot.writeI32(struct.partitions.size()); - for (Partition _iter342 : struct.partitions) + for (Partition _iter376 : struct.partitions) { - _iter342.write(oprot); + _iter376.write(oprot); } } } @@ -424,14 +424,14 @@ BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list343 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.partitions = new ArrayList(_list343.size); - for (int _i344 = 0; _i344 < _list343.size; ++_i344) + org.apache.thrift.protocol.TList _list377 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.partitions = new ArrayList(_list377.size); + for (int _i378 = 0; _i378 < _list377.size; ++_i378) { - Partition _elem345; // required - _elem345 = new Partition(); - _elem345.read(iprot); - struct.partitions.add(_elem345); + Partition _elem379; // required + _elem379 = new Partition(); + _elem379.read(iprot); + struct.partitions.add(_elem379); } } struct.setPartitionsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java (working copy) @@ -350,14 +350,14 @@ case 1: // TABLE_STATS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list288 = iprot.readListBegin(); - struct.tableStats = new ArrayList(_list288.size); - for (int _i289 = 0; _i289 < _list288.size; ++_i289) + org.apache.thrift.protocol.TList _list322 = iprot.readListBegin(); + struct.tableStats = new ArrayList(_list322.size); + for (int _i323 = 0; _i323 < _list322.size; ++_i323) { - ColumnStatisticsObj _elem290; // required - _elem290 = new ColumnStatisticsObj(); - _elem290.read(iprot); - struct.tableStats.add(_elem290); + ColumnStatisticsObj _elem324; // required + _elem324 = new ColumnStatisticsObj(); + _elem324.read(iprot); + struct.tableStats.add(_elem324); } iprot.readListEnd(); } @@ -383,9 +383,9 @@ oprot.writeFieldBegin(TABLE_STATS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.tableStats.size())); - for (ColumnStatisticsObj _iter291 : struct.tableStats) + for (ColumnStatisticsObj _iter325 : struct.tableStats) { - _iter291.write(oprot); + _iter325.write(oprot); } oprot.writeListEnd(); } @@ -410,9 +410,9 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.tableStats.size()); - for (ColumnStatisticsObj _iter292 : struct.tableStats) + for (ColumnStatisticsObj _iter326 : struct.tableStats) { - _iter292.write(oprot); + _iter326.write(oprot); } } } @@ -421,14 +421,14 @@ public void read(org.apache.thrift.protocol.TProtocol prot, TableStatsResult struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TList _list293 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.tableStats = new ArrayList(_list293.size); - for (int _i294 = 0; _i294 < _list293.size; ++_i294) + org.apache.thrift.protocol.TList _list327 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.tableStats = new ArrayList(_list327.size); + for (int _i328 = 0; _i328 < _list327.size; ++_i328) { - ColumnStatisticsObj _elem295; // required - _elem295 = new ColumnStatisticsObj(); - _elem295.read(iprot); - struct.tableStats.add(_elem295); + ColumnStatisticsObj _elem329; // required + _elem329 = new ColumnStatisticsObj(); + _elem329.read(iprot); + struct.tableStats.add(_elem329); } } struct.setTableStatsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsRequest.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsRequest.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsRequest.java (working copy) @@ -536,13 +536,13 @@ case 3: // COL_NAMES if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list314 = iprot.readListBegin(); - struct.colNames = new ArrayList(_list314.size); - for (int _i315 = 0; _i315 < _list314.size; ++_i315) + org.apache.thrift.protocol.TList _list348 = iprot.readListBegin(); + struct.colNames = new ArrayList(_list348.size); + for (int _i349 = 0; _i349 < _list348.size; ++_i349) { - String _elem316; // required - _elem316 = iprot.readString(); - struct.colNames.add(_elem316); + String _elem350; // required + _elem350 = iprot.readString(); + struct.colNames.add(_elem350); } iprot.readListEnd(); } @@ -578,9 +578,9 @@ oprot.writeFieldBegin(COL_NAMES_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.colNames.size())); - for (String _iter317 : struct.colNames) + for (String _iter351 : struct.colNames) { - oprot.writeString(_iter317); + oprot.writeString(_iter351); } oprot.writeListEnd(); } @@ -607,9 +607,9 @@ oprot.writeString(struct.tblName); { oprot.writeI32(struct.colNames.size()); - for (String _iter318 : struct.colNames) + for (String _iter352 : struct.colNames) { - oprot.writeString(_iter318); + oprot.writeString(_iter352); } } } @@ -622,13 +622,13 @@ struct.tblName = iprot.readString(); struct.setTblNameIsSet(true); { - org.apache.thrift.protocol.TList _list319 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.colNames = new ArrayList(_list319.size); - for (int _i320 = 0; _i320 < _list319.size; ++_i320) + org.apache.thrift.protocol.TList _list353 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.colNames = new ArrayList(_list353.size); + for (int _i354 = 0; _i354 < _list353.size; ++_i354) { - String _elem321; // required - _elem321 = iprot.readString(); - struct.colNames.add(_elem321); + String _elem355; // required + _elem355 = iprot.readString(); + struct.colNames.add(_elem355); } } struct.setColNamesIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionWithoutSD.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionWithoutSD.java (revision 0) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionWithoutSD.java (revision 0) @@ -0,0 +1,1026 @@ +/** + * Autogenerated by Thrift Compiler (0.9.0) + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package org.apache.hadoop.hive.metastore.api; + +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.thrift.scheme.IScheme; +import org.apache.thrift.scheme.SchemeFactory; +import org.apache.thrift.scheme.StandardScheme; + +import org.apache.thrift.scheme.TupleScheme; +import org.apache.thrift.protocol.TTupleProtocol; +import org.apache.thrift.protocol.TProtocolException; +import org.apache.thrift.EncodingUtils; +import org.apache.thrift.TException; +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.EnumMap; +import java.util.Set; +import java.util.HashSet; +import java.util.EnumSet; +import java.util.Collections; +import java.util.BitSet; +import java.nio.ByteBuffer; +import java.util.Arrays; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class PartitionWithoutSD 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("PartitionWithoutSD"); + + private static final org.apache.thrift.protocol.TField VALUES_FIELD_DESC = new org.apache.thrift.protocol.TField("values", org.apache.thrift.protocol.TType.LIST, (short)1); + private static final org.apache.thrift.protocol.TField CREATE_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("createTime", org.apache.thrift.protocol.TType.I32, (short)2); + private static final org.apache.thrift.protocol.TField LAST_ACCESS_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("lastAccessTime", org.apache.thrift.protocol.TType.I32, (short)3); + private static final org.apache.thrift.protocol.TField RELATIVE_PATH_FIELD_DESC = new org.apache.thrift.protocol.TField("relativePath", org.apache.thrift.protocol.TType.STRING, (short)4); + private static final org.apache.thrift.protocol.TField PARAMETERS_FIELD_DESC = new org.apache.thrift.protocol.TField("parameters", org.apache.thrift.protocol.TType.MAP, (short)5); + private static final org.apache.thrift.protocol.TField PRIVILEGES_FIELD_DESC = new org.apache.thrift.protocol.TField("privileges", org.apache.thrift.protocol.TType.STRUCT, (short)6); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new PartitionWithoutSDStandardSchemeFactory()); + schemes.put(TupleScheme.class, new PartitionWithoutSDTupleSchemeFactory()); + } + + private List values; // required + private int createTime; // required + private int lastAccessTime; // required + private String relativePath; // required + private Map parameters; // required + private PrincipalPrivilegeSet privileges; // optional + + /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ + public enum _Fields implements org.apache.thrift.TFieldIdEnum { + VALUES((short)1, "values"), + CREATE_TIME((short)2, "createTime"), + LAST_ACCESS_TIME((short)3, "lastAccessTime"), + RELATIVE_PATH((short)4, "relativePath"), + PARAMETERS((short)5, "parameters"), + PRIVILEGES((short)6, "privileges"); + + 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: // VALUES + return VALUES; + case 2: // CREATE_TIME + return CREATE_TIME; + case 3: // LAST_ACCESS_TIME + return LAST_ACCESS_TIME; + case 4: // RELATIVE_PATH + return RELATIVE_PATH; + case 5: // PARAMETERS + return PARAMETERS; + case 6: // PRIVILEGES + return PRIVILEGES; + 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 + private static final int __CREATETIME_ISSET_ID = 0; + private static final int __LASTACCESSTIME_ISSET_ID = 1; + private byte __isset_bitfield = 0; + private _Fields optionals[] = {_Fields.PRIVILEGES}; + 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.VALUES, new org.apache.thrift.meta_data.FieldMetaData("values", 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.CREATE_TIME, new org.apache.thrift.meta_data.FieldMetaData("createTime", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); + tmpMap.put(_Fields.LAST_ACCESS_TIME, new org.apache.thrift.meta_data.FieldMetaData("lastAccessTime", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); + tmpMap.put(_Fields.RELATIVE_PATH, new org.apache.thrift.meta_data.FieldMetaData("relativePath", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.PARAMETERS, new org.apache.thrift.meta_data.FieldMetaData("parameters", 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.PRIVILEGES, new org.apache.thrift.meta_data.FieldMetaData("privileges", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PrincipalPrivilegeSet.class))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PartitionWithoutSD.class, metaDataMap); + } + + public PartitionWithoutSD() { + } + + public PartitionWithoutSD( + List values, + int createTime, + int lastAccessTime, + String relativePath, + Map parameters) + { + this(); + this.values = values; + this.createTime = createTime; + setCreateTimeIsSet(true); + this.lastAccessTime = lastAccessTime; + setLastAccessTimeIsSet(true); + this.relativePath = relativePath; + this.parameters = parameters; + } + + /** + * Performs a deep copy on other. + */ + public PartitionWithoutSD(PartitionWithoutSD other) { + __isset_bitfield = other.__isset_bitfield; + if (other.isSetValues()) { + List __this__values = new ArrayList(); + for (String other_element : other.values) { + __this__values.add(other_element); + } + this.values = __this__values; + } + this.createTime = other.createTime; + this.lastAccessTime = other.lastAccessTime; + if (other.isSetRelativePath()) { + this.relativePath = other.relativePath; + } + if (other.isSetParameters()) { + Map __this__parameters = new HashMap(); + for (Map.Entry other_element : other.parameters.entrySet()) { + + String other_element_key = other_element.getKey(); + String other_element_value = other_element.getValue(); + + String __this__parameters_copy_key = other_element_key; + + String __this__parameters_copy_value = other_element_value; + + __this__parameters.put(__this__parameters_copy_key, __this__parameters_copy_value); + } + this.parameters = __this__parameters; + } + if (other.isSetPrivileges()) { + this.privileges = new PrincipalPrivilegeSet(other.privileges); + } + } + + public PartitionWithoutSD deepCopy() { + return new PartitionWithoutSD(this); + } + + @Override + public void clear() { + this.values = null; + setCreateTimeIsSet(false); + this.createTime = 0; + setLastAccessTimeIsSet(false); + this.lastAccessTime = 0; + this.relativePath = null; + this.parameters = null; + this.privileges = null; + } + + public int getValuesSize() { + return (this.values == null) ? 0 : this.values.size(); + } + + public java.util.Iterator getValuesIterator() { + return (this.values == null) ? null : this.values.iterator(); + } + + public void addToValues(String elem) { + if (this.values == null) { + this.values = new ArrayList(); + } + this.values.add(elem); + } + + public List getValues() { + return this.values; + } + + public void setValues(List values) { + this.values = values; + } + + public void unsetValues() { + this.values = null; + } + + /** Returns true if field values is set (has been assigned a value) and false otherwise */ + public boolean isSetValues() { + return this.values != null; + } + + public void setValuesIsSet(boolean value) { + if (!value) { + this.values = null; + } + } + + public int getCreateTime() { + return this.createTime; + } + + public void setCreateTime(int createTime) { + this.createTime = createTime; + setCreateTimeIsSet(true); + } + + public void unsetCreateTime() { + __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __CREATETIME_ISSET_ID); + } + + /** Returns true if field createTime is set (has been assigned a value) and false otherwise */ + public boolean isSetCreateTime() { + return EncodingUtils.testBit(__isset_bitfield, __CREATETIME_ISSET_ID); + } + + public void setCreateTimeIsSet(boolean value) { + __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __CREATETIME_ISSET_ID, value); + } + + public int getLastAccessTime() { + return this.lastAccessTime; + } + + public void setLastAccessTime(int lastAccessTime) { + this.lastAccessTime = lastAccessTime; + setLastAccessTimeIsSet(true); + } + + public void unsetLastAccessTime() { + __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LASTACCESSTIME_ISSET_ID); + } + + /** Returns true if field lastAccessTime is set (has been assigned a value) and false otherwise */ + public boolean isSetLastAccessTime() { + return EncodingUtils.testBit(__isset_bitfield, __LASTACCESSTIME_ISSET_ID); + } + + public void setLastAccessTimeIsSet(boolean value) { + __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LASTACCESSTIME_ISSET_ID, value); + } + + public String getRelativePath() { + return this.relativePath; + } + + public void setRelativePath(String relativePath) { + this.relativePath = relativePath; + } + + public void unsetRelativePath() { + this.relativePath = null; + } + + /** Returns true if field relativePath is set (has been assigned a value) and false otherwise */ + public boolean isSetRelativePath() { + return this.relativePath != null; + } + + public void setRelativePathIsSet(boolean value) { + if (!value) { + this.relativePath = null; + } + } + + public int getParametersSize() { + return (this.parameters == null) ? 0 : this.parameters.size(); + } + + public void putToParameters(String key, String val) { + if (this.parameters == null) { + this.parameters = new HashMap(); + } + this.parameters.put(key, val); + } + + public Map getParameters() { + return this.parameters; + } + + public void setParameters(Map parameters) { + this.parameters = parameters; + } + + public void unsetParameters() { + this.parameters = null; + } + + /** Returns true if field parameters is set (has been assigned a value) and false otherwise */ + public boolean isSetParameters() { + return this.parameters != null; + } + + public void setParametersIsSet(boolean value) { + if (!value) { + this.parameters = null; + } + } + + public PrincipalPrivilegeSet getPrivileges() { + return this.privileges; + } + + public void setPrivileges(PrincipalPrivilegeSet privileges) { + this.privileges = privileges; + } + + public void unsetPrivileges() { + this.privileges = null; + } + + /** Returns true if field privileges is set (has been assigned a value) and false otherwise */ + public boolean isSetPrivileges() { + return this.privileges != null; + } + + public void setPrivilegesIsSet(boolean value) { + if (!value) { + this.privileges = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case VALUES: + if (value == null) { + unsetValues(); + } else { + setValues((List)value); + } + break; + + case CREATE_TIME: + if (value == null) { + unsetCreateTime(); + } else { + setCreateTime((Integer)value); + } + break; + + case LAST_ACCESS_TIME: + if (value == null) { + unsetLastAccessTime(); + } else { + setLastAccessTime((Integer)value); + } + break; + + case RELATIVE_PATH: + if (value == null) { + unsetRelativePath(); + } else { + setRelativePath((String)value); + } + break; + + case PARAMETERS: + if (value == null) { + unsetParameters(); + } else { + setParameters((Map)value); + } + break; + + case PRIVILEGES: + if (value == null) { + unsetPrivileges(); + } else { + setPrivileges((PrincipalPrivilegeSet)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case VALUES: + return getValues(); + + case CREATE_TIME: + return Integer.valueOf(getCreateTime()); + + case LAST_ACCESS_TIME: + return Integer.valueOf(getLastAccessTime()); + + case RELATIVE_PATH: + return getRelativePath(); + + case PARAMETERS: + return getParameters(); + + case PRIVILEGES: + return getPrivileges(); + + } + 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 VALUES: + return isSetValues(); + case CREATE_TIME: + return isSetCreateTime(); + case LAST_ACCESS_TIME: + return isSetLastAccessTime(); + case RELATIVE_PATH: + return isSetRelativePath(); + case PARAMETERS: + return isSetParameters(); + case PRIVILEGES: + return isSetPrivileges(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof PartitionWithoutSD) + return this.equals((PartitionWithoutSD)that); + return false; + } + + public boolean equals(PartitionWithoutSD that) { + if (that == null) + return false; + + boolean this_present_values = true && this.isSetValues(); + boolean that_present_values = true && that.isSetValues(); + if (this_present_values || that_present_values) { + if (!(this_present_values && that_present_values)) + return false; + if (!this.values.equals(that.values)) + return false; + } + + boolean this_present_createTime = true; + boolean that_present_createTime = true; + if (this_present_createTime || that_present_createTime) { + if (!(this_present_createTime && that_present_createTime)) + return false; + if (this.createTime != that.createTime) + return false; + } + + boolean this_present_lastAccessTime = true; + boolean that_present_lastAccessTime = true; + if (this_present_lastAccessTime || that_present_lastAccessTime) { + if (!(this_present_lastAccessTime && that_present_lastAccessTime)) + return false; + if (this.lastAccessTime != that.lastAccessTime) + return false; + } + + boolean this_present_relativePath = true && this.isSetRelativePath(); + boolean that_present_relativePath = true && that.isSetRelativePath(); + if (this_present_relativePath || that_present_relativePath) { + if (!(this_present_relativePath && that_present_relativePath)) + return false; + if (!this.relativePath.equals(that.relativePath)) + return false; + } + + boolean this_present_parameters = true && this.isSetParameters(); + boolean that_present_parameters = true && that.isSetParameters(); + if (this_present_parameters || that_present_parameters) { + if (!(this_present_parameters && that_present_parameters)) + return false; + if (!this.parameters.equals(that.parameters)) + return false; + } + + boolean this_present_privileges = true && this.isSetPrivileges(); + boolean that_present_privileges = true && that.isSetPrivileges(); + if (this_present_privileges || that_present_privileges) { + if (!(this_present_privileges && that_present_privileges)) + return false; + if (!this.privileges.equals(that.privileges)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_values = true && (isSetValues()); + builder.append(present_values); + if (present_values) + builder.append(values); + + boolean present_createTime = true; + builder.append(present_createTime); + if (present_createTime) + builder.append(createTime); + + boolean present_lastAccessTime = true; + builder.append(present_lastAccessTime); + if (present_lastAccessTime) + builder.append(lastAccessTime); + + boolean present_relativePath = true && (isSetRelativePath()); + builder.append(present_relativePath); + if (present_relativePath) + builder.append(relativePath); + + boolean present_parameters = true && (isSetParameters()); + builder.append(present_parameters); + if (present_parameters) + builder.append(parameters); + + boolean present_privileges = true && (isSetPrivileges()); + builder.append(present_privileges); + if (present_privileges) + builder.append(privileges); + + return builder.toHashCode(); + } + + public int compareTo(PartitionWithoutSD other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + PartitionWithoutSD typedOther = (PartitionWithoutSD)other; + + lastComparison = Boolean.valueOf(isSetValues()).compareTo(typedOther.isSetValues()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetValues()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.values, typedOther.values); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetCreateTime()).compareTo(typedOther.isSetCreateTime()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetCreateTime()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.createTime, typedOther.createTime); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetLastAccessTime()).compareTo(typedOther.isSetLastAccessTime()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetLastAccessTime()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lastAccessTime, typedOther.lastAccessTime); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetRelativePath()).compareTo(typedOther.isSetRelativePath()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetRelativePath()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.relativePath, typedOther.relativePath); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetParameters()).compareTo(typedOther.isSetParameters()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetParameters()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.parameters, typedOther.parameters); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetPrivileges()).compareTo(typedOther.isSetPrivileges()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPrivileges()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.privileges, typedOther.privileges); + 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("PartitionWithoutSD("); + boolean first = true; + + sb.append("values:"); + if (this.values == null) { + sb.append("null"); + } else { + sb.append(this.values); + } + first = false; + if (!first) sb.append(", "); + sb.append("createTime:"); + sb.append(this.createTime); + first = false; + if (!first) sb.append(", "); + sb.append("lastAccessTime:"); + sb.append(this.lastAccessTime); + first = false; + if (!first) sb.append(", "); + sb.append("relativePath:"); + if (this.relativePath == null) { + sb.append("null"); + } else { + sb.append(this.relativePath); + } + first = false; + if (!first) sb.append(", "); + sb.append("parameters:"); + if (this.parameters == null) { + sb.append("null"); + } else { + sb.append(this.parameters); + } + first = false; + if (isSetPrivileges()) { + if (!first) sb.append(", "); + sb.append("privileges:"); + if (this.privileges == null) { + sb.append("null"); + } else { + sb.append(this.privileges); + } + 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 (privileges != null) { + privileges.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 { + // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor. + __isset_bitfield = 0; + 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 PartitionWithoutSDStandardSchemeFactory implements SchemeFactory { + public PartitionWithoutSDStandardScheme getScheme() { + return new PartitionWithoutSDStandardScheme(); + } + } + + private static class PartitionWithoutSDStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionWithoutSD 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: // VALUES + if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { + { + org.apache.thrift.protocol.TList _list226 = iprot.readListBegin(); + struct.values = new ArrayList(_list226.size); + for (int _i227 = 0; _i227 < _list226.size; ++_i227) + { + String _elem228; // required + _elem228 = iprot.readString(); + struct.values.add(_elem228); + } + iprot.readListEnd(); + } + struct.setValuesIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // CREATE_TIME + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.createTime = iprot.readI32(); + struct.setCreateTimeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // LAST_ACCESS_TIME + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.lastAccessTime = iprot.readI32(); + struct.setLastAccessTimeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // RELATIVE_PATH + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.relativePath = iprot.readString(); + struct.setRelativePathIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 5: // PARAMETERS + if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { + { + org.apache.thrift.protocol.TMap _map229 = iprot.readMapBegin(); + struct.parameters = new HashMap(2*_map229.size); + for (int _i230 = 0; _i230 < _map229.size; ++_i230) + { + String _key231; // required + String _val232; // required + _key231 = iprot.readString(); + _val232 = iprot.readString(); + struct.parameters.put(_key231, _val232); + } + iprot.readMapEnd(); + } + struct.setParametersIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 6: // PRIVILEGES + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.privileges = new PrincipalPrivilegeSet(); + struct.privileges.read(iprot); + struct.setPrivilegesIsSet(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, PartitionWithoutSD struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.values != null) { + oprot.writeFieldBegin(VALUES_FIELD_DESC); + { + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.values.size())); + for (String _iter233 : struct.values) + { + oprot.writeString(_iter233); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC); + oprot.writeI32(struct.createTime); + oprot.writeFieldEnd(); + oprot.writeFieldBegin(LAST_ACCESS_TIME_FIELD_DESC); + oprot.writeI32(struct.lastAccessTime); + oprot.writeFieldEnd(); + if (struct.relativePath != null) { + oprot.writeFieldBegin(RELATIVE_PATH_FIELD_DESC); + oprot.writeString(struct.relativePath); + oprot.writeFieldEnd(); + } + if (struct.parameters != null) { + oprot.writeFieldBegin(PARAMETERS_FIELD_DESC); + { + oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.parameters.size())); + for (Map.Entry _iter234 : struct.parameters.entrySet()) + { + oprot.writeString(_iter234.getKey()); + oprot.writeString(_iter234.getValue()); + } + oprot.writeMapEnd(); + } + oprot.writeFieldEnd(); + } + if (struct.privileges != null) { + if (struct.isSetPrivileges()) { + oprot.writeFieldBegin(PRIVILEGES_FIELD_DESC); + struct.privileges.write(oprot); + oprot.writeFieldEnd(); + } + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class PartitionWithoutSDTupleSchemeFactory implements SchemeFactory { + public PartitionWithoutSDTupleScheme getScheme() { + return new PartitionWithoutSDTupleScheme(); + } + } + + private static class PartitionWithoutSDTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, PartitionWithoutSD struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetValues()) { + optionals.set(0); + } + if (struct.isSetCreateTime()) { + optionals.set(1); + } + if (struct.isSetLastAccessTime()) { + optionals.set(2); + } + if (struct.isSetRelativePath()) { + optionals.set(3); + } + if (struct.isSetParameters()) { + optionals.set(4); + } + if (struct.isSetPrivileges()) { + optionals.set(5); + } + oprot.writeBitSet(optionals, 6); + if (struct.isSetValues()) { + { + oprot.writeI32(struct.values.size()); + for (String _iter235 : struct.values) + { + oprot.writeString(_iter235); + } + } + } + if (struct.isSetCreateTime()) { + oprot.writeI32(struct.createTime); + } + if (struct.isSetLastAccessTime()) { + oprot.writeI32(struct.lastAccessTime); + } + if (struct.isSetRelativePath()) { + oprot.writeString(struct.relativePath); + } + if (struct.isSetParameters()) { + { + oprot.writeI32(struct.parameters.size()); + for (Map.Entry _iter236 : struct.parameters.entrySet()) + { + oprot.writeString(_iter236.getKey()); + oprot.writeString(_iter236.getValue()); + } + } + } + if (struct.isSetPrivileges()) { + struct.privileges.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, PartitionWithoutSD struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(6); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TList _list237 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.values = new ArrayList(_list237.size); + for (int _i238 = 0; _i238 < _list237.size; ++_i238) + { + String _elem239; // required + _elem239 = iprot.readString(); + struct.values.add(_elem239); + } + } + struct.setValuesIsSet(true); + } + if (incoming.get(1)) { + struct.createTime = iprot.readI32(); + struct.setCreateTimeIsSet(true); + } + if (incoming.get(2)) { + struct.lastAccessTime = iprot.readI32(); + struct.setLastAccessTimeIsSet(true); + } + if (incoming.get(3)) { + struct.relativePath = iprot.readString(); + struct.setRelativePathIsSet(true); + } + if (incoming.get(4)) { + { + org.apache.thrift.protocol.TMap _map240 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.parameters = new HashMap(2*_map240.size); + for (int _i241 = 0; _i241 < _map240.size; ++_i241) + { + String _key242; // required + String _val243; // required + _key242 = iprot.readString(); + _val243 = iprot.readString(); + struct.parameters.put(_key242, _val243); + } + } + struct.setParametersIsSet(true); + } + if (incoming.get(5)) { + struct.privileges = new PrincipalPrivilegeSet(); + struct.privileges.read(iprot); + struct.setPrivilegesIsSet(true); + } + } + } + +} + Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsByExprResult.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsByExprResult.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsByExprResult.java (working copy) @@ -435,14 +435,14 @@ case 1: // PARTITIONS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list280 = iprot.readListBegin(); - struct.partitions = new ArrayList(_list280.size); - for (int _i281 = 0; _i281 < _list280.size; ++_i281) + org.apache.thrift.protocol.TList _list314 = iprot.readListBegin(); + struct.partitions = new ArrayList(_list314.size); + for (int _i315 = 0; _i315 < _list314.size; ++_i315) { - Partition _elem282; // required - _elem282 = new Partition(); - _elem282.read(iprot); - struct.partitions.add(_elem282); + Partition _elem316; // required + _elem316 = new Partition(); + _elem316.read(iprot); + struct.partitions.add(_elem316); } iprot.readListEnd(); } @@ -476,9 +476,9 @@ oprot.writeFieldBegin(PARTITIONS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.partitions.size())); - for (Partition _iter283 : struct.partitions) + for (Partition _iter317 : struct.partitions) { - _iter283.write(oprot); + _iter317.write(oprot); } oprot.writeListEnd(); } @@ -506,9 +506,9 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.partitions.size()); - for (Partition _iter284 : struct.partitions) + for (Partition _iter318 : struct.partitions) { - _iter284.write(oprot); + _iter318.write(oprot); } } oprot.writeBool(struct.hasUnknownPartitions); @@ -518,14 +518,14 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PartitionsByExprResult struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TList _list285 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.partitions = new ArrayList(_list285.size); - for (int _i286 = 0; _i286 < _list285.size; ++_i286) + org.apache.thrift.protocol.TList _list319 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.partitions = new ArrayList(_list319.size); + for (int _i320 = 0; _i320 < _list319.size; ++_i320) { - Partition _elem287; // required - _elem287 = new Partition(); - _elem287.read(iprot); - struct.partitions.add(_elem287); + Partition _elem321; // required + _elem321 = new Partition(); + _elem321.read(iprot); + struct.partitions.add(_elem321); } } struct.setPartitionsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpecWithSharedSD.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpecWithSharedSD.java (revision 0) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpecWithSharedSD.java (revision 0) @@ -0,0 +1,554 @@ +/** + * Autogenerated by Thrift Compiler (0.9.0) + * + * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING + * @generated + */ +package org.apache.hadoop.hive.metastore.api; + +import org.apache.commons.lang.builder.HashCodeBuilder; +import org.apache.thrift.scheme.IScheme; +import org.apache.thrift.scheme.SchemeFactory; +import org.apache.thrift.scheme.StandardScheme; + +import org.apache.thrift.scheme.TupleScheme; +import org.apache.thrift.protocol.TTupleProtocol; +import org.apache.thrift.protocol.TProtocolException; +import org.apache.thrift.EncodingUtils; +import org.apache.thrift.TException; +import java.util.List; +import java.util.ArrayList; +import java.util.Map; +import java.util.HashMap; +import java.util.EnumMap; +import java.util.Set; +import java.util.HashSet; +import java.util.EnumSet; +import java.util.Collections; +import java.util.BitSet; +import java.nio.ByteBuffer; +import java.util.Arrays; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class PartitionSpecWithSharedSD 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("PartitionSpecWithSharedSD"); + + private static final org.apache.thrift.protocol.TField PARTITIONS_FIELD_DESC = new org.apache.thrift.protocol.TField("partitions", org.apache.thrift.protocol.TType.LIST, (short)1); + private static final org.apache.thrift.protocol.TField SD_FIELD_DESC = new org.apache.thrift.protocol.TField("sd", org.apache.thrift.protocol.TType.STRUCT, (short)2); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new PartitionSpecWithSharedSDStandardSchemeFactory()); + schemes.put(TupleScheme.class, new PartitionSpecWithSharedSDTupleSchemeFactory()); + } + + private List partitions; // required + private StorageDescriptor sd; // 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 { + PARTITIONS((short)1, "partitions"), + SD((short)2, "sd"); + + 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: // PARTITIONS + return PARTITIONS; + case 2: // SD + return SD; + 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.PARTITIONS, new org.apache.thrift.meta_data.FieldMetaData("partitions", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionWithoutSD.class)))); + tmpMap.put(_Fields.SD, new org.apache.thrift.meta_data.FieldMetaData("sd", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, StorageDescriptor.class))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PartitionSpecWithSharedSD.class, metaDataMap); + } + + public PartitionSpecWithSharedSD() { + } + + public PartitionSpecWithSharedSD( + List partitions, + StorageDescriptor sd) + { + this(); + this.partitions = partitions; + this.sd = sd; + } + + /** + * Performs a deep copy on other. + */ + public PartitionSpecWithSharedSD(PartitionSpecWithSharedSD other) { + if (other.isSetPartitions()) { + List __this__partitions = new ArrayList(); + for (PartitionWithoutSD other_element : other.partitions) { + __this__partitions.add(new PartitionWithoutSD(other_element)); + } + this.partitions = __this__partitions; + } + if (other.isSetSd()) { + this.sd = new StorageDescriptor(other.sd); + } + } + + public PartitionSpecWithSharedSD deepCopy() { + return new PartitionSpecWithSharedSD(this); + } + + @Override + public void clear() { + this.partitions = null; + this.sd = null; + } + + public int getPartitionsSize() { + return (this.partitions == null) ? 0 : this.partitions.size(); + } + + public java.util.Iterator getPartitionsIterator() { + return (this.partitions == null) ? null : this.partitions.iterator(); + } + + public void addToPartitions(PartitionWithoutSD elem) { + if (this.partitions == null) { + this.partitions = new ArrayList(); + } + this.partitions.add(elem); + } + + public List getPartitions() { + return this.partitions; + } + + public void setPartitions(List partitions) { + this.partitions = partitions; + } + + public void unsetPartitions() { + this.partitions = null; + } + + /** Returns true if field partitions is set (has been assigned a value) and false otherwise */ + public boolean isSetPartitions() { + return this.partitions != null; + } + + public void setPartitionsIsSet(boolean value) { + if (!value) { + this.partitions = null; + } + } + + public StorageDescriptor getSd() { + return this.sd; + } + + public void setSd(StorageDescriptor sd) { + this.sd = sd; + } + + public void unsetSd() { + this.sd = null; + } + + /** Returns true if field sd is set (has been assigned a value) and false otherwise */ + public boolean isSetSd() { + return this.sd != null; + } + + public void setSdIsSet(boolean value) { + if (!value) { + this.sd = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case PARTITIONS: + if (value == null) { + unsetPartitions(); + } else { + setPartitions((List)value); + } + break; + + case SD: + if (value == null) { + unsetSd(); + } else { + setSd((StorageDescriptor)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case PARTITIONS: + return getPartitions(); + + case SD: + return getSd(); + + } + 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 PARTITIONS: + return isSetPartitions(); + case SD: + return isSetSd(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof PartitionSpecWithSharedSD) + return this.equals((PartitionSpecWithSharedSD)that); + return false; + } + + public boolean equals(PartitionSpecWithSharedSD that) { + if (that == null) + return false; + + boolean this_present_partitions = true && this.isSetPartitions(); + boolean that_present_partitions = true && that.isSetPartitions(); + if (this_present_partitions || that_present_partitions) { + if (!(this_present_partitions && that_present_partitions)) + return false; + if (!this.partitions.equals(that.partitions)) + return false; + } + + boolean this_present_sd = true && this.isSetSd(); + boolean that_present_sd = true && that.isSetSd(); + if (this_present_sd || that_present_sd) { + if (!(this_present_sd && that_present_sd)) + return false; + if (!this.sd.equals(that.sd)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_partitions = true && (isSetPartitions()); + builder.append(present_partitions); + if (present_partitions) + builder.append(partitions); + + boolean present_sd = true && (isSetSd()); + builder.append(present_sd); + if (present_sd) + builder.append(sd); + + return builder.toHashCode(); + } + + public int compareTo(PartitionSpecWithSharedSD other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + PartitionSpecWithSharedSD typedOther = (PartitionSpecWithSharedSD)other; + + lastComparison = Boolean.valueOf(isSetPartitions()).compareTo(typedOther.isSetPartitions()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPartitions()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.partitions, typedOther.partitions); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetSd()).compareTo(typedOther.isSetSd()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetSd()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sd, typedOther.sd); + 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("PartitionSpecWithSharedSD("); + boolean first = true; + + sb.append("partitions:"); + if (this.partitions == null) { + sb.append("null"); + } else { + sb.append(this.partitions); + } + first = false; + if (!first) sb.append(", "); + sb.append("sd:"); + if (this.sd == null) { + sb.append("null"); + } else { + sb.append(this.sd); + } + 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 (sd != null) { + sd.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 PartitionSpecWithSharedSDStandardSchemeFactory implements SchemeFactory { + public PartitionSpecWithSharedSDStandardScheme getScheme() { + return new PartitionSpecWithSharedSDStandardScheme(); + } + } + + private static class PartitionSpecWithSharedSDStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionSpecWithSharedSD 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: // PARTITIONS + if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { + { + org.apache.thrift.protocol.TList _list244 = iprot.readListBegin(); + struct.partitions = new ArrayList(_list244.size); + for (int _i245 = 0; _i245 < _list244.size; ++_i245) + { + PartitionWithoutSD _elem246; // required + _elem246 = new PartitionWithoutSD(); + _elem246.read(iprot); + struct.partitions.add(_elem246); + } + iprot.readListEnd(); + } + struct.setPartitionsIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // SD + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.sd = new StorageDescriptor(); + struct.sd.read(iprot); + struct.setSdIsSet(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, PartitionSpecWithSharedSD struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.partitions != null) { + oprot.writeFieldBegin(PARTITIONS_FIELD_DESC); + { + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.partitions.size())); + for (PartitionWithoutSD _iter247 : struct.partitions) + { + _iter247.write(oprot); + } + oprot.writeListEnd(); + } + oprot.writeFieldEnd(); + } + if (struct.sd != null) { + oprot.writeFieldBegin(SD_FIELD_DESC); + struct.sd.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class PartitionSpecWithSharedSDTupleSchemeFactory implements SchemeFactory { + public PartitionSpecWithSharedSDTupleScheme getScheme() { + return new PartitionSpecWithSharedSDTupleScheme(); + } + } + + private static class PartitionSpecWithSharedSDTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, PartitionSpecWithSharedSD struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetPartitions()) { + optionals.set(0); + } + if (struct.isSetSd()) { + optionals.set(1); + } + oprot.writeBitSet(optionals, 2); + if (struct.isSetPartitions()) { + { + oprot.writeI32(struct.partitions.size()); + for (PartitionWithoutSD _iter248 : struct.partitions) + { + _iter248.write(oprot); + } + } + } + if (struct.isSetSd()) { + struct.sd.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, PartitionSpecWithSharedSD struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(2); + if (incoming.get(0)) { + { + org.apache.thrift.protocol.TList _list249 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.partitions = new ArrayList(_list249.size); + for (int _i250 = 0; _i250 < _list249.size; ++_i250) + { + PartitionWithoutSD _elem251; // required + _elem251 = new PartitionWithoutSD(); + _elem251.read(iprot); + struct.partitions.add(_elem251); + } + } + struct.setPartitionsIsSet(true); + } + if (incoming.get(1)) { + struct.sd = new StorageDescriptor(); + struct.sd.read(iprot); + struct.setSdIsSet(true); + } + } + } + +} + Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/LockRequest.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/LockRequest.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/LockRequest.java (working copy) @@ -601,14 +601,14 @@ case 1: // COMPONENT if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list410 = iprot.readListBegin(); - struct.component = new ArrayList(_list410.size); - for (int _i411 = 0; _i411 < _list410.size; ++_i411) + org.apache.thrift.protocol.TList _list444 = iprot.readListBegin(); + struct.component = new ArrayList(_list444.size); + for (int _i445 = 0; _i445 < _list444.size; ++_i445) { - LockComponent _elem412; // required - _elem412 = new LockComponent(); - _elem412.read(iprot); - struct.component.add(_elem412); + LockComponent _elem446; // required + _elem446 = new LockComponent(); + _elem446.read(iprot); + struct.component.add(_elem446); } iprot.readListEnd(); } @@ -658,9 +658,9 @@ oprot.writeFieldBegin(COMPONENT_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.component.size())); - for (LockComponent _iter413 : struct.component) + for (LockComponent _iter447 : struct.component) { - _iter413.write(oprot); + _iter447.write(oprot); } oprot.writeListEnd(); } @@ -700,9 +700,9 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.component.size()); - for (LockComponent _iter414 : struct.component) + for (LockComponent _iter448 : struct.component) { - _iter414.write(oprot); + _iter448.write(oprot); } } oprot.writeString(struct.user); @@ -721,14 +721,14 @@ public void read(org.apache.thrift.protocol.TProtocol prot, LockRequest struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TList _list415 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.component = new ArrayList(_list415.size); - for (int _i416 = 0; _i416 < _list415.size; ++_i416) + org.apache.thrift.protocol.TList _list449 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.component = new ArrayList(_list449.size); + for (int _i450 = 0; _i450 < _list449.size; ++_i450) { - LockComponent _elem417; // required - _elem417 = new LockComponent(); - _elem417.read(iprot); - struct.component.add(_elem417); + LockComponent _elem451; // required + _elem451 = new LockComponent(); + _elem451.read(iprot); + struct.component.add(_elem451); } } struct.setComponentIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Index.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Index.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Index.java (working copy) @@ -1140,15 +1140,15 @@ case 9: // PARAMETERS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map226 = iprot.readMapBegin(); - struct.parameters = new HashMap(2*_map226.size); - for (int _i227 = 0; _i227 < _map226.size; ++_i227) + org.apache.thrift.protocol.TMap _map260 = iprot.readMapBegin(); + struct.parameters = new HashMap(2*_map260.size); + for (int _i261 = 0; _i261 < _map260.size; ++_i261) { - String _key228; // required - String _val229; // required - _key228 = iprot.readString(); - _val229 = iprot.readString(); - struct.parameters.put(_key228, _val229); + String _key262; // required + String _val263; // required + _key262 = iprot.readString(); + _val263 = iprot.readString(); + struct.parameters.put(_key262, _val263); } iprot.readMapEnd(); } @@ -1218,10 +1218,10 @@ oprot.writeFieldBegin(PARAMETERS_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.parameters.size())); - for (Map.Entry _iter230 : struct.parameters.entrySet()) + for (Map.Entry _iter264 : struct.parameters.entrySet()) { - oprot.writeString(_iter230.getKey()); - oprot.writeString(_iter230.getValue()); + oprot.writeString(_iter264.getKey()); + oprot.writeString(_iter264.getValue()); } oprot.writeMapEnd(); } @@ -1306,10 +1306,10 @@ if (struct.isSetParameters()) { { oprot.writeI32(struct.parameters.size()); - for (Map.Entry _iter231 : struct.parameters.entrySet()) + for (Map.Entry _iter265 : struct.parameters.entrySet()) { - oprot.writeString(_iter231.getKey()); - oprot.writeString(_iter231.getValue()); + oprot.writeString(_iter265.getKey()); + oprot.writeString(_iter265.getValue()); } } } @@ -1357,15 +1357,15 @@ } if (incoming.get(8)) { { - org.apache.thrift.protocol.TMap _map232 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.parameters = new HashMap(2*_map232.size); - for (int _i233 = 0; _i233 < _map232.size; ++_i233) + org.apache.thrift.protocol.TMap _map266 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.parameters = new HashMap(2*_map266.size); + for (int _i267 = 0; _i267 < _map266.size; ++_i267) { - String _key234; // required - String _val235; // required - _key234 = iprot.readString(); - _val235 = iprot.readString(); - struct.parameters.put(_key234, _val235); + String _key268; // required + String _val269; // required + _key268 = iprot.readString(); + _val269 = iprot.readString(); + struct.parameters.put(_key268, _val269); } } struct.setParametersIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetOpenTxnsInfoResponse.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetOpenTxnsInfoResponse.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetOpenTxnsInfoResponse.java (working copy) @@ -443,14 +443,14 @@ case 2: // OPEN_TXNS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list386 = iprot.readListBegin(); - struct.open_txns = new ArrayList(_list386.size); - for (int _i387 = 0; _i387 < _list386.size; ++_i387) + org.apache.thrift.protocol.TList _list420 = iprot.readListBegin(); + struct.open_txns = new ArrayList(_list420.size); + for (int _i421 = 0; _i421 < _list420.size; ++_i421) { - TxnInfo _elem388; // required - _elem388 = new TxnInfo(); - _elem388.read(iprot); - struct.open_txns.add(_elem388); + TxnInfo _elem422; // required + _elem422 = new TxnInfo(); + _elem422.read(iprot); + struct.open_txns.add(_elem422); } iprot.readListEnd(); } @@ -479,9 +479,9 @@ oprot.writeFieldBegin(OPEN_TXNS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.open_txns.size())); - for (TxnInfo _iter389 : struct.open_txns) + for (TxnInfo _iter423 : struct.open_txns) { - _iter389.write(oprot); + _iter423.write(oprot); } oprot.writeListEnd(); } @@ -507,9 +507,9 @@ oprot.writeI64(struct.txn_high_water_mark); { oprot.writeI32(struct.open_txns.size()); - for (TxnInfo _iter390 : struct.open_txns) + for (TxnInfo _iter424 : struct.open_txns) { - _iter390.write(oprot); + _iter424.write(oprot); } } } @@ -520,14 +520,14 @@ struct.txn_high_water_mark = iprot.readI64(); struct.setTxn_high_water_markIsSet(true); { - org.apache.thrift.protocol.TList _list391 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.open_txns = new ArrayList(_list391.size); - for (int _i392 = 0; _i392 < _list391.size; ++_i392) + org.apache.thrift.protocol.TList _list425 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.open_txns = new ArrayList(_list425.size); + for (int _i426 = 0; _i426 < _list425.size; ++_i426) { - TxnInfo _elem393; // required - _elem393 = new TxnInfo(); - _elem393.read(iprot); - struct.open_txns.add(_elem393); + TxnInfo _elem427; // required + _elem427 = new TxnInfo(); + _elem427.read(iprot); + struct.open_txns.add(_elem427); } } struct.setOpen_txnsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java (working copy) @@ -359,26 +359,26 @@ case 1: // PART_STATS if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { - org.apache.thrift.protocol.TMap _map296 = iprot.readMapBegin(); - struct.partStats = new HashMap>(2*_map296.size); - for (int _i297 = 0; _i297 < _map296.size; ++_i297) + org.apache.thrift.protocol.TMap _map330 = iprot.readMapBegin(); + struct.partStats = new HashMap>(2*_map330.size); + for (int _i331 = 0; _i331 < _map330.size; ++_i331) { - String _key298; // required - List _val299; // required - _key298 = iprot.readString(); + String _key332; // required + List _val333; // required + _key332 = iprot.readString(); { - org.apache.thrift.protocol.TList _list300 = iprot.readListBegin(); - _val299 = new ArrayList(_list300.size); - for (int _i301 = 0; _i301 < _list300.size; ++_i301) + org.apache.thrift.protocol.TList _list334 = iprot.readListBegin(); + _val333 = new ArrayList(_list334.size); + for (int _i335 = 0; _i335 < _list334.size; ++_i335) { - ColumnStatisticsObj _elem302; // required - _elem302 = new ColumnStatisticsObj(); - _elem302.read(iprot); - _val299.add(_elem302); + ColumnStatisticsObj _elem336; // required + _elem336 = new ColumnStatisticsObj(); + _elem336.read(iprot); + _val333.add(_elem336); } iprot.readListEnd(); } - struct.partStats.put(_key298, _val299); + struct.partStats.put(_key332, _val333); } iprot.readMapEnd(); } @@ -404,14 +404,14 @@ oprot.writeFieldBegin(PART_STATS_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.LIST, struct.partStats.size())); - for (Map.Entry> _iter303 : struct.partStats.entrySet()) + for (Map.Entry> _iter337 : struct.partStats.entrySet()) { - oprot.writeString(_iter303.getKey()); + oprot.writeString(_iter337.getKey()); { - oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, _iter303.getValue().size())); - for (ColumnStatisticsObj _iter304 : _iter303.getValue()) + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, _iter337.getValue().size())); + for (ColumnStatisticsObj _iter338 : _iter337.getValue()) { - _iter304.write(oprot); + _iter338.write(oprot); } oprot.writeListEnd(); } @@ -439,14 +439,14 @@ TTupleProtocol oprot = (TTupleProtocol) prot; { oprot.writeI32(struct.partStats.size()); - for (Map.Entry> _iter305 : struct.partStats.entrySet()) + for (Map.Entry> _iter339 : struct.partStats.entrySet()) { - oprot.writeString(_iter305.getKey()); + oprot.writeString(_iter339.getKey()); { - oprot.writeI32(_iter305.getValue().size()); - for (ColumnStatisticsObj _iter306 : _iter305.getValue()) + oprot.writeI32(_iter339.getValue().size()); + for (ColumnStatisticsObj _iter340 : _iter339.getValue()) { - _iter306.write(oprot); + _iter340.write(oprot); } } } @@ -457,25 +457,25 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PartitionsStatsResult struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { - org.apache.thrift.protocol.TMap _map307 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.LIST, iprot.readI32()); - struct.partStats = new HashMap>(2*_map307.size); - for (int _i308 = 0; _i308 < _map307.size; ++_i308) + org.apache.thrift.protocol.TMap _map341 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.LIST, iprot.readI32()); + struct.partStats = new HashMap>(2*_map341.size); + for (int _i342 = 0; _i342 < _map341.size; ++_i342) { - String _key309; // required - List _val310; // required - _key309 = iprot.readString(); + String _key343; // required + List _val344; // required + _key343 = iprot.readString(); { - org.apache.thrift.protocol.TList _list311 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - _val310 = new ArrayList(_list311.size); - for (int _i312 = 0; _i312 < _list311.size; ++_i312) + org.apache.thrift.protocol.TList _list345 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + _val344 = new ArrayList(_list345.size); + for (int _i346 = 0; _i346 < _list345.size; ++_i346) { - ColumnStatisticsObj _elem313; // required - _elem313 = new ColumnStatisticsObj(); - _elem313.read(iprot); - _val310.add(_elem313); + ColumnStatisticsObj _elem347; // required + _elem347 = new ColumnStatisticsObj(); + _elem347.read(iprot); + _val344.add(_elem347); } } - struct.partStats.put(_key309, _val310); + struct.partStats.put(_key343, _val344); } } struct.setPartStatsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/DropPartitionsResult.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/DropPartitionsResult.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/DropPartitionsResult.java (working copy) @@ -342,14 +342,14 @@ case 1: // PARTITIONS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list354 = iprot.readListBegin(); - struct.partitions = new ArrayList(_list354.size); - for (int _i355 = 0; _i355 < _list354.size; ++_i355) + org.apache.thrift.protocol.TList _list388 = iprot.readListBegin(); + struct.partitions = new ArrayList(_list388.size); + for (int _i389 = 0; _i389 < _list388.size; ++_i389) { - Partition _elem356; // required - _elem356 = new Partition(); - _elem356.read(iprot); - struct.partitions.add(_elem356); + Partition _elem390; // required + _elem390 = new Partition(); + _elem390.read(iprot); + struct.partitions.add(_elem390); } iprot.readListEnd(); } @@ -376,9 +376,9 @@ oprot.writeFieldBegin(PARTITIONS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.partitions.size())); - for (Partition _iter357 : struct.partitions) + for (Partition _iter391 : struct.partitions) { - _iter357.write(oprot); + _iter391.write(oprot); } oprot.writeListEnd(); } @@ -410,9 +410,9 @@ if (struct.isSetPartitions()) { { oprot.writeI32(struct.partitions.size()); - for (Partition _iter358 : struct.partitions) + for (Partition _iter392 : struct.partitions) { - _iter358.write(oprot); + _iter392.write(oprot); } } } @@ -424,14 +424,14 @@ BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { - org.apache.thrift.protocol.TList _list359 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.partitions = new ArrayList(_list359.size); - for (int _i360 = 0; _i360 < _list359.size; ++_i360) + org.apache.thrift.protocol.TList _list393 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.partitions = new ArrayList(_list393.size); + for (int _i394 = 0; _i394 < _list393.size; ++_i394) { - Partition _elem361; // required - _elem361 = new Partition(); - _elem361.read(iprot); - struct.partitions.add(_elem361); + Partition _elem395; // required + _elem395 = new Partition(); + _elem395.read(iprot); + struct.partitions.add(_elem395); } } struct.setPartitionsIsSet(true); Index: metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Function.java =================================================================== --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Function.java (revision 1619008) +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Function.java (working copy) @@ -993,14 +993,14 @@ case 8: // RESOURCE_URIS if (schemeField.type == org.apache.thrift.protocol.TType.LIST) { { - org.apache.thrift.protocol.TList _list378 = iprot.readListBegin(); - struct.resourceUris = new ArrayList(_list378.size); - for (int _i379 = 0; _i379 < _list378.size; ++_i379) + org.apache.thrift.protocol.TList _list412 = iprot.readListBegin(); + struct.resourceUris = new ArrayList(_list412.size); + for (int _i413 = 0; _i413 < _list412.size; ++_i413) { - ResourceUri _elem380; // required - _elem380 = new ResourceUri(); - _elem380.read(iprot); - struct.resourceUris.add(_elem380); + ResourceUri _elem414; // required + _elem414 = new ResourceUri(); + _elem414.read(iprot); + struct.resourceUris.add(_elem414); } iprot.readListEnd(); } @@ -1059,9 +1059,9 @@ oprot.writeFieldBegin(RESOURCE_URIS_FIELD_DESC); { oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.resourceUris.size())); - for (ResourceUri _iter381 : struct.resourceUris) + for (ResourceUri _iter415 : struct.resourceUris) { - _iter381.write(oprot); + _iter415.write(oprot); } oprot.writeListEnd(); } @@ -1134,9 +1134,9 @@ if (struct.isSetResourceUris()) { { oprot.writeI32(struct.resourceUris.size()); - for (ResourceUri _iter382 : struct.resourceUris) + for (ResourceUri _iter416 : struct.resourceUris) { - _iter382.write(oprot); + _iter416.write(oprot); } } } @@ -1176,14 +1176,14 @@ } if (incoming.get(7)) { { - org.apache.thrift.protocol.TList _list383 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.resourceUris = new ArrayList(_list383.size); - for (int _i384 = 0; _i384 < _list383.size; ++_i384) + org.apache.thrift.protocol.TList _list417 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.resourceUris = new ArrayList(_list417.size); + for (int _i418 = 0; _i418 < _list417.size; ++_i418) { - ResourceUri _elem385; // required - _elem385 = new ResourceUri(); - _elem385.read(iprot); - struct.resourceUris.add(_elem385); + ResourceUri _elem419; // required + _elem419 = new ResourceUri(); + _elem419.read(iprot); + struct.resourceUris.add(_elem419); } } struct.setResourceUrisIsSet(true); Index: metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php =================================================================== --- metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php (revision 1619008) +++ metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php (working copy) @@ -44,6 +44,7 @@ public function add_partition(\metastore\Partition $new_part); public function add_partition_with_environment_context(\metastore\Partition $new_part, \metastore\EnvironmentContext $environment_context); public function add_partitions($new_parts); + public function add_partitions_pspec($new_parts); public function append_partition($db_name, $tbl_name, $part_vals); public function add_partitions_req(\metastore\AddPartitionsRequest $request); public function append_partition_with_environment_context($db_name, $tbl_name, $part_vals, \metastore\EnvironmentContext $environment_context); @@ -60,11 +61,13 @@ public function get_partition_by_name($db_name, $tbl_name, $part_name); public function get_partitions($db_name, $tbl_name, $max_parts); public function get_partitions_with_auth($db_name, $tbl_name, $max_parts, $user_name, $group_names); + public function get_partitions_pspec($db_name, $tbl_name, $max_parts); public function get_partition_names($db_name, $tbl_name, $max_parts); public function get_partitions_ps($db_name, $tbl_name, $part_vals, $max_parts); public function get_partitions_ps_with_auth($db_name, $tbl_name, $part_vals, $max_parts, $user_name, $group_names); public function get_partition_names_ps($db_name, $tbl_name, $part_vals, $max_parts); public function get_partitions_by_filter($db_name, $tbl_name, $filter, $max_parts); + public function get_part_specs_by_filter($db_name, $tbl_name, $filter, $max_parts); public function get_partitions_by_expr(\metastore\PartitionsByExprRequest $req); public function get_partitions_by_names($db_name, $tbl_name, $names); public function alter_partition($db_name, $tbl_name, \metastore\Partition $new_part); @@ -1744,6 +1747,66 @@ throw new \Exception("add_partitions failed: unknown result"); } + public function add_partitions_pspec($new_parts) + { + $this->send_add_partitions_pspec($new_parts); + return $this->recv_add_partitions_pspec(); + } + + public function send_add_partitions_pspec($new_parts) + { + $args = new \metastore\ThriftHiveMetastore_add_partitions_pspec_args(); + $args->new_parts = $new_parts; + $bin_accel = ($this->output_ instanceof TProtocol::$TBINARYPROTOCOLACCELERATED) && function_exists('thrift_protocol_write_binary'); + if ($bin_accel) + { + thrift_protocol_write_binary($this->output_, 'add_partitions_pspec', TMessageType::CALL, $args, $this->seqid_, $this->output_->isStrictWrite()); + } + else + { + $this->output_->writeMessageBegin('add_partitions_pspec', TMessageType::CALL, $this->seqid_); + $args->write($this->output_); + $this->output_->writeMessageEnd(); + $this->output_->getTransport()->flush(); + } + } + + public function recv_add_partitions_pspec() + { + $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_add_partitions_pspec_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_add_partitions_pspec_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; + } + throw new \Exception("add_partitions_pspec failed: unknown result"); + } + public function append_partition($db_name, $tbl_name, $part_vals) { $this->send_append_partition($db_name, $tbl_name, $part_vals); @@ -2719,6 +2782,65 @@ throw new \Exception("get_partitions_with_auth failed: unknown result"); } + public function get_partitions_pspec($db_name, $tbl_name, $max_parts) + { + $this->send_get_partitions_pspec($db_name, $tbl_name, $max_parts); + return $this->recv_get_partitions_pspec(); + } + + public function send_get_partitions_pspec($db_name, $tbl_name, $max_parts) + { + $args = new \metastore\ThriftHiveMetastore_get_partitions_pspec_args(); + $args->db_name = $db_name; + $args->tbl_name = $tbl_name; + $args->max_parts = $max_parts; + $bin_accel = ($this->output_ instanceof TProtocol::$TBINARYPROTOCOLACCELERATED) && function_exists('thrift_protocol_write_binary'); + if ($bin_accel) + { + thrift_protocol_write_binary($this->output_, 'get_partitions_pspec', TMessageType::CALL, $args, $this->seqid_, $this->output_->isStrictWrite()); + } + else + { + $this->output_->writeMessageBegin('get_partitions_pspec', TMessageType::CALL, $this->seqid_); + $args->write($this->output_); + $this->output_->writeMessageEnd(); + $this->output_->getTransport()->flush(); + } + } + + public function recv_get_partitions_pspec() + { + $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_get_partitions_pspec_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_get_partitions_pspec_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; + } + throw new \Exception("get_partitions_pspec failed: unknown result"); + } + public function get_partition_names($db_name, $tbl_name, $max_parts) { $this->send_get_partition_names($db_name, $tbl_name, $max_parts); @@ -3017,6 +3139,66 @@ throw new \Exception("get_partitions_by_filter failed: unknown result"); } + public function get_part_specs_by_filter($db_name, $tbl_name, $filter, $max_parts) + { + $this->send_get_part_specs_by_filter($db_name, $tbl_name, $filter, $max_parts); + return $this->recv_get_part_specs_by_filter(); + } + + public function send_get_part_specs_by_filter($db_name, $tbl_name, $filter, $max_parts) + { + $args = new \metastore\ThriftHiveMetastore_get_part_specs_by_filter_args(); + $args->db_name = $db_name; + $args->tbl_name = $tbl_name; + $args->filter = $filter; + $args->max_parts = $max_parts; + $bin_accel = ($this->output_ instanceof TProtocol::$TBINARYPROTOCOLACCELERATED) && function_exists('thrift_protocol_write_binary'); + if ($bin_accel) + { + thrift_protocol_write_binary($this->output_, 'get_part_specs_by_filter', TMessageType::CALL, $args, $this->seqid_, $this->output_->isStrictWrite()); + } + else + { + $this->output_->writeMessageBegin('get_part_specs_by_filter', TMessageType::CALL, $this->seqid_); + $args->write($this->output_); + $this->output_->writeMessageEnd(); + $this->output_->getTransport()->flush(); + } + } + + public function recv_get_part_specs_by_filter() + { + $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_get_part_specs_by_filter_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_get_part_specs_by_filter_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; + } + throw new \Exception("get_part_specs_by_filter failed: unknown result"); + } + public function get_partitions_by_expr(\metastore\PartitionsByExprRequest $req) { $this->send_get_partitions_by_expr($req); @@ -7662,14 +7844,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size400 = 0; - $_etype403 = 0; - $xfer += $input->readListBegin($_etype403, $_size400); - for ($_i404 = 0; $_i404 < $_size400; ++$_i404) + $_size430 = 0; + $_etype433 = 0; + $xfer += $input->readListBegin($_etype433, $_size430); + for ($_i434 = 0; $_i434 < $_size430; ++$_i434) { - $elem405 = null; - $xfer += $input->readString($elem405); - $this->success []= $elem405; + $elem435 = null; + $xfer += $input->readString($elem435); + $this->success []= $elem435; } $xfer += $input->readListEnd(); } else { @@ -7705,9 +7887,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter406) + foreach ($this->success as $iter436) { - $xfer += $output->writeString($iter406); + $xfer += $output->writeString($iter436); } } $output->writeListEnd(); @@ -7832,14 +8014,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size407 = 0; - $_etype410 = 0; - $xfer += $input->readListBegin($_etype410, $_size407); - for ($_i411 = 0; $_i411 < $_size407; ++$_i411) + $_size437 = 0; + $_etype440 = 0; + $xfer += $input->readListBegin($_etype440, $_size437); + for ($_i441 = 0; $_i441 < $_size437; ++$_i441) { - $elem412 = null; - $xfer += $input->readString($elem412); - $this->success []= $elem412; + $elem442 = null; + $xfer += $input->readString($elem442); + $this->success []= $elem442; } $xfer += $input->readListEnd(); } else { @@ -7875,9 +8057,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter413) + foreach ($this->success as $iter443) { - $xfer += $output->writeString($iter413); + $xfer += $output->writeString($iter443); } } $output->writeListEnd(); @@ -8818,18 +9000,18 @@ case 0: if ($ftype == TType::MAP) { $this->success = array(); - $_size414 = 0; - $_ktype415 = 0; - $_vtype416 = 0; - $xfer += $input->readMapBegin($_ktype415, $_vtype416, $_size414); - for ($_i418 = 0; $_i418 < $_size414; ++$_i418) + $_size444 = 0; + $_ktype445 = 0; + $_vtype446 = 0; + $xfer += $input->readMapBegin($_ktype445, $_vtype446, $_size444); + for ($_i448 = 0; $_i448 < $_size444; ++$_i448) { - $key419 = ''; - $val420 = new \metastore\Type(); - $xfer += $input->readString($key419); - $val420 = new \metastore\Type(); - $xfer += $val420->read($input); - $this->success[$key419] = $val420; + $key449 = ''; + $val450 = new \metastore\Type(); + $xfer += $input->readString($key449); + $val450 = new \metastore\Type(); + $xfer += $val450->read($input); + $this->success[$key449] = $val450; } $xfer += $input->readMapEnd(); } else { @@ -8865,10 +9047,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRUCT, count($this->success)); { - foreach ($this->success as $kiter421 => $viter422) + foreach ($this->success as $kiter451 => $viter452) { - $xfer += $output->writeString($kiter421); - $xfer += $viter422->write($output); + $xfer += $output->writeString($kiter451); + $xfer += $viter452->write($output); } } $output->writeMapEnd(); @@ -9054,15 +9236,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size423 = 0; - $_etype426 = 0; - $xfer += $input->readListBegin($_etype426, $_size423); - for ($_i427 = 0; $_i427 < $_size423; ++$_i427) + $_size453 = 0; + $_etype456 = 0; + $xfer += $input->readListBegin($_etype456, $_size453); + for ($_i457 = 0; $_i457 < $_size453; ++$_i457) { - $elem428 = null; - $elem428 = new \metastore\FieldSchema(); - $xfer += $elem428->read($input); - $this->success []= $elem428; + $elem458 = null; + $elem458 = new \metastore\FieldSchema(); + $xfer += $elem458->read($input); + $this->success []= $elem458; } $xfer += $input->readListEnd(); } else { @@ -9114,9 +9296,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter429) + foreach ($this->success as $iter459) { - $xfer += $iter429->write($output); + $xfer += $iter459->write($output); } } $output->writeListEnd(); @@ -9312,15 +9494,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size430 = 0; - $_etype433 = 0; - $xfer += $input->readListBegin($_etype433, $_size430); - for ($_i434 = 0; $_i434 < $_size430; ++$_i434) + $_size460 = 0; + $_etype463 = 0; + $xfer += $input->readListBegin($_etype463, $_size460); + for ($_i464 = 0; $_i464 < $_size460; ++$_i464) { - $elem435 = null; - $elem435 = new \metastore\FieldSchema(); - $xfer += $elem435->read($input); - $this->success []= $elem435; + $elem465 = null; + $elem465 = new \metastore\FieldSchema(); + $xfer += $elem465->read($input); + $this->success []= $elem465; } $xfer += $input->readListEnd(); } else { @@ -9372,9 +9554,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter436) + foreach ($this->success as $iter466) { - $xfer += $iter436->write($output); + $xfer += $iter466->write($output); } } $output->writeListEnd(); @@ -10451,14 +10633,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size437 = 0; - $_etype440 = 0; - $xfer += $input->readListBegin($_etype440, $_size437); - for ($_i441 = 0; $_i441 < $_size437; ++$_i441) + $_size467 = 0; + $_etype470 = 0; + $xfer += $input->readListBegin($_etype470, $_size467); + for ($_i471 = 0; $_i471 < $_size467; ++$_i471) { - $elem442 = null; - $xfer += $input->readString($elem442); - $this->success []= $elem442; + $elem472 = null; + $xfer += $input->readString($elem472); + $this->success []= $elem472; } $xfer += $input->readListEnd(); } else { @@ -10494,9 +10676,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter443) + foreach ($this->success as $iter473) { - $xfer += $output->writeString($iter443); + $xfer += $output->writeString($iter473); } } $output->writeListEnd(); @@ -10643,14 +10825,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size444 = 0; - $_etype447 = 0; - $xfer += $input->readListBegin($_etype447, $_size444); - for ($_i448 = 0; $_i448 < $_size444; ++$_i448) + $_size474 = 0; + $_etype477 = 0; + $xfer += $input->readListBegin($_etype477, $_size474); + for ($_i478 = 0; $_i478 < $_size474; ++$_i478) { - $elem449 = null; - $xfer += $input->readString($elem449); - $this->success []= $elem449; + $elem479 = null; + $xfer += $input->readString($elem479); + $this->success []= $elem479; } $xfer += $input->readListEnd(); } else { @@ -10686,9 +10868,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter450) + foreach ($this->success as $iter480) { - $xfer += $output->writeString($iter450); + $xfer += $output->writeString($iter480); } } $output->writeListEnd(); @@ -10982,14 +11164,14 @@ case 2: if ($ftype == TType::LST) { $this->tbl_names = array(); - $_size451 = 0; - $_etype454 = 0; - $xfer += $input->readListBegin($_etype454, $_size451); - for ($_i455 = 0; $_i455 < $_size451; ++$_i455) + $_size481 = 0; + $_etype484 = 0; + $xfer += $input->readListBegin($_etype484, $_size481); + for ($_i485 = 0; $_i485 < $_size481; ++$_i485) { - $elem456 = null; - $xfer += $input->readString($elem456); - $this->tbl_names []= $elem456; + $elem486 = null; + $xfer += $input->readString($elem486); + $this->tbl_names []= $elem486; } $xfer += $input->readListEnd(); } else { @@ -11022,9 +11204,9 @@ { $output->writeListBegin(TType::STRING, count($this->tbl_names)); { - foreach ($this->tbl_names as $iter457) + foreach ($this->tbl_names as $iter487) { - $xfer += $output->writeString($iter457); + $xfer += $output->writeString($iter487); } } $output->writeListEnd(); @@ -11113,15 +11295,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size458 = 0; - $_etype461 = 0; - $xfer += $input->readListBegin($_etype461, $_size458); - for ($_i462 = 0; $_i462 < $_size458; ++$_i462) + $_size488 = 0; + $_etype491 = 0; + $xfer += $input->readListBegin($_etype491, $_size488); + for ($_i492 = 0; $_i492 < $_size488; ++$_i492) { - $elem463 = null; - $elem463 = new \metastore\Table(); - $xfer += $elem463->read($input); - $this->success []= $elem463; + $elem493 = null; + $elem493 = new \metastore\Table(); + $xfer += $elem493->read($input); + $this->success []= $elem493; } $xfer += $input->readListEnd(); } else { @@ -11173,9 +11355,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter464) + foreach ($this->success as $iter494) { - $xfer += $iter464->write($output); + $xfer += $iter494->write($output); } } $output->writeListEnd(); @@ -11390,14 +11572,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size465 = 0; - $_etype468 = 0; - $xfer += $input->readListBegin($_etype468, $_size465); - for ($_i469 = 0; $_i469 < $_size465; ++$_i469) + $_size495 = 0; + $_etype498 = 0; + $xfer += $input->readListBegin($_etype498, $_size495); + for ($_i499 = 0; $_i499 < $_size495; ++$_i499) { - $elem470 = null; - $xfer += $input->readString($elem470); - $this->success []= $elem470; + $elem500 = null; + $xfer += $input->readString($elem500); + $this->success []= $elem500; } $xfer += $input->readListEnd(); } else { @@ -11449,9 +11631,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter471) + foreach ($this->success as $iter501) { - $xfer += $output->writeString($iter471); + $xfer += $output->writeString($iter501); } } $output->writeListEnd(); @@ -12444,15 +12626,15 @@ case 1: if ($ftype == TType::LST) { $this->new_parts = array(); - $_size472 = 0; - $_etype475 = 0; - $xfer += $input->readListBegin($_etype475, $_size472); - for ($_i476 = 0; $_i476 < $_size472; ++$_i476) + $_size502 = 0; + $_etype505 = 0; + $xfer += $input->readListBegin($_etype505, $_size502); + for ($_i506 = 0; $_i506 < $_size502; ++$_i506) { - $elem477 = null; - $elem477 = new \metastore\Partition(); - $xfer += $elem477->read($input); - $this->new_parts []= $elem477; + $elem507 = null; + $elem507 = new \metastore\Partition(); + $xfer += $elem507->read($input); + $this->new_parts []= $elem507; } $xfer += $input->readListEnd(); } else { @@ -12480,9 +12662,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->new_parts)); { - foreach ($this->new_parts as $iter478) + foreach ($this->new_parts as $iter508) { - $xfer += $iter478->write($output); + $xfer += $iter508->write($output); } } $output->writeListEnd(); @@ -12634,6 +12816,244 @@ } +class ThriftHiveMetastore_add_partitions_pspec_args { + static $_TSPEC; + + public $new_parts = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'new_parts', + 'type' => TType::LST, + 'etype' => TType::STRUCT, + 'elem' => array( + 'type' => TType::STRUCT, + 'class' => '\metastore\PartitionSpec', + ), + ), + ); + } + if (is_array($vals)) { + if (isset($vals['new_parts'])) { + $this->new_parts = $vals['new_parts']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_add_partitions_pspec_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::LST) { + $this->new_parts = array(); + $_size509 = 0; + $_etype512 = 0; + $xfer += $input->readListBegin($_etype512, $_size509); + for ($_i513 = 0; $_i513 < $_size509; ++$_i513) + { + $elem514 = null; + $elem514 = new \metastore\PartitionSpec(); + $xfer += $elem514->read($input); + $this->new_parts []= $elem514; + } + $xfer += $input->readListEnd(); + } 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_add_partitions_pspec_args'); + if ($this->new_parts !== null) { + if (!is_array($this->new_parts)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('new_parts', TType::LST, 1); + { + $output->writeListBegin(TType::STRUCT, count($this->new_parts)); + { + foreach ($this->new_parts as $iter515) + { + $xfer += $iter515->write($output); + } + } + $output->writeListEnd(); + } + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class ThriftHiveMetastore_add_partitions_pspec_result { + static $_TSPEC; + + public $success = null; + public $o1 = null; + public $o2 = null; + public $o3 = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 0 => array( + 'var' => 'success', + 'type' => TType::I32, + ), + 1 => array( + 'var' => 'o1', + 'type' => TType::STRUCT, + 'class' => '\metastore\InvalidObjectException', + ), + 2 => array( + 'var' => 'o2', + 'type' => TType::STRUCT, + 'class' => '\metastore\AlreadyExistsException', + ), + 3 => array( + 'var' => 'o3', + 'type' => TType::STRUCT, + 'class' => '\metastore\MetaException', + ), + ); + } + 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']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_add_partitions_pspec_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::I32) { + $xfer += $input->readI32($this->success); + } else { + $xfer += $input->skip($ftype); + } + break; + case 1: + if ($ftype == TType::STRUCT) { + $this->o1 = new \metastore\InvalidObjectException(); + $xfer += $this->o1->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRUCT) { + $this->o2 = new \metastore\AlreadyExistsException(); + $xfer += $this->o2->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::STRUCT) { + $this->o3 = new \metastore\MetaException(); + $xfer += $this->o3->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_add_partitions_pspec_result'); + if ($this->success !== null) { + $xfer += $output->writeFieldBegin('success', TType::I32, 0); + $xfer += $output->writeI32($this->success); + $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(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class ThriftHiveMetastore_append_partition_args { static $_TSPEC; @@ -12711,14 +13131,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size479 = 0; - $_etype482 = 0; - $xfer += $input->readListBegin($_etype482, $_size479); - for ($_i483 = 0; $_i483 < $_size479; ++$_i483) + $_size516 = 0; + $_etype519 = 0; + $xfer += $input->readListBegin($_etype519, $_size516); + for ($_i520 = 0; $_i520 < $_size516; ++$_i520) { - $elem484 = null; - $xfer += $input->readString($elem484); - $this->part_vals []= $elem484; + $elem521 = null; + $xfer += $input->readString($elem521); + $this->part_vals []= $elem521; } $xfer += $input->readListEnd(); } else { @@ -12756,9 +13176,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter485) + foreach ($this->part_vals as $iter522) { - $xfer += $output->writeString($iter485); + $xfer += $output->writeString($iter522); } } $output->writeListEnd(); @@ -13221,14 +13641,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size486 = 0; - $_etype489 = 0; - $xfer += $input->readListBegin($_etype489, $_size486); - for ($_i490 = 0; $_i490 < $_size486; ++$_i490) + $_size523 = 0; + $_etype526 = 0; + $xfer += $input->readListBegin($_etype526, $_size523); + for ($_i527 = 0; $_i527 < $_size523; ++$_i527) { - $elem491 = null; - $xfer += $input->readString($elem491); - $this->part_vals []= $elem491; + $elem528 = null; + $xfer += $input->readString($elem528); + $this->part_vals []= $elem528; } $xfer += $input->readListEnd(); } else { @@ -13274,9 +13694,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter492) + foreach ($this->part_vals as $iter529) { - $xfer += $output->writeString($iter492); + $xfer += $output->writeString($iter529); } } $output->writeListEnd(); @@ -14061,14 +14481,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size493 = 0; - $_etype496 = 0; - $xfer += $input->readListBegin($_etype496, $_size493); - for ($_i497 = 0; $_i497 < $_size493; ++$_i497) + $_size530 = 0; + $_etype533 = 0; + $xfer += $input->readListBegin($_etype533, $_size530); + for ($_i534 = 0; $_i534 < $_size530; ++$_i534) { - $elem498 = null; - $xfer += $input->readString($elem498); - $this->part_vals []= $elem498; + $elem535 = null; + $xfer += $input->readString($elem535); + $this->part_vals []= $elem535; } $xfer += $input->readListEnd(); } else { @@ -14113,9 +14533,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter499) + foreach ($this->part_vals as $iter536) { - $xfer += $output->writeString($iter499); + $xfer += $output->writeString($iter536); } } $output->writeListEnd(); @@ -14344,14 +14764,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size500 = 0; - $_etype503 = 0; - $xfer += $input->readListBegin($_etype503, $_size500); - for ($_i504 = 0; $_i504 < $_size500; ++$_i504) + $_size537 = 0; + $_etype540 = 0; + $xfer += $input->readListBegin($_etype540, $_size537); + for ($_i541 = 0; $_i541 < $_size537; ++$_i541) { - $elem505 = null; - $xfer += $input->readString($elem505); - $this->part_vals []= $elem505; + $elem542 = null; + $xfer += $input->readString($elem542); + $this->part_vals []= $elem542; } $xfer += $input->readListEnd(); } else { @@ -14404,9 +14824,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter506) + foreach ($this->part_vals as $iter543) { - $xfer += $output->writeString($iter506); + $xfer += $output->writeString($iter543); } } $output->writeListEnd(); @@ -15345,14 +15765,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size507 = 0; - $_etype510 = 0; - $xfer += $input->readListBegin($_etype510, $_size507); - for ($_i511 = 0; $_i511 < $_size507; ++$_i511) + $_size544 = 0; + $_etype547 = 0; + $xfer += $input->readListBegin($_etype547, $_size544); + for ($_i548 = 0; $_i548 < $_size544; ++$_i548) { - $elem512 = null; - $xfer += $input->readString($elem512); - $this->part_vals []= $elem512; + $elem549 = null; + $xfer += $input->readString($elem549); + $this->part_vals []= $elem549; } $xfer += $input->readListEnd(); } else { @@ -15390,9 +15810,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter513) + foreach ($this->part_vals as $iter550) { - $xfer += $output->writeString($iter513); + $xfer += $output->writeString($iter550); } } $output->writeListEnd(); @@ -15610,17 +16030,17 @@ case 1: if ($ftype == TType::MAP) { $this->partitionSpecs = array(); - $_size514 = 0; - $_ktype515 = 0; - $_vtype516 = 0; - $xfer += $input->readMapBegin($_ktype515, $_vtype516, $_size514); - for ($_i518 = 0; $_i518 < $_size514; ++$_i518) + $_size551 = 0; + $_ktype552 = 0; + $_vtype553 = 0; + $xfer += $input->readMapBegin($_ktype552, $_vtype553, $_size551); + for ($_i555 = 0; $_i555 < $_size551; ++$_i555) { - $key519 = ''; - $val520 = ''; - $xfer += $input->readString($key519); - $xfer += $input->readString($val520); - $this->partitionSpecs[$key519] = $val520; + $key556 = ''; + $val557 = ''; + $xfer += $input->readString($key556); + $xfer += $input->readString($val557); + $this->partitionSpecs[$key556] = $val557; } $xfer += $input->readMapEnd(); } else { @@ -15676,10 +16096,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->partitionSpecs)); { - foreach ($this->partitionSpecs as $kiter521 => $viter522) + foreach ($this->partitionSpecs as $kiter558 => $viter559) { - $xfer += $output->writeString($kiter521); - $xfer += $output->writeString($viter522); + $xfer += $output->writeString($kiter558); + $xfer += $output->writeString($viter559); } } $output->writeMapEnd(); @@ -15975,14 +16395,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size523 = 0; - $_etype526 = 0; - $xfer += $input->readListBegin($_etype526, $_size523); - for ($_i527 = 0; $_i527 < $_size523; ++$_i527) + $_size560 = 0; + $_etype563 = 0; + $xfer += $input->readListBegin($_etype563, $_size560); + for ($_i564 = 0; $_i564 < $_size560; ++$_i564) { - $elem528 = null; - $xfer += $input->readString($elem528); - $this->part_vals []= $elem528; + $elem565 = null; + $xfer += $input->readString($elem565); + $this->part_vals []= $elem565; } $xfer += $input->readListEnd(); } else { @@ -15999,14 +16419,14 @@ case 5: if ($ftype == TType::LST) { $this->group_names = array(); - $_size529 = 0; - $_etype532 = 0; - $xfer += $input->readListBegin($_etype532, $_size529); - for ($_i533 = 0; $_i533 < $_size529; ++$_i533) + $_size566 = 0; + $_etype569 = 0; + $xfer += $input->readListBegin($_etype569, $_size566); + for ($_i570 = 0; $_i570 < $_size566; ++$_i570) { - $elem534 = null; - $xfer += $input->readString($elem534); - $this->group_names []= $elem534; + $elem571 = null; + $xfer += $input->readString($elem571); + $this->group_names []= $elem571; } $xfer += $input->readListEnd(); } else { @@ -16044,9 +16464,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter535) + foreach ($this->part_vals as $iter572) { - $xfer += $output->writeString($iter535); + $xfer += $output->writeString($iter572); } } $output->writeListEnd(); @@ -16066,9 +16486,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter536) + foreach ($this->group_names as $iter573) { - $xfer += $output->writeString($iter536); + $xfer += $output->writeString($iter573); } } $output->writeListEnd(); @@ -16614,15 +17034,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size537 = 0; - $_etype540 = 0; - $xfer += $input->readListBegin($_etype540, $_size537); - for ($_i541 = 0; $_i541 < $_size537; ++$_i541) + $_size574 = 0; + $_etype577 = 0; + $xfer += $input->readListBegin($_etype577, $_size574); + for ($_i578 = 0; $_i578 < $_size574; ++$_i578) { - $elem542 = null; - $elem542 = new \metastore\Partition(); - $xfer += $elem542->read($input); - $this->success []= $elem542; + $elem579 = null; + $elem579 = new \metastore\Partition(); + $xfer += $elem579->read($input); + $this->success []= $elem579; } $xfer += $input->readListEnd(); } else { @@ -16666,9 +17086,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter543) + foreach ($this->success as $iter580) { - $xfer += $iter543->write($output); + $xfer += $iter580->write($output); } } $output->writeListEnd(); @@ -16799,14 +17219,14 @@ case 5: if ($ftype == TType::LST) { $this->group_names = array(); - $_size544 = 0; - $_etype547 = 0; - $xfer += $input->readListBegin($_etype547, $_size544); - for ($_i548 = 0; $_i548 < $_size544; ++$_i548) + $_size581 = 0; + $_etype584 = 0; + $xfer += $input->readListBegin($_etype584, $_size581); + for ($_i585 = 0; $_i585 < $_size581; ++$_i585) { - $elem549 = null; - $xfer += $input->readString($elem549); - $this->group_names []= $elem549; + $elem586 = null; + $xfer += $input->readString($elem586); + $this->group_names []= $elem586; } $xfer += $input->readListEnd(); } else { @@ -16854,9 +17274,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter550) + foreach ($this->group_names as $iter587) { - $xfer += $output->writeString($iter550); + $xfer += $output->writeString($iter587); } } $output->writeListEnd(); @@ -16936,15 +17356,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size551 = 0; - $_etype554 = 0; - $xfer += $input->readListBegin($_etype554, $_size551); - for ($_i555 = 0; $_i555 < $_size551; ++$_i555) + $_size588 = 0; + $_etype591 = 0; + $xfer += $input->readListBegin($_etype591, $_size588); + for ($_i592 = 0; $_i592 < $_size588; ++$_i592) { - $elem556 = null; - $elem556 = new \metastore\Partition(); - $xfer += $elem556->read($input); - $this->success []= $elem556; + $elem593 = null; + $elem593 = new \metastore\Partition(); + $xfer += $elem593->read($input); + $this->success []= $elem593; } $xfer += $input->readListEnd(); } else { @@ -16988,9 +17408,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter557) + foreach ($this->success as $iter594) { - $xfer += $iter557->write($output); + $xfer += $iter594->write($output); } } $output->writeListEnd(); @@ -17014,6 +17434,262 @@ } +class ThriftHiveMetastore_get_partitions_pspec_args { + static $_TSPEC; + + public $db_name = null; + public $tbl_name = null; + public $max_parts = -1; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'db_name', + 'type' => TType::STRING, + ), + 2 => array( + 'var' => 'tbl_name', + 'type' => TType::STRING, + ), + 3 => array( + 'var' => 'max_parts', + 'type' => TType::I32, + ), + ); + } + if (is_array($vals)) { + if (isset($vals['db_name'])) { + $this->db_name = $vals['db_name']; + } + if (isset($vals['tbl_name'])) { + $this->tbl_name = $vals['tbl_name']; + } + if (isset($vals['max_parts'])) { + $this->max_parts = $vals['max_parts']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_get_partitions_pspec_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::STRING) { + $xfer += $input->readString($this->db_name); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->tbl_name); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::I32) { + $xfer += $input->readI32($this->max_parts); + } 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_get_partitions_pspec_args'); + if ($this->db_name !== null) { + $xfer += $output->writeFieldBegin('db_name', TType::STRING, 1); + $xfer += $output->writeString($this->db_name); + $xfer += $output->writeFieldEnd(); + } + if ($this->tbl_name !== null) { + $xfer += $output->writeFieldBegin('tbl_name', TType::STRING, 2); + $xfer += $output->writeString($this->tbl_name); + $xfer += $output->writeFieldEnd(); + } + if ($this->max_parts !== null) { + $xfer += $output->writeFieldBegin('max_parts', TType::I32, 3); + $xfer += $output->writeI32($this->max_parts); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class ThriftHiveMetastore_get_partitions_pspec_result { + static $_TSPEC; + + public $success = null; + public $o1 = null; + public $o2 = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 0 => array( + 'var' => 'success', + 'type' => TType::LST, + 'etype' => TType::STRUCT, + 'elem' => array( + 'type' => TType::STRUCT, + 'class' => '\metastore\PartitionSpec', + ), + ), + 1 => array( + 'var' => 'o1', + 'type' => TType::STRUCT, + 'class' => '\metastore\NoSuchObjectException', + ), + 2 => array( + 'var' => 'o2', + 'type' => TType::STRUCT, + 'class' => '\metastore\MetaException', + ), + ); + } + 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']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_get_partitions_pspec_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::LST) { + $this->success = array(); + $_size595 = 0; + $_etype598 = 0; + $xfer += $input->readListBegin($_etype598, $_size595); + for ($_i599 = 0; $_i599 < $_size595; ++$_i599) + { + $elem600 = null; + $elem600 = new \metastore\PartitionSpec(); + $xfer += $elem600->read($input); + $this->success []= $elem600; + } + $xfer += $input->readListEnd(); + } else { + $xfer += $input->skip($ftype); + } + break; + case 1: + if ($ftype == TType::STRUCT) { + $this->o1 = new \metastore\NoSuchObjectException(); + $xfer += $this->o1->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRUCT) { + $this->o2 = new \metastore\MetaException(); + $xfer += $this->o2->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_get_partitions_pspec_result'); + if ($this->success !== null) { + if (!is_array($this->success)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('success', TType::LST, 0); + { + $output->writeListBegin(TType::STRUCT, count($this->success)); + { + foreach ($this->success as $iter601) + { + $xfer += $iter601->write($output); + } + } + $output->writeListEnd(); + } + $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(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class ThriftHiveMetastore_get_partition_names_args { static $_TSPEC; @@ -17182,14 +17858,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size558 = 0; - $_etype561 = 0; - $xfer += $input->readListBegin($_etype561, $_size558); - for ($_i562 = 0; $_i562 < $_size558; ++$_i562) + $_size602 = 0; + $_etype605 = 0; + $xfer += $input->readListBegin($_etype605, $_size602); + for ($_i606 = 0; $_i606 < $_size602; ++$_i606) { - $elem563 = null; - $xfer += $input->readString($elem563); - $this->success []= $elem563; + $elem607 = null; + $xfer += $input->readString($elem607); + $this->success []= $elem607; } $xfer += $input->readListEnd(); } else { @@ -17225,9 +17901,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter564) + foreach ($this->success as $iter608) { - $xfer += $output->writeString($iter564); + $xfer += $output->writeString($iter608); } } $output->writeListEnd(); @@ -17331,14 +18007,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size565 = 0; - $_etype568 = 0; - $xfer += $input->readListBegin($_etype568, $_size565); - for ($_i569 = 0; $_i569 < $_size565; ++$_i569) + $_size609 = 0; + $_etype612 = 0; + $xfer += $input->readListBegin($_etype612, $_size609); + for ($_i613 = 0; $_i613 < $_size609; ++$_i613) { - $elem570 = null; - $xfer += $input->readString($elem570); - $this->part_vals []= $elem570; + $elem614 = null; + $xfer += $input->readString($elem614); + $this->part_vals []= $elem614; } $xfer += $input->readListEnd(); } else { @@ -17383,9 +18059,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter571) + foreach ($this->part_vals as $iter615) { - $xfer += $output->writeString($iter571); + $xfer += $output->writeString($iter615); } } $output->writeListEnd(); @@ -17470,15 +18146,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size572 = 0; - $_etype575 = 0; - $xfer += $input->readListBegin($_etype575, $_size572); - for ($_i576 = 0; $_i576 < $_size572; ++$_i576) + $_size616 = 0; + $_etype619 = 0; + $xfer += $input->readListBegin($_etype619, $_size616); + for ($_i620 = 0; $_i620 < $_size616; ++$_i620) { - $elem577 = null; - $elem577 = new \metastore\Partition(); - $xfer += $elem577->read($input); - $this->success []= $elem577; + $elem621 = null; + $elem621 = new \metastore\Partition(); + $xfer += $elem621->read($input); + $this->success []= $elem621; } $xfer += $input->readListEnd(); } else { @@ -17522,9 +18198,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter578) + foreach ($this->success as $iter622) { - $xfer += $iter578->write($output); + $xfer += $iter622->write($output); } } $output->writeListEnd(); @@ -17653,14 +18329,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size579 = 0; - $_etype582 = 0; - $xfer += $input->readListBegin($_etype582, $_size579); - for ($_i583 = 0; $_i583 < $_size579; ++$_i583) + $_size623 = 0; + $_etype626 = 0; + $xfer += $input->readListBegin($_etype626, $_size623); + for ($_i627 = 0; $_i627 < $_size623; ++$_i627) { - $elem584 = null; - $xfer += $input->readString($elem584); - $this->part_vals []= $elem584; + $elem628 = null; + $xfer += $input->readString($elem628); + $this->part_vals []= $elem628; } $xfer += $input->readListEnd(); } else { @@ -17684,14 +18360,14 @@ case 6: if ($ftype == TType::LST) { $this->group_names = array(); - $_size585 = 0; - $_etype588 = 0; - $xfer += $input->readListBegin($_etype588, $_size585); - for ($_i589 = 0; $_i589 < $_size585; ++$_i589) + $_size629 = 0; + $_etype632 = 0; + $xfer += $input->readListBegin($_etype632, $_size629); + for ($_i633 = 0; $_i633 < $_size629; ++$_i633) { - $elem590 = null; - $xfer += $input->readString($elem590); - $this->group_names []= $elem590; + $elem634 = null; + $xfer += $input->readString($elem634); + $this->group_names []= $elem634; } $xfer += $input->readListEnd(); } else { @@ -17729,9 +18405,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter591) + foreach ($this->part_vals as $iter635) { - $xfer += $output->writeString($iter591); + $xfer += $output->writeString($iter635); } } $output->writeListEnd(); @@ -17756,9 +18432,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter592) + foreach ($this->group_names as $iter636) { - $xfer += $output->writeString($iter592); + $xfer += $output->writeString($iter636); } } $output->writeListEnd(); @@ -17838,15 +18514,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size593 = 0; - $_etype596 = 0; - $xfer += $input->readListBegin($_etype596, $_size593); - for ($_i597 = 0; $_i597 < $_size593; ++$_i597) + $_size637 = 0; + $_etype640 = 0; + $xfer += $input->readListBegin($_etype640, $_size637); + for ($_i641 = 0; $_i641 < $_size637; ++$_i641) { - $elem598 = null; - $elem598 = new \metastore\Partition(); - $xfer += $elem598->read($input); - $this->success []= $elem598; + $elem642 = null; + $elem642 = new \metastore\Partition(); + $xfer += $elem642->read($input); + $this->success []= $elem642; } $xfer += $input->readListEnd(); } else { @@ -17890,9 +18566,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter599) + foreach ($this->success as $iter643) { - $xfer += $iter599->write($output); + $xfer += $iter643->write($output); } } $output->writeListEnd(); @@ -18001,14 +18677,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size600 = 0; - $_etype603 = 0; - $xfer += $input->readListBegin($_etype603, $_size600); - for ($_i604 = 0; $_i604 < $_size600; ++$_i604) + $_size644 = 0; + $_etype647 = 0; + $xfer += $input->readListBegin($_etype647, $_size644); + for ($_i648 = 0; $_i648 < $_size644; ++$_i648) { - $elem605 = null; - $xfer += $input->readString($elem605); - $this->part_vals []= $elem605; + $elem649 = null; + $xfer += $input->readString($elem649); + $this->part_vals []= $elem649; } $xfer += $input->readListEnd(); } else { @@ -18053,9 +18729,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter606) + foreach ($this->part_vals as $iter650) { - $xfer += $output->writeString($iter606); + $xfer += $output->writeString($iter650); } } $output->writeListEnd(); @@ -18139,14 +18815,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size607 = 0; - $_etype610 = 0; - $xfer += $input->readListBegin($_etype610, $_size607); - for ($_i611 = 0; $_i611 < $_size607; ++$_i611) + $_size651 = 0; + $_etype654 = 0; + $xfer += $input->readListBegin($_etype654, $_size651); + for ($_i655 = 0; $_i655 < $_size651; ++$_i655) { - $elem612 = null; - $xfer += $input->readString($elem612); - $this->success []= $elem612; + $elem656 = null; + $xfer += $input->readString($elem656); + $this->success []= $elem656; } $xfer += $input->readListEnd(); } else { @@ -18190,9 +18866,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter613) + foreach ($this->success as $iter657) { - $xfer += $output->writeString($iter613); + $xfer += $output->writeString($iter657); } } $output->writeListEnd(); @@ -18414,15 +19090,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size614 = 0; - $_etype617 = 0; - $xfer += $input->readListBegin($_etype617, $_size614); - for ($_i618 = 0; $_i618 < $_size614; ++$_i618) + $_size658 = 0; + $_etype661 = 0; + $xfer += $input->readListBegin($_etype661, $_size658); + for ($_i662 = 0; $_i662 < $_size658; ++$_i662) { - $elem619 = null; - $elem619 = new \metastore\Partition(); - $xfer += $elem619->read($input); - $this->success []= $elem619; + $elem663 = null; + $elem663 = new \metastore\Partition(); + $xfer += $elem663->read($input); + $this->success []= $elem663; } $xfer += $input->readListEnd(); } else { @@ -18466,9 +19142,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter620) + foreach ($this->success as $iter664) { - $xfer += $iter620->write($output); + $xfer += $iter664->write($output); } } $output->writeListEnd(); @@ -18492,6 +19168,282 @@ } +class ThriftHiveMetastore_get_part_specs_by_filter_args { + static $_TSPEC; + + public $db_name = null; + public $tbl_name = null; + public $filter = null; + public $max_parts = -1; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'db_name', + 'type' => TType::STRING, + ), + 2 => array( + 'var' => 'tbl_name', + 'type' => TType::STRING, + ), + 3 => array( + 'var' => 'filter', + 'type' => TType::STRING, + ), + 4 => array( + 'var' => 'max_parts', + 'type' => TType::I32, + ), + ); + } + if (is_array($vals)) { + if (isset($vals['db_name'])) { + $this->db_name = $vals['db_name']; + } + if (isset($vals['tbl_name'])) { + $this->tbl_name = $vals['tbl_name']; + } + if (isset($vals['filter'])) { + $this->filter = $vals['filter']; + } + if (isset($vals['max_parts'])) { + $this->max_parts = $vals['max_parts']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_get_part_specs_by_filter_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::STRING) { + $xfer += $input->readString($this->db_name); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->tbl_name); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->filter); + } else { + $xfer += $input->skip($ftype); + } + break; + case 4: + if ($ftype == TType::I32) { + $xfer += $input->readI32($this->max_parts); + } 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_get_part_specs_by_filter_args'); + if ($this->db_name !== null) { + $xfer += $output->writeFieldBegin('db_name', TType::STRING, 1); + $xfer += $output->writeString($this->db_name); + $xfer += $output->writeFieldEnd(); + } + if ($this->tbl_name !== null) { + $xfer += $output->writeFieldBegin('tbl_name', TType::STRING, 2); + $xfer += $output->writeString($this->tbl_name); + $xfer += $output->writeFieldEnd(); + } + if ($this->filter !== null) { + $xfer += $output->writeFieldBegin('filter', TType::STRING, 3); + $xfer += $output->writeString($this->filter); + $xfer += $output->writeFieldEnd(); + } + if ($this->max_parts !== null) { + $xfer += $output->writeFieldBegin('max_parts', TType::I32, 4); + $xfer += $output->writeI32($this->max_parts); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class ThriftHiveMetastore_get_part_specs_by_filter_result { + static $_TSPEC; + + public $success = null; + public $o1 = null; + public $o2 = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 0 => array( + 'var' => 'success', + 'type' => TType::LST, + 'etype' => TType::STRUCT, + 'elem' => array( + 'type' => TType::STRUCT, + 'class' => '\metastore\PartitionSpec', + ), + ), + 1 => array( + 'var' => 'o1', + 'type' => TType::STRUCT, + 'class' => '\metastore\MetaException', + ), + 2 => array( + 'var' => 'o2', + 'type' => TType::STRUCT, + 'class' => '\metastore\NoSuchObjectException', + ), + ); + } + 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']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_get_part_specs_by_filter_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::LST) { + $this->success = array(); + $_size665 = 0; + $_etype668 = 0; + $xfer += $input->readListBegin($_etype668, $_size665); + for ($_i669 = 0; $_i669 < $_size665; ++$_i669) + { + $elem670 = null; + $elem670 = new \metastore\PartitionSpec(); + $xfer += $elem670->read($input); + $this->success []= $elem670; + } + $xfer += $input->readListEnd(); + } 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; + default: + $xfer += $input->skip($ftype); + break; + } + $xfer += $input->readFieldEnd(); + } + $xfer += $input->readStructEnd(); + return $xfer; + } + + public function write($output) { + $xfer = 0; + $xfer += $output->writeStructBegin('ThriftHiveMetastore_get_part_specs_by_filter_result'); + if ($this->success !== null) { + if (!is_array($this->success)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('success', TType::LST, 0); + { + $output->writeListBegin(TType::STRUCT, count($this->success)); + { + foreach ($this->success as $iter671) + { + $xfer += $iter671->write($output); + } + } + $output->writeListEnd(); + } + $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(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class ThriftHiveMetastore_get_partitions_by_expr_args { static $_TSPEC; @@ -18767,14 +19719,14 @@ case 3: if ($ftype == TType::LST) { $this->names = array(); - $_size621 = 0; - $_etype624 = 0; - $xfer += $input->readListBegin($_etype624, $_size621); - for ($_i625 = 0; $_i625 < $_size621; ++$_i625) + $_size672 = 0; + $_etype675 = 0; + $xfer += $input->readListBegin($_etype675, $_size672); + for ($_i676 = 0; $_i676 < $_size672; ++$_i676) { - $elem626 = null; - $xfer += $input->readString($elem626); - $this->names []= $elem626; + $elem677 = null; + $xfer += $input->readString($elem677); + $this->names []= $elem677; } $xfer += $input->readListEnd(); } else { @@ -18812,9 +19764,9 @@ { $output->writeListBegin(TType::STRING, count($this->names)); { - foreach ($this->names as $iter627) + foreach ($this->names as $iter678) { - $xfer += $output->writeString($iter627); + $xfer += $output->writeString($iter678); } } $output->writeListEnd(); @@ -18894,15 +19846,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size628 = 0; - $_etype631 = 0; - $xfer += $input->readListBegin($_etype631, $_size628); - for ($_i632 = 0; $_i632 < $_size628; ++$_i632) + $_size679 = 0; + $_etype682 = 0; + $xfer += $input->readListBegin($_etype682, $_size679); + for ($_i683 = 0; $_i683 < $_size679; ++$_i683) { - $elem633 = null; - $elem633 = new \metastore\Partition(); - $xfer += $elem633->read($input); - $this->success []= $elem633; + $elem684 = null; + $elem684 = new \metastore\Partition(); + $xfer += $elem684->read($input); + $this->success []= $elem684; } $xfer += $input->readListEnd(); } else { @@ -18946,9 +19898,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter634) + foreach ($this->success as $iter685) { - $xfer += $iter634->write($output); + $xfer += $iter685->write($output); } } $output->writeListEnd(); @@ -19263,15 +20215,15 @@ case 3: if ($ftype == TType::LST) { $this->new_parts = array(); - $_size635 = 0; - $_etype638 = 0; - $xfer += $input->readListBegin($_etype638, $_size635); - for ($_i639 = 0; $_i639 < $_size635; ++$_i639) + $_size686 = 0; + $_etype689 = 0; + $xfer += $input->readListBegin($_etype689, $_size686); + for ($_i690 = 0; $_i690 < $_size686; ++$_i690) { - $elem640 = null; - $elem640 = new \metastore\Partition(); - $xfer += $elem640->read($input); - $this->new_parts []= $elem640; + $elem691 = null; + $elem691 = new \metastore\Partition(); + $xfer += $elem691->read($input); + $this->new_parts []= $elem691; } $xfer += $input->readListEnd(); } else { @@ -19309,9 +20261,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->new_parts)); { - foreach ($this->new_parts as $iter641) + foreach ($this->new_parts as $iter692) { - $xfer += $iter641->write($output); + $xfer += $iter692->write($output); } } $output->writeListEnd(); @@ -19745,14 +20697,14 @@ case 3: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size642 = 0; - $_etype645 = 0; - $xfer += $input->readListBegin($_etype645, $_size642); - for ($_i646 = 0; $_i646 < $_size642; ++$_i646) + $_size693 = 0; + $_etype696 = 0; + $xfer += $input->readListBegin($_etype696, $_size693); + for ($_i697 = 0; $_i697 < $_size693; ++$_i697) { - $elem647 = null; - $xfer += $input->readString($elem647); - $this->part_vals []= $elem647; + $elem698 = null; + $xfer += $input->readString($elem698); + $this->part_vals []= $elem698; } $xfer += $input->readListEnd(); } else { @@ -19798,9 +20750,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter648) + foreach ($this->part_vals as $iter699) { - $xfer += $output->writeString($iter648); + $xfer += $output->writeString($iter699); } } $output->writeListEnd(); @@ -19973,14 +20925,14 @@ case 1: if ($ftype == TType::LST) { $this->part_vals = array(); - $_size649 = 0; - $_etype652 = 0; - $xfer += $input->readListBegin($_etype652, $_size649); - for ($_i653 = 0; $_i653 < $_size649; ++$_i653) + $_size700 = 0; + $_etype703 = 0; + $xfer += $input->readListBegin($_etype703, $_size700); + for ($_i704 = 0; $_i704 < $_size700; ++$_i704) { - $elem654 = null; - $xfer += $input->readString($elem654); - $this->part_vals []= $elem654; + $elem705 = null; + $xfer += $input->readString($elem705); + $this->part_vals []= $elem705; } $xfer += $input->readListEnd(); } else { @@ -20015,9 +20967,9 @@ { $output->writeListBegin(TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $iter655) + foreach ($this->part_vals as $iter706) { - $xfer += $output->writeString($iter655); + $xfer += $output->writeString($iter706); } } $output->writeListEnd(); @@ -20444,14 +21396,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size656 = 0; - $_etype659 = 0; - $xfer += $input->readListBegin($_etype659, $_size656); - for ($_i660 = 0; $_i660 < $_size656; ++$_i660) + $_size707 = 0; + $_etype710 = 0; + $xfer += $input->readListBegin($_etype710, $_size707); + for ($_i711 = 0; $_i711 < $_size707; ++$_i711) { - $elem661 = null; - $xfer += $input->readString($elem661); - $this->success []= $elem661; + $elem712 = null; + $xfer += $input->readString($elem712); + $this->success []= $elem712; } $xfer += $input->readListEnd(); } else { @@ -20487,9 +21439,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter662) + foreach ($this->success as $iter713) { - $xfer += $output->writeString($iter662); + $xfer += $output->writeString($iter713); } } $output->writeListEnd(); @@ -20640,17 +21592,17 @@ case 0: if ($ftype == TType::MAP) { $this->success = array(); - $_size663 = 0; - $_ktype664 = 0; - $_vtype665 = 0; - $xfer += $input->readMapBegin($_ktype664, $_vtype665, $_size663); - for ($_i667 = 0; $_i667 < $_size663; ++$_i667) + $_size714 = 0; + $_ktype715 = 0; + $_vtype716 = 0; + $xfer += $input->readMapBegin($_ktype715, $_vtype716, $_size714); + for ($_i718 = 0; $_i718 < $_size714; ++$_i718) { - $key668 = ''; - $val669 = ''; - $xfer += $input->readString($key668); - $xfer += $input->readString($val669); - $this->success[$key668] = $val669; + $key719 = ''; + $val720 = ''; + $xfer += $input->readString($key719); + $xfer += $input->readString($val720); + $this->success[$key719] = $val720; } $xfer += $input->readMapEnd(); } else { @@ -20686,10 +21638,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->success)); { - foreach ($this->success as $kiter670 => $viter671) + foreach ($this->success as $kiter721 => $viter722) { - $xfer += $output->writeString($kiter670); - $xfer += $output->writeString($viter671); + $xfer += $output->writeString($kiter721); + $xfer += $output->writeString($viter722); } } $output->writeMapEnd(); @@ -20797,17 +21749,17 @@ case 3: if ($ftype == TType::MAP) { $this->part_vals = array(); - $_size672 = 0; - $_ktype673 = 0; - $_vtype674 = 0; - $xfer += $input->readMapBegin($_ktype673, $_vtype674, $_size672); - for ($_i676 = 0; $_i676 < $_size672; ++$_i676) + $_size723 = 0; + $_ktype724 = 0; + $_vtype725 = 0; + $xfer += $input->readMapBegin($_ktype724, $_vtype725, $_size723); + for ($_i727 = 0; $_i727 < $_size723; ++$_i727) { - $key677 = ''; - $val678 = ''; - $xfer += $input->readString($key677); - $xfer += $input->readString($val678); - $this->part_vals[$key677] = $val678; + $key728 = ''; + $val729 = ''; + $xfer += $input->readString($key728); + $xfer += $input->readString($val729); + $this->part_vals[$key728] = $val729; } $xfer += $input->readMapEnd(); } else { @@ -20852,10 +21804,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $kiter679 => $viter680) + foreach ($this->part_vals as $kiter730 => $viter731) { - $xfer += $output->writeString($kiter679); - $xfer += $output->writeString($viter680); + $xfer += $output->writeString($kiter730); + $xfer += $output->writeString($viter731); } } $output->writeMapEnd(); @@ -21147,17 +22099,17 @@ case 3: if ($ftype == TType::MAP) { $this->part_vals = array(); - $_size681 = 0; - $_ktype682 = 0; - $_vtype683 = 0; - $xfer += $input->readMapBegin($_ktype682, $_vtype683, $_size681); - for ($_i685 = 0; $_i685 < $_size681; ++$_i685) + $_size732 = 0; + $_ktype733 = 0; + $_vtype734 = 0; + $xfer += $input->readMapBegin($_ktype733, $_vtype734, $_size732); + for ($_i736 = 0; $_i736 < $_size732; ++$_i736) { - $key686 = ''; - $val687 = ''; - $xfer += $input->readString($key686); - $xfer += $input->readString($val687); - $this->part_vals[$key686] = $val687; + $key737 = ''; + $val738 = ''; + $xfer += $input->readString($key737); + $xfer += $input->readString($val738); + $this->part_vals[$key737] = $val738; } $xfer += $input->readMapEnd(); } else { @@ -21202,10 +22154,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->part_vals)); { - foreach ($this->part_vals as $kiter688 => $viter689) + foreach ($this->part_vals as $kiter739 => $viter740) { - $xfer += $output->writeString($kiter688); - $xfer += $output->writeString($viter689); + $xfer += $output->writeString($kiter739); + $xfer += $output->writeString($viter740); } } $output->writeMapEnd(); @@ -22565,15 +23517,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size690 = 0; - $_etype693 = 0; - $xfer += $input->readListBegin($_etype693, $_size690); - for ($_i694 = 0; $_i694 < $_size690; ++$_i694) + $_size741 = 0; + $_etype744 = 0; + $xfer += $input->readListBegin($_etype744, $_size741); + for ($_i745 = 0; $_i745 < $_size741; ++$_i745) { - $elem695 = null; - $elem695 = new \metastore\Index(); - $xfer += $elem695->read($input); - $this->success []= $elem695; + $elem746 = null; + $elem746 = new \metastore\Index(); + $xfer += $elem746->read($input); + $this->success []= $elem746; } $xfer += $input->readListEnd(); } else { @@ -22617,9 +23569,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter696) + foreach ($this->success as $iter747) { - $xfer += $iter696->write($output); + $xfer += $iter747->write($output); } } $output->writeListEnd(); @@ -22811,14 +23763,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size697 = 0; - $_etype700 = 0; - $xfer += $input->readListBegin($_etype700, $_size697); - for ($_i701 = 0; $_i701 < $_size697; ++$_i701) + $_size748 = 0; + $_etype751 = 0; + $xfer += $input->readListBegin($_etype751, $_size748); + for ($_i752 = 0; $_i752 < $_size748; ++$_i752) { - $elem702 = null; - $xfer += $input->readString($elem702); - $this->success []= $elem702; + $elem753 = null; + $xfer += $input->readString($elem753); + $this->success []= $elem753; } $xfer += $input->readListEnd(); } else { @@ -22854,9 +23806,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter703) + foreach ($this->success as $iter754) { - $xfer += $output->writeString($iter703); + $xfer += $output->writeString($iter754); } } $output->writeListEnd(); @@ -25847,14 +26799,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size704 = 0; - $_etype707 = 0; - $xfer += $input->readListBegin($_etype707, $_size704); - for ($_i708 = 0; $_i708 < $_size704; ++$_i708) + $_size755 = 0; + $_etype758 = 0; + $xfer += $input->readListBegin($_etype758, $_size755); + for ($_i759 = 0; $_i759 < $_size755; ++$_i759) { - $elem709 = null; - $xfer += $input->readString($elem709); - $this->success []= $elem709; + $elem760 = null; + $xfer += $input->readString($elem760); + $this->success []= $elem760; } $xfer += $input->readListEnd(); } else { @@ -25890,9 +26842,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter710) + foreach ($this->success as $iter761) { - $xfer += $output->writeString($iter710); + $xfer += $output->writeString($iter761); } } $output->writeListEnd(); @@ -26567,14 +27519,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size711 = 0; - $_etype714 = 0; - $xfer += $input->readListBegin($_etype714, $_size711); - for ($_i715 = 0; $_i715 < $_size711; ++$_i715) + $_size762 = 0; + $_etype765 = 0; + $xfer += $input->readListBegin($_etype765, $_size762); + for ($_i766 = 0; $_i766 < $_size762; ++$_i766) { - $elem716 = null; - $xfer += $input->readString($elem716); - $this->success []= $elem716; + $elem767 = null; + $xfer += $input->readString($elem767); + $this->success []= $elem767; } $xfer += $input->readListEnd(); } else { @@ -26610,9 +27562,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter717) + foreach ($this->success as $iter768) { - $xfer += $output->writeString($iter717); + $xfer += $output->writeString($iter768); } } $output->writeListEnd(); @@ -27252,15 +28204,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size718 = 0; - $_etype721 = 0; - $xfer += $input->readListBegin($_etype721, $_size718); - for ($_i722 = 0; $_i722 < $_size718; ++$_i722) + $_size769 = 0; + $_etype772 = 0; + $xfer += $input->readListBegin($_etype772, $_size769); + for ($_i773 = 0; $_i773 < $_size769; ++$_i773) { - $elem723 = null; - $elem723 = new \metastore\Role(); - $xfer += $elem723->read($input); - $this->success []= $elem723; + $elem774 = null; + $elem774 = new \metastore\Role(); + $xfer += $elem774->read($input); + $this->success []= $elem774; } $xfer += $input->readListEnd(); } else { @@ -27296,9 +28248,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter724) + foreach ($this->success as $iter775) { - $xfer += $iter724->write($output); + $xfer += $iter775->write($output); } } $output->writeListEnd(); @@ -27924,14 +28876,14 @@ case 3: if ($ftype == TType::LST) { $this->group_names = array(); - $_size725 = 0; - $_etype728 = 0; - $xfer += $input->readListBegin($_etype728, $_size725); - for ($_i729 = 0; $_i729 < $_size725; ++$_i729) + $_size776 = 0; + $_etype779 = 0; + $xfer += $input->readListBegin($_etype779, $_size776); + for ($_i780 = 0; $_i780 < $_size776; ++$_i780) { - $elem730 = null; - $xfer += $input->readString($elem730); - $this->group_names []= $elem730; + $elem781 = null; + $xfer += $input->readString($elem781); + $this->group_names []= $elem781; } $xfer += $input->readListEnd(); } else { @@ -27972,9 +28924,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter731) + foreach ($this->group_names as $iter782) { - $xfer += $output->writeString($iter731); + $xfer += $output->writeString($iter782); } } $output->writeListEnd(); @@ -28261,15 +29213,15 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size732 = 0; - $_etype735 = 0; - $xfer += $input->readListBegin($_etype735, $_size732); - for ($_i736 = 0; $_i736 < $_size732; ++$_i736) + $_size783 = 0; + $_etype786 = 0; + $xfer += $input->readListBegin($_etype786, $_size783); + for ($_i787 = 0; $_i787 < $_size783; ++$_i787) { - $elem737 = null; - $elem737 = new \metastore\HiveObjectPrivilege(); - $xfer += $elem737->read($input); - $this->success []= $elem737; + $elem788 = null; + $elem788 = new \metastore\HiveObjectPrivilege(); + $xfer += $elem788->read($input); + $this->success []= $elem788; } $xfer += $input->readListEnd(); } else { @@ -28305,9 +29257,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->success)); { - foreach ($this->success as $iter738) + foreach ($this->success as $iter789) { - $xfer += $iter738->write($output); + $xfer += $iter789->write($output); } } $output->writeListEnd(); @@ -28906,14 +29858,14 @@ case 2: if ($ftype == TType::LST) { $this->group_names = array(); - $_size739 = 0; - $_etype742 = 0; - $xfer += $input->readListBegin($_etype742, $_size739); - for ($_i743 = 0; $_i743 < $_size739; ++$_i743) + $_size790 = 0; + $_etype793 = 0; + $xfer += $input->readListBegin($_etype793, $_size790); + for ($_i794 = 0; $_i794 < $_size790; ++$_i794) { - $elem744 = null; - $xfer += $input->readString($elem744); - $this->group_names []= $elem744; + $elem795 = null; + $xfer += $input->readString($elem795); + $this->group_names []= $elem795; } $xfer += $input->readListEnd(); } else { @@ -28946,9 +29898,9 @@ { $output->writeListBegin(TType::STRING, count($this->group_names)); { - foreach ($this->group_names as $iter745) + foreach ($this->group_names as $iter796) { - $xfer += $output->writeString($iter745); + $xfer += $output->writeString($iter796); } } $output->writeListEnd(); @@ -29018,14 +29970,14 @@ case 0: if ($ftype == TType::LST) { $this->success = array(); - $_size746 = 0; - $_etype749 = 0; - $xfer += $input->readListBegin($_etype749, $_size746); - for ($_i750 = 0; $_i750 < $_size746; ++$_i750) + $_size797 = 0; + $_etype800 = 0; + $xfer += $input->readListBegin($_etype800, $_size797); + for ($_i801 = 0; $_i801 < $_size797; ++$_i801) { - $elem751 = null; - $xfer += $input->readString($elem751); - $this->success []= $elem751; + $elem802 = null; + $xfer += $input->readString($elem802); + $this->success []= $elem802; } $xfer += $input->readListEnd(); } else { @@ -29061,9 +30013,9 @@ { $output->writeListBegin(TType::STRING, count($this->success)); { - foreach ($this->success as $iter752) + foreach ($this->success as $iter803) { - $xfer += $output->writeString($iter752); + $xfer += $output->writeString($iter803); } } $output->writeListEnd(); Index: metastore/src/gen/thrift/gen-php/metastore/Types.php =================================================================== --- metastore/src/gen/thrift/gen-php/metastore/Types.php (revision 1619008) +++ metastore/src/gen/thrift/gen-php/metastore/Types.php (working copy) @@ -4294,6 +4294,630 @@ } +class PartitionWithoutSD { + static $_TSPEC; + + public $values = null; + public $createTime = null; + public $lastAccessTime = null; + public $relativePath = null; + public $parameters = null; + public $privileges = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'values', + 'type' => TType::LST, + 'etype' => TType::STRING, + 'elem' => array( + 'type' => TType::STRING, + ), + ), + 2 => array( + 'var' => 'createTime', + 'type' => TType::I32, + ), + 3 => array( + 'var' => 'lastAccessTime', + 'type' => TType::I32, + ), + 4 => array( + 'var' => 'relativePath', + 'type' => TType::STRING, + ), + 5 => array( + 'var' => 'parameters', + 'type' => TType::MAP, + 'ktype' => TType::STRING, + 'vtype' => TType::STRING, + 'key' => array( + 'type' => TType::STRING, + ), + 'val' => array( + 'type' => TType::STRING, + ), + ), + 6 => array( + 'var' => 'privileges', + 'type' => TType::STRUCT, + 'class' => '\metastore\PrincipalPrivilegeSet', + ), + ); + } + if (is_array($vals)) { + if (isset($vals['values'])) { + $this->values = $vals['values']; + } + if (isset($vals['createTime'])) { + $this->createTime = $vals['createTime']; + } + if (isset($vals['lastAccessTime'])) { + $this->lastAccessTime = $vals['lastAccessTime']; + } + if (isset($vals['relativePath'])) { + $this->relativePath = $vals['relativePath']; + } + if (isset($vals['parameters'])) { + $this->parameters = $vals['parameters']; + } + if (isset($vals['privileges'])) { + $this->privileges = $vals['privileges']; + } + } + } + + public function getName() { + return 'PartitionWithoutSD'; + } + + 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::LST) { + $this->values = array(); + $_size200 = 0; + $_etype203 = 0; + $xfer += $input->readListBegin($_etype203, $_size200); + for ($_i204 = 0; $_i204 < $_size200; ++$_i204) + { + $elem205 = null; + $xfer += $input->readString($elem205); + $this->values []= $elem205; + } + $xfer += $input->readListEnd(); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::I32) { + $xfer += $input->readI32($this->createTime); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::I32) { + $xfer += $input->readI32($this->lastAccessTime); + } else { + $xfer += $input->skip($ftype); + } + break; + case 4: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->relativePath); + } else { + $xfer += $input->skip($ftype); + } + break; + case 5: + if ($ftype == TType::MAP) { + $this->parameters = array(); + $_size206 = 0; + $_ktype207 = 0; + $_vtype208 = 0; + $xfer += $input->readMapBegin($_ktype207, $_vtype208, $_size206); + for ($_i210 = 0; $_i210 < $_size206; ++$_i210) + { + $key211 = ''; + $val212 = ''; + $xfer += $input->readString($key211); + $xfer += $input->readString($val212); + $this->parameters[$key211] = $val212; + } + $xfer += $input->readMapEnd(); + } else { + $xfer += $input->skip($ftype); + } + break; + case 6: + if ($ftype == TType::STRUCT) { + $this->privileges = new \metastore\PrincipalPrivilegeSet(); + $xfer += $this->privileges->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('PartitionWithoutSD'); + if ($this->values !== null) { + if (!is_array($this->values)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('values', TType::LST, 1); + { + $output->writeListBegin(TType::STRING, count($this->values)); + { + foreach ($this->values as $iter213) + { + $xfer += $output->writeString($iter213); + } + } + $output->writeListEnd(); + } + $xfer += $output->writeFieldEnd(); + } + if ($this->createTime !== null) { + $xfer += $output->writeFieldBegin('createTime', TType::I32, 2); + $xfer += $output->writeI32($this->createTime); + $xfer += $output->writeFieldEnd(); + } + if ($this->lastAccessTime !== null) { + $xfer += $output->writeFieldBegin('lastAccessTime', TType::I32, 3); + $xfer += $output->writeI32($this->lastAccessTime); + $xfer += $output->writeFieldEnd(); + } + if ($this->relativePath !== null) { + $xfer += $output->writeFieldBegin('relativePath', TType::STRING, 4); + $xfer += $output->writeString($this->relativePath); + $xfer += $output->writeFieldEnd(); + } + if ($this->parameters !== null) { + if (!is_array($this->parameters)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('parameters', TType::MAP, 5); + { + $output->writeMapBegin(TType::STRING, TType::STRING, count($this->parameters)); + { + foreach ($this->parameters as $kiter214 => $viter215) + { + $xfer += $output->writeString($kiter214); + $xfer += $output->writeString($viter215); + } + } + $output->writeMapEnd(); + } + $xfer += $output->writeFieldEnd(); + } + if ($this->privileges !== null) { + if (!is_object($this->privileges)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('privileges', TType::STRUCT, 6); + $xfer += $this->privileges->write($output); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class PartitionSpecWithSharedSD { + static $_TSPEC; + + public $partitions = null; + public $sd = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'partitions', + 'type' => TType::LST, + 'etype' => TType::STRUCT, + 'elem' => array( + 'type' => TType::STRUCT, + 'class' => '\metastore\PartitionWithoutSD', + ), + ), + 2 => array( + 'var' => 'sd', + 'type' => TType::STRUCT, + 'class' => '\metastore\StorageDescriptor', + ), + ); + } + if (is_array($vals)) { + if (isset($vals['partitions'])) { + $this->partitions = $vals['partitions']; + } + if (isset($vals['sd'])) { + $this->sd = $vals['sd']; + } + } + } + + public function getName() { + return 'PartitionSpecWithSharedSD'; + } + + 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::LST) { + $this->partitions = array(); + $_size216 = 0; + $_etype219 = 0; + $xfer += $input->readListBegin($_etype219, $_size216); + for ($_i220 = 0; $_i220 < $_size216; ++$_i220) + { + $elem221 = null; + $elem221 = new \metastore\PartitionWithoutSD(); + $xfer += $elem221->read($input); + $this->partitions []= $elem221; + } + $xfer += $input->readListEnd(); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRUCT) { + $this->sd = new \metastore\StorageDescriptor(); + $xfer += $this->sd->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('PartitionSpecWithSharedSD'); + if ($this->partitions !== null) { + if (!is_array($this->partitions)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('partitions', TType::LST, 1); + { + $output->writeListBegin(TType::STRUCT, count($this->partitions)); + { + foreach ($this->partitions as $iter222) + { + $xfer += $iter222->write($output); + } + } + $output->writeListEnd(); + } + $xfer += $output->writeFieldEnd(); + } + if ($this->sd !== null) { + if (!is_object($this->sd)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('sd', TType::STRUCT, 2); + $xfer += $this->sd->write($output); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class PartitionListComposingSpec { + static $_TSPEC; + + public $partitions = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'partitions', + 'type' => TType::LST, + 'etype' => TType::STRUCT, + 'elem' => array( + 'type' => TType::STRUCT, + 'class' => '\metastore\Partition', + ), + ), + ); + } + if (is_array($vals)) { + if (isset($vals['partitions'])) { + $this->partitions = $vals['partitions']; + } + } + } + + public function getName() { + return 'PartitionListComposingSpec'; + } + + 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::LST) { + $this->partitions = array(); + $_size223 = 0; + $_etype226 = 0; + $xfer += $input->readListBegin($_etype226, $_size223); + for ($_i227 = 0; $_i227 < $_size223; ++$_i227) + { + $elem228 = null; + $elem228 = new \metastore\Partition(); + $xfer += $elem228->read($input); + $this->partitions []= $elem228; + } + $xfer += $input->readListEnd(); + } 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('PartitionListComposingSpec'); + if ($this->partitions !== null) { + if (!is_array($this->partitions)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('partitions', TType::LST, 1); + { + $output->writeListBegin(TType::STRUCT, count($this->partitions)); + { + foreach ($this->partitions as $iter229) + { + $xfer += $iter229->write($output); + } + } + $output->writeListEnd(); + } + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class PartitionSpec { + static $_TSPEC; + + public $dbName = null; + public $tableName = null; + public $rootPath = null; + public $sharedSDPartitionSpec = null; + public $partitionList = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'dbName', + 'type' => TType::STRING, + ), + 2 => array( + 'var' => 'tableName', + 'type' => TType::STRING, + ), + 3 => array( + 'var' => 'rootPath', + 'type' => TType::STRING, + ), + 4 => array( + 'var' => 'sharedSDPartitionSpec', + 'type' => TType::STRUCT, + 'class' => '\metastore\PartitionSpecWithSharedSD', + ), + 5 => array( + 'var' => 'partitionList', + 'type' => TType::STRUCT, + 'class' => '\metastore\PartitionListComposingSpec', + ), + ); + } + if (is_array($vals)) { + if (isset($vals['dbName'])) { + $this->dbName = $vals['dbName']; + } + if (isset($vals['tableName'])) { + $this->tableName = $vals['tableName']; + } + if (isset($vals['rootPath'])) { + $this->rootPath = $vals['rootPath']; + } + if (isset($vals['sharedSDPartitionSpec'])) { + $this->sharedSDPartitionSpec = $vals['sharedSDPartitionSpec']; + } + if (isset($vals['partitionList'])) { + $this->partitionList = $vals['partitionList']; + } + } + } + + public function getName() { + return 'PartitionSpec'; + } + + 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::STRING) { + $xfer += $input->readString($this->dbName); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->tableName); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->rootPath); + } else { + $xfer += $input->skip($ftype); + } + break; + case 4: + if ($ftype == TType::STRUCT) { + $this->sharedSDPartitionSpec = new \metastore\PartitionSpecWithSharedSD(); + $xfer += $this->sharedSDPartitionSpec->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 5: + if ($ftype == TType::STRUCT) { + $this->partitionList = new \metastore\PartitionListComposingSpec(); + $xfer += $this->partitionList->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('PartitionSpec'); + if ($this->dbName !== null) { + $xfer += $output->writeFieldBegin('dbName', TType::STRING, 1); + $xfer += $output->writeString($this->dbName); + $xfer += $output->writeFieldEnd(); + } + if ($this->tableName !== null) { + $xfer += $output->writeFieldBegin('tableName', TType::STRING, 2); + $xfer += $output->writeString($this->tableName); + $xfer += $output->writeFieldEnd(); + } + if ($this->rootPath !== null) { + $xfer += $output->writeFieldBegin('rootPath', TType::STRING, 3); + $xfer += $output->writeString($this->rootPath); + $xfer += $output->writeFieldEnd(); + } + if ($this->sharedSDPartitionSpec !== null) { + if (!is_object($this->sharedSDPartitionSpec)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('sharedSDPartitionSpec', TType::STRUCT, 4); + $xfer += $this->sharedSDPartitionSpec->write($output); + $xfer += $output->writeFieldEnd(); + } + if ($this->partitionList !== null) { + if (!is_object($this->partitionList)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('partitionList', TType::STRUCT, 5); + $xfer += $this->partitionList->write($output); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class Index { static $_TSPEC; @@ -4475,17 +5099,17 @@ case 9: if ($ftype == TType::MAP) { $this->parameters = array(); - $_size200 = 0; - $_ktype201 = 0; - $_vtype202 = 0; - $xfer += $input->readMapBegin($_ktype201, $_vtype202, $_size200); - for ($_i204 = 0; $_i204 < $_size200; ++$_i204) + $_size230 = 0; + $_ktype231 = 0; + $_vtype232 = 0; + $xfer += $input->readMapBegin($_ktype231, $_vtype232, $_size230); + for ($_i234 = 0; $_i234 < $_size230; ++$_i234) { - $key205 = ''; - $val206 = ''; - $xfer += $input->readString($key205); - $xfer += $input->readString($val206); - $this->parameters[$key205] = $val206; + $key235 = ''; + $val236 = ''; + $xfer += $input->readString($key235); + $xfer += $input->readString($val236); + $this->parameters[$key235] = $val236; } $xfer += $input->readMapEnd(); } else { @@ -4563,10 +5187,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->parameters)); { - foreach ($this->parameters as $kiter207 => $viter208) + foreach ($this->parameters as $kiter237 => $viter238) { - $xfer += $output->writeString($kiter207); - $xfer += $output->writeString($viter208); + $xfer += $output->writeString($kiter237); + $xfer += $output->writeString($viter238); } } $output->writeMapEnd(); @@ -5975,15 +6599,15 @@ case 2: if ($ftype == TType::LST) { $this->statsObj = array(); - $_size209 = 0; - $_etype212 = 0; - $xfer += $input->readListBegin($_etype212, $_size209); - for ($_i213 = 0; $_i213 < $_size209; ++$_i213) + $_size239 = 0; + $_etype242 = 0; + $xfer += $input->readListBegin($_etype242, $_size239); + for ($_i243 = 0; $_i243 < $_size239; ++$_i243) { - $elem214 = null; - $elem214 = new \metastore\ColumnStatisticsObj(); - $xfer += $elem214->read($input); - $this->statsObj []= $elem214; + $elem244 = null; + $elem244 = new \metastore\ColumnStatisticsObj(); + $xfer += $elem244->read($input); + $this->statsObj []= $elem244; } $xfer += $input->readListEnd(); } else { @@ -6019,9 +6643,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->statsObj)); { - foreach ($this->statsObj as $iter215) + foreach ($this->statsObj as $iter245) { - $xfer += $iter215->write($output); + $xfer += $iter245->write($output); } } $output->writeListEnd(); @@ -6091,15 +6715,15 @@ case 1: if ($ftype == TType::LST) { $this->colStats = array(); - $_size216 = 0; - $_etype219 = 0; - $xfer += $input->readListBegin($_etype219, $_size216); - for ($_i220 = 0; $_i220 < $_size216; ++$_i220) + $_size246 = 0; + $_etype249 = 0; + $xfer += $input->readListBegin($_etype249, $_size246); + for ($_i250 = 0; $_i250 < $_size246; ++$_i250) { - $elem221 = null; - $elem221 = new \metastore\ColumnStatisticsObj(); - $xfer += $elem221->read($input); - $this->colStats []= $elem221; + $elem251 = null; + $elem251 = new \metastore\ColumnStatisticsObj(); + $xfer += $elem251->read($input); + $this->colStats []= $elem251; } $xfer += $input->readListEnd(); } else { @@ -6134,9 +6758,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->colStats)); { - foreach ($this->colStats as $iter222) + foreach ($this->colStats as $iter252) { - $xfer += $iter222->write($output); + $xfer += $iter252->write($output); } } $output->writeListEnd(); @@ -6219,15 +6843,15 @@ case 1: if ($ftype == TType::LST) { $this->fieldSchemas = array(); - $_size223 = 0; - $_etype226 = 0; - $xfer += $input->readListBegin($_etype226, $_size223); - for ($_i227 = 0; $_i227 < $_size223; ++$_i227) + $_size253 = 0; + $_etype256 = 0; + $xfer += $input->readListBegin($_etype256, $_size253); + for ($_i257 = 0; $_i257 < $_size253; ++$_i257) { - $elem228 = null; - $elem228 = new \metastore\FieldSchema(); - $xfer += $elem228->read($input); - $this->fieldSchemas []= $elem228; + $elem258 = null; + $elem258 = new \metastore\FieldSchema(); + $xfer += $elem258->read($input); + $this->fieldSchemas []= $elem258; } $xfer += $input->readListEnd(); } else { @@ -6237,17 +6861,17 @@ case 2: if ($ftype == TType::MAP) { $this->properties = array(); - $_size229 = 0; - $_ktype230 = 0; - $_vtype231 = 0; - $xfer += $input->readMapBegin($_ktype230, $_vtype231, $_size229); - for ($_i233 = 0; $_i233 < $_size229; ++$_i233) + $_size259 = 0; + $_ktype260 = 0; + $_vtype261 = 0; + $xfer += $input->readMapBegin($_ktype260, $_vtype261, $_size259); + for ($_i263 = 0; $_i263 < $_size259; ++$_i263) { - $key234 = ''; - $val235 = ''; - $xfer += $input->readString($key234); - $xfer += $input->readString($val235); - $this->properties[$key234] = $val235; + $key264 = ''; + $val265 = ''; + $xfer += $input->readString($key264); + $xfer += $input->readString($val265); + $this->properties[$key264] = $val265; } $xfer += $input->readMapEnd(); } else { @@ -6275,9 +6899,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->fieldSchemas)); { - foreach ($this->fieldSchemas as $iter236) + foreach ($this->fieldSchemas as $iter266) { - $xfer += $iter236->write($output); + $xfer += $iter266->write($output); } } $output->writeListEnd(); @@ -6292,10 +6916,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->properties)); { - foreach ($this->properties as $kiter237 => $viter238) + foreach ($this->properties as $kiter267 => $viter268) { - $xfer += $output->writeString($kiter237); - $xfer += $output->writeString($viter238); + $xfer += $output->writeString($kiter267); + $xfer += $output->writeString($viter268); } } $output->writeMapEnd(); @@ -6360,17 +6984,17 @@ case 1: if ($ftype == TType::MAP) { $this->properties = array(); - $_size239 = 0; - $_ktype240 = 0; - $_vtype241 = 0; - $xfer += $input->readMapBegin($_ktype240, $_vtype241, $_size239); - for ($_i243 = 0; $_i243 < $_size239; ++$_i243) + $_size269 = 0; + $_ktype270 = 0; + $_vtype271 = 0; + $xfer += $input->readMapBegin($_ktype270, $_vtype271, $_size269); + for ($_i273 = 0; $_i273 < $_size269; ++$_i273) { - $key244 = ''; - $val245 = ''; - $xfer += $input->readString($key244); - $xfer += $input->readString($val245); - $this->properties[$key244] = $val245; + $key274 = ''; + $val275 = ''; + $xfer += $input->readString($key274); + $xfer += $input->readString($val275); + $this->properties[$key274] = $val275; } $xfer += $input->readMapEnd(); } else { @@ -6398,10 +7022,10 @@ { $output->writeMapBegin(TType::STRING, TType::STRING, count($this->properties)); { - foreach ($this->properties as $kiter246 => $viter247) + foreach ($this->properties as $kiter276 => $viter277) { - $xfer += $output->writeString($kiter246); - $xfer += $output->writeString($viter247); + $xfer += $output->writeString($kiter276); + $xfer += $output->writeString($viter277); } } $output->writeMapEnd(); @@ -6471,15 +7095,15 @@ case 1: if ($ftype == TType::LST) { $this->partitions = array(); - $_size248 = 0; - $_etype251 = 0; - $xfer += $input->readListBegin($_etype251, $_size248); - for ($_i252 = 0; $_i252 < $_size248; ++$_i252) + $_size278 = 0; + $_etype281 = 0; + $xfer += $input->readListBegin($_etype281, $_size278); + for ($_i282 = 0; $_i282 < $_size278; ++$_i282) { - $elem253 = null; - $elem253 = new \metastore\Partition(); - $xfer += $elem253->read($input); - $this->partitions []= $elem253; + $elem283 = null; + $elem283 = new \metastore\Partition(); + $xfer += $elem283->read($input); + $this->partitions []= $elem283; } $xfer += $input->readListEnd(); } else { @@ -6514,9 +7138,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->partitions)); { - foreach ($this->partitions as $iter254) + foreach ($this->partitions as $iter284) { - $xfer += $iter254->write($output); + $xfer += $iter284->write($output); } } $output->writeListEnd(); @@ -6735,15 +7359,15 @@ case 1: if ($ftype == TType::LST) { $this->tableStats = array(); - $_size255 = 0; - $_etype258 = 0; - $xfer += $input->readListBegin($_etype258, $_size255); - for ($_i259 = 0; $_i259 < $_size255; ++$_i259) + $_size285 = 0; + $_etype288 = 0; + $xfer += $input->readListBegin($_etype288, $_size285); + for ($_i289 = 0; $_i289 < $_size285; ++$_i289) { - $elem260 = null; - $elem260 = new \metastore\ColumnStatisticsObj(); - $xfer += $elem260->read($input); - $this->tableStats []= $elem260; + $elem290 = null; + $elem290 = new \metastore\ColumnStatisticsObj(); + $xfer += $elem290->read($input); + $this->tableStats []= $elem290; } $xfer += $input->readListEnd(); } else { @@ -6771,9 +7395,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->tableStats)); { - foreach ($this->tableStats as $iter261) + foreach ($this->tableStats as $iter291) { - $xfer += $iter261->write($output); + $xfer += $iter291->write($output); } } $output->writeListEnd(); @@ -6843,28 +7467,28 @@ case 1: if ($ftype == TType::MAP) { $this->partStats = array(); - $_size262 = 0; - $_ktype263 = 0; - $_vtype264 = 0; - $xfer += $input->readMapBegin($_ktype263, $_vtype264, $_size262); - for ($_i266 = 0; $_i266 < $_size262; ++$_i266) + $_size292 = 0; + $_ktype293 = 0; + $_vtype294 = 0; + $xfer += $input->readMapBegin($_ktype293, $_vtype294, $_size292); + for ($_i296 = 0; $_i296 < $_size292; ++$_i296) { - $key267 = ''; - $val268 = array(); - $xfer += $input->readString($key267); - $val268 = array(); - $_size269 = 0; - $_etype272 = 0; - $xfer += $input->readListBegin($_etype272, $_size269); - for ($_i273 = 0; $_i273 < $_size269; ++$_i273) + $key297 = ''; + $val298 = array(); + $xfer += $input->readString($key297); + $val298 = array(); + $_size299 = 0; + $_etype302 = 0; + $xfer += $input->readListBegin($_etype302, $_size299); + for ($_i303 = 0; $_i303 < $_size299; ++$_i303) { - $elem274 = null; - $elem274 = new \metastore\ColumnStatisticsObj(); - $xfer += $elem274->read($input); - $val268 []= $elem274; + $elem304 = null; + $elem304 = new \metastore\ColumnStatisticsObj(); + $xfer += $elem304->read($input); + $val298 []= $elem304; } $xfer += $input->readListEnd(); - $this->partStats[$key267] = $val268; + $this->partStats[$key297] = $val298; } $xfer += $input->readMapEnd(); } else { @@ -6892,15 +7516,15 @@ { $output->writeMapBegin(TType::STRING, TType::LST, count($this->partStats)); { - foreach ($this->partStats as $kiter275 => $viter276) + foreach ($this->partStats as $kiter305 => $viter306) { - $xfer += $output->writeString($kiter275); + $xfer += $output->writeString($kiter305); { - $output->writeListBegin(TType::STRUCT, count($viter276)); + $output->writeListBegin(TType::STRUCT, count($viter306)); { - foreach ($viter276 as $iter277) + foreach ($viter306 as $iter307) { - $xfer += $iter277->write($output); + $xfer += $iter307->write($output); } } $output->writeListEnd(); @@ -6995,14 +7619,14 @@ case 3: if ($ftype == TType::LST) { $this->colNames = array(); - $_size278 = 0; - $_etype281 = 0; - $xfer += $input->readListBegin($_etype281, $_size278); - for ($_i282 = 0; $_i282 < $_size278; ++$_i282) + $_size308 = 0; + $_etype311 = 0; + $xfer += $input->readListBegin($_etype311, $_size308); + for ($_i312 = 0; $_i312 < $_size308; ++$_i312) { - $elem283 = null; - $xfer += $input->readString($elem283); - $this->colNames []= $elem283; + $elem313 = null; + $xfer += $input->readString($elem313); + $this->colNames []= $elem313; } $xfer += $input->readListEnd(); } else { @@ -7040,9 +7664,9 @@ { $output->writeListBegin(TType::STRING, count($this->colNames)); { - foreach ($this->colNames as $iter284) + foreach ($this->colNames as $iter314) { - $xfer += $output->writeString($iter284); + $xfer += $output->writeString($iter314); } } $output->writeListEnd(); @@ -7145,14 +7769,14 @@ case 3: if ($ftype == TType::LST) { $this->colNames = array(); - $_size285 = 0; - $_etype288 = 0; - $xfer += $input->readListBegin($_etype288, $_size285); - for ($_i289 = 0; $_i289 < $_size285; ++$_i289) + $_size315 = 0; + $_etype318 = 0; + $xfer += $input->readListBegin($_etype318, $_size315); + for ($_i319 = 0; $_i319 < $_size315; ++$_i319) { - $elem290 = null; - $xfer += $input->readString($elem290); - $this->colNames []= $elem290; + $elem320 = null; + $xfer += $input->readString($elem320); + $this->colNames []= $elem320; } $xfer += $input->readListEnd(); } else { @@ -7162,14 +7786,14 @@ case 4: if ($ftype == TType::LST) { $this->partNames = array(); - $_size291 = 0; - $_etype294 = 0; - $xfer += $input->readListBegin($_etype294, $_size291); - for ($_i295 = 0; $_i295 < $_size291; ++$_i295) + $_size321 = 0; + $_etype324 = 0; + $xfer += $input->readListBegin($_etype324, $_size321); + for ($_i325 = 0; $_i325 < $_size321; ++$_i325) { - $elem296 = null; - $xfer += $input->readString($elem296); - $this->partNames []= $elem296; + $elem326 = null; + $xfer += $input->readString($elem326); + $this->partNames []= $elem326; } $xfer += $input->readListEnd(); } else { @@ -7207,9 +7831,9 @@ { $output->writeListBegin(TType::STRING, count($this->colNames)); { - foreach ($this->colNames as $iter297) + foreach ($this->colNames as $iter327) { - $xfer += $output->writeString($iter297); + $xfer += $output->writeString($iter327); } } $output->writeListEnd(); @@ -7224,9 +7848,9 @@ { $output->writeListBegin(TType::STRING, count($this->partNames)); { - foreach ($this->partNames as $iter298) + foreach ($this->partNames as $iter328) { - $xfer += $output->writeString($iter298); + $xfer += $output->writeString($iter328); } } $output->writeListEnd(); @@ -7288,15 +7912,15 @@ case 1: if ($ftype == TType::LST) { $this->partitions = array(); - $_size299 = 0; - $_etype302 = 0; - $xfer += $input->readListBegin($_etype302, $_size299); - for ($_i303 = 0; $_i303 < $_size299; ++$_i303) + $_size329 = 0; + $_etype332 = 0; + $xfer += $input->readListBegin($_etype332, $_size329); + for ($_i333 = 0; $_i333 < $_size329; ++$_i333) { - $elem304 = null; - $elem304 = new \metastore\Partition(); - $xfer += $elem304->read($input); - $this->partitions []= $elem304; + $elem334 = null; + $elem334 = new \metastore\Partition(); + $xfer += $elem334->read($input); + $this->partitions []= $elem334; } $xfer += $input->readListEnd(); } else { @@ -7324,9 +7948,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->partitions)); { - foreach ($this->partitions as $iter305) + foreach ($this->partitions as $iter335) { - $xfer += $iter305->write($output); + $xfer += $iter335->write($output); } } $output->writeListEnd(); @@ -7434,15 +8058,15 @@ case 3: if ($ftype == TType::LST) { $this->parts = array(); - $_size306 = 0; - $_etype309 = 0; - $xfer += $input->readListBegin($_etype309, $_size306); - for ($_i310 = 0; $_i310 < $_size306; ++$_i310) + $_size336 = 0; + $_etype339 = 0; + $xfer += $input->readListBegin($_etype339, $_size336); + for ($_i340 = 0; $_i340 < $_size336; ++$_i340) { - $elem311 = null; - $elem311 = new \metastore\Partition(); - $xfer += $elem311->read($input); - $this->parts []= $elem311; + $elem341 = null; + $elem341 = new \metastore\Partition(); + $xfer += $elem341->read($input); + $this->parts []= $elem341; } $xfer += $input->readListEnd(); } else { @@ -7494,9 +8118,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->parts)); { - foreach ($this->parts as $iter312) + foreach ($this->parts as $iter342) { - $xfer += $iter312->write($output); + $xfer += $iter342->write($output); } } $output->writeListEnd(); @@ -7568,15 +8192,15 @@ case 1: if ($ftype == TType::LST) { $this->partitions = array(); - $_size313 = 0; - $_etype316 = 0; - $xfer += $input->readListBegin($_etype316, $_size313); - for ($_i317 = 0; $_i317 < $_size313; ++$_i317) + $_size343 = 0; + $_etype346 = 0; + $xfer += $input->readListBegin($_etype346, $_size343); + for ($_i347 = 0; $_i347 < $_size343; ++$_i347) { - $elem318 = null; - $elem318 = new \metastore\Partition(); - $xfer += $elem318->read($input); - $this->partitions []= $elem318; + $elem348 = null; + $elem348 = new \metastore\Partition(); + $xfer += $elem348->read($input); + $this->partitions []= $elem348; } $xfer += $input->readListEnd(); } else { @@ -7604,9 +8228,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->partitions)); { - foreach ($this->partitions as $iter319) + foreach ($this->partitions as $iter349) { - $xfer += $iter319->write($output); + $xfer += $iter349->write($output); } } $output->writeListEnd(); @@ -7772,14 +8396,14 @@ case 1: if ($ftype == TType::LST) { $this->names = array(); - $_size320 = 0; - $_etype323 = 0; - $xfer += $input->readListBegin($_etype323, $_size320); - for ($_i324 = 0; $_i324 < $_size320; ++$_i324) + $_size350 = 0; + $_etype353 = 0; + $xfer += $input->readListBegin($_etype353, $_size350); + for ($_i354 = 0; $_i354 < $_size350; ++$_i354) { - $elem325 = null; - $xfer += $input->readString($elem325); - $this->names []= $elem325; + $elem355 = null; + $xfer += $input->readString($elem355); + $this->names []= $elem355; } $xfer += $input->readListEnd(); } else { @@ -7789,15 +8413,15 @@ case 2: if ($ftype == TType::LST) { $this->exprs = array(); - $_size326 = 0; - $_etype329 = 0; - $xfer += $input->readListBegin($_etype329, $_size326); - for ($_i330 = 0; $_i330 < $_size326; ++$_i330) + $_size356 = 0; + $_etype359 = 0; + $xfer += $input->readListBegin($_etype359, $_size356); + for ($_i360 = 0; $_i360 < $_size356; ++$_i360) { - $elem331 = null; - $elem331 = new \metastore\DropPartitionsExpr(); - $xfer += $elem331->read($input); - $this->exprs []= $elem331; + $elem361 = null; + $elem361 = new \metastore\DropPartitionsExpr(); + $xfer += $elem361->read($input); + $this->exprs []= $elem361; } $xfer += $input->readListEnd(); } else { @@ -7825,9 +8449,9 @@ { $output->writeListBegin(TType::STRING, count($this->names)); { - foreach ($this->names as $iter332) + foreach ($this->names as $iter362) { - $xfer += $output->writeString($iter332); + $xfer += $output->writeString($iter362); } } $output->writeListEnd(); @@ -7842,9 +8466,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->exprs)); { - foreach ($this->exprs as $iter333) + foreach ($this->exprs as $iter363) { - $xfer += $iter333->write($output); + $xfer += $iter363->write($output); } } $output->writeListEnd(); @@ -8325,15 +8949,15 @@ case 8: if ($ftype == TType::LST) { $this->resourceUris = array(); - $_size334 = 0; - $_etype337 = 0; - $xfer += $input->readListBegin($_etype337, $_size334); - for ($_i338 = 0; $_i338 < $_size334; ++$_i338) + $_size364 = 0; + $_etype367 = 0; + $xfer += $input->readListBegin($_etype367, $_size364); + for ($_i368 = 0; $_i368 < $_size364; ++$_i368) { - $elem339 = null; - $elem339 = new \metastore\ResourceUri(); - $xfer += $elem339->read($input); - $this->resourceUris []= $elem339; + $elem369 = null; + $elem369 = new \metastore\ResourceUri(); + $xfer += $elem369->read($input); + $this->resourceUris []= $elem369; } $xfer += $input->readListEnd(); } else { @@ -8396,9 +9020,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->resourceUris)); { - foreach ($this->resourceUris as $iter340) + foreach ($this->resourceUris as $iter370) { - $xfer += $iter340->write($output); + $xfer += $iter370->write($output); } } $output->writeListEnd(); @@ -8607,15 +9231,15 @@ case 2: if ($ftype == TType::LST) { $this->open_txns = array(); - $_size341 = 0; - $_etype344 = 0; - $xfer += $input->readListBegin($_etype344, $_size341); - for ($_i345 = 0; $_i345 < $_size341; ++$_i345) + $_size371 = 0; + $_etype374 = 0; + $xfer += $input->readListBegin($_etype374, $_size371); + for ($_i375 = 0; $_i375 < $_size371; ++$_i375) { - $elem346 = null; - $elem346 = new \metastore\TxnInfo(); - $xfer += $elem346->read($input); - $this->open_txns []= $elem346; + $elem376 = null; + $elem376 = new \metastore\TxnInfo(); + $xfer += $elem376->read($input); + $this->open_txns []= $elem376; } $xfer += $input->readListEnd(); } else { @@ -8648,9 +9272,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->open_txns)); { - foreach ($this->open_txns as $iter347) + foreach ($this->open_txns as $iter377) { - $xfer += $iter347->write($output); + $xfer += $iter377->write($output); } } $output->writeListEnd(); @@ -8726,17 +9350,17 @@ case 2: if ($ftype == TType::SET) { $this->open_txns = array(); - $_size348 = 0; - $_etype351 = 0; - $xfer += $input->readSetBegin($_etype351, $_size348); - for ($_i352 = 0; $_i352 < $_size348; ++$_i352) + $_size378 = 0; + $_etype381 = 0; + $xfer += $input->readSetBegin($_etype381, $_size378); + for ($_i382 = 0; $_i382 < $_size378; ++$_i382) { - $elem353 = null; - $xfer += $input->readI64($elem353); - if (is_scalar($elem353)) { - $this->open_txns[$elem353] = true; + $elem383 = null; + $xfer += $input->readI64($elem383); + if (is_scalar($elem383)) { + $this->open_txns[$elem383] = true; } else { - $this->open_txns []= $elem353; + $this->open_txns []= $elem383; } } $xfer += $input->readSetEnd(); @@ -8770,12 +9394,12 @@ { $output->writeSetBegin(TType::I64, count($this->open_txns)); { - foreach ($this->open_txns as $iter354 => $iter355) + foreach ($this->open_txns as $iter384 => $iter385) { - if (is_scalar($iter355)) { - $xfer += $output->writeI64($iter354); + if (is_scalar($iter385)) { + $xfer += $output->writeI64($iter384); } else { - $xfer += $output->writeI64($iter355); + $xfer += $output->writeI64($iter385); } } } @@ -8949,14 +9573,14 @@ case 1: if ($ftype == TType::LST) { $this->txn_ids = array(); - $_size356 = 0; - $_etype359 = 0; - $xfer += $input->readListBegin($_etype359, $_size356); - for ($_i360 = 0; $_i360 < $_size356; ++$_i360) + $_size386 = 0; + $_etype389 = 0; + $xfer += $input->readListBegin($_etype389, $_size386); + for ($_i390 = 0; $_i390 < $_size386; ++$_i390) { - $elem361 = null; - $xfer += $input->readI64($elem361); - $this->txn_ids []= $elem361; + $elem391 = null; + $xfer += $input->readI64($elem391); + $this->txn_ids []= $elem391; } $xfer += $input->readListEnd(); } else { @@ -8984,9 +9608,9 @@ { $output->writeListBegin(TType::I64, count($this->txn_ids)); { - foreach ($this->txn_ids as $iter362) + foreach ($this->txn_ids as $iter392) { - $xfer += $output->writeI64($iter362); + $xfer += $output->writeI64($iter392); } } $output->writeListEnd(); @@ -9368,15 +9992,15 @@ case 1: if ($ftype == TType::LST) { $this->component = array(); - $_size363 = 0; - $_etype366 = 0; - $xfer += $input->readListBegin($_etype366, $_size363); - for ($_i367 = 0; $_i367 < $_size363; ++$_i367) + $_size393 = 0; + $_etype396 = 0; + $xfer += $input->readListBegin($_etype396, $_size393); + for ($_i397 = 0; $_i397 < $_size393; ++$_i397) { - $elem368 = null; - $elem368 = new \metastore\LockComponent(); - $xfer += $elem368->read($input); - $this->component []= $elem368; + $elem398 = null; + $elem398 = new \metastore\LockComponent(); + $xfer += $elem398->read($input); + $this->component []= $elem398; } $xfer += $input->readListEnd(); } else { @@ -9425,9 +10049,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->component)); { - foreach ($this->component as $iter369) + foreach ($this->component as $iter399) { - $xfer += $iter369->write($output); + $xfer += $iter399->write($output); } } $output->writeListEnd(); @@ -10062,15 +10686,15 @@ case 1: if ($ftype == TType::LST) { $this->locks = array(); - $_size370 = 0; - $_etype373 = 0; - $xfer += $input->readListBegin($_etype373, $_size370); - for ($_i374 = 0; $_i374 < $_size370; ++$_i374) + $_size400 = 0; + $_etype403 = 0; + $xfer += $input->readListBegin($_etype403, $_size400); + for ($_i404 = 0; $_i404 < $_size400; ++$_i404) { - $elem375 = null; - $elem375 = new \metastore\ShowLocksResponseElement(); - $xfer += $elem375->read($input); - $this->locks []= $elem375; + $elem405 = null; + $elem405 = new \metastore\ShowLocksResponseElement(); + $xfer += $elem405->read($input); + $this->locks []= $elem405; } $xfer += $input->readListEnd(); } else { @@ -10098,9 +10722,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->locks)); { - foreach ($this->locks as $iter376) + foreach ($this->locks as $iter406) { - $xfer += $iter376->write($output); + $xfer += $iter406->write($output); } } $output->writeListEnd(); @@ -10357,17 +10981,17 @@ case 1: if ($ftype == TType::SET) { $this->aborted = array(); - $_size377 = 0; - $_etype380 = 0; - $xfer += $input->readSetBegin($_etype380, $_size377); - for ($_i381 = 0; $_i381 < $_size377; ++$_i381) + $_size407 = 0; + $_etype410 = 0; + $xfer += $input->readSetBegin($_etype410, $_size407); + for ($_i411 = 0; $_i411 < $_size407; ++$_i411) { - $elem382 = null; - $xfer += $input->readI64($elem382); - if (is_scalar($elem382)) { - $this->aborted[$elem382] = true; + $elem412 = null; + $xfer += $input->readI64($elem412); + if (is_scalar($elem412)) { + $this->aborted[$elem412] = true; } else { - $this->aborted []= $elem382; + $this->aborted []= $elem412; } } $xfer += $input->readSetEnd(); @@ -10378,17 +11002,17 @@ case 2: if ($ftype == TType::SET) { $this->nosuch = array(); - $_size383 = 0; - $_etype386 = 0; - $xfer += $input->readSetBegin($_etype386, $_size383); - for ($_i387 = 0; $_i387 < $_size383; ++$_i387) + $_size413 = 0; + $_etype416 = 0; + $xfer += $input->readSetBegin($_etype416, $_size413); + for ($_i417 = 0; $_i417 < $_size413; ++$_i417) { - $elem388 = null; - $xfer += $input->readI64($elem388); - if (is_scalar($elem388)) { - $this->nosuch[$elem388] = true; + $elem418 = null; + $xfer += $input->readI64($elem418); + if (is_scalar($elem418)) { + $this->nosuch[$elem418] = true; } else { - $this->nosuch []= $elem388; + $this->nosuch []= $elem418; } } $xfer += $input->readSetEnd(); @@ -10417,12 +11041,12 @@ { $output->writeSetBegin(TType::I64, count($this->aborted)); { - foreach ($this->aborted as $iter389 => $iter390) + foreach ($this->aborted as $iter419 => $iter420) { - if (is_scalar($iter390)) { - $xfer += $output->writeI64($iter389); + if (is_scalar($iter420)) { + $xfer += $output->writeI64($iter419); } else { - $xfer += $output->writeI64($iter390); + $xfer += $output->writeI64($iter420); } } } @@ -10438,12 +11062,12 @@ { $output->writeSetBegin(TType::I64, count($this->nosuch)); { - foreach ($this->nosuch as $iter391 => $iter392) + foreach ($this->nosuch as $iter421 => $iter422) { - if (is_scalar($iter392)) { - $xfer += $output->writeI64($iter391); + if (is_scalar($iter422)) { + $xfer += $output->writeI64($iter421); } else { - $xfer += $output->writeI64($iter392); + $xfer += $output->writeI64($iter422); } } } @@ -10920,15 +11544,15 @@ case 1: if ($ftype == TType::LST) { $this->compacts = array(); - $_size393 = 0; - $_etype396 = 0; - $xfer += $input->readListBegin($_etype396, $_size393); - for ($_i397 = 0; $_i397 < $_size393; ++$_i397) + $_size423 = 0; + $_etype426 = 0; + $xfer += $input->readListBegin($_etype426, $_size423); + for ($_i427 = 0; $_i427 < $_size423; ++$_i427) { - $elem398 = null; - $elem398 = new \metastore\ShowCompactResponseElement(); - $xfer += $elem398->read($input); - $this->compacts []= $elem398; + $elem428 = null; + $elem428 = new \metastore\ShowCompactResponseElement(); + $xfer += $elem428->read($input); + $this->compacts []= $elem428; } $xfer += $input->readListEnd(); } else { @@ -10956,9 +11580,9 @@ { $output->writeListBegin(TType::STRUCT, count($this->compacts)); { - foreach ($this->compacts as $iter399) + foreach ($this->compacts as $iter429) { - $xfer += $iter399->write($output); + $xfer += $iter429->write($output); } } $output->writeListEnd(); Index: metastore/if/hive_metastore.thrift =================================================================== --- metastore/if/hive_metastore.thrift (revision 1619008) +++ metastore/if/hive_metastore.thrift (working copy) @@ -273,6 +273,32 @@ 8: optional PrincipalPrivilegeSet privileges } +struct PartitionWithoutSD { + 1: list values // string value is converted to appropriate partition key type + 2: i32 createTime, + 3: i32 lastAccessTime, + 4: string relativePath, + 5: map parameters, + 6: optional PrincipalPrivilegeSet privileges +} + +struct PartitionSpecWithSharedSD { + 1: list partitions, + 2: StorageDescriptor sd, +} + +struct PartitionListComposingSpec { + 1: list partitions +} + +struct PartitionSpec { + 1: string dbName, + 2: string tableName, + 3: string rootPath, + 4: optional PartitionSpecWithSharedSD sharedSDPartitionSpec, + 5: optional PartitionListComposingSpec partitionList +} + struct Index { 1: string indexName, // unique with in the whole database namespace 2: string indexHandlerClass, // reserved @@ -789,6 +815,8 @@ 3:MetaException o3) i32 add_partitions(1:list new_parts) throws(1:InvalidObjectException o1, 2:AlreadyExistsException o2, 3:MetaException o3) + i32 add_partitions_pspec(1:list new_parts) + throws(1:InvalidObjectException o1, 2:AlreadyExistsException o2, 3:MetaException o3) Partition append_partition(1:string db_name, 2:string tbl_name, 3:list part_vals) throws (1:InvalidObjectException o1, 2:AlreadyExistsException o2, 3:MetaException o3) AddPartitionsResult add_partitions_req(1:AddPartitionsRequest request) @@ -834,6 +862,9 @@ list get_partitions_with_auth(1:string db_name, 2:string tbl_name, 3:i16 max_parts=-1, 4: string user_name, 5: list group_names) throws(1:NoSuchObjectException o1, 2:MetaException o2) + list get_partitions_pspec(1:string db_name, 2:string tbl_name, 3:i32 max_parts=-1) + throws(1:NoSuchObjectException o1, 2:MetaException o2) + list get_partition_names(1:string db_name, 2:string tbl_name, 3:i16 max_parts=-1) throws(1:MetaException o2) @@ -858,6 +889,11 @@ 3:string filter, 4:i16 max_parts=-1) throws(1:MetaException o1, 2:NoSuchObjectException o2) + // List partitions as PartitionSpec instances. + list get_part_specs_by_filter(1:string db_name 2:string tbl_name + 3:string filter, 4:i32 max_parts=-1) + throws(1:MetaException o1, 2:NoSuchObjectException o2) + // get the partitions matching the given partition filter // unlike get_partitions_by_filter, takes serialized hive expression, and with that can work // with any filter (get_partitions_by_filter only works if the filter can be pushed down to JDOQL.