You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by se...@apache.org on 2018/07/03 18:00:29 UTC
[05/10] hive git commit: HIVE-19975 : Checking writeIdList per table
may not check the commit level of a partition on a partitioned table (Sergey
Shelukhin)
http://git-wip-us.apache.org/repos/asf/hive/blob/a47a80fe/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java
index 63b88db..47ff56c 100644
--- a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java
+++ b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionSpec.java
@@ -44,10 +44,8 @@ import org.slf4j.LoggerFactory;
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 org.apache.thrift.protocol.TField CAT_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("catName", org.apache.thrift.protocol.TType.STRING, (short)6);
- private static final org.apache.thrift.protocol.TField TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("txnId", org.apache.thrift.protocol.TType.I64, (short)7);
- private static final org.apache.thrift.protocol.TField WRITE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("writeId", org.apache.thrift.protocol.TType.I64, (short)8);
- private static final org.apache.thrift.protocol.TField VALID_WRITE_ID_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("validWriteIdList", org.apache.thrift.protocol.TType.STRING, (short)9);
- private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.I32, (short)10);
+ private static final org.apache.thrift.protocol.TField WRITE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("writeId", org.apache.thrift.protocol.TType.I64, (short)7);
+ private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.BOOL, (short)8);
private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
@@ -61,10 +59,8 @@ import org.slf4j.LoggerFactory;
private PartitionSpecWithSharedSD sharedSDPartitionSpec; // optional
private PartitionListComposingSpec partitionList; // optional
private String catName; // optional
- private long txnId; // optional
private long writeId; // optional
- private String validWriteIdList; // optional
- private IsolationLevelCompliance isStatsCompliant; // optional
+ private boolean isStatsCompliant; // 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 {
@@ -74,14 +70,8 @@ import org.slf4j.LoggerFactory;
SHARED_SDPARTITION_SPEC((short)4, "sharedSDPartitionSpec"),
PARTITION_LIST((short)5, "partitionList"),
CAT_NAME((short)6, "catName"),
- TXN_ID((short)7, "txnId"),
- WRITE_ID((short)8, "writeId"),
- VALID_WRITE_ID_LIST((short)9, "validWriteIdList"),
- /**
- *
- * @see IsolationLevelCompliance
- */
- IS_STATS_COMPLIANT((short)10, "isStatsCompliant");
+ WRITE_ID((short)7, "writeId"),
+ IS_STATS_COMPLIANT((short)8, "isStatsCompliant");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
@@ -108,13 +98,9 @@ import org.slf4j.LoggerFactory;
return PARTITION_LIST;
case 6: // CAT_NAME
return CAT_NAME;
- case 7: // TXN_ID
- return TXN_ID;
- case 8: // WRITE_ID
+ case 7: // WRITE_ID
return WRITE_ID;
- case 9: // VALID_WRITE_ID_LIST
- return VALID_WRITE_ID_LIST;
- case 10: // IS_STATS_COMPLIANT
+ case 8: // IS_STATS_COMPLIANT
return IS_STATS_COMPLIANT;
default:
return null;
@@ -156,10 +142,10 @@ import org.slf4j.LoggerFactory;
}
// isset id assignments
- private static final int __TXNID_ISSET_ID = 0;
- private static final int __WRITEID_ISSET_ID = 1;
+ private static final int __WRITEID_ISSET_ID = 0;
+ private static final int __ISSTATSCOMPLIANT_ISSET_ID = 1;
private byte __isset_bitfield = 0;
- private static final _Fields optionals[] = {_Fields.SHARED_SDPARTITION_SPEC,_Fields.PARTITION_LIST,_Fields.CAT_NAME,_Fields.TXN_ID,_Fields.WRITE_ID,_Fields.VALID_WRITE_ID_LIST,_Fields.IS_STATS_COMPLIANT};
+ private static final _Fields optionals[] = {_Fields.SHARED_SDPARTITION_SPEC,_Fields.PARTITION_LIST,_Fields.CAT_NAME,_Fields.WRITE_ID,_Fields.IS_STATS_COMPLIANT};
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);
@@ -175,21 +161,15 @@ import org.slf4j.LoggerFactory;
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PartitionListComposingSpec.class)));
tmpMap.put(_Fields.CAT_NAME, new org.apache.thrift.meta_data.FieldMetaData("catName", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
- tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.WRITE_ID, new org.apache.thrift.meta_data.FieldMetaData("writeId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- tmpMap.put(_Fields.VALID_WRITE_ID_LIST, new org.apache.thrift.meta_data.FieldMetaData("validWriteIdList", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.IS_STATS_COMPLIANT, new org.apache.thrift.meta_data.FieldMetaData("isStatsCompliant", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, IsolationLevelCompliance.class)));
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PartitionSpec.class, metaDataMap);
}
public PartitionSpec() {
- this.txnId = -1L;
-
this.writeId = -1L;
}
@@ -228,14 +208,8 @@ import org.slf4j.LoggerFactory;
if (other.isSetCatName()) {
this.catName = other.catName;
}
- this.txnId = other.txnId;
this.writeId = other.writeId;
- if (other.isSetValidWriteIdList()) {
- this.validWriteIdList = other.validWriteIdList;
- }
- if (other.isSetIsStatsCompliant()) {
- this.isStatsCompliant = other.isStatsCompliant;
- }
+ this.isStatsCompliant = other.isStatsCompliant;
}
public PartitionSpec deepCopy() {
@@ -250,12 +224,10 @@ import org.slf4j.LoggerFactory;
this.sharedSDPartitionSpec = null;
this.partitionList = null;
this.catName = null;
- this.txnId = -1L;
-
this.writeId = -1L;
- this.validWriteIdList = null;
- this.isStatsCompliant = null;
+ setIsStatsCompliantIsSet(false);
+ this.isStatsCompliant = false;
}
public String getDbName() {
@@ -396,28 +368,6 @@ import org.slf4j.LoggerFactory;
}
}
- public long getTxnId() {
- return this.txnId;
- }
-
- public void setTxnId(long txnId) {
- this.txnId = txnId;
- setTxnIdIsSet(true);
- }
-
- public void unsetTxnId() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TXNID_ISSET_ID);
- }
-
- /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
- public boolean isSetTxnId() {
- return EncodingUtils.testBit(__isset_bitfield, __TXNID_ISSET_ID);
- }
-
- public void setTxnIdIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TXNID_ISSET_ID, value);
- }
-
public long getWriteId() {
return this.writeId;
}
@@ -440,58 +390,26 @@ import org.slf4j.LoggerFactory;
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __WRITEID_ISSET_ID, value);
}
- public String getValidWriteIdList() {
- return this.validWriteIdList;
- }
-
- public void setValidWriteIdList(String validWriteIdList) {
- this.validWriteIdList = validWriteIdList;
- }
-
- public void unsetValidWriteIdList() {
- this.validWriteIdList = null;
- }
-
- /** Returns true if field validWriteIdList is set (has been assigned a value) and false otherwise */
- public boolean isSetValidWriteIdList() {
- return this.validWriteIdList != null;
- }
-
- public void setValidWriteIdListIsSet(boolean value) {
- if (!value) {
- this.validWriteIdList = null;
- }
- }
-
- /**
- *
- * @see IsolationLevelCompliance
- */
- public IsolationLevelCompliance getIsStatsCompliant() {
+ public boolean isIsStatsCompliant() {
return this.isStatsCompliant;
}
- /**
- *
- * @see IsolationLevelCompliance
- */
- public void setIsStatsCompliant(IsolationLevelCompliance isStatsCompliant) {
+ public void setIsStatsCompliant(boolean isStatsCompliant) {
this.isStatsCompliant = isStatsCompliant;
+ setIsStatsCompliantIsSet(true);
}
public void unsetIsStatsCompliant() {
- this.isStatsCompliant = null;
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
/** Returns true if field isStatsCompliant is set (has been assigned a value) and false otherwise */
public boolean isSetIsStatsCompliant() {
- return this.isStatsCompliant != null;
+ return EncodingUtils.testBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
public void setIsStatsCompliantIsSet(boolean value) {
- if (!value) {
- this.isStatsCompliant = null;
- }
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID, value);
}
public void setFieldValue(_Fields field, Object value) {
@@ -544,14 +462,6 @@ import org.slf4j.LoggerFactory;
}
break;
- case TXN_ID:
- if (value == null) {
- unsetTxnId();
- } else {
- setTxnId((Long)value);
- }
- break;
-
case WRITE_ID:
if (value == null) {
unsetWriteId();
@@ -560,19 +470,11 @@ import org.slf4j.LoggerFactory;
}
break;
- case VALID_WRITE_ID_LIST:
- if (value == null) {
- unsetValidWriteIdList();
- } else {
- setValidWriteIdList((String)value);
- }
- break;
-
case IS_STATS_COMPLIANT:
if (value == null) {
unsetIsStatsCompliant();
} else {
- setIsStatsCompliant((IsolationLevelCompliance)value);
+ setIsStatsCompliant((Boolean)value);
}
break;
@@ -599,17 +501,11 @@ import org.slf4j.LoggerFactory;
case CAT_NAME:
return getCatName();
- case TXN_ID:
- return getTxnId();
-
case WRITE_ID:
return getWriteId();
- case VALID_WRITE_ID_LIST:
- return getValidWriteIdList();
-
case IS_STATS_COMPLIANT:
- return getIsStatsCompliant();
+ return isIsStatsCompliant();
}
throw new IllegalStateException();
@@ -634,12 +530,8 @@ import org.slf4j.LoggerFactory;
return isSetPartitionList();
case CAT_NAME:
return isSetCatName();
- case TXN_ID:
- return isSetTxnId();
case WRITE_ID:
return isSetWriteId();
- case VALID_WRITE_ID_LIST:
- return isSetValidWriteIdList();
case IS_STATS_COMPLIANT:
return isSetIsStatsCompliant();
}
@@ -713,15 +605,6 @@ import org.slf4j.LoggerFactory;
return false;
}
- boolean this_present_txnId = true && this.isSetTxnId();
- boolean that_present_txnId = true && that.isSetTxnId();
- if (this_present_txnId || that_present_txnId) {
- if (!(this_present_txnId && that_present_txnId))
- return false;
- if (this.txnId != that.txnId)
- return false;
- }
-
boolean this_present_writeId = true && this.isSetWriteId();
boolean that_present_writeId = true && that.isSetWriteId();
if (this_present_writeId || that_present_writeId) {
@@ -731,21 +614,12 @@ import org.slf4j.LoggerFactory;
return false;
}
- boolean this_present_validWriteIdList = true && this.isSetValidWriteIdList();
- boolean that_present_validWriteIdList = true && that.isSetValidWriteIdList();
- if (this_present_validWriteIdList || that_present_validWriteIdList) {
- if (!(this_present_validWriteIdList && that_present_validWriteIdList))
- return false;
- if (!this.validWriteIdList.equals(that.validWriteIdList))
- return false;
- }
-
boolean this_present_isStatsCompliant = true && this.isSetIsStatsCompliant();
boolean that_present_isStatsCompliant = true && that.isSetIsStatsCompliant();
if (this_present_isStatsCompliant || that_present_isStatsCompliant) {
if (!(this_present_isStatsCompliant && that_present_isStatsCompliant))
return false;
- if (!this.isStatsCompliant.equals(that.isStatsCompliant))
+ if (this.isStatsCompliant != that.isStatsCompliant)
return false;
}
@@ -786,25 +660,15 @@ import org.slf4j.LoggerFactory;
if (present_catName)
list.add(catName);
- boolean present_txnId = true && (isSetTxnId());
- list.add(present_txnId);
- if (present_txnId)
- list.add(txnId);
-
boolean present_writeId = true && (isSetWriteId());
list.add(present_writeId);
if (present_writeId)
list.add(writeId);
- boolean present_validWriteIdList = true && (isSetValidWriteIdList());
- list.add(present_validWriteIdList);
- if (present_validWriteIdList)
- list.add(validWriteIdList);
-
boolean present_isStatsCompliant = true && (isSetIsStatsCompliant());
list.add(present_isStatsCompliant);
if (present_isStatsCompliant)
- list.add(isStatsCompliant.getValue());
+ list.add(isStatsCompliant);
return list.hashCode();
}
@@ -877,16 +741,6 @@ import org.slf4j.LoggerFactory;
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(other.isSetTxnId());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetTxnId()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, other.txnId);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
lastComparison = Boolean.valueOf(isSetWriteId()).compareTo(other.isSetWriteId());
if (lastComparison != 0) {
return lastComparison;
@@ -897,16 +751,6 @@ import org.slf4j.LoggerFactory;
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValidWriteIdList()).compareTo(other.isSetValidWriteIdList());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetValidWriteIdList()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.validWriteIdList, other.validWriteIdList);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
lastComparison = Boolean.valueOf(isSetIsStatsCompliant()).compareTo(other.isSetIsStatsCompliant());
if (lastComparison != 0) {
return lastComparison;
@@ -990,36 +834,16 @@ import org.slf4j.LoggerFactory;
}
first = false;
}
- if (isSetTxnId()) {
- if (!first) sb.append(", ");
- sb.append("txnId:");
- sb.append(this.txnId);
- first = false;
- }
if (isSetWriteId()) {
if (!first) sb.append(", ");
sb.append("writeId:");
sb.append(this.writeId);
first = false;
}
- if (isSetValidWriteIdList()) {
- if (!first) sb.append(", ");
- sb.append("validWriteIdList:");
- if (this.validWriteIdList == null) {
- sb.append("null");
- } else {
- sb.append(this.validWriteIdList);
- }
- first = false;
- }
if (isSetIsStatsCompliant()) {
if (!first) sb.append(", ");
sb.append("isStatsCompliant:");
- if (this.isStatsCompliant == null) {
- sb.append("null");
- } else {
- sb.append(this.isStatsCompliant);
- }
+ sb.append(this.isStatsCompliant);
first = false;
}
sb.append(")");
@@ -1123,15 +947,7 @@ import org.slf4j.LoggerFactory;
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 7: // TXN_ID
- if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
- struct.txnId = iprot.readI64();
- struct.setTxnIdIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 8: // WRITE_ID
+ case 7: // WRITE_ID
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.writeId = iprot.readI64();
struct.setWriteIdIsSet(true);
@@ -1139,17 +955,9 @@ import org.slf4j.LoggerFactory;
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 9: // VALID_WRITE_ID_LIST
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.validWriteIdList = iprot.readString();
- struct.setValidWriteIdListIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 10: // IS_STATS_COMPLIANT
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ case 8: // IS_STATS_COMPLIANT
+ if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
@@ -1204,29 +1012,15 @@ import org.slf4j.LoggerFactory;
oprot.writeFieldEnd();
}
}
- if (struct.isSetTxnId()) {
- oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
- oprot.writeI64(struct.txnId);
- oprot.writeFieldEnd();
- }
if (struct.isSetWriteId()) {
oprot.writeFieldBegin(WRITE_ID_FIELD_DESC);
oprot.writeI64(struct.writeId);
oprot.writeFieldEnd();
}
- if (struct.validWriteIdList != null) {
- if (struct.isSetValidWriteIdList()) {
- oprot.writeFieldBegin(VALID_WRITE_ID_LIST_FIELD_DESC);
- oprot.writeString(struct.validWriteIdList);
- oprot.writeFieldEnd();
- }
- }
- if (struct.isStatsCompliant != null) {
- if (struct.isSetIsStatsCompliant()) {
- oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
- oprot.writeI32(struct.isStatsCompliant.getValue());
- oprot.writeFieldEnd();
- }
+ if (struct.isSetIsStatsCompliant()) {
+ oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
+ oprot.writeBool(struct.isStatsCompliant);
+ oprot.writeFieldEnd();
}
oprot.writeFieldStop();
oprot.writeStructEnd();
@@ -1264,19 +1058,13 @@ import org.slf4j.LoggerFactory;
if (struct.isSetCatName()) {
optionals.set(5);
}
- if (struct.isSetTxnId()) {
- optionals.set(6);
- }
if (struct.isSetWriteId()) {
- optionals.set(7);
- }
- if (struct.isSetValidWriteIdList()) {
- optionals.set(8);
+ optionals.set(6);
}
if (struct.isSetIsStatsCompliant()) {
- optionals.set(9);
+ optionals.set(7);
}
- oprot.writeBitSet(optionals, 10);
+ oprot.writeBitSet(optionals, 8);
if (struct.isSetDbName()) {
oprot.writeString(struct.dbName);
}
@@ -1295,24 +1083,18 @@ import org.slf4j.LoggerFactory;
if (struct.isSetCatName()) {
oprot.writeString(struct.catName);
}
- if (struct.isSetTxnId()) {
- oprot.writeI64(struct.txnId);
- }
if (struct.isSetWriteId()) {
oprot.writeI64(struct.writeId);
}
- if (struct.isSetValidWriteIdList()) {
- oprot.writeString(struct.validWriteIdList);
- }
if (struct.isSetIsStatsCompliant()) {
- oprot.writeI32(struct.isStatsCompliant.getValue());
+ oprot.writeBool(struct.isStatsCompliant);
}
}
@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(10);
+ BitSet incoming = iprot.readBitSet(8);
if (incoming.get(0)) {
struct.dbName = iprot.readString();
struct.setDbNameIsSet(true);
@@ -1340,19 +1122,11 @@ import org.slf4j.LoggerFactory;
struct.setCatNameIsSet(true);
}
if (incoming.get(6)) {
- struct.txnId = iprot.readI64();
- struct.setTxnIdIsSet(true);
- }
- if (incoming.get(7)) {
struct.writeId = iprot.readI64();
struct.setWriteIdIsSet(true);
}
- if (incoming.get(8)) {
- struct.validWriteIdList = iprot.readString();
- struct.setValidWriteIdListIsSet(true);
- }
- if (incoming.get(9)) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ if (incoming.get(7)) {
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
}
}
http://git-wip-us.apache.org/repos/asf/hive/blob/a47a80fe/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java
index 2414399..fe6130c 100644
--- a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java
+++ b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PartitionsStatsResult.java
@@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("PartitionsStatsResult");
private static final org.apache.thrift.protocol.TField PART_STATS_FIELD_DESC = new org.apache.thrift.protocol.TField("partStats", org.apache.thrift.protocol.TType.MAP, (short)1);
- private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.I32, (short)2);
+ private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.BOOL, (short)2);
private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
@@ -48,15 +48,11 @@ import org.slf4j.LoggerFactory;
}
private Map<String,List<ColumnStatisticsObj>> partStats; // required
- private IsolationLevelCompliance isStatsCompliant; // optional
+ private boolean isStatsCompliant; // 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 {
PART_STATS((short)1, "partStats"),
- /**
- *
- * @see IsolationLevelCompliance
- */
IS_STATS_COMPLIANT((short)2, "isStatsCompliant");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
@@ -116,6 +112,8 @@ import org.slf4j.LoggerFactory;
}
// isset id assignments
+ private static final int __ISSTATSCOMPLIANT_ISSET_ID = 0;
+ private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.IS_STATS_COMPLIANT};
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
@@ -126,7 +124,7 @@ import org.slf4j.LoggerFactory;
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, ColumnStatisticsObj.class)))));
tmpMap.put(_Fields.IS_STATS_COMPLIANT, new org.apache.thrift.meta_data.FieldMetaData("isStatsCompliant", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, IsolationLevelCompliance.class)));
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PartitionsStatsResult.class, metaDataMap);
}
@@ -145,6 +143,7 @@ import org.slf4j.LoggerFactory;
* Performs a deep copy on <i>other</i>.
*/
public PartitionsStatsResult(PartitionsStatsResult other) {
+ __isset_bitfield = other.__isset_bitfield;
if (other.isSetPartStats()) {
Map<String,List<ColumnStatisticsObj>> __this__partStats = new HashMap<String,List<ColumnStatisticsObj>>(other.partStats.size());
for (Map.Entry<String, List<ColumnStatisticsObj>> other_element : other.partStats.entrySet()) {
@@ -163,9 +162,7 @@ import org.slf4j.LoggerFactory;
}
this.partStats = __this__partStats;
}
- if (other.isSetIsStatsCompliant()) {
- this.isStatsCompliant = other.isStatsCompliant;
- }
+ this.isStatsCompliant = other.isStatsCompliant;
}
public PartitionsStatsResult deepCopy() {
@@ -175,7 +172,8 @@ import org.slf4j.LoggerFactory;
@Override
public void clear() {
this.partStats = null;
- this.isStatsCompliant = null;
+ setIsStatsCompliantIsSet(false);
+ this.isStatsCompliant = false;
}
public int getPartStatsSize() {
@@ -212,35 +210,26 @@ import org.slf4j.LoggerFactory;
}
}
- /**
- *
- * @see IsolationLevelCompliance
- */
- public IsolationLevelCompliance getIsStatsCompliant() {
+ public boolean isIsStatsCompliant() {
return this.isStatsCompliant;
}
- /**
- *
- * @see IsolationLevelCompliance
- */
- public void setIsStatsCompliant(IsolationLevelCompliance isStatsCompliant) {
+ public void setIsStatsCompliant(boolean isStatsCompliant) {
this.isStatsCompliant = isStatsCompliant;
+ setIsStatsCompliantIsSet(true);
}
public void unsetIsStatsCompliant() {
- this.isStatsCompliant = null;
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
/** Returns true if field isStatsCompliant is set (has been assigned a value) and false otherwise */
public boolean isSetIsStatsCompliant() {
- return this.isStatsCompliant != null;
+ return EncodingUtils.testBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
public void setIsStatsCompliantIsSet(boolean value) {
- if (!value) {
- this.isStatsCompliant = null;
- }
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID, value);
}
public void setFieldValue(_Fields field, Object value) {
@@ -257,7 +246,7 @@ import org.slf4j.LoggerFactory;
if (value == null) {
unsetIsStatsCompliant();
} else {
- setIsStatsCompliant((IsolationLevelCompliance)value);
+ setIsStatsCompliant((Boolean)value);
}
break;
@@ -270,7 +259,7 @@ import org.slf4j.LoggerFactory;
return getPartStats();
case IS_STATS_COMPLIANT:
- return getIsStatsCompliant();
+ return isIsStatsCompliant();
}
throw new IllegalStateException();
@@ -318,7 +307,7 @@ import org.slf4j.LoggerFactory;
if (this_present_isStatsCompliant || that_present_isStatsCompliant) {
if (!(this_present_isStatsCompliant && that_present_isStatsCompliant))
return false;
- if (!this.isStatsCompliant.equals(that.isStatsCompliant))
+ if (this.isStatsCompliant != that.isStatsCompliant)
return false;
}
@@ -337,7 +326,7 @@ import org.slf4j.LoggerFactory;
boolean present_isStatsCompliant = true && (isSetIsStatsCompliant());
list.add(present_isStatsCompliant);
if (present_isStatsCompliant)
- list.add(isStatsCompliant.getValue());
+ list.add(isStatsCompliant);
return list.hashCode();
}
@@ -400,11 +389,7 @@ import org.slf4j.LoggerFactory;
if (isSetIsStatsCompliant()) {
if (!first) sb.append(", ");
sb.append("isStatsCompliant:");
- if (this.isStatsCompliant == null) {
- sb.append("null");
- } else {
- sb.append(this.isStatsCompliant);
- }
+ sb.append(this.isStatsCompliant);
first = false;
}
sb.append(")");
@@ -430,6 +415,8 @@ import org.slf4j.LoggerFactory;
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);
@@ -486,8 +473,8 @@ import org.slf4j.LoggerFactory;
}
break;
case 2: // IS_STATS_COMPLIANT
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
@@ -526,12 +513,10 @@ import org.slf4j.LoggerFactory;
}
oprot.writeFieldEnd();
}
- if (struct.isStatsCompliant != null) {
- if (struct.isSetIsStatsCompliant()) {
- oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
- oprot.writeI32(struct.isStatsCompliant.getValue());
- oprot.writeFieldEnd();
- }
+ if (struct.isSetIsStatsCompliant()) {
+ oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
+ oprot.writeBool(struct.isStatsCompliant);
+ oprot.writeFieldEnd();
}
oprot.writeFieldStop();
oprot.writeStructEnd();
@@ -570,7 +555,7 @@ import org.slf4j.LoggerFactory;
}
oprot.writeBitSet(optionals, 1);
if (struct.isSetIsStatsCompliant()) {
- oprot.writeI32(struct.isStatsCompliant.getValue());
+ oprot.writeBool(struct.isStatsCompliant);
}
}
@@ -602,7 +587,7 @@ import org.slf4j.LoggerFactory;
struct.setPartStatsIsSet(true);
BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
}
}
http://git-wip-us.apache.org/repos/asf/hive/blob/a47a80fe/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java
index 27c0528..f9d48c8 100644
--- a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java
+++ b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java
@@ -56,10 +56,8 @@ import org.slf4j.LoggerFactory;
private static final org.apache.thrift.protocol.TField CREATION_METADATA_FIELD_DESC = new org.apache.thrift.protocol.TField("creationMetadata", org.apache.thrift.protocol.TType.STRUCT, (short)16);
private static final org.apache.thrift.protocol.TField CAT_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("catName", org.apache.thrift.protocol.TType.STRING, (short)17);
private static final org.apache.thrift.protocol.TField OWNER_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("ownerType", org.apache.thrift.protocol.TType.I32, (short)18);
- private static final org.apache.thrift.protocol.TField TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("txnId", org.apache.thrift.protocol.TType.I64, (short)19);
- private static final org.apache.thrift.protocol.TField WRITE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("writeId", org.apache.thrift.protocol.TType.I64, (short)20);
- private static final org.apache.thrift.protocol.TField VALID_WRITE_ID_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("validWriteIdList", org.apache.thrift.protocol.TType.STRING, (short)21);
- private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.I32, (short)22);
+ private static final org.apache.thrift.protocol.TField WRITE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("writeId", org.apache.thrift.protocol.TType.I64, (short)19);
+ private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.BOOL, (short)20);
private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
@@ -85,10 +83,8 @@ import org.slf4j.LoggerFactory;
private CreationMetadata creationMetadata; // optional
private String catName; // optional
private PrincipalType ownerType; // optional
- private long txnId; // optional
private long writeId; // optional
- private String validWriteIdList; // optional
- private IsolationLevelCompliance isStatsCompliant; // optional
+ private boolean isStatsCompliant; // 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 {
@@ -114,14 +110,8 @@ import org.slf4j.LoggerFactory;
* @see PrincipalType
*/
OWNER_TYPE((short)18, "ownerType"),
- TXN_ID((short)19, "txnId"),
- WRITE_ID((short)20, "writeId"),
- VALID_WRITE_ID_LIST((short)21, "validWriteIdList"),
- /**
- *
- * @see IsolationLevelCompliance
- */
- IS_STATS_COMPLIANT((short)22, "isStatsCompliant");
+ WRITE_ID((short)19, "writeId"),
+ IS_STATS_COMPLIANT((short)20, "isStatsCompliant");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
@@ -172,13 +162,9 @@ import org.slf4j.LoggerFactory;
return CAT_NAME;
case 18: // OWNER_TYPE
return OWNER_TYPE;
- case 19: // TXN_ID
- return TXN_ID;
- case 20: // WRITE_ID
+ case 19: // WRITE_ID
return WRITE_ID;
- case 21: // VALID_WRITE_ID_LIST
- return VALID_WRITE_ID_LIST;
- case 22: // IS_STATS_COMPLIANT
+ case 20: // IS_STATS_COMPLIANT
return IS_STATS_COMPLIANT;
default:
return null;
@@ -225,10 +211,10 @@ import org.slf4j.LoggerFactory;
private static final int __RETENTION_ISSET_ID = 2;
private static final int __TEMPORARY_ISSET_ID = 3;
private static final int __REWRITEENABLED_ISSET_ID = 4;
- private static final int __TXNID_ISSET_ID = 5;
- private static final int __WRITEID_ISSET_ID = 6;
+ private static final int __WRITEID_ISSET_ID = 5;
+ private static final int __ISSTATSCOMPLIANT_ISSET_ID = 6;
private byte __isset_bitfield = 0;
- private static final _Fields optionals[] = {_Fields.PRIVILEGES,_Fields.TEMPORARY,_Fields.REWRITE_ENABLED,_Fields.CREATION_METADATA,_Fields.CAT_NAME,_Fields.OWNER_TYPE,_Fields.TXN_ID,_Fields.WRITE_ID,_Fields.VALID_WRITE_ID_LIST,_Fields.IS_STATS_COMPLIANT};
+ private static final _Fields optionals[] = {_Fields.PRIVILEGES,_Fields.TEMPORARY,_Fields.REWRITE_ENABLED,_Fields.CREATION_METADATA,_Fields.CAT_NAME,_Fields.OWNER_TYPE,_Fields.WRITE_ID,_Fields.IS_STATS_COMPLIANT};
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);
@@ -271,14 +257,10 @@ import org.slf4j.LoggerFactory;
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.OWNER_TYPE, new org.apache.thrift.meta_data.FieldMetaData("ownerType", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PrincipalType.class)));
- tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.WRITE_ID, new org.apache.thrift.meta_data.FieldMetaData("writeId", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
- tmpMap.put(_Fields.VALID_WRITE_ID_LIST, new org.apache.thrift.meta_data.FieldMetaData("validWriteIdList", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.IS_STATS_COMPLIANT, new org.apache.thrift.meta_data.FieldMetaData("isStatsCompliant", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, IsolationLevelCompliance.class)));
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Table.class, metaDataMap);
}
@@ -288,8 +270,6 @@ import org.slf4j.LoggerFactory;
this.ownerType = org.apache.hadoop.hive.metastore.api.PrincipalType.USER;
- this.txnId = -1L;
-
this.writeId = -1L;
}
@@ -380,14 +360,8 @@ import org.slf4j.LoggerFactory;
if (other.isSetOwnerType()) {
this.ownerType = other.ownerType;
}
- this.txnId = other.txnId;
this.writeId = other.writeId;
- if (other.isSetValidWriteIdList()) {
- this.validWriteIdList = other.validWriteIdList;
- }
- if (other.isSetIsStatsCompliant()) {
- this.isStatsCompliant = other.isStatsCompliant;
- }
+ this.isStatsCompliant = other.isStatsCompliant;
}
public Table deepCopy() {
@@ -420,12 +394,10 @@ import org.slf4j.LoggerFactory;
this.catName = null;
this.ownerType = org.apache.hadoop.hive.metastore.api.PrincipalType.USER;
- this.txnId = -1L;
-
this.writeId = -1L;
- this.validWriteIdList = null;
- this.isStatsCompliant = null;
+ setIsStatsCompliantIsSet(false);
+ this.isStatsCompliant = false;
}
public String getTableName() {
@@ -871,28 +843,6 @@ import org.slf4j.LoggerFactory;
}
}
- public long getTxnId() {
- return this.txnId;
- }
-
- public void setTxnId(long txnId) {
- this.txnId = txnId;
- setTxnIdIsSet(true);
- }
-
- public void unsetTxnId() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __TXNID_ISSET_ID);
- }
-
- /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
- public boolean isSetTxnId() {
- return EncodingUtils.testBit(__isset_bitfield, __TXNID_ISSET_ID);
- }
-
- public void setTxnIdIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __TXNID_ISSET_ID, value);
- }
-
public long getWriteId() {
return this.writeId;
}
@@ -915,58 +865,26 @@ import org.slf4j.LoggerFactory;
__isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __WRITEID_ISSET_ID, value);
}
- public String getValidWriteIdList() {
- return this.validWriteIdList;
- }
-
- public void setValidWriteIdList(String validWriteIdList) {
- this.validWriteIdList = validWriteIdList;
- }
-
- public void unsetValidWriteIdList() {
- this.validWriteIdList = null;
- }
-
- /** Returns true if field validWriteIdList is set (has been assigned a value) and false otherwise */
- public boolean isSetValidWriteIdList() {
- return this.validWriteIdList != null;
- }
-
- public void setValidWriteIdListIsSet(boolean value) {
- if (!value) {
- this.validWriteIdList = null;
- }
- }
-
- /**
- *
- * @see IsolationLevelCompliance
- */
- public IsolationLevelCompliance getIsStatsCompliant() {
+ public boolean isIsStatsCompliant() {
return this.isStatsCompliant;
}
- /**
- *
- * @see IsolationLevelCompliance
- */
- public void setIsStatsCompliant(IsolationLevelCompliance isStatsCompliant) {
+ public void setIsStatsCompliant(boolean isStatsCompliant) {
this.isStatsCompliant = isStatsCompliant;
+ setIsStatsCompliantIsSet(true);
}
public void unsetIsStatsCompliant() {
- this.isStatsCompliant = null;
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
/** Returns true if field isStatsCompliant is set (has been assigned a value) and false otherwise */
public boolean isSetIsStatsCompliant() {
- return this.isStatsCompliant != null;
+ return EncodingUtils.testBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
public void setIsStatsCompliantIsSet(boolean value) {
- if (!value) {
- this.isStatsCompliant = null;
- }
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID, value);
}
public void setFieldValue(_Fields field, Object value) {
@@ -1115,14 +1033,6 @@ import org.slf4j.LoggerFactory;
}
break;
- case TXN_ID:
- if (value == null) {
- unsetTxnId();
- } else {
- setTxnId((Long)value);
- }
- break;
-
case WRITE_ID:
if (value == null) {
unsetWriteId();
@@ -1131,19 +1041,11 @@ import org.slf4j.LoggerFactory;
}
break;
- case VALID_WRITE_ID_LIST:
- if (value == null) {
- unsetValidWriteIdList();
- } else {
- setValidWriteIdList((String)value);
- }
- break;
-
case IS_STATS_COMPLIANT:
if (value == null) {
unsetIsStatsCompliant();
} else {
- setIsStatsCompliant((IsolationLevelCompliance)value);
+ setIsStatsCompliant((Boolean)value);
}
break;
@@ -1206,17 +1108,11 @@ import org.slf4j.LoggerFactory;
case OWNER_TYPE:
return getOwnerType();
- case TXN_ID:
- return getTxnId();
-
case WRITE_ID:
return getWriteId();
- case VALID_WRITE_ID_LIST:
- return getValidWriteIdList();
-
case IS_STATS_COMPLIANT:
- return getIsStatsCompliant();
+ return isIsStatsCompliant();
}
throw new IllegalStateException();
@@ -1265,12 +1161,8 @@ import org.slf4j.LoggerFactory;
return isSetCatName();
case OWNER_TYPE:
return isSetOwnerType();
- case TXN_ID:
- return isSetTxnId();
case WRITE_ID:
return isSetWriteId();
- case VALID_WRITE_ID_LIST:
- return isSetValidWriteIdList();
case IS_STATS_COMPLIANT:
return isSetIsStatsCompliant();
}
@@ -1452,15 +1344,6 @@ import org.slf4j.LoggerFactory;
return false;
}
- boolean this_present_txnId = true && this.isSetTxnId();
- boolean that_present_txnId = true && that.isSetTxnId();
- if (this_present_txnId || that_present_txnId) {
- if (!(this_present_txnId && that_present_txnId))
- return false;
- if (this.txnId != that.txnId)
- return false;
- }
-
boolean this_present_writeId = true && this.isSetWriteId();
boolean that_present_writeId = true && that.isSetWriteId();
if (this_present_writeId || that_present_writeId) {
@@ -1470,21 +1353,12 @@ import org.slf4j.LoggerFactory;
return false;
}
- boolean this_present_validWriteIdList = true && this.isSetValidWriteIdList();
- boolean that_present_validWriteIdList = true && that.isSetValidWriteIdList();
- if (this_present_validWriteIdList || that_present_validWriteIdList) {
- if (!(this_present_validWriteIdList && that_present_validWriteIdList))
- return false;
- if (!this.validWriteIdList.equals(that.validWriteIdList))
- return false;
- }
-
boolean this_present_isStatsCompliant = true && this.isSetIsStatsCompliant();
boolean that_present_isStatsCompliant = true && that.isSetIsStatsCompliant();
if (this_present_isStatsCompliant || that_present_isStatsCompliant) {
if (!(this_present_isStatsCompliant && that_present_isStatsCompliant))
return false;
- if (!this.isStatsCompliant.equals(that.isStatsCompliant))
+ if (this.isStatsCompliant != that.isStatsCompliant)
return false;
}
@@ -1585,25 +1459,15 @@ import org.slf4j.LoggerFactory;
if (present_ownerType)
list.add(ownerType.getValue());
- boolean present_txnId = true && (isSetTxnId());
- list.add(present_txnId);
- if (present_txnId)
- list.add(txnId);
-
boolean present_writeId = true && (isSetWriteId());
list.add(present_writeId);
if (present_writeId)
list.add(writeId);
- boolean present_validWriteIdList = true && (isSetValidWriteIdList());
- list.add(present_validWriteIdList);
- if (present_validWriteIdList)
- list.add(validWriteIdList);
-
boolean present_isStatsCompliant = true && (isSetIsStatsCompliant());
list.add(present_isStatsCompliant);
if (present_isStatsCompliant)
- list.add(isStatsCompliant.getValue());
+ list.add(isStatsCompliant);
return list.hashCode();
}
@@ -1796,16 +1660,6 @@ import org.slf4j.LoggerFactory;
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(other.isSetTxnId());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetTxnId()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, other.txnId);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
lastComparison = Boolean.valueOf(isSetWriteId()).compareTo(other.isSetWriteId());
if (lastComparison != 0) {
return lastComparison;
@@ -1816,16 +1670,6 @@ import org.slf4j.LoggerFactory;
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetValidWriteIdList()).compareTo(other.isSetValidWriteIdList());
- if (lastComparison != 0) {
- return lastComparison;
- }
- if (isSetValidWriteIdList()) {
- lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.validWriteIdList, other.validWriteIdList);
- if (lastComparison != 0) {
- return lastComparison;
- }
- }
lastComparison = Boolean.valueOf(isSetIsStatsCompliant()).compareTo(other.isSetIsStatsCompliant());
if (lastComparison != 0) {
return lastComparison;
@@ -1991,36 +1835,16 @@ import org.slf4j.LoggerFactory;
}
first = false;
}
- if (isSetTxnId()) {
- if (!first) sb.append(", ");
- sb.append("txnId:");
- sb.append(this.txnId);
- first = false;
- }
if (isSetWriteId()) {
if (!first) sb.append(", ");
sb.append("writeId:");
sb.append(this.writeId);
first = false;
}
- if (isSetValidWriteIdList()) {
- if (!first) sb.append(", ");
- sb.append("validWriteIdList:");
- if (this.validWriteIdList == null) {
- sb.append("null");
- } else {
- sb.append(this.validWriteIdList);
- }
- first = false;
- }
if (isSetIsStatsCompliant()) {
if (!first) sb.append(", ");
sb.append("isStatsCompliant:");
- if (this.isStatsCompliant == null) {
- sb.append("null");
- } else {
- sb.append(this.isStatsCompliant);
- }
+ sb.append(this.isStatsCompliant);
first = false;
}
sb.append(")");
@@ -2244,15 +2068,7 @@ import org.slf4j.LoggerFactory;
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 19: // TXN_ID
- if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
- struct.txnId = iprot.readI64();
- struct.setTxnIdIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 20: // WRITE_ID
+ case 19: // WRITE_ID
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.writeId = iprot.readI64();
struct.setWriteIdIsSet(true);
@@ -2260,17 +2076,9 @@ import org.slf4j.LoggerFactory;
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
- case 21: // VALID_WRITE_ID_LIST
- if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
- struct.validWriteIdList = iprot.readString();
- struct.setValidWriteIdListIsSet(true);
- } else {
- org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
- }
- break;
- case 22: // IS_STATS_COMPLIANT
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ case 20: // IS_STATS_COMPLIANT
+ if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
@@ -2396,29 +2204,15 @@ import org.slf4j.LoggerFactory;
oprot.writeFieldEnd();
}
}
- if (struct.isSetTxnId()) {
- oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
- oprot.writeI64(struct.txnId);
- oprot.writeFieldEnd();
- }
if (struct.isSetWriteId()) {
oprot.writeFieldBegin(WRITE_ID_FIELD_DESC);
oprot.writeI64(struct.writeId);
oprot.writeFieldEnd();
}
- if (struct.validWriteIdList != null) {
- if (struct.isSetValidWriteIdList()) {
- oprot.writeFieldBegin(VALID_WRITE_ID_LIST_FIELD_DESC);
- oprot.writeString(struct.validWriteIdList);
- oprot.writeFieldEnd();
- }
- }
- if (struct.isStatsCompliant != null) {
- if (struct.isSetIsStatsCompliant()) {
- oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
- oprot.writeI32(struct.isStatsCompliant.getValue());
- oprot.writeFieldEnd();
- }
+ if (struct.isSetIsStatsCompliant()) {
+ oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
+ oprot.writeBool(struct.isStatsCompliant);
+ oprot.writeFieldEnd();
}
oprot.writeFieldStop();
oprot.writeStructEnd();
@@ -2492,19 +2286,13 @@ import org.slf4j.LoggerFactory;
if (struct.isSetOwnerType()) {
optionals.set(17);
}
- if (struct.isSetTxnId()) {
- optionals.set(18);
- }
if (struct.isSetWriteId()) {
- optionals.set(19);
- }
- if (struct.isSetValidWriteIdList()) {
- optionals.set(20);
+ optionals.set(18);
}
if (struct.isSetIsStatsCompliant()) {
- optionals.set(21);
+ optionals.set(19);
}
- oprot.writeBitSet(optionals, 22);
+ oprot.writeBitSet(optionals, 20);
if (struct.isSetTableName()) {
oprot.writeString(struct.tableName);
}
@@ -2572,24 +2360,18 @@ import org.slf4j.LoggerFactory;
if (struct.isSetOwnerType()) {
oprot.writeI32(struct.ownerType.getValue());
}
- if (struct.isSetTxnId()) {
- oprot.writeI64(struct.txnId);
- }
if (struct.isSetWriteId()) {
oprot.writeI64(struct.writeId);
}
- if (struct.isSetValidWriteIdList()) {
- oprot.writeString(struct.validWriteIdList);
- }
if (struct.isSetIsStatsCompliant()) {
- oprot.writeI32(struct.isStatsCompliant.getValue());
+ oprot.writeBool(struct.isStatsCompliant);
}
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, Table struct) throws org.apache.thrift.TException {
TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(22);
+ BitSet incoming = iprot.readBitSet(20);
if (incoming.get(0)) {
struct.tableName = iprot.readString();
struct.setTableNameIsSet(true);
@@ -2687,19 +2469,11 @@ import org.slf4j.LoggerFactory;
struct.setOwnerTypeIsSet(true);
}
if (incoming.get(18)) {
- struct.txnId = iprot.readI64();
- struct.setTxnIdIsSet(true);
- }
- if (incoming.get(19)) {
struct.writeId = iprot.readI64();
struct.setWriteIdIsSet(true);
}
- if (incoming.get(20)) {
- struct.validWriteIdList = iprot.readString();
- struct.setValidWriteIdListIsSet(true);
- }
- if (incoming.get(21)) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ if (incoming.get(19)) {
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
}
}
http://git-wip-us.apache.org/repos/asf/hive/blob/a47a80fe/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java
index 4864f68..0685a22 100644
--- a/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java
+++ b/standalone-metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/TableStatsResult.java
@@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TableStatsResult");
private static final org.apache.thrift.protocol.TField TABLE_STATS_FIELD_DESC = new org.apache.thrift.protocol.TField("tableStats", org.apache.thrift.protocol.TType.LIST, (short)1);
- private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.I32, (short)2);
+ private static final org.apache.thrift.protocol.TField IS_STATS_COMPLIANT_FIELD_DESC = new org.apache.thrift.protocol.TField("isStatsCompliant", org.apache.thrift.protocol.TType.BOOL, (short)2);
private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
static {
@@ -48,15 +48,11 @@ import org.slf4j.LoggerFactory;
}
private List<ColumnStatisticsObj> tableStats; // required
- private IsolationLevelCompliance isStatsCompliant; // optional
+ private boolean isStatsCompliant; // 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 {
TABLE_STATS((short)1, "tableStats"),
- /**
- *
- * @see IsolationLevelCompliance
- */
IS_STATS_COMPLIANT((short)2, "isStatsCompliant");
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
@@ -116,6 +112,8 @@ import org.slf4j.LoggerFactory;
}
// isset id assignments
+ private static final int __ISSTATSCOMPLIANT_ISSET_ID = 0;
+ private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.IS_STATS_COMPLIANT};
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
@@ -124,7 +122,7 @@ import org.slf4j.LoggerFactory;
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, ColumnStatisticsObj.class))));
tmpMap.put(_Fields.IS_STATS_COMPLIANT, new org.apache.thrift.meta_data.FieldMetaData("isStatsCompliant", org.apache.thrift.TFieldRequirementType.OPTIONAL,
- new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, IsolationLevelCompliance.class)));
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
metaDataMap = Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TableStatsResult.class, metaDataMap);
}
@@ -143,6 +141,7 @@ import org.slf4j.LoggerFactory;
* Performs a deep copy on <i>other</i>.
*/
public TableStatsResult(TableStatsResult other) {
+ __isset_bitfield = other.__isset_bitfield;
if (other.isSetTableStats()) {
List<ColumnStatisticsObj> __this__tableStats = new ArrayList<ColumnStatisticsObj>(other.tableStats.size());
for (ColumnStatisticsObj other_element : other.tableStats) {
@@ -150,9 +149,7 @@ import org.slf4j.LoggerFactory;
}
this.tableStats = __this__tableStats;
}
- if (other.isSetIsStatsCompliant()) {
- this.isStatsCompliant = other.isStatsCompliant;
- }
+ this.isStatsCompliant = other.isStatsCompliant;
}
public TableStatsResult deepCopy() {
@@ -162,7 +159,8 @@ import org.slf4j.LoggerFactory;
@Override
public void clear() {
this.tableStats = null;
- this.isStatsCompliant = null;
+ setIsStatsCompliantIsSet(false);
+ this.isStatsCompliant = false;
}
public int getTableStatsSize() {
@@ -203,35 +201,26 @@ import org.slf4j.LoggerFactory;
}
}
- /**
- *
- * @see IsolationLevelCompliance
- */
- public IsolationLevelCompliance getIsStatsCompliant() {
+ public boolean isIsStatsCompliant() {
return this.isStatsCompliant;
}
- /**
- *
- * @see IsolationLevelCompliance
- */
- public void setIsStatsCompliant(IsolationLevelCompliance isStatsCompliant) {
+ public void setIsStatsCompliant(boolean isStatsCompliant) {
this.isStatsCompliant = isStatsCompliant;
+ setIsStatsCompliantIsSet(true);
}
public void unsetIsStatsCompliant() {
- this.isStatsCompliant = null;
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
/** Returns true if field isStatsCompliant is set (has been assigned a value) and false otherwise */
public boolean isSetIsStatsCompliant() {
- return this.isStatsCompliant != null;
+ return EncodingUtils.testBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID);
}
public void setIsStatsCompliantIsSet(boolean value) {
- if (!value) {
- this.isStatsCompliant = null;
- }
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISSTATSCOMPLIANT_ISSET_ID, value);
}
public void setFieldValue(_Fields field, Object value) {
@@ -248,7 +237,7 @@ import org.slf4j.LoggerFactory;
if (value == null) {
unsetIsStatsCompliant();
} else {
- setIsStatsCompliant((IsolationLevelCompliance)value);
+ setIsStatsCompliant((Boolean)value);
}
break;
@@ -261,7 +250,7 @@ import org.slf4j.LoggerFactory;
return getTableStats();
case IS_STATS_COMPLIANT:
- return getIsStatsCompliant();
+ return isIsStatsCompliant();
}
throw new IllegalStateException();
@@ -309,7 +298,7 @@ import org.slf4j.LoggerFactory;
if (this_present_isStatsCompliant || that_present_isStatsCompliant) {
if (!(this_present_isStatsCompliant && that_present_isStatsCompliant))
return false;
- if (!this.isStatsCompliant.equals(that.isStatsCompliant))
+ if (this.isStatsCompliant != that.isStatsCompliant)
return false;
}
@@ -328,7 +317,7 @@ import org.slf4j.LoggerFactory;
boolean present_isStatsCompliant = true && (isSetIsStatsCompliant());
list.add(present_isStatsCompliant);
if (present_isStatsCompliant)
- list.add(isStatsCompliant.getValue());
+ list.add(isStatsCompliant);
return list.hashCode();
}
@@ -391,11 +380,7 @@ import org.slf4j.LoggerFactory;
if (isSetIsStatsCompliant()) {
if (!first) sb.append(", ");
sb.append("isStatsCompliant:");
- if (this.isStatsCompliant == null) {
- sb.append("null");
- } else {
- sb.append(this.isStatsCompliant);
- }
+ sb.append(this.isStatsCompliant);
first = false;
}
sb.append(")");
@@ -421,6 +406,8 @@ import org.slf4j.LoggerFactory;
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);
@@ -465,8 +452,8 @@ import org.slf4j.LoggerFactory;
}
break;
case 2: // IS_STATS_COMPLIANT
- if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
@@ -497,12 +484,10 @@ import org.slf4j.LoggerFactory;
}
oprot.writeFieldEnd();
}
- if (struct.isStatsCompliant != null) {
- if (struct.isSetIsStatsCompliant()) {
- oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
- oprot.writeI32(struct.isStatsCompliant.getValue());
- oprot.writeFieldEnd();
- }
+ if (struct.isSetIsStatsCompliant()) {
+ oprot.writeFieldBegin(IS_STATS_COMPLIANT_FIELD_DESC);
+ oprot.writeBool(struct.isStatsCompliant);
+ oprot.writeFieldEnd();
}
oprot.writeFieldStop();
oprot.writeStructEnd();
@@ -534,7 +519,7 @@ import org.slf4j.LoggerFactory;
}
oprot.writeBitSet(optionals, 1);
if (struct.isSetIsStatsCompliant()) {
- oprot.writeI32(struct.isStatsCompliant.getValue());
+ oprot.writeBool(struct.isStatsCompliant);
}
}
@@ -555,7 +540,7 @@ import org.slf4j.LoggerFactory;
struct.setTableStatsIsSet(true);
BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
- struct.isStatsCompliant = org.apache.hadoop.hive.metastore.api.IsolationLevelCompliance.findByValue(iprot.readI32());
+ struct.isStatsCompliant = iprot.readBool();
struct.setIsStatsCompliantIsSet(true);
}
}