This is an automated email from the ASF dual-hosted git repository.
dkuzmenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hive.git
The following commit(s) were added to refs/heads/master by this push:
new 205587979b1 Revert "HIVE-23931: Addendum: ValidWriteIdList isn't used
by get_*_constraints HMS APIs (#6135)"
205587979b1 is described below
commit 205587979b1bea00c94eb834165409e21f815e80
Author: Denys Kuzmenko <[email protected]>
AuthorDate: Fri Oct 17 11:38:28 2025 +0300
Revert "HIVE-23931: Addendum: ValidWriteIdList isn't used by
get_*_constraints HMS APIs (#6135)"
This reverts commit 809b2f9c16b84c9fdc252b8b050da3ae010f6c4b.
---
.../org/apache/hadoop/hive/ql/metadata/Hive.java | 5 +
.../gen/thrift/gen-cpp/hive_metastore_types.cpp | 24 +++-
.../src/gen/thrift/gen-cpp/hive_metastore_types.h | 11 +-
.../hive/metastore/api/PrimaryKeysRequest.java | 122 +++++++++++++++++++--
.../gen-php/metastore/PrimaryKeysRequest.php | 26 ++++-
.../src/gen/thrift/gen-py/hive_metastore/ttypes.py | 18 ++-
.../src/gen/thrift/gen-rb/hive_metastore_types.rb | 4 +-
.../src/main/thrift/hive_metastore.thrift | 3 +-
8 files changed, 197 insertions(+), 16 deletions(-)
diff --git a/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
b/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
index 5a60308513e..07b98266d85 100644
--- a/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
+++ b/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
@@ -6640,8 +6640,10 @@ public List<SQLCheckConstraint>
getCheckConstraintList(String dbName, String tbl
public SQLAllTableConstraints getTableConstraints(String dbName, String
tblName, long tableId)
throws HiveException, NoSuchObjectException {
try {
+ ValidWriteIdList validWriteIdList = getValidWriteIdList(dbName, tblName);
AllTableConstraintsRequest request = new
AllTableConstraintsRequest(dbName, tblName, getDefaultCatalog(conf));
request.setTableId(tableId);
+ request.setValidWriteIdList(validWriteIdList != null ?
validWriteIdList.writeToString() : null);
return getMSC().getAllTableConstraints(request);
} catch (NoSuchObjectException e) {
throw e;
@@ -6656,7 +6658,10 @@ public TableConstraintsInfo getTableConstraints(String
dbName, String tblName, b
perfLogger.perfLogBegin(CLASS_NAME, PerfLogger.HIVE_GET_TABLE_CONSTRAINTS);
try {
+
+ ValidWriteIdList validWriteIdList = getValidWriteIdList(dbName,tblName);
AllTableConstraintsRequest request = new
AllTableConstraintsRequest(dbName, tblName, getDefaultCatalog(conf));
+ request.setValidWriteIdList(validWriteIdList != null ?
validWriteIdList.writeToString() : null);
request.setTableId(tableId);
SQLAllTableConstraints tableConstraints =
getMSC().getAllTableConstraints(request);
diff --git
a/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.cpp
b/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.cpp
index d99c4bdde0d..1be1a922423 100644
---
a/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.cpp
+++
b/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.cpp
@@ -14628,6 +14628,11 @@ void PrimaryKeysRequest::__set_catName(const
std::string& val) {
__isset.catName = true;
}
+void PrimaryKeysRequest::__set_validWriteIdList(const std::string& val) {
+ this->validWriteIdList = val;
+__isset.validWriteIdList = true;
+}
+
void PrimaryKeysRequest::__set_tableId(const int64_t val) {
this->tableId = val;
__isset.tableId = true;
@@ -14687,6 +14692,14 @@ uint32_t
PrimaryKeysRequest::read(::apache::thrift::protocol::TProtocol* iprot)
}
break;
case 4:
+ if (ftype == ::apache::thrift::protocol::T_STRING) {
+ xfer += iprot->readString(this->validWriteIdList);
+ this->__isset.validWriteIdList = true;
+ } else {
+ xfer += iprot->skip(ftype);
+ }
+ break;
+ case 5:
if (ftype == ::apache::thrift::protocol::T_I64) {
xfer += iprot->readI64(this->tableId);
this->__isset.tableId = true;
@@ -14728,8 +14741,13 @@ uint32_t
PrimaryKeysRequest::write(::apache::thrift::protocol::TProtocol* oprot)
xfer += oprot->writeString(this->catName);
xfer += oprot->writeFieldEnd();
}
+ if (this->__isset.validWriteIdList) {
+ xfer += oprot->writeFieldBegin("validWriteIdList",
::apache::thrift::protocol::T_STRING, 4);
+ xfer += oprot->writeString(this->validWriteIdList);
+ xfer += oprot->writeFieldEnd();
+ }
if (this->__isset.tableId) {
- xfer += oprot->writeFieldBegin("tableId",
::apache::thrift::protocol::T_I64, 4);
+ xfer += oprot->writeFieldBegin("tableId",
::apache::thrift::protocol::T_I64, 5);
xfer += oprot->writeI64(this->tableId);
xfer += oprot->writeFieldEnd();
}
@@ -14743,6 +14761,7 @@ void swap(PrimaryKeysRequest &a, PrimaryKeysRequest &b)
{
swap(a.db_name, b.db_name);
swap(a.tbl_name, b.tbl_name);
swap(a.catName, b.catName);
+ swap(a.validWriteIdList, b.validWriteIdList);
swap(a.tableId, b.tableId);
swap(a.__isset, b.__isset);
}
@@ -14751,6 +14770,7 @@ PrimaryKeysRequest::PrimaryKeysRequest(const
PrimaryKeysRequest& other531) {
db_name = other531.db_name;
tbl_name = other531.tbl_name;
catName = other531.catName;
+ validWriteIdList = other531.validWriteIdList;
tableId = other531.tableId;
__isset = other531.__isset;
}
@@ -14758,6 +14778,7 @@ PrimaryKeysRequest& PrimaryKeysRequest::operator=(const
PrimaryKeysRequest& othe
db_name = other532.db_name;
tbl_name = other532.tbl_name;
catName = other532.catName;
+ validWriteIdList = other532.validWriteIdList;
tableId = other532.tableId;
__isset = other532.__isset;
return *this;
@@ -14768,6 +14789,7 @@ void PrimaryKeysRequest::printTo(std::ostream& out)
const {
out << "db_name=" << to_string(db_name);
out << ", " << "tbl_name=" << to_string(tbl_name);
out << ", " << "catName="; (__isset.catName ? (out << to_string(catName)) :
(out << "<null>"));
+ out << ", " << "validWriteIdList="; (__isset.validWriteIdList ? (out <<
to_string(validWriteIdList)) : (out << "<null>"));
out << ", " << "tableId="; (__isset.tableId ? (out << to_string(tableId)) :
(out << "<null>"));
out << ")";
}
diff --git
a/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.h
b/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.h
index ba4a231106a..6ae7016d0e6 100644
---
a/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.h
+++
b/standalone-metastore/metastore-common/src/gen/thrift/gen-cpp/hive_metastore_types.h
@@ -6222,8 +6222,9 @@ void swap(Schema &a, Schema &b);
std::ostream& operator<<(std::ostream& out, const Schema& obj);
typedef struct _PrimaryKeysRequest__isset {
- _PrimaryKeysRequest__isset() : catName(false), tableId(true) {}
+ _PrimaryKeysRequest__isset() : catName(false), validWriteIdList(false),
tableId(true) {}
bool catName :1;
+ bool validWriteIdList :1;
bool tableId :1;
} _PrimaryKeysRequest__isset;
@@ -6236,6 +6237,7 @@ class PrimaryKeysRequest : public virtual
::apache::thrift::TBase {
: db_name(),
tbl_name(),
catName(),
+ validWriteIdList(),
tableId(-1LL) {
}
@@ -6243,6 +6245,7 @@ class PrimaryKeysRequest : public virtual
::apache::thrift::TBase {
std::string db_name;
std::string tbl_name;
std::string catName;
+ std::string validWriteIdList;
int64_t tableId;
_PrimaryKeysRequest__isset __isset;
@@ -6253,6 +6256,8 @@ class PrimaryKeysRequest : public virtual
::apache::thrift::TBase {
void __set_catName(const std::string& val);
+ void __set_validWriteIdList(const std::string& val);
+
void __set_tableId(const int64_t val);
bool operator == (const PrimaryKeysRequest & rhs) const
@@ -6265,6 +6270,10 @@ class PrimaryKeysRequest : public virtual
::apache::thrift::TBase {
return false;
else if (__isset.catName && !(catName == rhs.catName))
return false;
+ if (__isset.validWriteIdList != rhs.__isset.validWriteIdList)
+ return false;
+ else if (__isset.validWriteIdList && !(validWriteIdList ==
rhs.validWriteIdList))
+ return false;
if (__isset.tableId != rhs.__isset.tableId)
return false;
else if (__isset.tableId && !(tableId == rhs.tableId))
diff --git
a/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrimaryKeysRequest.java
b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrimaryKeysRequest.java
index 8532ac05eb4..2df2fe1f1d3 100644
---
a/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrimaryKeysRequest.java
+++
b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrimaryKeysRequest.java
@@ -14,7 +14,8 @@
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 CAT_NAME_FIELD_DESC =
new org.apache.thrift.protocol.TField("catName",
org.apache.thrift.protocol.TType.STRING, (short)3);
- private static final org.apache.thrift.protocol.TField TABLE_ID_FIELD_DESC =
new org.apache.thrift.protocol.TField("tableId",
org.apache.thrift.protocol.TType.I64, (short)4);
+ 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)4);
+ private static final org.apache.thrift.protocol.TField TABLE_ID_FIELD_DESC =
new org.apache.thrift.protocol.TField("tableId",
org.apache.thrift.protocol.TType.I64, (short)5);
private static final org.apache.thrift.scheme.SchemeFactory
STANDARD_SCHEME_FACTORY = new PrimaryKeysRequestStandardSchemeFactory();
private static final org.apache.thrift.scheme.SchemeFactory
TUPLE_SCHEME_FACTORY = new PrimaryKeysRequestTupleSchemeFactory();
@@ -22,6 +23,7 @@
private @org.apache.thrift.annotation.Nullable java.lang.String db_name; //
required
private @org.apache.thrift.annotation.Nullable java.lang.String tbl_name; //
required
private @org.apache.thrift.annotation.Nullable java.lang.String catName; //
optional
+ private @org.apache.thrift.annotation.Nullable java.lang.String
validWriteIdList; // optional
private long tableId; // optional
/** The set of fields this struct contains, along with convenience methods
for finding and manipulating them. */
@@ -29,7 +31,8 @@ public enum _Fields implements org.apache.thrift.TFieldIdEnum
{
DB_NAME((short)1, "db_name"),
TBL_NAME((short)2, "tbl_name"),
CAT_NAME((short)3, "catName"),
- TABLE_ID((short)4, "tableId");
+ VALID_WRITE_ID_LIST((short)4, "validWriteIdList"),
+ TABLE_ID((short)5, "tableId");
private static final java.util.Map<java.lang.String, _Fields> byName = new
java.util.HashMap<java.lang.String, _Fields>();
@@ -51,7 +54,9 @@ public static _Fields findByThriftId(int fieldId) {
return TBL_NAME;
case 3: // CAT_NAME
return CAT_NAME;
- case 4: // TABLE_ID
+ case 4: // VALID_WRITE_ID_LIST
+ return VALID_WRITE_ID_LIST;
+ case 5: // TABLE_ID
return TABLE_ID;
default:
return null;
@@ -96,7 +101,7 @@ public java.lang.String getFieldName() {
// isset id assignments
private static final int __TABLEID_ISSET_ID = 0;
private byte __isset_bitfield = 0;
- private static final _Fields optionals[] =
{_Fields.CAT_NAME,_Fields.TABLE_ID};
+ private static final _Fields optionals[] =
{_Fields.CAT_NAME,_Fields.VALID_WRITE_ID_LIST,_Fields.TABLE_ID};
public static final java.util.Map<_Fields,
org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap =
new java.util.EnumMap<_Fields,
org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
@@ -106,6 +111,8 @@ public java.lang.String getFieldName() {
new
org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
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.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.TABLE_ID, new
org.apache.thrift.meta_data.FieldMetaData("tableId",
org.apache.thrift.TFieldRequirementType.OPTIONAL,
new
org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
@@ -140,6 +147,9 @@ public PrimaryKeysRequest(PrimaryKeysRequest other) {
if (other.isSetCatName()) {
this.catName = other.catName;
}
+ if (other.isSetValidWriteIdList()) {
+ this.validWriteIdList = other.validWriteIdList;
+ }
this.tableId = other.tableId;
}
@@ -152,6 +162,7 @@ public void clear() {
this.db_name = null;
this.tbl_name = null;
this.catName = null;
+ this.validWriteIdList = null;
this.tableId = -1L;
}
@@ -228,6 +239,30 @@ public void setCatNameIsSet(boolean value) {
}
}
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getValidWriteIdList() {
+ return this.validWriteIdList;
+ }
+
+ public void setValidWriteIdList(@org.apache.thrift.annotation.Nullable
java.lang.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;
+ }
+ }
+
public long getTableId() {
return this.tableId;
}
@@ -276,6 +311,14 @@ public void setFieldValue(_Fields field,
@org.apache.thrift.annotation.Nullable
}
break;
+ case VALID_WRITE_ID_LIST:
+ if (value == null) {
+ unsetValidWriteIdList();
+ } else {
+ setValidWriteIdList((java.lang.String)value);
+ }
+ break;
+
case TABLE_ID:
if (value == null) {
unsetTableId();
@@ -299,6 +342,9 @@ public java.lang.Object getFieldValue(_Fields field) {
case CAT_NAME:
return getCatName();
+ case VALID_WRITE_ID_LIST:
+ return getValidWriteIdList();
+
case TABLE_ID:
return getTableId();
@@ -319,6 +365,8 @@ public boolean isSet(_Fields field) {
return isSetTbl_name();
case CAT_NAME:
return isSetCatName();
+ case VALID_WRITE_ID_LIST:
+ return isSetValidWriteIdList();
case TABLE_ID:
return isSetTableId();
}
@@ -365,6 +413,15 @@ public boolean equals(PrimaryKeysRequest that) {
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_tableId = true && this.isSetTableId();
boolean that_present_tableId = true && that.isSetTableId();
if (this_present_tableId || that_present_tableId) {
@@ -393,6 +450,10 @@ public int hashCode() {
if (isSetCatName())
hashCode = hashCode * 8191 + catName.hashCode();
+ hashCode = hashCode * 8191 + ((isSetValidWriteIdList()) ? 131071 : 524287);
+ if (isSetValidWriteIdList())
+ hashCode = hashCode * 8191 + validWriteIdList.hashCode();
+
hashCode = hashCode * 8191 + ((isSetTableId()) ? 131071 : 524287);
if (isSetTableId())
hashCode = hashCode * 8191 +
org.apache.thrift.TBaseHelper.hashCode(tableId);
@@ -438,6 +499,16 @@ public int compareTo(PrimaryKeysRequest other) {
return lastComparison;
}
}
+ lastComparison = java.lang.Boolean.compare(isSetValidWriteIdList(),
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 = java.lang.Boolean.compare(isSetTableId(),
other.isSetTableId());
if (lastComparison != 0) {
return lastComparison;
@@ -494,6 +565,16 @@ public java.lang.String toString() {
}
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 (isSetTableId()) {
if (!first) sb.append(", ");
sb.append("tableId:");
@@ -577,7 +658,15 @@ public void read(org.apache.thrift.protocol.TProtocol
iprot, PrimaryKeysRequest
org.apache.thrift.protocol.TProtocolUtil.skip(iprot,
schemeField.type);
}
break;
- case 4: // TABLE_ID
+ case 4: // 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 5: // TABLE_ID
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.tableId = iprot.readI64();
struct.setTableIdIsSet(true);
@@ -615,6 +704,13 @@ public void write(org.apache.thrift.protocol.TProtocol
oprot, PrimaryKeysRequest
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.isSetTableId()) {
oprot.writeFieldBegin(TABLE_ID_FIELD_DESC);
oprot.writeI64(struct.tableId);
@@ -643,13 +739,19 @@ public void write(org.apache.thrift.protocol.TProtocol
prot, PrimaryKeysRequest
if (struct.isSetCatName()) {
optionals.set(0);
}
- if (struct.isSetTableId()) {
+ if (struct.isSetValidWriteIdList()) {
optionals.set(1);
}
- oprot.writeBitSet(optionals, 2);
+ if (struct.isSetTableId()) {
+ optionals.set(2);
+ }
+ oprot.writeBitSet(optionals, 3);
if (struct.isSetCatName()) {
oprot.writeString(struct.catName);
}
+ if (struct.isSetValidWriteIdList()) {
+ oprot.writeString(struct.validWriteIdList);
+ }
if (struct.isSetTableId()) {
oprot.writeI64(struct.tableId);
}
@@ -662,12 +764,16 @@ public void read(org.apache.thrift.protocol.TProtocol
prot, PrimaryKeysRequest s
struct.setDb_nameIsSet(true);
struct.tbl_name = iprot.readString();
struct.setTbl_nameIsSet(true);
- java.util.BitSet incoming = iprot.readBitSet(2);
+ java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
struct.catName = iprot.readString();
struct.setCatNameIsSet(true);
}
if (incoming.get(1)) {
+ struct.validWriteIdList = iprot.readString();
+ struct.setValidWriteIdListIsSet(true);
+ }
+ if (incoming.get(2)) {
struct.tableId = iprot.readI64();
struct.setTableIdIsSet(true);
}
diff --git
a/standalone-metastore/metastore-common/src/gen/thrift/gen-php/metastore/PrimaryKeysRequest.php
b/standalone-metastore/metastore-common/src/gen/thrift/gen-php/metastore/PrimaryKeysRequest.php
index 5222d4d068a..95d523619c9 100644
---
a/standalone-metastore/metastore-common/src/gen/thrift/gen-php/metastore/PrimaryKeysRequest.php
+++
b/standalone-metastore/metastore-common/src/gen/thrift/gen-php/metastore/PrimaryKeysRequest.php
@@ -37,6 +37,11 @@ class PrimaryKeysRequest
'type' => TType::STRING,
),
4 => array(
+ 'var' => 'validWriteIdList',
+ 'isRequired' => false,
+ 'type' => TType::STRING,
+ ),
+ 5 => array(
'var' => 'tableId',
'isRequired' => false,
'type' => TType::I64,
@@ -55,6 +60,10 @@ class PrimaryKeysRequest
* @var string
*/
public $catName = null;
+ /**
+ * @var string
+ */
+ public $validWriteIdList = null;
/**
* @var int
*/
@@ -72,6 +81,9 @@ class PrimaryKeysRequest
if (isset($vals['catName'])) {
$this->catName = $vals['catName'];
}
+ if (isset($vals['validWriteIdList'])) {
+ $this->validWriteIdList = $vals['validWriteIdList'];
+ }
if (isset($vals['tableId'])) {
$this->tableId = $vals['tableId'];
}
@@ -119,6 +131,13 @@ class PrimaryKeysRequest
}
break;
case 4:
+ if ($ftype == TType::STRING) {
+ $xfer += $input->readString($this->validWriteIdList);
+ } else {
+ $xfer += $input->skip($ftype);
+ }
+ break;
+ case 5:
if ($ftype == TType::I64) {
$xfer += $input->readI64($this->tableId);
} else {
@@ -154,8 +173,13 @@ class PrimaryKeysRequest
$xfer += $output->writeString($this->catName);
$xfer += $output->writeFieldEnd();
}
+ if ($this->validWriteIdList !== null) {
+ $xfer += $output->writeFieldBegin('validWriteIdList',
TType::STRING, 4);
+ $xfer += $output->writeString($this->validWriteIdList);
+ $xfer += $output->writeFieldEnd();
+ }
if ($this->tableId !== null) {
- $xfer += $output->writeFieldBegin('tableId', TType::I64, 4);
+ $xfer += $output->writeFieldBegin('tableId', TType::I64, 5);
$xfer += $output->writeI64($this->tableId);
$xfer += $output->writeFieldEnd();
}
diff --git
a/standalone-metastore/metastore-common/src/gen/thrift/gen-py/hive_metastore/ttypes.py
b/standalone-metastore/metastore-common/src/gen/thrift/gen-py/hive_metastore/ttypes.py
index 755e124ed1c..a8df9cc6893 100644
---
a/standalone-metastore/metastore-common/src/gen/thrift/gen-py/hive_metastore/ttypes.py
+++
b/standalone-metastore/metastore-common/src/gen/thrift/gen-py/hive_metastore/ttypes.py
@@ -8357,15 +8357,17 @@ class PrimaryKeysRequest(object):
- db_name
- tbl_name
- catName
+ - validWriteIdList
- tableId
"""
- def __init__(self, db_name=None, tbl_name=None, catName=None, tableId=-1,):
+ def __init__(self, db_name=None, tbl_name=None, catName=None,
validWriteIdList=None, tableId=-1,):
self.db_name = db_name
self.tbl_name = tbl_name
self.catName = catName
+ self.validWriteIdList = validWriteIdList
self.tableId = tableId
def read(self, iprot):
@@ -8393,6 +8395,11 @@ def read(self, iprot):
else:
iprot.skip(ftype)
elif fid == 4:
+ if ftype == TType.STRING:
+ self.validWriteIdList = iprot.readString().decode('utf-8',
errors='replace') if sys.version_info[0] == 2 else iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
if ftype == TType.I64:
self.tableId = iprot.readI64()
else:
@@ -8419,8 +8426,12 @@ def write(self, oprot):
oprot.writeFieldBegin('catName', TType.STRING, 3)
oprot.writeString(self.catName.encode('utf-8') if
sys.version_info[0] == 2 else self.catName)
oprot.writeFieldEnd()
+ if self.validWriteIdList is not None:
+ oprot.writeFieldBegin('validWriteIdList', TType.STRING, 4)
+ oprot.writeString(self.validWriteIdList.encode('utf-8') if
sys.version_info[0] == 2 else self.validWriteIdList)
+ oprot.writeFieldEnd()
if self.tableId is not None:
- oprot.writeFieldBegin('tableId', TType.I64, 4)
+ oprot.writeFieldBegin('tableId', TType.I64, 5)
oprot.writeI64(self.tableId)
oprot.writeFieldEnd()
oprot.writeFieldStop()
@@ -33072,7 +33083,8 @@ def __ne__(self, other):
(1, TType.STRING, 'db_name', 'UTF8', None, ), # 1
(2, TType.STRING, 'tbl_name', 'UTF8', None, ), # 2
(3, TType.STRING, 'catName', 'UTF8', None, ), # 3
- (4, TType.I64, 'tableId', None, -1, ), # 4
+ (4, TType.STRING, 'validWriteIdList', 'UTF8', None, ), # 4
+ (5, TType.I64, 'tableId', None, -1, ), # 5
)
all_structs.append(PrimaryKeysResponse)
PrimaryKeysResponse.thrift_spec = (
diff --git
a/standalone-metastore/metastore-common/src/gen/thrift/gen-rb/hive_metastore_types.rb
b/standalone-metastore/metastore-common/src/gen/thrift/gen-rb/hive_metastore_types.rb
index 44f6a048519..3a12634f79e 100644
---
a/standalone-metastore/metastore-common/src/gen/thrift/gen-rb/hive_metastore_types.rb
+++
b/standalone-metastore/metastore-common/src/gen/thrift/gen-rb/hive_metastore_types.rb
@@ -2770,12 +2770,14 @@ class PrimaryKeysRequest
DB_NAME = 1
TBL_NAME = 2
CATNAME = 3
- TABLEID = 4
+ VALIDWRITEIDLIST = 4
+ TABLEID = 5
FIELDS = {
DB_NAME => {:type => ::Thrift::Types::STRING, :name => 'db_name'},
TBL_NAME => {:type => ::Thrift::Types::STRING, :name => 'tbl_name'},
CATNAME => {:type => ::Thrift::Types::STRING, :name => 'catName',
:optional => true},
+ VALIDWRITEIDLIST => {:type => ::Thrift::Types::STRING, :name =>
'validWriteIdList', :optional => true},
TABLEID => {:type => ::Thrift::Types::I64, :name => 'tableId', :default =>
-1, :optional => true}
}
diff --git
a/standalone-metastore/metastore-common/src/main/thrift/hive_metastore.thrift
b/standalone-metastore/metastore-common/src/main/thrift/hive_metastore.thrift
index ecea9c33777..df072165529 100644
---
a/standalone-metastore/metastore-common/src/main/thrift/hive_metastore.thrift
+++
b/standalone-metastore/metastore-common/src/main/thrift/hive_metastore.thrift
@@ -754,7 +754,8 @@ struct PrimaryKeysRequest {
1: required string db_name,
2: required string tbl_name,
3: optional string catName,
- 4: optional i64 tableId=-1
+ 4: optional string validWriteIdList,
+ 5: optional i64 tableId=-1
}
struct PrimaryKeysResponse {