diff --git itests/hive-unit/src/test/java/org/apache/hadoop/hive/metastore/TestAuthorizationApiAuthorizer.java itests/hive-unit/src/test/java/org/apache/hadoop/hive/metastore/TestAuthorizationApiAuthorizer.java index 6b2f28e..d2b6355 100644 --- itests/hive-unit/src/test/java/org/apache/hadoop/hive/metastore/TestAuthorizationApiAuthorizer.java +++ itests/hive-unit/src/test/java/org/apache/hadoop/hive/metastore/TestAuthorizationApiAuthorizer.java @@ -145,7 +145,7 @@ public void testRevokeRole() throws Exception { FunctionInvoker invoker = new FunctionInvoker() { @Override public void invoke() throws Exception { - msc.revoke_role(null, null, null); + msc.revoke_role(null, null, null, false); } }; testFunction(invoker); diff --git metastore/if/hive_metastore.thrift metastore/if/hive_metastore.thrift index d425d2b..65cba19 100755 --- metastore/if/hive_metastore.thrift +++ metastore/if/hive_metastore.thrift @@ -101,6 +101,11 @@ enum CompactionType { MAJOR = 2, } +enum GrantRevokeType { + GRANT = 1, + REVOKE = 2, +} + struct HiveObjectRef{ 1: HiveObjectType objectType, 2: string dbName, @@ -168,6 +173,20 @@ struct GetPrincipalsInRoleResponse { 1: required list principalGrants; } +struct GrantRevokeRoleRequest { + 1: required GrantRevokeType requestType; + 2: optional string roleName; + 3: optional string principalName; + 4: optional PrincipalType principalType; + 5: optional string grantor; // Needed for grant + 6: optional PrincipalType grantorType; // Needed for grant + 7: optional bool grantOption; +} + +struct GrantRevokeRoleResponse { + 1: optional bool success; +} + // namespace for tables struct Database { 1: string name, @@ -963,6 +982,7 @@ service ThriftHiveMetastore extends fb303.FacebookService bool revoke_role(1:string role_name, 2:string principal_name, 3:PrincipalType principal_type) throws(1:MetaException o1) list list_roles(1:string principal_name, 2:PrincipalType principal_type) throws(1:MetaException o1) + GrantRevokeRoleResponse grant_revoke_role(GrantRevokeRoleRequest request) throws(1:MetaException o1) // get all role-grants for users/roles that have been granted the given role // Note that in the returned list of RolePrincipalGrants, the roleName is diff --git metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp index 9567874..9632b9e 100644 --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.cpp @@ -736,14 +736,14 @@ uint32_t ThriftHiveMetastore_get_databases_result::read(::apache::thrift::protoc if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size359; - ::apache::thrift::protocol::TType _etype362; - xfer += iprot->readListBegin(_etype362, _size359); - this->success.resize(_size359); - uint32_t _i363; - for (_i363 = 0; _i363 < _size359; ++_i363) + uint32_t _size362; + ::apache::thrift::protocol::TType _etype365; + xfer += iprot->readListBegin(_etype365, _size362); + this->success.resize(_size362); + uint32_t _i366; + for (_i366 = 0; _i366 < _size362; ++_i366) { - xfer += iprot->readString(this->success[_i363]); + xfer += iprot->readString(this->success[_i366]); } xfer += iprot->readListEnd(); } @@ -782,10 +782,10 @@ uint32_t ThriftHiveMetastore_get_databases_result::write(::apache::thrift::proto 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 _iter364; - for (_iter364 = this->success.begin(); _iter364 != this->success.end(); ++_iter364) + std::vector ::const_iterator _iter367; + for (_iter367 = this->success.begin(); _iter367 != this->success.end(); ++_iter367) { - xfer += oprot->writeString((*_iter364)); + xfer += oprot->writeString((*_iter367)); } xfer += oprot->writeListEnd(); } @@ -824,14 +824,14 @@ uint32_t ThriftHiveMetastore_get_databases_presult::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size365; - ::apache::thrift::protocol::TType _etype368; - xfer += iprot->readListBegin(_etype368, _size365); - (*(this->success)).resize(_size365); - uint32_t _i369; - for (_i369 = 0; _i369 < _size365; ++_i369) + uint32_t _size368; + ::apache::thrift::protocol::TType _etype371; + xfer += iprot->readListBegin(_etype371, _size368); + (*(this->success)).resize(_size368); + uint32_t _i372; + for (_i372 = 0; _i372 < _size368; ++_i372) { - xfer += iprot->readString((*(this->success))[_i369]); + xfer += iprot->readString((*(this->success))[_i372]); } xfer += iprot->readListEnd(); } @@ -929,14 +929,14 @@ uint32_t ThriftHiveMetastore_get_all_databases_result::read(::apache::thrift::pr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size370; - ::apache::thrift::protocol::TType _etype373; - xfer += iprot->readListBegin(_etype373, _size370); - this->success.resize(_size370); - uint32_t _i374; - for (_i374 = 0; _i374 < _size370; ++_i374) + uint32_t _size373; + ::apache::thrift::protocol::TType _etype376; + xfer += iprot->readListBegin(_etype376, _size373); + this->success.resize(_size373); + uint32_t _i377; + for (_i377 = 0; _i377 < _size373; ++_i377) { - xfer += iprot->readString(this->success[_i374]); + xfer += iprot->readString(this->success[_i377]); } xfer += iprot->readListEnd(); } @@ -975,10 +975,10 @@ uint32_t ThriftHiveMetastore_get_all_databases_result::write(::apache::thrift::p 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 _iter375; - for (_iter375 = this->success.begin(); _iter375 != this->success.end(); ++_iter375) + std::vector ::const_iterator _iter378; + for (_iter378 = this->success.begin(); _iter378 != this->success.end(); ++_iter378) { - xfer += oprot->writeString((*_iter375)); + xfer += oprot->writeString((*_iter378)); } xfer += oprot->writeListEnd(); } @@ -1017,14 +1017,14 @@ uint32_t ThriftHiveMetastore_get_all_databases_presult::read(::apache::thrift::p if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size376; - ::apache::thrift::protocol::TType _etype379; - xfer += iprot->readListBegin(_etype379, _size376); - (*(this->success)).resize(_size376); - uint32_t _i380; - for (_i380 = 0; _i380 < _size376; ++_i380) + uint32_t _size379; + ::apache::thrift::protocol::TType _etype382; + xfer += iprot->readListBegin(_etype382, _size379); + (*(this->success)).resize(_size379); + uint32_t _i383; + for (_i383 = 0; _i383 < _size379; ++_i383) { - xfer += iprot->readString((*(this->success))[_i380]); + xfer += iprot->readString((*(this->success))[_i383]); } xfer += iprot->readListEnd(); } @@ -1967,17 +1967,17 @@ uint32_t ThriftHiveMetastore_get_type_all_result::read(::apache::thrift::protoco if (ftype == ::apache::thrift::protocol::T_MAP) { { this->success.clear(); - uint32_t _size381; - ::apache::thrift::protocol::TType _ktype382; - ::apache::thrift::protocol::TType _vtype383; - xfer += iprot->readMapBegin(_ktype382, _vtype383, _size381); - uint32_t _i385; - for (_i385 = 0; _i385 < _size381; ++_i385) + uint32_t _size384; + ::apache::thrift::protocol::TType _ktype385; + ::apache::thrift::protocol::TType _vtype386; + xfer += iprot->readMapBegin(_ktype385, _vtype386, _size384); + uint32_t _i388; + for (_i388 = 0; _i388 < _size384; ++_i388) { - std::string _key386; - xfer += iprot->readString(_key386); - Type& _val387 = this->success[_key386]; - xfer += _val387.read(iprot); + std::string _key389; + xfer += iprot->readString(_key389); + Type& _val390 = this->success[_key389]; + xfer += _val390.read(iprot); } xfer += iprot->readMapEnd(); } @@ -2016,11 +2016,11 @@ uint32_t ThriftHiveMetastore_get_type_all_result::write(::apache::thrift::protoc 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 _iter388; - for (_iter388 = this->success.begin(); _iter388 != this->success.end(); ++_iter388) + std::map ::const_iterator _iter391; + for (_iter391 = this->success.begin(); _iter391 != this->success.end(); ++_iter391) { - xfer += oprot->writeString(_iter388->first); - xfer += _iter388->second.write(oprot); + xfer += oprot->writeString(_iter391->first); + xfer += _iter391->second.write(oprot); } xfer += oprot->writeMapEnd(); } @@ -2059,17 +2059,17 @@ uint32_t ThriftHiveMetastore_get_type_all_presult::read(::apache::thrift::protoc if (ftype == ::apache::thrift::protocol::T_MAP) { { (*(this->success)).clear(); - uint32_t _size389; - ::apache::thrift::protocol::TType _ktype390; - ::apache::thrift::protocol::TType _vtype391; - xfer += iprot->readMapBegin(_ktype390, _vtype391, _size389); - uint32_t _i393; - for (_i393 = 0; _i393 < _size389; ++_i393) + uint32_t _size392; + ::apache::thrift::protocol::TType _ktype393; + ::apache::thrift::protocol::TType _vtype394; + xfer += iprot->readMapBegin(_ktype393, _vtype394, _size392); + uint32_t _i396; + for (_i396 = 0; _i396 < _size392; ++_i396) { - std::string _key394; - xfer += iprot->readString(_key394); - Type& _val395 = (*(this->success))[_key394]; - xfer += _val395.read(iprot); + std::string _key397; + xfer += iprot->readString(_key397); + Type& _val398 = (*(this->success))[_key397]; + xfer += _val398.read(iprot); } xfer += iprot->readMapEnd(); } @@ -2204,14 +2204,14 @@ uint32_t ThriftHiveMetastore_get_fields_result::read(::apache::thrift::protocol: if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size396; - ::apache::thrift::protocol::TType _etype399; - xfer += iprot->readListBegin(_etype399, _size396); - this->success.resize(_size396); - uint32_t _i400; - for (_i400 = 0; _i400 < _size396; ++_i400) + uint32_t _size399; + ::apache::thrift::protocol::TType _etype402; + xfer += iprot->readListBegin(_etype402, _size399); + this->success.resize(_size399); + uint32_t _i403; + for (_i403 = 0; _i403 < _size399; ++_i403) { - xfer += this->success[_i400].read(iprot); + xfer += this->success[_i403].read(iprot); } xfer += iprot->readListEnd(); } @@ -2266,10 +2266,10 @@ uint32_t ThriftHiveMetastore_get_fields_result::write(::apache::thrift::protocol 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 _iter401; - for (_iter401 = this->success.begin(); _iter401 != this->success.end(); ++_iter401) + std::vector ::const_iterator _iter404; + for (_iter404 = this->success.begin(); _iter404 != this->success.end(); ++_iter404) { - xfer += (*_iter401).write(oprot); + xfer += (*_iter404).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2316,14 +2316,14 @@ uint32_t ThriftHiveMetastore_get_fields_presult::read(::apache::thrift::protocol if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size402; - ::apache::thrift::protocol::TType _etype405; - xfer += iprot->readListBegin(_etype405, _size402); - (*(this->success)).resize(_size402); - uint32_t _i406; - for (_i406 = 0; _i406 < _size402; ++_i406) + uint32_t _size405; + ::apache::thrift::protocol::TType _etype408; + xfer += iprot->readListBegin(_etype408, _size405); + (*(this->success)).resize(_size405); + uint32_t _i409; + for (_i409 = 0; _i409 < _size405; ++_i409) { - xfer += (*(this->success))[_i406].read(iprot); + xfer += (*(this->success))[_i409].read(iprot); } xfer += iprot->readListEnd(); } @@ -2474,14 +2474,14 @@ uint32_t ThriftHiveMetastore_get_schema_result::read(::apache::thrift::protocol: if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size407; - ::apache::thrift::protocol::TType _etype410; - xfer += iprot->readListBegin(_etype410, _size407); - this->success.resize(_size407); - uint32_t _i411; - for (_i411 = 0; _i411 < _size407; ++_i411) + uint32_t _size410; + ::apache::thrift::protocol::TType _etype413; + xfer += iprot->readListBegin(_etype413, _size410); + this->success.resize(_size410); + uint32_t _i414; + for (_i414 = 0; _i414 < _size410; ++_i414) { - xfer += this->success[_i411].read(iprot); + xfer += this->success[_i414].read(iprot); } xfer += iprot->readListEnd(); } @@ -2536,10 +2536,10 @@ uint32_t ThriftHiveMetastore_get_schema_result::write(::apache::thrift::protocol 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 _iter412; - for (_iter412 = this->success.begin(); _iter412 != this->success.end(); ++_iter412) + std::vector ::const_iterator _iter415; + for (_iter415 = this->success.begin(); _iter415 != this->success.end(); ++_iter415) { - xfer += (*_iter412).write(oprot); + xfer += (*_iter415).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2586,14 +2586,14 @@ uint32_t ThriftHiveMetastore_get_schema_presult::read(::apache::thrift::protocol if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size413; - ::apache::thrift::protocol::TType _etype416; - xfer += iprot->readListBegin(_etype416, _size413); - (*(this->success)).resize(_size413); - uint32_t _i417; - for (_i417 = 0; _i417 < _size413; ++_i417) + uint32_t _size416; + ::apache::thrift::protocol::TType _etype419; + xfer += iprot->readListBegin(_etype419, _size416); + (*(this->success)).resize(_size416); + uint32_t _i420; + for (_i420 = 0; _i420 < _size416; ++_i420) { - xfer += (*(this->success))[_i417].read(iprot); + xfer += (*(this->success))[_i420].read(iprot); } xfer += iprot->readListEnd(); } @@ -3648,14 +3648,14 @@ uint32_t ThriftHiveMetastore_get_tables_result::read(::apache::thrift::protocol: if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size418; - ::apache::thrift::protocol::TType _etype421; - xfer += iprot->readListBegin(_etype421, _size418); - this->success.resize(_size418); - uint32_t _i422; - for (_i422 = 0; _i422 < _size418; ++_i422) + uint32_t _size421; + ::apache::thrift::protocol::TType _etype424; + xfer += iprot->readListBegin(_etype424, _size421); + this->success.resize(_size421); + uint32_t _i425; + for (_i425 = 0; _i425 < _size421; ++_i425) { - xfer += iprot->readString(this->success[_i422]); + xfer += iprot->readString(this->success[_i425]); } xfer += iprot->readListEnd(); } @@ -3694,10 +3694,10 @@ uint32_t ThriftHiveMetastore_get_tables_result::write(::apache::thrift::protocol 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 _iter423; - for (_iter423 = this->success.begin(); _iter423 != this->success.end(); ++_iter423) + std::vector ::const_iterator _iter426; + for (_iter426 = this->success.begin(); _iter426 != this->success.end(); ++_iter426) { - xfer += oprot->writeString((*_iter423)); + xfer += oprot->writeString((*_iter426)); } xfer += oprot->writeListEnd(); } @@ -3736,14 +3736,14 @@ uint32_t ThriftHiveMetastore_get_tables_presult::read(::apache::thrift::protocol if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size424; - ::apache::thrift::protocol::TType _etype427; - xfer += iprot->readListBegin(_etype427, _size424); - (*(this->success)).resize(_size424); - uint32_t _i428; - for (_i428 = 0; _i428 < _size424; ++_i428) + uint32_t _size427; + ::apache::thrift::protocol::TType _etype430; + xfer += iprot->readListBegin(_etype430, _size427); + (*(this->success)).resize(_size427); + uint32_t _i431; + for (_i431 = 0; _i431 < _size427; ++_i431) { - xfer += iprot->readString((*(this->success))[_i428]); + xfer += iprot->readString((*(this->success))[_i431]); } xfer += iprot->readListEnd(); } @@ -3862,14 +3862,14 @@ uint32_t ThriftHiveMetastore_get_all_tables_result::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size429; - ::apache::thrift::protocol::TType _etype432; - xfer += iprot->readListBegin(_etype432, _size429); - this->success.resize(_size429); - uint32_t _i433; - for (_i433 = 0; _i433 < _size429; ++_i433) + 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 += iprot->readString(this->success[_i433]); + xfer += iprot->readString(this->success[_i436]); } xfer += iprot->readListEnd(); } @@ -3908,10 +3908,10 @@ uint32_t ThriftHiveMetastore_get_all_tables_result::write(::apache::thrift::prot 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 _iter434; - for (_iter434 = this->success.begin(); _iter434 != this->success.end(); ++_iter434) + std::vector ::const_iterator _iter437; + for (_iter437 = this->success.begin(); _iter437 != this->success.end(); ++_iter437) { - xfer += oprot->writeString((*_iter434)); + xfer += oprot->writeString((*_iter437)); } xfer += oprot->writeListEnd(); } @@ -3950,14 +3950,14 @@ uint32_t ThriftHiveMetastore_get_all_tables_presult::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size435; - ::apache::thrift::protocol::TType _etype438; - xfer += iprot->readListBegin(_etype438, _size435); - (*(this->success)).resize(_size435); - uint32_t _i439; - for (_i439 = 0; _i439 < _size435; ++_i439) + 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 += iprot->readString((*(this->success))[_i439]); + xfer += iprot->readString((*(this->success))[_i442]); } xfer += iprot->readListEnd(); } @@ -4236,14 +4236,14 @@ uint32_t ThriftHiveMetastore_get_table_objects_by_name_args::read(::apache::thri if (ftype == ::apache::thrift::protocol::T_LIST) { { this->tbl_names.clear(); - uint32_t _size440; - ::apache::thrift::protocol::TType _etype443; - xfer += iprot->readListBegin(_etype443, _size440); - this->tbl_names.resize(_size440); - uint32_t _i444; - for (_i444 = 0; _i444 < _size440; ++_i444) + uint32_t _size443; + ::apache::thrift::protocol::TType _etype446; + xfer += iprot->readListBegin(_etype446, _size443); + this->tbl_names.resize(_size443); + uint32_t _i447; + for (_i447 = 0; _i447 < _size443; ++_i447) { - xfer += iprot->readString(this->tbl_names[_i444]); + xfer += iprot->readString(this->tbl_names[_i447]); } xfer += iprot->readListEnd(); } @@ -4275,10 +4275,10 @@ uint32_t ThriftHiveMetastore_get_table_objects_by_name_args::write(::apache::thr 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 _iter445; - for (_iter445 = this->tbl_names.begin(); _iter445 != this->tbl_names.end(); ++_iter445) + std::vector ::const_iterator _iter448; + for (_iter448 = this->tbl_names.begin(); _iter448 != this->tbl_names.end(); ++_iter448) { - xfer += oprot->writeString((*_iter445)); + xfer += oprot->writeString((*_iter448)); } xfer += oprot->writeListEnd(); } @@ -4300,10 +4300,10 @@ uint32_t ThriftHiveMetastore_get_table_objects_by_name_pargs::write(::apache::th 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 _iter446; - for (_iter446 = (*(this->tbl_names)).begin(); _iter446 != (*(this->tbl_names)).end(); ++_iter446) + std::vector ::const_iterator _iter449; + for (_iter449 = (*(this->tbl_names)).begin(); _iter449 != (*(this->tbl_names)).end(); ++_iter449) { - xfer += oprot->writeString((*_iter446)); + xfer += oprot->writeString((*_iter449)); } xfer += oprot->writeListEnd(); } @@ -4338,14 +4338,14 @@ uint32_t ThriftHiveMetastore_get_table_objects_by_name_result::read(::apache::th if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size447; - ::apache::thrift::protocol::TType _etype450; - xfer += iprot->readListBegin(_etype450, _size447); - this->success.resize(_size447); - uint32_t _i451; - for (_i451 = 0; _i451 < _size447; ++_i451) + uint32_t _size450; + ::apache::thrift::protocol::TType _etype453; + xfer += iprot->readListBegin(_etype453, _size450); + this->success.resize(_size450); + uint32_t _i454; + for (_i454 = 0; _i454 < _size450; ++_i454) { - xfer += this->success[_i451].read(iprot); + xfer += this->success[_i454].read(iprot); } xfer += iprot->readListEnd(); } @@ -4400,10 +4400,10 @@ uint32_t ThriftHiveMetastore_get_table_objects_by_name_result::write(::apache::t 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 _iter452; - for (_iter452 = this->success.begin(); _iter452 != this->success.end(); ++_iter452) + std::vector
::const_iterator _iter455; + for (_iter455 = this->success.begin(); _iter455 != this->success.end(); ++_iter455) { - xfer += (*_iter452).write(oprot); + xfer += (*_iter455).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4450,14 +4450,14 @@ uint32_t ThriftHiveMetastore_get_table_objects_by_name_presult::read(::apache::t if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size453; - ::apache::thrift::protocol::TType _etype456; - xfer += iprot->readListBegin(_etype456, _size453); - (*(this->success)).resize(_size453); - uint32_t _i457; - for (_i457 = 0; _i457 < _size453; ++_i457) + uint32_t _size456; + ::apache::thrift::protocol::TType _etype459; + xfer += iprot->readListBegin(_etype459, _size456); + (*(this->success)).resize(_size456); + uint32_t _i460; + for (_i460 = 0; _i460 < _size456; ++_i460) { - xfer += (*(this->success))[_i457].read(iprot); + xfer += (*(this->success))[_i460].read(iprot); } xfer += iprot->readListEnd(); } @@ -4624,14 +4624,14 @@ uint32_t ThriftHiveMetastore_get_table_names_by_filter_result::read(::apache::th if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size458; - ::apache::thrift::protocol::TType _etype461; - xfer += iprot->readListBegin(_etype461, _size458); - this->success.resize(_size458); - uint32_t _i462; - for (_i462 = 0; _i462 < _size458; ++_i462) + uint32_t _size461; + ::apache::thrift::protocol::TType _etype464; + xfer += iprot->readListBegin(_etype464, _size461); + this->success.resize(_size461); + uint32_t _i465; + for (_i465 = 0; _i465 < _size461; ++_i465) { - xfer += iprot->readString(this->success[_i462]); + xfer += iprot->readString(this->success[_i465]); } xfer += iprot->readListEnd(); } @@ -4686,10 +4686,10 @@ uint32_t ThriftHiveMetastore_get_table_names_by_filter_result::write(::apache::t 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 _iter463; - for (_iter463 = this->success.begin(); _iter463 != this->success.end(); ++_iter463) + std::vector ::const_iterator _iter466; + for (_iter466 = this->success.begin(); _iter466 != this->success.end(); ++_iter466) { - xfer += oprot->writeString((*_iter463)); + xfer += oprot->writeString((*_iter466)); } xfer += oprot->writeListEnd(); } @@ -4736,14 +4736,14 @@ uint32_t ThriftHiveMetastore_get_table_names_by_filter_presult::read(::apache::t if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size464; - ::apache::thrift::protocol::TType _etype467; - xfer += iprot->readListBegin(_etype467, _size464); - (*(this->success)).resize(_size464); - uint32_t _i468; - for (_i468 = 0; _i468 < _size464; ++_i468) + uint32_t _size467; + ::apache::thrift::protocol::TType _etype470; + xfer += iprot->readListBegin(_etype470, _size467); + (*(this->success)).resize(_size467); + uint32_t _i471; + for (_i471 = 0; _i471 < _size467; ++_i471) { - xfer += iprot->readString((*(this->success))[_i468]); + xfer += iprot->readString((*(this->success))[_i471]); } xfer += iprot->readListEnd(); } @@ -5716,14 +5716,14 @@ uint32_t ThriftHiveMetastore_add_partitions_args::read(::apache::thrift::protoco if (ftype == ::apache::thrift::protocol::T_LIST) { { this->new_parts.clear(); - uint32_t _size469; - ::apache::thrift::protocol::TType _etype472; - xfer += iprot->readListBegin(_etype472, _size469); - this->new_parts.resize(_size469); - uint32_t _i473; - for (_i473 = 0; _i473 < _size469; ++_i473) + uint32_t _size472; + ::apache::thrift::protocol::TType _etype475; + xfer += iprot->readListBegin(_etype475, _size472); + this->new_parts.resize(_size472); + uint32_t _i476; + for (_i476 = 0; _i476 < _size472; ++_i476) { - xfer += this->new_parts[_i473].read(iprot); + xfer += this->new_parts[_i476].read(iprot); } xfer += iprot->readListEnd(); } @@ -5751,10 +5751,10 @@ uint32_t ThriftHiveMetastore_add_partitions_args::write(::apache::thrift::protoc 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 _iter474; - for (_iter474 = this->new_parts.begin(); _iter474 != this->new_parts.end(); ++_iter474) + std::vector ::const_iterator _iter477; + for (_iter477 = this->new_parts.begin(); _iter477 != this->new_parts.end(); ++_iter477) { - xfer += (*_iter474).write(oprot); + xfer += (*_iter477).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5772,10 +5772,10 @@ uint32_t ThriftHiveMetastore_add_partitions_pargs::write(::apache::thrift::proto 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 _iter475; - for (_iter475 = (*(this->new_parts)).begin(); _iter475 != (*(this->new_parts)).end(); ++_iter475) + std::vector ::const_iterator _iter478; + for (_iter478 = (*(this->new_parts)).begin(); _iter478 != (*(this->new_parts)).end(); ++_iter478) { - xfer += (*_iter475).write(oprot); + xfer += (*_iter478).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5982,14 +5982,14 @@ uint32_t ThriftHiveMetastore_append_partition_args::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size476; - ::apache::thrift::protocol::TType _etype479; - xfer += iprot->readListBegin(_etype479, _size476); - this->part_vals.resize(_size476); - uint32_t _i480; - for (_i480 = 0; _i480 < _size476; ++_i480) + uint32_t _size479; + ::apache::thrift::protocol::TType _etype482; + xfer += iprot->readListBegin(_etype482, _size479); + this->part_vals.resize(_size479); + uint32_t _i483; + for (_i483 = 0; _i483 < _size479; ++_i483) { - xfer += iprot->readString(this->part_vals[_i480]); + xfer += iprot->readString(this->part_vals[_i483]); } xfer += iprot->readListEnd(); } @@ -6025,10 +6025,10 @@ uint32_t ThriftHiveMetastore_append_partition_args::write(::apache::thrift::prot 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 _iter481; - for (_iter481 = this->part_vals.begin(); _iter481 != this->part_vals.end(); ++_iter481) + std::vector ::const_iterator _iter484; + for (_iter484 = this->part_vals.begin(); _iter484 != this->part_vals.end(); ++_iter484) { - xfer += oprot->writeString((*_iter481)); + xfer += oprot->writeString((*_iter484)); } xfer += oprot->writeListEnd(); } @@ -6054,10 +6054,10 @@ uint32_t ThriftHiveMetastore_append_partition_pargs::write(::apache::thrift::pro 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 _iter482; - for (_iter482 = (*(this->part_vals)).begin(); _iter482 != (*(this->part_vals)).end(); ++_iter482) + std::vector ::const_iterator _iter485; + for (_iter485 = (*(this->part_vals)).begin(); _iter485 != (*(this->part_vals)).end(); ++_iter485) { - xfer += oprot->writeString((*_iter482)); + xfer += oprot->writeString((*_iter485)); } xfer += oprot->writeListEnd(); } @@ -6486,14 +6486,14 @@ uint32_t ThriftHiveMetastore_append_partition_with_environment_context_args::rea if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size483; - ::apache::thrift::protocol::TType _etype486; - xfer += iprot->readListBegin(_etype486, _size483); - this->part_vals.resize(_size483); - uint32_t _i487; - for (_i487 = 0; _i487 < _size483; ++_i487) + 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) { - xfer += iprot->readString(this->part_vals[_i487]); + xfer += iprot->readString(this->part_vals[_i490]); } xfer += iprot->readListEnd(); } @@ -6537,10 +6537,10 @@ uint32_t ThriftHiveMetastore_append_partition_with_environment_context_args::wri 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 _iter488; - for (_iter488 = this->part_vals.begin(); _iter488 != this->part_vals.end(); ++_iter488) + std::vector ::const_iterator _iter491; + for (_iter491 = this->part_vals.begin(); _iter491 != this->part_vals.end(); ++_iter491) { - xfer += oprot->writeString((*_iter488)); + xfer += oprot->writeString((*_iter491)); } xfer += oprot->writeListEnd(); } @@ -6570,10 +6570,10 @@ uint32_t ThriftHiveMetastore_append_partition_with_environment_context_pargs::wr 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 _iter489; - for (_iter489 = (*(this->part_vals)).begin(); _iter489 != (*(this->part_vals)).end(); ++_iter489) + std::vector ::const_iterator _iter492; + for (_iter492 = (*(this->part_vals)).begin(); _iter492 != (*(this->part_vals)).end(); ++_iter492) { - xfer += oprot->writeString((*_iter489)); + xfer += oprot->writeString((*_iter492)); } xfer += oprot->writeListEnd(); } @@ -7308,14 +7308,14 @@ uint32_t ThriftHiveMetastore_drop_partition_args::read(::apache::thrift::protoco if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size490; - ::apache::thrift::protocol::TType _etype493; - xfer += iprot->readListBegin(_etype493, _size490); - this->part_vals.resize(_size490); - uint32_t _i494; - for (_i494 = 0; _i494 < _size490; ++_i494) + 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) { - xfer += iprot->readString(this->part_vals[_i494]); + xfer += iprot->readString(this->part_vals[_i497]); } xfer += iprot->readListEnd(); } @@ -7359,10 +7359,10 @@ uint32_t ThriftHiveMetastore_drop_partition_args::write(::apache::thrift::protoc 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 _iter495; - for (_iter495 = this->part_vals.begin(); _iter495 != this->part_vals.end(); ++_iter495) + std::vector ::const_iterator _iter498; + for (_iter498 = this->part_vals.begin(); _iter498 != this->part_vals.end(); ++_iter498) { - xfer += oprot->writeString((*_iter495)); + xfer += oprot->writeString((*_iter498)); } xfer += oprot->writeListEnd(); } @@ -7392,10 +7392,10 @@ uint32_t ThriftHiveMetastore_drop_partition_pargs::write(::apache::thrift::proto 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 _iter496; - for (_iter496 = (*(this->part_vals)).begin(); _iter496 != (*(this->part_vals)).end(); ++_iter496) + std::vector ::const_iterator _iter499; + for (_iter499 = (*(this->part_vals)).begin(); _iter499 != (*(this->part_vals)).end(); ++_iter499) { - xfer += oprot->writeString((*_iter496)); + xfer += oprot->writeString((*_iter499)); } xfer += oprot->writeListEnd(); } @@ -7586,14 +7586,14 @@ uint32_t ThriftHiveMetastore_drop_partition_with_environment_context_args::read( if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size497; - ::apache::thrift::protocol::TType _etype500; - xfer += iprot->readListBegin(_etype500, _size497); - this->part_vals.resize(_size497); - uint32_t _i501; - for (_i501 = 0; _i501 < _size497; ++_i501) + 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) { - xfer += iprot->readString(this->part_vals[_i501]); + xfer += iprot->readString(this->part_vals[_i504]); } xfer += iprot->readListEnd(); } @@ -7645,10 +7645,10 @@ uint32_t ThriftHiveMetastore_drop_partition_with_environment_context_args::write 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 _iter502; - for (_iter502 = this->part_vals.begin(); _iter502 != this->part_vals.end(); ++_iter502) + std::vector ::const_iterator _iter505; + for (_iter505 = this->part_vals.begin(); _iter505 != this->part_vals.end(); ++_iter505) { - xfer += oprot->writeString((*_iter502)); + xfer += oprot->writeString((*_iter505)); } xfer += oprot->writeListEnd(); } @@ -7682,10 +7682,10 @@ uint32_t ThriftHiveMetastore_drop_partition_with_environment_context_pargs::writ 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 _iter503; - for (_iter503 = (*(this->part_vals)).begin(); _iter503 != (*(this->part_vals)).end(); ++_iter503) + std::vector ::const_iterator _iter506; + for (_iter506 = (*(this->part_vals)).begin(); _iter506 != (*(this->part_vals)).end(); ++_iter506) { - xfer += oprot->writeString((*_iter503)); + xfer += oprot->writeString((*_iter506)); } xfer += oprot->writeListEnd(); } @@ -8598,14 +8598,14 @@ uint32_t ThriftHiveMetastore_get_partition_args::read(::apache::thrift::protocol if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size504; - ::apache::thrift::protocol::TType _etype507; - xfer += iprot->readListBegin(_etype507, _size504); - this->part_vals.resize(_size504); - uint32_t _i508; - for (_i508 = 0; _i508 < _size504; ++_i508) + uint32_t _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) { - xfer += iprot->readString(this->part_vals[_i508]); + xfer += iprot->readString(this->part_vals[_i511]); } xfer += iprot->readListEnd(); } @@ -8641,10 +8641,10 @@ uint32_t ThriftHiveMetastore_get_partition_args::write(::apache::thrift::protoco xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->part_vals.size())); - std::vector ::const_iterator _iter509; - for (_iter509 = this->part_vals.begin(); _iter509 != this->part_vals.end(); ++_iter509) + std::vector ::const_iterator _iter512; + for (_iter512 = this->part_vals.begin(); _iter512 != this->part_vals.end(); ++_iter512) { - xfer += oprot->writeString((*_iter509)); + xfer += oprot->writeString((*_iter512)); } xfer += oprot->writeListEnd(); } @@ -8670,10 +8670,10 @@ uint32_t ThriftHiveMetastore_get_partition_pargs::write(::apache::thrift::protoc xfer += oprot->writeFieldBegin("part_vals", ::apache::thrift::protocol::T_LIST, 3); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*(this->part_vals)).size())); - std::vector ::const_iterator _iter510; - for (_iter510 = (*(this->part_vals)).begin(); _iter510 != (*(this->part_vals)).end(); ++_iter510) + std::vector ::const_iterator _iter513; + for (_iter513 = (*(this->part_vals)).begin(); _iter513 != (*(this->part_vals)).end(); ++_iter513) { - xfer += oprot->writeString((*_iter510)); + xfer += oprot->writeString((*_iter513)); } xfer += oprot->writeListEnd(); } @@ -8844,17 +8844,17 @@ uint32_t ThriftHiveMetastore_exchange_partition_args::read(::apache::thrift::pro if (ftype == ::apache::thrift::protocol::T_MAP) { { this->partitionSpecs.clear(); - uint32_t _size511; - ::apache::thrift::protocol::TType _ktype512; - ::apache::thrift::protocol::TType _vtype513; - xfer += iprot->readMapBegin(_ktype512, _vtype513, _size511); - uint32_t _i515; - for (_i515 = 0; _i515 < _size511; ++_i515) + uint32_t _size514; + ::apache::thrift::protocol::TType _ktype515; + ::apache::thrift::protocol::TType _vtype516; + xfer += iprot->readMapBegin(_ktype515, _vtype516, _size514); + uint32_t _i518; + for (_i518 = 0; _i518 < _size514; ++_i518) { - std::string _key516; - xfer += iprot->readString(_key516); - std::string& _val517 = this->partitionSpecs[_key516]; - xfer += iprot->readString(_val517); + std::string _key519; + xfer += iprot->readString(_key519); + std::string& _val520 = this->partitionSpecs[_key519]; + xfer += iprot->readString(_val520); } xfer += iprot->readMapEnd(); } @@ -8914,11 +8914,11 @@ uint32_t ThriftHiveMetastore_exchange_partition_args::write(::apache::thrift::pr 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 _iter518; - for (_iter518 = this->partitionSpecs.begin(); _iter518 != this->partitionSpecs.end(); ++_iter518) + std::map ::const_iterator _iter521; + for (_iter521 = this->partitionSpecs.begin(); _iter521 != this->partitionSpecs.end(); ++_iter521) { - xfer += oprot->writeString(_iter518->first); - xfer += oprot->writeString(_iter518->second); + xfer += oprot->writeString(_iter521->first); + xfer += oprot->writeString(_iter521->second); } xfer += oprot->writeMapEnd(); } @@ -8952,11 +8952,11 @@ uint32_t ThriftHiveMetastore_exchange_partition_pargs::write(::apache::thrift::p 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 _iter519; - for (_iter519 = (*(this->partitionSpecs)).begin(); _iter519 != (*(this->partitionSpecs)).end(); ++_iter519) + std::map ::const_iterator _iter522; + for (_iter522 = (*(this->partitionSpecs)).begin(); _iter522 != (*(this->partitionSpecs)).end(); ++_iter522) { - xfer += oprot->writeString(_iter519->first); - xfer += oprot->writeString(_iter519->second); + xfer += oprot->writeString(_iter522->first); + xfer += oprot->writeString(_iter522->second); } xfer += oprot->writeMapEnd(); } @@ -9199,14 +9199,14 @@ uint32_t ThriftHiveMetastore_get_partition_with_auth_args::read(::apache::thrift if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size520; - ::apache::thrift::protocol::TType _etype523; - xfer += iprot->readListBegin(_etype523, _size520); - this->part_vals.resize(_size520); - uint32_t _i524; - for (_i524 = 0; _i524 < _size520; ++_i524) + uint32_t _size523; + ::apache::thrift::protocol::TType _etype526; + xfer += iprot->readListBegin(_etype526, _size523); + this->part_vals.resize(_size523); + uint32_t _i527; + for (_i527 = 0; _i527 < _size523; ++_i527) { - xfer += iprot->readString(this->part_vals[_i524]); + xfer += iprot->readString(this->part_vals[_i527]); } xfer += iprot->readListEnd(); } @@ -9227,14 +9227,14 @@ uint32_t ThriftHiveMetastore_get_partition_with_auth_args::read(::apache::thrift if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size525; - ::apache::thrift::protocol::TType _etype528; - xfer += iprot->readListBegin(_etype528, _size525); - this->group_names.resize(_size525); - uint32_t _i529; - for (_i529 = 0; _i529 < _size525; ++_i529) + uint32_t _size528; + ::apache::thrift::protocol::TType _etype531; + xfer += iprot->readListBegin(_etype531, _size528); + this->group_names.resize(_size528); + uint32_t _i532; + for (_i532 = 0; _i532 < _size528; ++_i532) { - xfer += iprot->readString(this->group_names[_i529]); + xfer += iprot->readString(this->group_names[_i532]); } xfer += iprot->readListEnd(); } @@ -9270,10 +9270,10 @@ uint32_t ThriftHiveMetastore_get_partition_with_auth_args::write(::apache::thrif 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 _iter530; - for (_iter530 = this->part_vals.begin(); _iter530 != this->part_vals.end(); ++_iter530) + std::vector ::const_iterator _iter533; + for (_iter533 = this->part_vals.begin(); _iter533 != this->part_vals.end(); ++_iter533) { - xfer += oprot->writeString((*_iter530)); + xfer += oprot->writeString((*_iter533)); } xfer += oprot->writeListEnd(); } @@ -9286,10 +9286,10 @@ uint32_t ThriftHiveMetastore_get_partition_with_auth_args::write(::apache::thrif 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 _iter531; - for (_iter531 = this->group_names.begin(); _iter531 != this->group_names.end(); ++_iter531) + std::vector ::const_iterator _iter534; + for (_iter534 = this->group_names.begin(); _iter534 != this->group_names.end(); ++_iter534) { - xfer += oprot->writeString((*_iter531)); + xfer += oprot->writeString((*_iter534)); } xfer += oprot->writeListEnd(); } @@ -9315,10 +9315,10 @@ uint32_t ThriftHiveMetastore_get_partition_with_auth_pargs::write(::apache::thri 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 _iter532; - for (_iter532 = (*(this->part_vals)).begin(); _iter532 != (*(this->part_vals)).end(); ++_iter532) + std::vector ::const_iterator _iter535; + for (_iter535 = (*(this->part_vals)).begin(); _iter535 != (*(this->part_vals)).end(); ++_iter535) { - xfer += oprot->writeString((*_iter532)); + xfer += oprot->writeString((*_iter535)); } xfer += oprot->writeListEnd(); } @@ -9331,10 +9331,10 @@ uint32_t ThriftHiveMetastore_get_partition_with_auth_pargs::write(::apache::thri 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 _iter533; - for (_iter533 = (*(this->group_names)).begin(); _iter533 != (*(this->group_names)).end(); ++_iter533) + std::vector ::const_iterator _iter536; + for (_iter536 = (*(this->group_names)).begin(); _iter536 != (*(this->group_names)).end(); ++_iter536) { - xfer += oprot->writeString((*_iter533)); + xfer += oprot->writeString((*_iter536)); } xfer += oprot->writeListEnd(); } @@ -9837,14 +9837,14 @@ uint32_t ThriftHiveMetastore_get_partitions_result::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size534; - ::apache::thrift::protocol::TType _etype537; - xfer += iprot->readListBegin(_etype537, _size534); - this->success.resize(_size534); - uint32_t _i538; - for (_i538 = 0; _i538 < _size534; ++_i538) + uint32_t _size537; + ::apache::thrift::protocol::TType _etype540; + xfer += iprot->readListBegin(_etype540, _size537); + this->success.resize(_size537); + uint32_t _i541; + for (_i541 = 0; _i541 < _size537; ++_i541) { - xfer += this->success[_i538].read(iprot); + xfer += this->success[_i541].read(iprot); } xfer += iprot->readListEnd(); } @@ -9891,10 +9891,10 @@ uint32_t ThriftHiveMetastore_get_partitions_result::write(::apache::thrift::prot 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 _iter539; - for (_iter539 = this->success.begin(); _iter539 != this->success.end(); ++_iter539) + std::vector ::const_iterator _iter542; + for (_iter542 = this->success.begin(); _iter542 != this->success.end(); ++_iter542) { - xfer += (*_iter539).write(oprot); + xfer += (*_iter542).write(oprot); } xfer += oprot->writeListEnd(); } @@ -9937,14 +9937,14 @@ uint32_t ThriftHiveMetastore_get_partitions_presult::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size540; - ::apache::thrift::protocol::TType _etype543; - xfer += iprot->readListBegin(_etype543, _size540); - (*(this->success)).resize(_size540); - uint32_t _i544; - for (_i544 = 0; _i544 < _size540; ++_i544) + uint32_t _size543; + ::apache::thrift::protocol::TType _etype546; + xfer += iprot->readListBegin(_etype546, _size543); + (*(this->success)).resize(_size543); + uint32_t _i547; + for (_i547 = 0; _i547 < _size543; ++_i547) { - xfer += (*(this->success))[_i544].read(iprot); + xfer += (*(this->success))[_i547].read(iprot); } xfer += iprot->readListEnd(); } @@ -10037,14 +10037,14 @@ uint32_t ThriftHiveMetastore_get_partitions_with_auth_args::read(::apache::thrif if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size545; - ::apache::thrift::protocol::TType _etype548; - xfer += iprot->readListBegin(_etype548, _size545); - this->group_names.resize(_size545); - uint32_t _i549; - for (_i549 = 0; _i549 < _size545; ++_i549) + uint32_t _size548; + ::apache::thrift::protocol::TType _etype551; + xfer += iprot->readListBegin(_etype551, _size548); + this->group_names.resize(_size548); + uint32_t _i552; + for (_i552 = 0; _i552 < _size548; ++_i552) { - xfer += iprot->readString(this->group_names[_i549]); + xfer += iprot->readString(this->group_names[_i552]); } xfer += iprot->readListEnd(); } @@ -10088,10 +10088,10 @@ uint32_t ThriftHiveMetastore_get_partitions_with_auth_args::write(::apache::thri 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 _iter550; - for (_iter550 = this->group_names.begin(); _iter550 != this->group_names.end(); ++_iter550) + std::vector ::const_iterator _iter553; + for (_iter553 = this->group_names.begin(); _iter553 != this->group_names.end(); ++_iter553) { - xfer += oprot->writeString((*_iter550)); + xfer += oprot->writeString((*_iter553)); } xfer += oprot->writeListEnd(); } @@ -10125,10 +10125,10 @@ uint32_t ThriftHiveMetastore_get_partitions_with_auth_pargs::write(::apache::thr 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 _iter551; - for (_iter551 = (*(this->group_names)).begin(); _iter551 != (*(this->group_names)).end(); ++_iter551) + std::vector ::const_iterator _iter554; + for (_iter554 = (*(this->group_names)).begin(); _iter554 != (*(this->group_names)).end(); ++_iter554) { - xfer += oprot->writeString((*_iter551)); + xfer += oprot->writeString((*_iter554)); } xfer += oprot->writeListEnd(); } @@ -10163,14 +10163,14 @@ uint32_t ThriftHiveMetastore_get_partitions_with_auth_result::read(::apache::thr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size552; - ::apache::thrift::protocol::TType _etype555; - xfer += iprot->readListBegin(_etype555, _size552); - this->success.resize(_size552); - uint32_t _i556; - for (_i556 = 0; _i556 < _size552; ++_i556) + uint32_t _size555; + ::apache::thrift::protocol::TType _etype558; + xfer += iprot->readListBegin(_etype558, _size555); + this->success.resize(_size555); + uint32_t _i559; + for (_i559 = 0; _i559 < _size555; ++_i559) { - xfer += this->success[_i556].read(iprot); + xfer += this->success[_i559].read(iprot); } xfer += iprot->readListEnd(); } @@ -10217,10 +10217,10 @@ uint32_t ThriftHiveMetastore_get_partitions_with_auth_result::write(::apache::th 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 _iter557; - for (_iter557 = this->success.begin(); _iter557 != this->success.end(); ++_iter557) + std::vector ::const_iterator _iter560; + for (_iter560 = this->success.begin(); _iter560 != this->success.end(); ++_iter560) { - xfer += (*_iter557).write(oprot); + xfer += (*_iter560).write(oprot); } xfer += oprot->writeListEnd(); } @@ -10263,14 +10263,14 @@ uint32_t ThriftHiveMetastore_get_partitions_with_auth_presult::read(::apache::th if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size558; - ::apache::thrift::protocol::TType _etype561; - xfer += iprot->readListBegin(_etype561, _size558); - (*(this->success)).resize(_size558); - uint32_t _i562; - for (_i562 = 0; _i562 < _size558; ++_i562) + uint32_t _size561; + ::apache::thrift::protocol::TType _etype564; + xfer += iprot->readListBegin(_etype564, _size561); + (*(this->success)).resize(_size561); + uint32_t _i565; + for (_i565 = 0; _i565 < _size561; ++_i565) { - xfer += (*(this->success))[_i562].read(iprot); + xfer += (*(this->success))[_i565].read(iprot); } xfer += iprot->readListEnd(); } @@ -10429,14 +10429,14 @@ uint32_t ThriftHiveMetastore_get_partition_names_result::read(::apache::thrift:: if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size563; - ::apache::thrift::protocol::TType _etype566; - xfer += iprot->readListBegin(_etype566, _size563); - this->success.resize(_size563); - uint32_t _i567; - for (_i567 = 0; _i567 < _size563; ++_i567) + uint32_t _size566; + ::apache::thrift::protocol::TType _etype569; + xfer += iprot->readListBegin(_etype569, _size566); + this->success.resize(_size566); + uint32_t _i570; + for (_i570 = 0; _i570 < _size566; ++_i570) { - xfer += iprot->readString(this->success[_i567]); + xfer += iprot->readString(this->success[_i570]); } xfer += iprot->readListEnd(); } @@ -10475,10 +10475,10 @@ uint32_t ThriftHiveMetastore_get_partition_names_result::write(::apache::thrift: 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 _iter568; - for (_iter568 = this->success.begin(); _iter568 != this->success.end(); ++_iter568) + std::vector ::const_iterator _iter571; + for (_iter571 = this->success.begin(); _iter571 != this->success.end(); ++_iter571) { - xfer += oprot->writeString((*_iter568)); + xfer += oprot->writeString((*_iter571)); } xfer += oprot->writeListEnd(); } @@ -10517,14 +10517,14 @@ uint32_t ThriftHiveMetastore_get_partition_names_presult::read(::apache::thrift: if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size569; - ::apache::thrift::protocol::TType _etype572; - xfer += iprot->readListBegin(_etype572, _size569); - (*(this->success)).resize(_size569); - uint32_t _i573; - for (_i573 = 0; _i573 < _size569; ++_i573) + uint32_t _size572; + ::apache::thrift::protocol::TType _etype575; + xfer += iprot->readListBegin(_etype575, _size572); + (*(this->success)).resize(_size572); + uint32_t _i576; + for (_i576 = 0; _i576 < _size572; ++_i576) { - xfer += iprot->readString((*(this->success))[_i573]); + xfer += iprot->readString((*(this->success))[_i576]); } xfer += iprot->readListEnd(); } @@ -10593,14 +10593,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_args::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size574; - ::apache::thrift::protocol::TType _etype577; - xfer += iprot->readListBegin(_etype577, _size574); - this->part_vals.resize(_size574); - uint32_t _i578; - for (_i578 = 0; _i578 < _size574; ++_i578) + uint32_t _size577; + ::apache::thrift::protocol::TType _etype580; + xfer += iprot->readListBegin(_etype580, _size577); + this->part_vals.resize(_size577); + uint32_t _i581; + for (_i581 = 0; _i581 < _size577; ++_i581) { - xfer += iprot->readString(this->part_vals[_i578]); + xfer += iprot->readString(this->part_vals[_i581]); } xfer += iprot->readListEnd(); } @@ -10644,10 +10644,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_args::write(::apache::thrift::pro 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 _iter579; - for (_iter579 = this->part_vals.begin(); _iter579 != this->part_vals.end(); ++_iter579) + std::vector ::const_iterator _iter582; + for (_iter582 = this->part_vals.begin(); _iter582 != this->part_vals.end(); ++_iter582) { - xfer += oprot->writeString((*_iter579)); + xfer += oprot->writeString((*_iter582)); } xfer += oprot->writeListEnd(); } @@ -10677,10 +10677,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_pargs::write(::apache::thrift::pr 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 _iter580; - for (_iter580 = (*(this->part_vals)).begin(); _iter580 != (*(this->part_vals)).end(); ++_iter580) + std::vector ::const_iterator _iter583; + for (_iter583 = (*(this->part_vals)).begin(); _iter583 != (*(this->part_vals)).end(); ++_iter583) { - xfer += oprot->writeString((*_iter580)); + xfer += oprot->writeString((*_iter583)); } xfer += oprot->writeListEnd(); } @@ -10719,14 +10719,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_result::read(::apache::thrift::pr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size581; - ::apache::thrift::protocol::TType _etype584; - xfer += iprot->readListBegin(_etype584, _size581); - this->success.resize(_size581); - uint32_t _i585; - for (_i585 = 0; _i585 < _size581; ++_i585) + uint32_t _size584; + ::apache::thrift::protocol::TType _etype587; + xfer += iprot->readListBegin(_etype587, _size584); + this->success.resize(_size584); + uint32_t _i588; + for (_i588 = 0; _i588 < _size584; ++_i588) { - xfer += this->success[_i585].read(iprot); + xfer += this->success[_i588].read(iprot); } xfer += iprot->readListEnd(); } @@ -10773,10 +10773,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_result::write(::apache::thrift::p 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 _iter586; - for (_iter586 = this->success.begin(); _iter586 != this->success.end(); ++_iter586) + std::vector ::const_iterator _iter589; + for (_iter589 = this->success.begin(); _iter589 != this->success.end(); ++_iter589) { - xfer += (*_iter586).write(oprot); + xfer += (*_iter589).write(oprot); } xfer += oprot->writeListEnd(); } @@ -10819,14 +10819,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_presult::read(::apache::thrift::p if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size587; - ::apache::thrift::protocol::TType _etype590; - xfer += iprot->readListBegin(_etype590, _size587); - (*(this->success)).resize(_size587); - uint32_t _i591; - for (_i591 = 0; _i591 < _size587; ++_i591) + uint32_t _size590; + ::apache::thrift::protocol::TType _etype593; + xfer += iprot->readListBegin(_etype593, _size590); + (*(this->success)).resize(_size590); + uint32_t _i594; + for (_i594 = 0; _i594 < _size590; ++_i594) { - xfer += (*(this->success))[_i591].read(iprot); + xfer += (*(this->success))[_i594].read(iprot); } xfer += iprot->readListEnd(); } @@ -10903,14 +10903,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_args::read(::apache::th if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size592; - ::apache::thrift::protocol::TType _etype595; - xfer += iprot->readListBegin(_etype595, _size592); - this->part_vals.resize(_size592); - uint32_t _i596; - for (_i596 = 0; _i596 < _size592; ++_i596) + uint32_t _size595; + ::apache::thrift::protocol::TType _etype598; + xfer += iprot->readListBegin(_etype598, _size595); + this->part_vals.resize(_size595); + uint32_t _i599; + for (_i599 = 0; _i599 < _size595; ++_i599) { - xfer += iprot->readString(this->part_vals[_i596]); + xfer += iprot->readString(this->part_vals[_i599]); } xfer += iprot->readListEnd(); } @@ -10939,14 +10939,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_args::read(::apache::th if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size597; - ::apache::thrift::protocol::TType _etype600; - xfer += iprot->readListBegin(_etype600, _size597); - this->group_names.resize(_size597); - uint32_t _i601; - for (_i601 = 0; _i601 < _size597; ++_i601) + uint32_t _size600; + ::apache::thrift::protocol::TType _etype603; + xfer += iprot->readListBegin(_etype603, _size600); + this->group_names.resize(_size600); + uint32_t _i604; + for (_i604 = 0; _i604 < _size600; ++_i604) { - xfer += iprot->readString(this->group_names[_i601]); + xfer += iprot->readString(this->group_names[_i604]); } xfer += iprot->readListEnd(); } @@ -10982,10 +10982,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_args::write(::apache::t 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 _iter602; - for (_iter602 = this->part_vals.begin(); _iter602 != this->part_vals.end(); ++_iter602) + std::vector ::const_iterator _iter605; + for (_iter605 = this->part_vals.begin(); _iter605 != this->part_vals.end(); ++_iter605) { - xfer += oprot->writeString((*_iter602)); + xfer += oprot->writeString((*_iter605)); } xfer += oprot->writeListEnd(); } @@ -11002,10 +11002,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_args::write(::apache::t 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 _iter603; - for (_iter603 = this->group_names.begin(); _iter603 != this->group_names.end(); ++_iter603) + std::vector ::const_iterator _iter606; + for (_iter606 = this->group_names.begin(); _iter606 != this->group_names.end(); ++_iter606) { - xfer += oprot->writeString((*_iter603)); + xfer += oprot->writeString((*_iter606)); } xfer += oprot->writeListEnd(); } @@ -11031,10 +11031,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_pargs::write(::apache:: 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 _iter604; - for (_iter604 = (*(this->part_vals)).begin(); _iter604 != (*(this->part_vals)).end(); ++_iter604) + std::vector ::const_iterator _iter607; + for (_iter607 = (*(this->part_vals)).begin(); _iter607 != (*(this->part_vals)).end(); ++_iter607) { - xfer += oprot->writeString((*_iter604)); + xfer += oprot->writeString((*_iter607)); } xfer += oprot->writeListEnd(); } @@ -11051,10 +11051,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_pargs::write(::apache:: 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 _iter605; - for (_iter605 = (*(this->group_names)).begin(); _iter605 != (*(this->group_names)).end(); ++_iter605) + std::vector ::const_iterator _iter608; + for (_iter608 = (*(this->group_names)).begin(); _iter608 != (*(this->group_names)).end(); ++_iter608) { - xfer += oprot->writeString((*_iter605)); + xfer += oprot->writeString((*_iter608)); } xfer += oprot->writeListEnd(); } @@ -11089,14 +11089,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_result::read(::apache:: 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) + uint32_t _size609; + ::apache::thrift::protocol::TType _etype612; + xfer += iprot->readListBegin(_etype612, _size609); + this->success.resize(_size609); + uint32_t _i613; + for (_i613 = 0; _i613 < _size609; ++_i613) { - xfer += this->success[_i610].read(iprot); + xfer += this->success[_i613].read(iprot); } xfer += iprot->readListEnd(); } @@ -11143,10 +11143,10 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_result::write(::apache: 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) + std::vector ::const_iterator _iter614; + for (_iter614 = this->success.begin(); _iter614 != this->success.end(); ++_iter614) { - xfer += (*_iter611).write(oprot); + xfer += (*_iter614).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11189,14 +11189,14 @@ uint32_t ThriftHiveMetastore_get_partitions_ps_with_auth_presult::read(::apache: 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) + uint32_t _size615; + ::apache::thrift::protocol::TType _etype618; + xfer += iprot->readListBegin(_etype618, _size615); + (*(this->success)).resize(_size615); + uint32_t _i619; + for (_i619 = 0; _i619 < _size615; ++_i619) { - xfer += (*(this->success))[_i616].read(iprot); + xfer += (*(this->success))[_i619].read(iprot); } xfer += iprot->readListEnd(); } @@ -11273,14 +11273,14 @@ uint32_t ThriftHiveMetastore_get_partition_names_ps_args::read(::apache::thrift: if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size617; - ::apache::thrift::protocol::TType _etype620; - xfer += iprot->readListBegin(_etype620, _size617); - this->part_vals.resize(_size617); - uint32_t _i621; - for (_i621 = 0; _i621 < _size617; ++_i621) + uint32_t _size620; + ::apache::thrift::protocol::TType _etype623; + xfer += iprot->readListBegin(_etype623, _size620); + this->part_vals.resize(_size620); + uint32_t _i624; + for (_i624 = 0; _i624 < _size620; ++_i624) { - xfer += iprot->readString(this->part_vals[_i621]); + xfer += iprot->readString(this->part_vals[_i624]); } xfer += iprot->readListEnd(); } @@ -11324,10 +11324,10 @@ uint32_t ThriftHiveMetastore_get_partition_names_ps_args::write(::apache::thrift 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 _iter622; - for (_iter622 = this->part_vals.begin(); _iter622 != this->part_vals.end(); ++_iter622) + std::vector ::const_iterator _iter625; + for (_iter625 = this->part_vals.begin(); _iter625 != this->part_vals.end(); ++_iter625) { - xfer += oprot->writeString((*_iter622)); + xfer += oprot->writeString((*_iter625)); } xfer += oprot->writeListEnd(); } @@ -11357,10 +11357,10 @@ uint32_t ThriftHiveMetastore_get_partition_names_ps_pargs::write(::apache::thrif 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 _iter623; - for (_iter623 = (*(this->part_vals)).begin(); _iter623 != (*(this->part_vals)).end(); ++_iter623) + std::vector ::const_iterator _iter626; + for (_iter626 = (*(this->part_vals)).begin(); _iter626 != (*(this->part_vals)).end(); ++_iter626) { - xfer += oprot->writeString((*_iter623)); + xfer += oprot->writeString((*_iter626)); } xfer += oprot->writeListEnd(); } @@ -11399,14 +11399,14 @@ uint32_t ThriftHiveMetastore_get_partition_names_ps_result::read(::apache::thrif if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size624; - ::apache::thrift::protocol::TType _etype627; - xfer += iprot->readListBegin(_etype627, _size624); - this->success.resize(_size624); - uint32_t _i628; - for (_i628 = 0; _i628 < _size624; ++_i628) + uint32_t _size627; + ::apache::thrift::protocol::TType _etype630; + xfer += iprot->readListBegin(_etype630, _size627); + this->success.resize(_size627); + uint32_t _i631; + for (_i631 = 0; _i631 < _size627; ++_i631) { - xfer += iprot->readString(this->success[_i628]); + xfer += iprot->readString(this->success[_i631]); } xfer += iprot->readListEnd(); } @@ -11453,10 +11453,10 @@ uint32_t ThriftHiveMetastore_get_partition_names_ps_result::write(::apache::thri 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 _iter629; - for (_iter629 = this->success.begin(); _iter629 != this->success.end(); ++_iter629) + std::vector ::const_iterator _iter632; + for (_iter632 = this->success.begin(); _iter632 != this->success.end(); ++_iter632) { - xfer += oprot->writeString((*_iter629)); + xfer += oprot->writeString((*_iter632)); } xfer += oprot->writeListEnd(); } @@ -11499,14 +11499,14 @@ uint32_t ThriftHiveMetastore_get_partition_names_ps_presult::read(::apache::thri if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size630; - ::apache::thrift::protocol::TType _etype633; - xfer += iprot->readListBegin(_etype633, _size630); - (*(this->success)).resize(_size630); - uint32_t _i634; - for (_i634 = 0; _i634 < _size630; ++_i634) + uint32_t _size633; + ::apache::thrift::protocol::TType _etype636; + xfer += iprot->readListBegin(_etype636, _size633); + (*(this->success)).resize(_size633); + uint32_t _i637; + for (_i637 = 0; _i637 < _size633; ++_i637) { - xfer += iprot->readString((*(this->success))[_i634]); + xfer += iprot->readString((*(this->success))[_i637]); } xfer += iprot->readListEnd(); } @@ -11681,14 +11681,14 @@ uint32_t ThriftHiveMetastore_get_partitions_by_filter_result::read(::apache::thr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - 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) + uint32_t _size638; + ::apache::thrift::protocol::TType _etype641; + xfer += iprot->readListBegin(_etype641, _size638); + this->success.resize(_size638); + uint32_t _i642; + for (_i642 = 0; _i642 < _size638; ++_i642) { - xfer += this->success[_i639].read(iprot); + xfer += this->success[_i642].read(iprot); } xfer += iprot->readListEnd(); } @@ -11735,10 +11735,10 @@ uint32_t ThriftHiveMetastore_get_partitions_by_filter_result::write(::apache::th 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 _iter640; - for (_iter640 = this->success.begin(); _iter640 != this->success.end(); ++_iter640) + std::vector ::const_iterator _iter643; + for (_iter643 = this->success.begin(); _iter643 != this->success.end(); ++_iter643) { - xfer += (*_iter640).write(oprot); + xfer += (*_iter643).write(oprot); } xfer += oprot->writeListEnd(); } @@ -11781,14 +11781,14 @@ uint32_t ThriftHiveMetastore_get_partitions_by_filter_presult::read(::apache::th if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - 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) + uint32_t _size644; + ::apache::thrift::protocol::TType _etype647; + xfer += iprot->readListBegin(_etype647, _size644); + (*(this->success)).resize(_size644); + uint32_t _i648; + for (_i648 = 0; _i648 < _size644; ++_i648) { - xfer += (*(this->success))[_i645].read(iprot); + xfer += (*(this->success))[_i648].read(iprot); } xfer += iprot->readListEnd(); } @@ -12067,14 +12067,14 @@ uint32_t ThriftHiveMetastore_get_partitions_by_names_args::read(::apache::thrift if (ftype == ::apache::thrift::protocol::T_LIST) { { this->names.clear(); - uint32_t _size646; - ::apache::thrift::protocol::TType _etype649; - xfer += iprot->readListBegin(_etype649, _size646); - this->names.resize(_size646); - uint32_t _i650; - for (_i650 = 0; _i650 < _size646; ++_i650) + uint32_t _size649; + ::apache::thrift::protocol::TType _etype652; + xfer += iprot->readListBegin(_etype652, _size649); + this->names.resize(_size649); + uint32_t _i653; + for (_i653 = 0; _i653 < _size649; ++_i653) { - xfer += iprot->readString(this->names[_i650]); + xfer += iprot->readString(this->names[_i653]); } xfer += iprot->readListEnd(); } @@ -12110,10 +12110,10 @@ uint32_t ThriftHiveMetastore_get_partitions_by_names_args::write(::apache::thrif 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 _iter651; - for (_iter651 = this->names.begin(); _iter651 != this->names.end(); ++_iter651) + std::vector ::const_iterator _iter654; + for (_iter654 = this->names.begin(); _iter654 != this->names.end(); ++_iter654) { - xfer += oprot->writeString((*_iter651)); + xfer += oprot->writeString((*_iter654)); } xfer += oprot->writeListEnd(); } @@ -12139,10 +12139,10 @@ uint32_t ThriftHiveMetastore_get_partitions_by_names_pargs::write(::apache::thri 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 _iter652; - for (_iter652 = (*(this->names)).begin(); _iter652 != (*(this->names)).end(); ++_iter652) + std::vector ::const_iterator _iter655; + for (_iter655 = (*(this->names)).begin(); _iter655 != (*(this->names)).end(); ++_iter655) { - xfer += oprot->writeString((*_iter652)); + xfer += oprot->writeString((*_iter655)); } xfer += oprot->writeListEnd(); } @@ -12177,14 +12177,14 @@ uint32_t ThriftHiveMetastore_get_partitions_by_names_result::read(::apache::thri if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size653; - ::apache::thrift::protocol::TType _etype656; - xfer += iprot->readListBegin(_etype656, _size653); - this->success.resize(_size653); - uint32_t _i657; - for (_i657 = 0; _i657 < _size653; ++_i657) + uint32_t _size656; + ::apache::thrift::protocol::TType _etype659; + xfer += iprot->readListBegin(_etype659, _size656); + this->success.resize(_size656); + uint32_t _i660; + for (_i660 = 0; _i660 < _size656; ++_i660) { - xfer += this->success[_i657].read(iprot); + xfer += this->success[_i660].read(iprot); } xfer += iprot->readListEnd(); } @@ -12231,10 +12231,10 @@ uint32_t ThriftHiveMetastore_get_partitions_by_names_result::write(::apache::thr 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 _iter658; - for (_iter658 = this->success.begin(); _iter658 != this->success.end(); ++_iter658) + std::vector ::const_iterator _iter661; + for (_iter661 = this->success.begin(); _iter661 != this->success.end(); ++_iter661) { - xfer += (*_iter658).write(oprot); + xfer += (*_iter661).write(oprot); } xfer += oprot->writeListEnd(); } @@ -12277,14 +12277,14 @@ uint32_t ThriftHiveMetastore_get_partitions_by_names_presult::read(::apache::thr if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size659; - ::apache::thrift::protocol::TType _etype662; - xfer += iprot->readListBegin(_etype662, _size659); - (*(this->success)).resize(_size659); - uint32_t _i663; - for (_i663 = 0; _i663 < _size659; ++_i663) + uint32_t _size662; + ::apache::thrift::protocol::TType _etype665; + xfer += iprot->readListBegin(_etype665, _size662); + (*(this->success)).resize(_size662); + uint32_t _i666; + for (_i666 = 0; _i666 < _size662; ++_i666) { - xfer += (*(this->success))[_i663].read(iprot); + xfer += (*(this->success))[_i666].read(iprot); } xfer += iprot->readListEnd(); } @@ -12575,14 +12575,14 @@ uint32_t ThriftHiveMetastore_alter_partitions_args::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { this->new_parts.clear(); - uint32_t _size664; - ::apache::thrift::protocol::TType _etype667; - xfer += iprot->readListBegin(_etype667, _size664); - this->new_parts.resize(_size664); - uint32_t _i668; - for (_i668 = 0; _i668 < _size664; ++_i668) + uint32_t _size667; + ::apache::thrift::protocol::TType _etype670; + xfer += iprot->readListBegin(_etype670, _size667); + this->new_parts.resize(_size667); + uint32_t _i671; + for (_i671 = 0; _i671 < _size667; ++_i671) { - xfer += this->new_parts[_i668].read(iprot); + xfer += this->new_parts[_i671].read(iprot); } xfer += iprot->readListEnd(); } @@ -12618,10 +12618,10 @@ uint32_t ThriftHiveMetastore_alter_partitions_args::write(::apache::thrift::prot 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 _iter669; - for (_iter669 = this->new_parts.begin(); _iter669 != this->new_parts.end(); ++_iter669) + std::vector ::const_iterator _iter672; + for (_iter672 = this->new_parts.begin(); _iter672 != this->new_parts.end(); ++_iter672) { - xfer += (*_iter669).write(oprot); + xfer += (*_iter672).write(oprot); } xfer += oprot->writeListEnd(); } @@ -12647,10 +12647,10 @@ uint32_t ThriftHiveMetastore_alter_partitions_pargs::write(::apache::thrift::pro 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 _iter670; - for (_iter670 = (*(this->new_parts)).begin(); _iter670 != (*(this->new_parts)).end(); ++_iter670) + std::vector ::const_iterator _iter673; + for (_iter673 = (*(this->new_parts)).begin(); _iter673 != (*(this->new_parts)).end(); ++_iter673) { - xfer += (*_iter670).write(oprot); + xfer += (*_iter673).write(oprot); } xfer += oprot->writeListEnd(); } @@ -13047,14 +13047,14 @@ uint32_t ThriftHiveMetastore_rename_partition_args::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - 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) + uint32_t _size674; + ::apache::thrift::protocol::TType _etype677; + xfer += iprot->readListBegin(_etype677, _size674); + this->part_vals.resize(_size674); + uint32_t _i678; + for (_i678 = 0; _i678 < _size674; ++_i678) { - xfer += iprot->readString(this->part_vals[_i675]); + xfer += iprot->readString(this->part_vals[_i678]); } xfer += iprot->readListEnd(); } @@ -13098,10 +13098,10 @@ uint32_t ThriftHiveMetastore_rename_partition_args::write(::apache::thrift::prot 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 _iter676; - for (_iter676 = this->part_vals.begin(); _iter676 != this->part_vals.end(); ++_iter676) + std::vector ::const_iterator _iter679; + for (_iter679 = this->part_vals.begin(); _iter679 != this->part_vals.end(); ++_iter679) { - xfer += oprot->writeString((*_iter676)); + xfer += oprot->writeString((*_iter679)); } xfer += oprot->writeListEnd(); } @@ -13131,10 +13131,10 @@ uint32_t ThriftHiveMetastore_rename_partition_pargs::write(::apache::thrift::pro 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 _iter677; - for (_iter677 = (*(this->part_vals)).begin(); _iter677 != (*(this->part_vals)).end(); ++_iter677) + std::vector ::const_iterator _iter680; + for (_iter680 = (*(this->part_vals)).begin(); _iter680 != (*(this->part_vals)).end(); ++_iter680) { - xfer += oprot->writeString((*_iter677)); + xfer += oprot->writeString((*_iter680)); } xfer += oprot->writeListEnd(); } @@ -13289,14 +13289,14 @@ uint32_t ThriftHiveMetastore_partition_name_has_valid_characters_args::read(::ap if (ftype == ::apache::thrift::protocol::T_LIST) { { this->part_vals.clear(); - uint32_t _size678; - ::apache::thrift::protocol::TType _etype681; - xfer += iprot->readListBegin(_etype681, _size678); - this->part_vals.resize(_size678); - uint32_t _i682; - for (_i682 = 0; _i682 < _size678; ++_i682) + 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) { - xfer += iprot->readString(this->part_vals[_i682]); + xfer += iprot->readString(this->part_vals[_i685]); } xfer += iprot->readListEnd(); } @@ -13332,10 +13332,10 @@ uint32_t ThriftHiveMetastore_partition_name_has_valid_characters_args::write(::a 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 _iter683; - for (_iter683 = this->part_vals.begin(); _iter683 != this->part_vals.end(); ++_iter683) + std::vector ::const_iterator _iter686; + for (_iter686 = this->part_vals.begin(); _iter686 != this->part_vals.end(); ++_iter686) { - xfer += oprot->writeString((*_iter683)); + xfer += oprot->writeString((*_iter686)); } xfer += oprot->writeListEnd(); } @@ -13357,10 +13357,10 @@ uint32_t ThriftHiveMetastore_partition_name_has_valid_characters_pargs::write(:: 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 _iter684; - for (_iter684 = (*(this->part_vals)).begin(); _iter684 != (*(this->part_vals)).end(); ++_iter684) + std::vector ::const_iterator _iter687; + for (_iter687 = (*(this->part_vals)).begin(); _iter687 != (*(this->part_vals)).end(); ++_iter687) { - xfer += oprot->writeString((*_iter684)); + xfer += oprot->writeString((*_iter687)); } xfer += oprot->writeListEnd(); } @@ -13779,14 +13779,14 @@ uint32_t ThriftHiveMetastore_partition_name_to_vals_result::read(::apache::thrif if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size685; - ::apache::thrift::protocol::TType _etype688; - xfer += iprot->readListBegin(_etype688, _size685); - this->success.resize(_size685); - uint32_t _i689; - for (_i689 = 0; _i689 < _size685; ++_i689) + uint32_t _size688; + ::apache::thrift::protocol::TType _etype691; + xfer += iprot->readListBegin(_etype691, _size688); + this->success.resize(_size688); + uint32_t _i692; + for (_i692 = 0; _i692 < _size688; ++_i692) { - xfer += iprot->readString(this->success[_i689]); + xfer += iprot->readString(this->success[_i692]); } xfer += iprot->readListEnd(); } @@ -13825,10 +13825,10 @@ uint32_t ThriftHiveMetastore_partition_name_to_vals_result::write(::apache::thri 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 _iter690; - for (_iter690 = this->success.begin(); _iter690 != this->success.end(); ++_iter690) + std::vector ::const_iterator _iter693; + for (_iter693 = this->success.begin(); _iter693 != this->success.end(); ++_iter693) { - xfer += oprot->writeString((*_iter690)); + xfer += oprot->writeString((*_iter693)); } xfer += oprot->writeListEnd(); } @@ -13867,14 +13867,14 @@ uint32_t ThriftHiveMetastore_partition_name_to_vals_presult::read(::apache::thri if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size691; - ::apache::thrift::protocol::TType _etype694; - xfer += iprot->readListBegin(_etype694, _size691); - (*(this->success)).resize(_size691); - uint32_t _i695; - for (_i695 = 0; _i695 < _size691; ++_i695) + uint32_t _size694; + ::apache::thrift::protocol::TType _etype697; + xfer += iprot->readListBegin(_etype697, _size694); + (*(this->success)).resize(_size694); + uint32_t _i698; + for (_i698 = 0; _i698 < _size694; ++_i698) { - xfer += iprot->readString((*(this->success))[_i695]); + xfer += iprot->readString((*(this->success))[_i698]); } xfer += iprot->readListEnd(); } @@ -13993,17 +13993,17 @@ uint32_t ThriftHiveMetastore_partition_name_to_spec_result::read(::apache::thrif if (ftype == ::apache::thrift::protocol::T_MAP) { { this->success.clear(); - uint32_t _size696; - ::apache::thrift::protocol::TType _ktype697; - ::apache::thrift::protocol::TType _vtype698; - xfer += iprot->readMapBegin(_ktype697, _vtype698, _size696); - uint32_t _i700; - for (_i700 = 0; _i700 < _size696; ++_i700) + uint32_t _size699; + ::apache::thrift::protocol::TType _ktype700; + ::apache::thrift::protocol::TType _vtype701; + xfer += iprot->readMapBegin(_ktype700, _vtype701, _size699); + uint32_t _i703; + for (_i703 = 0; _i703 < _size699; ++_i703) { - std::string _key701; - xfer += iprot->readString(_key701); - std::string& _val702 = this->success[_key701]; - xfer += iprot->readString(_val702); + std::string _key704; + xfer += iprot->readString(_key704); + std::string& _val705 = this->success[_key704]; + xfer += iprot->readString(_val705); } xfer += iprot->readMapEnd(); } @@ -14042,11 +14042,11 @@ uint32_t ThriftHiveMetastore_partition_name_to_spec_result::write(::apache::thri 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 _iter703; - for (_iter703 = this->success.begin(); _iter703 != this->success.end(); ++_iter703) + std::map ::const_iterator _iter706; + for (_iter706 = this->success.begin(); _iter706 != this->success.end(); ++_iter706) { - xfer += oprot->writeString(_iter703->first); - xfer += oprot->writeString(_iter703->second); + xfer += oprot->writeString(_iter706->first); + xfer += oprot->writeString(_iter706->second); } xfer += oprot->writeMapEnd(); } @@ -14085,17 +14085,17 @@ uint32_t ThriftHiveMetastore_partition_name_to_spec_presult::read(::apache::thri if (ftype == ::apache::thrift::protocol::T_MAP) { { (*(this->success)).clear(); - uint32_t _size704; - ::apache::thrift::protocol::TType _ktype705; - ::apache::thrift::protocol::TType _vtype706; - xfer += iprot->readMapBegin(_ktype705, _vtype706, _size704); - uint32_t _i708; - for (_i708 = 0; _i708 < _size704; ++_i708) + uint32_t _size707; + ::apache::thrift::protocol::TType _ktype708; + ::apache::thrift::protocol::TType _vtype709; + xfer += iprot->readMapBegin(_ktype708, _vtype709, _size707); + uint32_t _i711; + for (_i711 = 0; _i711 < _size707; ++_i711) { - std::string _key709; - xfer += iprot->readString(_key709); - std::string& _val710 = (*(this->success))[_key709]; - xfer += iprot->readString(_val710); + std::string _key712; + xfer += iprot->readString(_key712); + std::string& _val713 = (*(this->success))[_key712]; + xfer += iprot->readString(_val713); } xfer += iprot->readMapEnd(); } @@ -14164,17 +14164,17 @@ uint32_t ThriftHiveMetastore_markPartitionForEvent_args::read(::apache::thrift:: if (ftype == ::apache::thrift::protocol::T_MAP) { { this->part_vals.clear(); - uint32_t _size711; - ::apache::thrift::protocol::TType _ktype712; - ::apache::thrift::protocol::TType _vtype713; - xfer += iprot->readMapBegin(_ktype712, _vtype713, _size711); - uint32_t _i715; - for (_i715 = 0; _i715 < _size711; ++_i715) + 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) { - std::string _key716; - xfer += iprot->readString(_key716); - std::string& _val717 = this->part_vals[_key716]; - xfer += iprot->readString(_val717); + std::string _key719; + xfer += iprot->readString(_key719); + std::string& _val720 = this->part_vals[_key719]; + xfer += iprot->readString(_val720); } xfer += iprot->readMapEnd(); } @@ -14185,9 +14185,9 @@ uint32_t ThriftHiveMetastore_markPartitionForEvent_args::read(::apache::thrift:: break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast718; - xfer += iprot->readI32(ecast718); - this->eventType = (PartitionEventType::type)ecast718; + int32_t ecast721; + xfer += iprot->readI32(ecast721); + this->eventType = (PartitionEventType::type)ecast721; this->__isset.eventType = true; } else { xfer += iprot->skip(ftype); @@ -14220,11 +14220,11 @@ uint32_t ThriftHiveMetastore_markPartitionForEvent_args::write(::apache::thrift: 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 _iter719; - for (_iter719 = this->part_vals.begin(); _iter719 != this->part_vals.end(); ++_iter719) + std::map ::const_iterator _iter722; + for (_iter722 = this->part_vals.begin(); _iter722 != this->part_vals.end(); ++_iter722) { - xfer += oprot->writeString(_iter719->first); - xfer += oprot->writeString(_iter719->second); + xfer += oprot->writeString(_iter722->first); + xfer += oprot->writeString(_iter722->second); } xfer += oprot->writeMapEnd(); } @@ -14254,11 +14254,11 @@ uint32_t ThriftHiveMetastore_markPartitionForEvent_pargs::write(::apache::thrift 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 _iter720; - for (_iter720 = (*(this->part_vals)).begin(); _iter720 != (*(this->part_vals)).end(); ++_iter720) + std::map ::const_iterator _iter723; + for (_iter723 = (*(this->part_vals)).begin(); _iter723 != (*(this->part_vals)).end(); ++_iter723) { - xfer += oprot->writeString(_iter720->first); - xfer += oprot->writeString(_iter720->second); + xfer += oprot->writeString(_iter723->first); + xfer += oprot->writeString(_iter723->second); } xfer += oprot->writeMapEnd(); } @@ -14509,17 +14509,17 @@ uint32_t ThriftHiveMetastore_isPartitionMarkedForEvent_args::read(::apache::thri 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 _size724; + ::apache::thrift::protocol::TType _ktype725; + ::apache::thrift::protocol::TType _vtype726; + xfer += iprot->readMapBegin(_ktype725, _vtype726, _size724); + uint32_t _i728; + for (_i728 = 0; _i728 < _size724; ++_i728) { - std::string _key726; - xfer += iprot->readString(_key726); - std::string& _val727 = this->part_vals[_key726]; - xfer += iprot->readString(_val727); + std::string _key729; + xfer += iprot->readString(_key729); + std::string& _val730 = this->part_vals[_key729]; + xfer += iprot->readString(_val730); } xfer += iprot->readMapEnd(); } @@ -14530,9 +14530,9 @@ uint32_t ThriftHiveMetastore_isPartitionMarkedForEvent_args::read(::apache::thri break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast728; - xfer += iprot->readI32(ecast728); - this->eventType = (PartitionEventType::type)ecast728; + int32_t ecast731; + xfer += iprot->readI32(ecast731); + this->eventType = (PartitionEventType::type)ecast731; this->__isset.eventType = true; } else { xfer += iprot->skip(ftype); @@ -14565,11 +14565,11 @@ uint32_t ThriftHiveMetastore_isPartitionMarkedForEvent_args::write(::apache::thr 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 _iter732; + for (_iter732 = this->part_vals.begin(); _iter732 != this->part_vals.end(); ++_iter732) { - xfer += oprot->writeString(_iter729->first); - xfer += oprot->writeString(_iter729->second); + xfer += oprot->writeString(_iter732->first); + xfer += oprot->writeString(_iter732->second); } xfer += oprot->writeMapEnd(); } @@ -14599,11 +14599,11 @@ uint32_t ThriftHiveMetastore_isPartitionMarkedForEvent_pargs::write(::apache::th 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 _iter733; + for (_iter733 = (*(this->part_vals)).begin(); _iter733 != (*(this->part_vals)).end(); ++_iter733) { - xfer += oprot->writeString(_iter730->first); - xfer += oprot->writeString(_iter730->second); + xfer += oprot->writeString(_iter733->first); + xfer += oprot->writeString(_iter733->second); } xfer += oprot->writeMapEnd(); } @@ -15908,14 +15908,14 @@ uint32_t ThriftHiveMetastore_get_indexes_result::read(::apache::thrift::protocol if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size731; - ::apache::thrift::protocol::TType _etype734; - xfer += iprot->readListBegin(_etype734, _size731); - this->success.resize(_size731); - uint32_t _i735; - for (_i735 = 0; _i735 < _size731; ++_i735) + uint32_t _size734; + ::apache::thrift::protocol::TType _etype737; + xfer += iprot->readListBegin(_etype737, _size734); + this->success.resize(_size734); + uint32_t _i738; + for (_i738 = 0; _i738 < _size734; ++_i738) { - xfer += this->success[_i735].read(iprot); + xfer += this->success[_i738].read(iprot); } xfer += iprot->readListEnd(); } @@ -15962,10 +15962,10 @@ uint32_t ThriftHiveMetastore_get_indexes_result::write(::apache::thrift::protoco 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 _iter736; - for (_iter736 = this->success.begin(); _iter736 != this->success.end(); ++_iter736) + std::vector ::const_iterator _iter739; + for (_iter739 = this->success.begin(); _iter739 != this->success.end(); ++_iter739) { - xfer += (*_iter736).write(oprot); + xfer += (*_iter739).write(oprot); } xfer += oprot->writeListEnd(); } @@ -16008,14 +16008,14 @@ uint32_t ThriftHiveMetastore_get_indexes_presult::read(::apache::thrift::protoco if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size737; - ::apache::thrift::protocol::TType _etype740; - xfer += iprot->readListBegin(_etype740, _size737); - (*(this->success)).resize(_size737); - uint32_t _i741; - for (_i741 = 0; _i741 < _size737; ++_i741) + uint32_t _size740; + ::apache::thrift::protocol::TType _etype743; + xfer += iprot->readListBegin(_etype743, _size740); + (*(this->success)).resize(_size740); + uint32_t _i744; + for (_i744 = 0; _i744 < _size740; ++_i744) { - xfer += (*(this->success))[_i741].read(iprot); + xfer += (*(this->success))[_i744].read(iprot); } xfer += iprot->readListEnd(); } @@ -16174,14 +16174,14 @@ uint32_t ThriftHiveMetastore_get_index_names_result::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size742; - ::apache::thrift::protocol::TType _etype745; - xfer += iprot->readListBegin(_etype745, _size742); - this->success.resize(_size742); - uint32_t _i746; - for (_i746 = 0; _i746 < _size742; ++_i746) + uint32_t _size745; + ::apache::thrift::protocol::TType _etype748; + xfer += iprot->readListBegin(_etype748, _size745); + this->success.resize(_size745); + uint32_t _i749; + for (_i749 = 0; _i749 < _size745; ++_i749) { - xfer += iprot->readString(this->success[_i746]); + xfer += iprot->readString(this->success[_i749]); } xfer += iprot->readListEnd(); } @@ -16220,10 +16220,10 @@ uint32_t ThriftHiveMetastore_get_index_names_result::write(::apache::thrift::pro 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 _iter747; - for (_iter747 = this->success.begin(); _iter747 != this->success.end(); ++_iter747) + std::vector ::const_iterator _iter750; + for (_iter750 = this->success.begin(); _iter750 != this->success.end(); ++_iter750) { - xfer += oprot->writeString((*_iter747)); + xfer += oprot->writeString((*_iter750)); } xfer += oprot->writeListEnd(); } @@ -16262,14 +16262,14 @@ uint32_t ThriftHiveMetastore_get_index_names_presult::read(::apache::thrift::pro if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size748; - ::apache::thrift::protocol::TType _etype751; - xfer += iprot->readListBegin(_etype751, _size748); - (*(this->success)).resize(_size748); - uint32_t _i752; - for (_i752 = 0; _i752 < _size748; ++_i752) + uint32_t _size751; + ::apache::thrift::protocol::TType _etype754; + xfer += iprot->readListBegin(_etype754, _size751); + (*(this->success)).resize(_size751); + uint32_t _i755; + for (_i755 = 0; _i755 < _size751; ++_i755) { - xfer += iprot->readString((*(this->success))[_i752]); + xfer += iprot->readString((*(this->success))[_i755]); } xfer += iprot->readListEnd(); } @@ -19054,14 +19054,14 @@ uint32_t ThriftHiveMetastore_get_functions_result::read(::apache::thrift::protoc if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size753; - ::apache::thrift::protocol::TType _etype756; - xfer += iprot->readListBegin(_etype756, _size753); - this->success.resize(_size753); - uint32_t _i757; - for (_i757 = 0; _i757 < _size753; ++_i757) + 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[_i757]); + xfer += iprot->readString(this->success[_i760]); } xfer += iprot->readListEnd(); } @@ -19100,10 +19100,10 @@ uint32_t ThriftHiveMetastore_get_functions_result::write(::apache::thrift::proto 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 _iter758; - for (_iter758 = this->success.begin(); _iter758 != this->success.end(); ++_iter758) + std::vector ::const_iterator _iter761; + for (_iter761 = this->success.begin(); _iter761 != this->success.end(); ++_iter761) { - xfer += oprot->writeString((*_iter758)); + xfer += oprot->writeString((*_iter761)); } xfer += oprot->writeListEnd(); } @@ -19142,14 +19142,14 @@ uint32_t ThriftHiveMetastore_get_functions_presult::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size759; - ::apache::thrift::protocol::TType _etype762; - xfer += iprot->readListBegin(_etype762, _size759); - (*(this->success)).resize(_size759); - uint32_t _i763; - for (_i763 = 0; _i763 < _size759; ++_i763) + uint32_t _size762; + ::apache::thrift::protocol::TType _etype765; + xfer += iprot->readListBegin(_etype765, _size762); + (*(this->success)).resize(_size762); + uint32_t _i766; + for (_i766 = 0; _i766 < _size762; ++_i766) { - xfer += iprot->readString((*(this->success))[_i763]); + xfer += iprot->readString((*(this->success))[_i766]); } xfer += iprot->readListEnd(); } @@ -19829,14 +19829,14 @@ uint32_t ThriftHiveMetastore_get_role_names_result::read(::apache::thrift::proto if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size764; - ::apache::thrift::protocol::TType _etype767; - xfer += iprot->readListBegin(_etype767, _size764); - this->success.resize(_size764); - uint32_t _i768; - for (_i768 = 0; _i768 < _size764; ++_i768) + uint32_t _size767; + ::apache::thrift::protocol::TType _etype770; + xfer += iprot->readListBegin(_etype770, _size767); + this->success.resize(_size767); + uint32_t _i771; + for (_i771 = 0; _i771 < _size767; ++_i771) { - xfer += iprot->readString(this->success[_i768]); + xfer += iprot->readString(this->success[_i771]); } xfer += iprot->readListEnd(); } @@ -19875,10 +19875,10 @@ uint32_t ThriftHiveMetastore_get_role_names_result::write(::apache::thrift::prot 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 _iter769; - for (_iter769 = this->success.begin(); _iter769 != this->success.end(); ++_iter769) + std::vector ::const_iterator _iter772; + for (_iter772 = this->success.begin(); _iter772 != this->success.end(); ++_iter772) { - xfer += oprot->writeString((*_iter769)); + xfer += oprot->writeString((*_iter772)); } xfer += oprot->writeListEnd(); } @@ -19917,14 +19917,14 @@ uint32_t ThriftHiveMetastore_get_role_names_presult::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size770; - ::apache::thrift::protocol::TType _etype773; - xfer += iprot->readListBegin(_etype773, _size770); - (*(this->success)).resize(_size770); - uint32_t _i774; - for (_i774 = 0; _i774 < _size770; ++_i774) + uint32_t _size773; + ::apache::thrift::protocol::TType _etype776; + xfer += iprot->readListBegin(_etype776, _size773); + (*(this->success)).resize(_size773); + uint32_t _i777; + for (_i777 = 0; _i777 < _size773; ++_i777) { - xfer += iprot->readString((*(this->success))[_i774]); + xfer += iprot->readString((*(this->success))[_i777]); } xfer += iprot->readListEnd(); } @@ -19991,9 +19991,9 @@ uint32_t ThriftHiveMetastore_grant_role_args::read(::apache::thrift::protocol::T break; case 3: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast775; - xfer += iprot->readI32(ecast775); - this->principal_type = (PrincipalType::type)ecast775; + int32_t ecast778; + xfer += iprot->readI32(ecast778); + this->principal_type = (PrincipalType::type)ecast778; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -20009,9 +20009,9 @@ uint32_t ThriftHiveMetastore_grant_role_args::read(::apache::thrift::protocol::T break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast776; - xfer += iprot->readI32(ecast776); - this->grantorType = (PrincipalType::type)ecast776; + int32_t ecast779; + xfer += iprot->readI32(ecast779); + this->grantorType = (PrincipalType::type)ecast779; this->__isset.grantorType = true; } else { xfer += iprot->skip(ftype); @@ -20257,9 +20257,9 @@ uint32_t ThriftHiveMetastore_revoke_role_args::read(::apache::thrift::protocol:: break; case 3: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast777; - xfer += iprot->readI32(ecast777); - this->principal_type = (PrincipalType::type)ecast777; + int32_t ecast780; + xfer += iprot->readI32(ecast780); + this->principal_type = (PrincipalType::type)ecast780; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -20465,9 +20465,9 @@ uint32_t ThriftHiveMetastore_list_roles_args::read(::apache::thrift::protocol::T break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast778; - xfer += iprot->readI32(ecast778); - this->principal_type = (PrincipalType::type)ecast778; + int32_t ecast781; + xfer += iprot->readI32(ecast781); + this->principal_type = (PrincipalType::type)ecast781; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -20543,14 +20543,14 @@ uint32_t ThriftHiveMetastore_list_roles_result::read(::apache::thrift::protocol: if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size779; - ::apache::thrift::protocol::TType _etype782; - xfer += iprot->readListBegin(_etype782, _size779); - this->success.resize(_size779); - uint32_t _i783; - for (_i783 = 0; _i783 < _size779; ++_i783) + uint32_t _size782; + ::apache::thrift::protocol::TType _etype785; + xfer += iprot->readListBegin(_etype785, _size782); + this->success.resize(_size782); + uint32_t _i786; + for (_i786 = 0; _i786 < _size782; ++_i786) { - xfer += this->success[_i783].read(iprot); + xfer += this->success[_i786].read(iprot); } xfer += iprot->readListEnd(); } @@ -20589,10 +20589,10 @@ uint32_t ThriftHiveMetastore_list_roles_result::write(::apache::thrift::protocol 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 _iter784; - for (_iter784 = this->success.begin(); _iter784 != this->success.end(); ++_iter784) + std::vector ::const_iterator _iter787; + for (_iter787 = this->success.begin(); _iter787 != this->success.end(); ++_iter787) { - xfer += (*_iter784).write(oprot); + xfer += (*_iter787).write(oprot); } xfer += oprot->writeListEnd(); } @@ -20631,14 +20631,14 @@ uint32_t ThriftHiveMetastore_list_roles_presult::read(::apache::thrift::protocol if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size785; - ::apache::thrift::protocol::TType _etype788; - xfer += iprot->readListBegin(_etype788, _size785); - (*(this->success)).resize(_size785); - uint32_t _i789; - for (_i789 = 0; _i789 < _size785; ++_i789) + uint32_t _size788; + ::apache::thrift::protocol::TType _etype791; + xfer += iprot->readListBegin(_etype791, _size788); + (*(this->success)).resize(_size788); + uint32_t _i792; + for (_i792 = 0; _i792 < _size788; ++_i792) { - xfer += (*(this->success))[_i789].read(iprot); + xfer += (*(this->success))[_i792].read(iprot); } xfer += iprot->readListEnd(); } @@ -20667,6 +20667,188 @@ uint32_t ThriftHiveMetastore_list_roles_presult::read(::apache::thrift::protocol return xfer; } +uint32_t ThriftHiveMetastore_grant_revoke_role_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_STRUCT) { + xfer += this->request.read(iprot); + this->__isset.request = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_grant_revoke_role_args::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_grant_revoke_role_args"); + + xfer += oprot->writeFieldBegin("request", ::apache::thrift::protocol::T_STRUCT, -1); + xfer += this->request.write(oprot); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_grant_revoke_role_pargs::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("ThriftHiveMetastore_grant_revoke_role_pargs"); + + xfer += oprot->writeFieldBegin("request", ::apache::thrift::protocol::T_STRUCT, -1); + xfer += (*(this->request)).write(oprot); + xfer += oprot->writeFieldEnd(); + + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_grant_revoke_role_result::read(::apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + + while (true) + { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) + { + case 0: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->success.read(iprot); + this->__isset.success = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 1: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o1.read(iprot); + this->__isset.o1 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t ThriftHiveMetastore_grant_revoke_role_result::write(::apache::thrift::protocol::TProtocol* oprot) const { + + uint32_t xfer = 0; + + xfer += oprot->writeStructBegin("ThriftHiveMetastore_grant_revoke_role_result"); + + if (this->__isset.success) { + xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_STRUCT, 0); + xfer += this->success.write(oprot); + xfer += oprot->writeFieldEnd(); + } else if (this->__isset.o1) { + xfer += oprot->writeFieldBegin("o1", ::apache::thrift::protocol::T_STRUCT, 1); + xfer += this->o1.write(oprot); + xfer += oprot->writeFieldEnd(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +uint32_t ThriftHiveMetastore_grant_revoke_role_presult::read(::apache::thrift::protocol::TProtocol* iprot) { + + uint32_t xfer = 0; + std::string fname; + ::apache::thrift::protocol::TType ftype; + int16_t fid; + + xfer += iprot->readStructBegin(fname); + + using ::apache::thrift::protocol::TProtocolException; + + + while (true) + { + xfer += iprot->readFieldBegin(fname, ftype, fid); + if (ftype == ::apache::thrift::protocol::T_STOP) { + break; + } + switch (fid) + { + case 0: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += (*(this->success)).read(iprot); + this->__isset.success = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 1: + if (ftype == ::apache::thrift::protocol::T_STRUCT) { + xfer += this->o1.read(iprot); + this->__isset.o1 = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + uint32_t ThriftHiveMetastore_get_principals_in_role_args::read(::apache::thrift::protocol::TProtocol* iprot) { uint32_t xfer = 0; @@ -21071,14 +21253,14 @@ uint32_t ThriftHiveMetastore_get_privilege_set_args::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size790; - ::apache::thrift::protocol::TType _etype793; - xfer += iprot->readListBegin(_etype793, _size790); - this->group_names.resize(_size790); - uint32_t _i794; - for (_i794 = 0; _i794 < _size790; ++_i794) + uint32_t _size793; + ::apache::thrift::protocol::TType _etype796; + xfer += iprot->readListBegin(_etype796, _size793); + this->group_names.resize(_size793); + uint32_t _i797; + for (_i797 = 0; _i797 < _size793; ++_i797) { - xfer += iprot->readString(this->group_names[_i794]); + xfer += iprot->readString(this->group_names[_i797]); } xfer += iprot->readListEnd(); } @@ -21114,10 +21296,10 @@ uint32_t ThriftHiveMetastore_get_privilege_set_args::write(::apache::thrift::pro 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 _iter795; - for (_iter795 = this->group_names.begin(); _iter795 != this->group_names.end(); ++_iter795) + std::vector ::const_iterator _iter798; + for (_iter798 = this->group_names.begin(); _iter798 != this->group_names.end(); ++_iter798) { - xfer += oprot->writeString((*_iter795)); + xfer += oprot->writeString((*_iter798)); } xfer += oprot->writeListEnd(); } @@ -21143,10 +21325,10 @@ uint32_t ThriftHiveMetastore_get_privilege_set_pargs::write(::apache::thrift::pr 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 _iter796; - for (_iter796 = (*(this->group_names)).begin(); _iter796 != (*(this->group_names)).end(); ++_iter796) + std::vector ::const_iterator _iter799; + for (_iter799 = (*(this->group_names)).begin(); _iter799 != (*(this->group_names)).end(); ++_iter799) { - xfer += oprot->writeString((*_iter796)); + xfer += oprot->writeString((*_iter799)); } xfer += oprot->writeListEnd(); } @@ -21303,9 +21485,9 @@ uint32_t ThriftHiveMetastore_list_privileges_args::read(::apache::thrift::protoc break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast797; - xfer += iprot->readI32(ecast797); - this->principal_type = (PrincipalType::type)ecast797; + int32_t ecast800; + xfer += iprot->readI32(ecast800); + this->principal_type = (PrincipalType::type)ecast800; this->__isset.principal_type = true; } else { xfer += iprot->skip(ftype); @@ -21397,14 +21579,14 @@ uint32_t ThriftHiveMetastore_list_privileges_result::read(::apache::thrift::prot if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size798; - ::apache::thrift::protocol::TType _etype801; - xfer += iprot->readListBegin(_etype801, _size798); - this->success.resize(_size798); - uint32_t _i802; - for (_i802 = 0; _i802 < _size798; ++_i802) + uint32_t _size801; + ::apache::thrift::protocol::TType _etype804; + xfer += iprot->readListBegin(_etype804, _size801); + this->success.resize(_size801); + uint32_t _i805; + for (_i805 = 0; _i805 < _size801; ++_i805) { - xfer += this->success[_i802].read(iprot); + xfer += this->success[_i805].read(iprot); } xfer += iprot->readListEnd(); } @@ -21443,10 +21625,10 @@ uint32_t ThriftHiveMetastore_list_privileges_result::write(::apache::thrift::pro 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 _iter803; - for (_iter803 = this->success.begin(); _iter803 != this->success.end(); ++_iter803) + std::vector ::const_iterator _iter806; + for (_iter806 = this->success.begin(); _iter806 != this->success.end(); ++_iter806) { - xfer += (*_iter803).write(oprot); + xfer += (*_iter806).write(oprot); } xfer += oprot->writeListEnd(); } @@ -21485,14 +21667,14 @@ uint32_t ThriftHiveMetastore_list_privileges_presult::read(::apache::thrift::pro if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size804; - ::apache::thrift::protocol::TType _etype807; - xfer += iprot->readListBegin(_etype807, _size804); - (*(this->success)).resize(_size804); - uint32_t _i808; - for (_i808 = 0; _i808 < _size804; ++_i808) + 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 += (*(this->success))[_i808].read(iprot); + xfer += (*(this->success))[_i811].read(iprot); } xfer += iprot->readListEnd(); } @@ -21917,14 +22099,14 @@ uint32_t ThriftHiveMetastore_set_ugi_args::read(::apache::thrift::protocol::TPro if (ftype == ::apache::thrift::protocol::T_LIST) { { this->group_names.clear(); - uint32_t _size809; - ::apache::thrift::protocol::TType _etype812; - xfer += iprot->readListBegin(_etype812, _size809); - this->group_names.resize(_size809); - uint32_t _i813; - for (_i813 = 0; _i813 < _size809; ++_i813) + uint32_t _size812; + ::apache::thrift::protocol::TType _etype815; + xfer += iprot->readListBegin(_etype815, _size812); + this->group_names.resize(_size812); + uint32_t _i816; + for (_i816 = 0; _i816 < _size812; ++_i816) { - xfer += iprot->readString(this->group_names[_i813]); + xfer += iprot->readString(this->group_names[_i816]); } xfer += iprot->readListEnd(); } @@ -21956,10 +22138,10 @@ uint32_t ThriftHiveMetastore_set_ugi_args::write(::apache::thrift::protocol::TPr 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 _iter814; - for (_iter814 = this->group_names.begin(); _iter814 != this->group_names.end(); ++_iter814) + std::vector ::const_iterator _iter817; + for (_iter817 = this->group_names.begin(); _iter817 != this->group_names.end(); ++_iter817) { - xfer += oprot->writeString((*_iter814)); + xfer += oprot->writeString((*_iter817)); } xfer += oprot->writeListEnd(); } @@ -21981,10 +22163,10 @@ uint32_t ThriftHiveMetastore_set_ugi_pargs::write(::apache::thrift::protocol::TP 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 _iter815; - for (_iter815 = (*(this->group_names)).begin(); _iter815 != (*(this->group_names)).end(); ++_iter815) + std::vector ::const_iterator _iter818; + for (_iter818 = (*(this->group_names)).begin(); _iter818 != (*(this->group_names)).end(); ++_iter818) { - xfer += oprot->writeString((*_iter815)); + xfer += oprot->writeString((*_iter818)); } xfer += oprot->writeListEnd(); } @@ -22019,14 +22201,14 @@ uint32_t ThriftHiveMetastore_set_ugi_result::read(::apache::thrift::protocol::TP if (ftype == ::apache::thrift::protocol::T_LIST) { { this->success.clear(); - uint32_t _size816; - ::apache::thrift::protocol::TType _etype819; - xfer += iprot->readListBegin(_etype819, _size816); - this->success.resize(_size816); - uint32_t _i820; - for (_i820 = 0; _i820 < _size816; ++_i820) + uint32_t _size819; + ::apache::thrift::protocol::TType _etype822; + xfer += iprot->readListBegin(_etype822, _size819); + this->success.resize(_size819); + uint32_t _i823; + for (_i823 = 0; _i823 < _size819; ++_i823) { - xfer += iprot->readString(this->success[_i820]); + xfer += iprot->readString(this->success[_i823]); } xfer += iprot->readListEnd(); } @@ -22065,10 +22247,10 @@ uint32_t ThriftHiveMetastore_set_ugi_result::write(::apache::thrift::protocol::T 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 _iter821; - for (_iter821 = this->success.begin(); _iter821 != this->success.end(); ++_iter821) + std::vector ::const_iterator _iter824; + for (_iter824 = this->success.begin(); _iter824 != this->success.end(); ++_iter824) { - xfer += oprot->writeString((*_iter821)); + xfer += oprot->writeString((*_iter824)); } xfer += oprot->writeListEnd(); } @@ -22107,14 +22289,14 @@ uint32_t ThriftHiveMetastore_set_ugi_presult::read(::apache::thrift::protocol::T if (ftype == ::apache::thrift::protocol::T_LIST) { { (*(this->success)).clear(); - uint32_t _size822; - ::apache::thrift::protocol::TType _etype825; - xfer += iprot->readListBegin(_etype825, _size822); - (*(this->success)).resize(_size822); - uint32_t _i826; - for (_i826 = 0; _i826 < _size822; ++_i826) + uint32_t _size825; + ::apache::thrift::protocol::TType _etype828; + xfer += iprot->readListBegin(_etype828, _size825); + (*(this->success)).resize(_size825); + uint32_t _i829; + for (_i829 = 0; _i829 < _size825; ++_i829) { - xfer += iprot->readString((*(this->success))[_i826]); + xfer += iprot->readString((*(this->success))[_i829]); } xfer += iprot->readListEnd(); } @@ -30396,6 +30578,67 @@ void ThriftHiveMetastoreClient::recv_list_roles(std::vector & _return) throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "list_roles failed: unknown result"); } +void ThriftHiveMetastoreClient::grant_revoke_role(GrantRevokeRoleResponse& _return, const GrantRevokeRoleRequest& request) +{ + send_grant_revoke_role(request); + recv_grant_revoke_role(_return); +} + +void ThriftHiveMetastoreClient::send_grant_revoke_role(const GrantRevokeRoleRequest& request) +{ + int32_t cseqid = 0; + oprot_->writeMessageBegin("grant_revoke_role", ::apache::thrift::protocol::T_CALL, cseqid); + + ThriftHiveMetastore_grant_revoke_role_pargs args; + args.request = &request; + args.write(oprot_); + + oprot_->writeMessageEnd(); + oprot_->getTransport()->writeEnd(); + oprot_->getTransport()->flush(); +} + +void ThriftHiveMetastoreClient::recv_grant_revoke_role(GrantRevokeRoleResponse& _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("grant_revoke_role") != 0) { + iprot_->skip(::apache::thrift::protocol::T_STRUCT); + iprot_->readMessageEnd(); + iprot_->getTransport()->readEnd(); + } + ThriftHiveMetastore_grant_revoke_role_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; + } + throw ::apache::thrift::TApplicationException(::apache::thrift::TApplicationException::MISSING_RESULT, "grant_revoke_role failed: unknown result"); +} + void ThriftHiveMetastoreClient::get_principals_in_role(GetPrincipalsInRoleResponse& _return, const GetPrincipalsInRoleRequest& request) { send_get_principals_in_role(request); @@ -36883,6 +37126,63 @@ void ThriftHiveMetastoreProcessor::process_list_roles(int32_t seqid, ::apache::t } } +void ThriftHiveMetastoreProcessor::process_grant_revoke_role(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.grant_revoke_role", callContext); + } + ::apache::thrift::TProcessorContextFreer freer(this->eventHandler_.get(), ctx, "ThriftHiveMetastore.grant_revoke_role"); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->preRead(ctx, "ThriftHiveMetastore.grant_revoke_role"); + } + + ThriftHiveMetastore_grant_revoke_role_args args; + args.read(iprot); + iprot->readMessageEnd(); + uint32_t bytes = iprot->getTransport()->readEnd(); + + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->postRead(ctx, "ThriftHiveMetastore.grant_revoke_role", bytes); + } + + ThriftHiveMetastore_grant_revoke_role_result result; + try { + iface_->grant_revoke_role(result.success, args.request); + result.__isset.success = true; + } catch (MetaException &o1) { + result.o1 = o1; + result.__isset.o1 = true; + } catch (const std::exception& e) { + if (this->eventHandler_.get() != NULL) { + this->eventHandler_->handlerError(ctx, "ThriftHiveMetastore.grant_revoke_role"); + } + + ::apache::thrift::TApplicationException x(e.what()); + oprot->writeMessageBegin("grant_revoke_role", ::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.grant_revoke_role"); + } + + oprot->writeMessageBegin("grant_revoke_role", ::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.grant_revoke_role", bytes); + } +} + void ThriftHiveMetastoreProcessor::process_get_principals_in_role(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext) { void* ctx = NULL; diff --git metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h index 2a1b4d7..11c64ab 100644 --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h @@ -100,6 +100,7 @@ class ThriftHiveMetastoreIf : virtual public ::facebook::fb303::FacebookService virtual bool grant_role(const std::string& role_name, const std::string& principal_name, const PrincipalType::type principal_type, const std::string& grantor, const PrincipalType::type grantorType, const bool grant_option) = 0; virtual bool revoke_role(const std::string& role_name, const std::string& principal_name, const PrincipalType::type principal_type) = 0; virtual void list_roles(std::vector & _return, const std::string& principal_name, const PrincipalType::type principal_type) = 0; + virtual void grant_revoke_role(GrantRevokeRoleResponse& _return, const GrantRevokeRoleRequest& request) = 0; virtual void get_principals_in_role(GetPrincipalsInRoleResponse& _return, const GetPrincipalsInRoleRequest& request) = 0; virtual void get_role_grants_for_principal(GetRoleGrantsForPrincipalResponse& _return, const GetRoleGrantsForPrincipalRequest& request) = 0; virtual void get_privilege_set(PrincipalPrivilegeSet& _return, const HiveObjectRef& hiveObject, const std::string& user_name, const std::vector & group_names) = 0; @@ -422,6 +423,9 @@ class ThriftHiveMetastoreNull : virtual public ThriftHiveMetastoreIf , virtual p void list_roles(std::vector & /* _return */, const std::string& /* principal_name */, const PrincipalType::type /* principal_type */) { return; } + void grant_revoke_role(GrantRevokeRoleResponse& /* _return */, const GrantRevokeRoleRequest& /* request */) { + return; + } void get_principals_in_role(GetPrincipalsInRoleResponse& /* _return */, const GetPrincipalsInRoleRequest& /* request */) { return; } @@ -12524,6 +12528,124 @@ class ThriftHiveMetastore_list_roles_presult { }; +typedef struct _ThriftHiveMetastore_grant_revoke_role_args__isset { + _ThriftHiveMetastore_grant_revoke_role_args__isset() : request(false) {} + bool request; +} _ThriftHiveMetastore_grant_revoke_role_args__isset; + +class ThriftHiveMetastore_grant_revoke_role_args { + public: + + ThriftHiveMetastore_grant_revoke_role_args() { + } + + virtual ~ThriftHiveMetastore_grant_revoke_role_args() throw() {} + + GrantRevokeRoleRequest request; + + _ThriftHiveMetastore_grant_revoke_role_args__isset __isset; + + void __set_request(const GrantRevokeRoleRequest& val) { + request = val; + } + + bool operator == (const ThriftHiveMetastore_grant_revoke_role_args & rhs) const + { + if (!(request == rhs.request)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_grant_revoke_role_args &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_grant_revoke_role_args & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + + +class ThriftHiveMetastore_grant_revoke_role_pargs { + public: + + + virtual ~ThriftHiveMetastore_grant_revoke_role_pargs() throw() {} + + const GrantRevokeRoleRequest* request; + + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_grant_revoke_role_result__isset { + _ThriftHiveMetastore_grant_revoke_role_result__isset() : success(false), o1(false) {} + bool success; + bool o1; +} _ThriftHiveMetastore_grant_revoke_role_result__isset; + +class ThriftHiveMetastore_grant_revoke_role_result { + public: + + ThriftHiveMetastore_grant_revoke_role_result() { + } + + virtual ~ThriftHiveMetastore_grant_revoke_role_result() throw() {} + + GrantRevokeRoleResponse success; + MetaException o1; + + _ThriftHiveMetastore_grant_revoke_role_result__isset __isset; + + void __set_success(const GrantRevokeRoleResponse& val) { + success = val; + } + + void __set_o1(const MetaException& val) { + o1 = val; + } + + bool operator == (const ThriftHiveMetastore_grant_revoke_role_result & rhs) const + { + if (!(success == rhs.success)) + return false; + if (!(o1 == rhs.o1)) + return false; + return true; + } + bool operator != (const ThriftHiveMetastore_grant_revoke_role_result &rhs) const { + return !(*this == rhs); + } + + bool operator < (const ThriftHiveMetastore_grant_revoke_role_result & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +typedef struct _ThriftHiveMetastore_grant_revoke_role_presult__isset { + _ThriftHiveMetastore_grant_revoke_role_presult__isset() : success(false), o1(false) {} + bool success; + bool o1; +} _ThriftHiveMetastore_grant_revoke_role_presult__isset; + +class ThriftHiveMetastore_grant_revoke_role_presult { + public: + + + virtual ~ThriftHiveMetastore_grant_revoke_role_presult() throw() {} + + GrantRevokeRoleResponse* success; + MetaException o1; + + _ThriftHiveMetastore_grant_revoke_role_presult__isset __isset; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + +}; + typedef struct _ThriftHiveMetastore_get_principals_in_role_args__isset { _ThriftHiveMetastore_get_principals_in_role_args__isset() : request(false) {} bool request; @@ -15458,6 +15580,9 @@ class ThriftHiveMetastoreClient : virtual public ThriftHiveMetastoreIf, public void list_roles(std::vector & _return, const std::string& principal_name, const PrincipalType::type principal_type); void send_list_roles(const std::string& principal_name, const PrincipalType::type principal_type); void recv_list_roles(std::vector & _return); + void grant_revoke_role(GrantRevokeRoleResponse& _return, const GrantRevokeRoleRequest& request); + void send_grant_revoke_role(const GrantRevokeRoleRequest& request); + void recv_grant_revoke_role(GrantRevokeRoleResponse& _return); void get_principals_in_role(GetPrincipalsInRoleResponse& _return, const GetPrincipalsInRoleRequest& request); void send_get_principals_in_role(const GetPrincipalsInRoleRequest& request); void recv_get_principals_in_role(GetPrincipalsInRoleResponse& _return); @@ -15621,6 +15746,7 @@ class ThriftHiveMetastoreProcessor : public ::facebook::fb303::FacebookServiceP void process_grant_role(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_revoke_role(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_list_roles(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); + void process_grant_revoke_role(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_principals_in_role(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_role_grants_for_principal(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); void process_get_privilege_set(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext); @@ -15732,6 +15858,7 @@ class ThriftHiveMetastoreProcessor : public ::facebook::fb303::FacebookServiceP processMap_["grant_role"] = &ThriftHiveMetastoreProcessor::process_grant_role; processMap_["revoke_role"] = &ThriftHiveMetastoreProcessor::process_revoke_role; processMap_["list_roles"] = &ThriftHiveMetastoreProcessor::process_list_roles; + processMap_["grant_revoke_role"] = &ThriftHiveMetastoreProcessor::process_grant_revoke_role; processMap_["get_principals_in_role"] = &ThriftHiveMetastoreProcessor::process_get_principals_in_role; processMap_["get_role_grants_for_principal"] = &ThriftHiveMetastoreProcessor::process_get_role_grants_for_principal; processMap_["get_privilege_set"] = &ThriftHiveMetastoreProcessor::process_get_privilege_set; @@ -16592,6 +16719,16 @@ class ThriftHiveMetastoreMultiface : virtual public ThriftHiveMetastoreIf, publi return; } + void grant_revoke_role(GrantRevokeRoleResponse& _return, const GrantRevokeRoleRequest& request) { + size_t sz = ifaces_.size(); + size_t i = 0; + for (; i < (sz - 1); ++i) { + ifaces_[i]->grant_revoke_role(_return, request); + } + ifaces_[i]->grant_revoke_role(_return, request); + return; + } + void get_principals_in_role(GetPrincipalsInRoleResponse& _return, const GetPrincipalsInRoleRequest& request) { size_t sz = ifaces_.size(); size_t i = 0; diff --git metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp index b18009c..a72076b 100644 --- metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp +++ metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp @@ -442,6 +442,11 @@ class ThriftHiveMetastoreHandler : virtual public ThriftHiveMetastoreIf { printf("list_roles\n"); } + void grant_revoke_role(GrantRevokeRoleResponse& _return, const GrantRevokeRoleRequest& request) { + // Your implementation goes here + printf("grant_revoke_role\n"); + } + void get_principals_in_role(GetPrincipalsInRoleResponse& _return, const GetPrincipalsInRoleRequest& request) { // Your implementation goes here printf("get_principals_in_role\n"); diff --git metastore/src/gen/thrift/gen-cpp/hive_metastore_types.cpp metastore/src/gen/thrift/gen-cpp/hive_metastore_types.cpp index a6cd09a..5a05ca0 100644 --- metastore/src/gen/thrift/gen-cpp/hive_metastore_types.cpp +++ metastore/src/gen/thrift/gen-cpp/hive_metastore_types.cpp @@ -106,6 +106,16 @@ const char* _kCompactionTypeNames[] = { }; const std::map _CompactionType_VALUES_TO_NAMES(::apache::thrift::TEnumIterator(2, _kCompactionTypeValues, _kCompactionTypeNames), ::apache::thrift::TEnumIterator(-1, NULL, NULL)); +int _kGrantRevokeTypeValues[] = { + GrantRevokeType::GRANT, + GrantRevokeType::REVOKE +}; +const char* _kGrantRevokeTypeNames[] = { + "GRANT", + "REVOKE" +}; +const std::map _GrantRevokeType_VALUES_TO_NAMES(::apache::thrift::TEnumIterator(2, _kGrantRevokeTypeValues, _kGrantRevokeTypeNames), ::apache::thrift::TEnumIterator(-1, NULL, NULL)); + int _kFunctionTypeValues[] = { FunctionType::JAVA }; @@ -1616,6 +1626,224 @@ void swap(GetPrincipalsInRoleResponse &a, GetPrincipalsInRoleResponse &b) { swap(a.principalGrants, b.principalGrants); } +const char* GrantRevokeRoleRequest::ascii_fingerprint = "6E67525C3B3AE82051F0BE16EE91FDAD"; +const uint8_t GrantRevokeRoleRequest::binary_fingerprint[16] = {0x6E,0x67,0x52,0x5C,0x3B,0x3A,0xE8,0x20,0x51,0xF0,0xBE,0x16,0xEE,0x91,0xFD,0xAD}; + +uint32_t GrantRevokeRoleRequest::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; + + bool isset_requestType = false; + + 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_I32) { + int32_t ecast78; + xfer += iprot->readI32(ecast78); + this->requestType = (GrantRevokeType::type)ecast78; + isset_requestType = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 2: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->roleName); + this->__isset.roleName = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 3: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->principalName); + this->__isset.principalName = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 4: + if (ftype == ::apache::thrift::protocol::T_I32) { + int32_t ecast79; + xfer += iprot->readI32(ecast79); + this->principalType = (PrincipalType::type)ecast79; + this->__isset.principalType = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 5: + if (ftype == ::apache::thrift::protocol::T_STRING) { + xfer += iprot->readString(this->grantor); + this->__isset.grantor = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 6: + if (ftype == ::apache::thrift::protocol::T_I32) { + int32_t ecast80; + xfer += iprot->readI32(ecast80); + this->grantorType = (PrincipalType::type)ecast80; + this->__isset.grantorType = true; + } else { + xfer += iprot->skip(ftype); + } + break; + case 7: + if (ftype == ::apache::thrift::protocol::T_BOOL) { + xfer += iprot->readBool(this->grantOption); + this->__isset.grantOption = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + if (!isset_requestType) + throw TProtocolException(TProtocolException::INVALID_DATA); + return xfer; +} + +uint32_t GrantRevokeRoleRequest::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("GrantRevokeRoleRequest"); + + xfer += oprot->writeFieldBegin("requestType", ::apache::thrift::protocol::T_I32, 1); + xfer += oprot->writeI32((int32_t)this->requestType); + xfer += oprot->writeFieldEnd(); + + if (this->__isset.roleName) { + xfer += oprot->writeFieldBegin("roleName", ::apache::thrift::protocol::T_STRING, 2); + xfer += oprot->writeString(this->roleName); + xfer += oprot->writeFieldEnd(); + } + if (this->__isset.principalName) { + xfer += oprot->writeFieldBegin("principalName", ::apache::thrift::protocol::T_STRING, 3); + xfer += oprot->writeString(this->principalName); + xfer += oprot->writeFieldEnd(); + } + if (this->__isset.principalType) { + xfer += oprot->writeFieldBegin("principalType", ::apache::thrift::protocol::T_I32, 4); + xfer += oprot->writeI32((int32_t)this->principalType); + xfer += oprot->writeFieldEnd(); + } + if (this->__isset.grantor) { + xfer += oprot->writeFieldBegin("grantor", ::apache::thrift::protocol::T_STRING, 5); + xfer += oprot->writeString(this->grantor); + xfer += oprot->writeFieldEnd(); + } + if (this->__isset.grantorType) { + xfer += oprot->writeFieldBegin("grantorType", ::apache::thrift::protocol::T_I32, 6); + xfer += oprot->writeI32((int32_t)this->grantorType); + xfer += oprot->writeFieldEnd(); + } + if (this->__isset.grantOption) { + xfer += oprot->writeFieldBegin("grantOption", ::apache::thrift::protocol::T_BOOL, 7); + xfer += oprot->writeBool(this->grantOption); + xfer += oprot->writeFieldEnd(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +void swap(GrantRevokeRoleRequest &a, GrantRevokeRoleRequest &b) { + using ::std::swap; + swap(a.requestType, b.requestType); + swap(a.roleName, b.roleName); + swap(a.principalName, b.principalName); + swap(a.principalType, b.principalType); + swap(a.grantor, b.grantor); + swap(a.grantorType, b.grantorType); + swap(a.grantOption, b.grantOption); + swap(a.__isset, b.__isset); +} + +const char* GrantRevokeRoleResponse::ascii_fingerprint = "BF054652DEF86253C2BEE7D947F167DD"; +const uint8_t GrantRevokeRoleResponse::binary_fingerprint[16] = {0xBF,0x05,0x46,0x52,0xDE,0xF8,0x62,0x53,0xC2,0xBE,0xE7,0xD9,0x47,0xF1,0x67,0xDD}; + +uint32_t GrantRevokeRoleResponse::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_BOOL) { + xfer += iprot->readBool(this->success); + this->__isset.success = true; + } else { + xfer += iprot->skip(ftype); + } + break; + default: + xfer += iprot->skip(ftype); + break; + } + xfer += iprot->readFieldEnd(); + } + + xfer += iprot->readStructEnd(); + + return xfer; +} + +uint32_t GrantRevokeRoleResponse::write(::apache::thrift::protocol::TProtocol* oprot) const { + uint32_t xfer = 0; + xfer += oprot->writeStructBegin("GrantRevokeRoleResponse"); + + if (this->__isset.success) { + xfer += oprot->writeFieldBegin("success", ::apache::thrift::protocol::T_BOOL, 1); + xfer += oprot->writeBool(this->success); + xfer += oprot->writeFieldEnd(); + } + xfer += oprot->writeFieldStop(); + xfer += oprot->writeStructEnd(); + return xfer; +} + +void swap(GrantRevokeRoleResponse &a, GrantRevokeRoleResponse &b) { + using ::std::swap; + swap(a.success, b.success); + swap(a.__isset, b.__isset); +} + const char* Database::ascii_fingerprint = "553495CAE243A1C583D5C3DD990AED53"; const uint8_t Database::binary_fingerprint[16] = {0x55,0x34,0x95,0xCA,0xE2,0x43,0xA1,0xC5,0x83,0xD5,0xC3,0xDD,0x99,0x0A,0xED,0x53}; @@ -1667,17 +1895,17 @@ uint32_t Database::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size78; - ::apache::thrift::protocol::TType _ktype79; - ::apache::thrift::protocol::TType _vtype80; - xfer += iprot->readMapBegin(_ktype79, _vtype80, _size78); - uint32_t _i82; - for (_i82 = 0; _i82 < _size78; ++_i82) + uint32_t _size81; + ::apache::thrift::protocol::TType _ktype82; + ::apache::thrift::protocol::TType _vtype83; + xfer += iprot->readMapBegin(_ktype82, _vtype83, _size81); + uint32_t _i85; + for (_i85 = 0; _i85 < _size81; ++_i85) { - std::string _key83; - xfer += iprot->readString(_key83); - std::string& _val84 = this->parameters[_key83]; - xfer += iprot->readString(_val84); + std::string _key86; + xfer += iprot->readString(_key86); + std::string& _val87 = this->parameters[_key86]; + xfer += iprot->readString(_val87); } xfer += iprot->readMapEnd(); } @@ -1704,9 +1932,9 @@ uint32_t Database::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 7: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast85; - xfer += iprot->readI32(ecast85); - this->ownerType = (PrincipalType::type)ecast85; + int32_t ecast88; + xfer += iprot->readI32(ecast88); + this->ownerType = (PrincipalType::type)ecast88; this->__isset.ownerType = true; } else { xfer += iprot->skip(ftype); @@ -1743,11 +1971,11 @@ uint32_t Database::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_MAP, 4); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); - std::map ::const_iterator _iter86; - for (_iter86 = this->parameters.begin(); _iter86 != this->parameters.end(); ++_iter86) + std::map ::const_iterator _iter89; + for (_iter89 = this->parameters.begin(); _iter89 != this->parameters.end(); ++_iter89) { - xfer += oprot->writeString(_iter86->first); - xfer += oprot->writeString(_iter86->second); + xfer += oprot->writeString(_iter89->first); + xfer += oprot->writeString(_iter89->second); } xfer += oprot->writeMapEnd(); } @@ -1828,17 +2056,17 @@ uint32_t SerDeInfo::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size87; - ::apache::thrift::protocol::TType _ktype88; - ::apache::thrift::protocol::TType _vtype89; - xfer += iprot->readMapBegin(_ktype88, _vtype89, _size87); - uint32_t _i91; - for (_i91 = 0; _i91 < _size87; ++_i91) + uint32_t _size90; + ::apache::thrift::protocol::TType _ktype91; + ::apache::thrift::protocol::TType _vtype92; + xfer += iprot->readMapBegin(_ktype91, _vtype92, _size90); + uint32_t _i94; + for (_i94 = 0; _i94 < _size90; ++_i94) { - std::string _key92; - xfer += iprot->readString(_key92); - std::string& _val93 = this->parameters[_key92]; - xfer += iprot->readString(_val93); + std::string _key95; + xfer += iprot->readString(_key95); + std::string& _val96 = this->parameters[_key95]; + xfer += iprot->readString(_val96); } xfer += iprot->readMapEnd(); } @@ -1874,11 +2102,11 @@ uint32_t SerDeInfo::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_MAP, 3); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); - std::map ::const_iterator _iter94; - for (_iter94 = this->parameters.begin(); _iter94 != this->parameters.end(); ++_iter94) + std::map ::const_iterator _iter97; + for (_iter97 = this->parameters.begin(); _iter97 != this->parameters.end(); ++_iter97) { - xfer += oprot->writeString(_iter94->first); - xfer += oprot->writeString(_iter94->second); + xfer += oprot->writeString(_iter97->first); + xfer += oprot->writeString(_iter97->second); } xfer += oprot->writeMapEnd(); } @@ -1999,14 +2227,14 @@ uint32_t SkewedInfo::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->skewedColNames.clear(); - uint32_t _size95; - ::apache::thrift::protocol::TType _etype98; - xfer += iprot->readListBegin(_etype98, _size95); - this->skewedColNames.resize(_size95); - uint32_t _i99; - for (_i99 = 0; _i99 < _size95; ++_i99) + uint32_t _size98; + ::apache::thrift::protocol::TType _etype101; + xfer += iprot->readListBegin(_etype101, _size98); + this->skewedColNames.resize(_size98); + uint32_t _i102; + for (_i102 = 0; _i102 < _size98; ++_i102) { - xfer += iprot->readString(this->skewedColNames[_i99]); + xfer += iprot->readString(this->skewedColNames[_i102]); } xfer += iprot->readListEnd(); } @@ -2019,23 +2247,23 @@ uint32_t SkewedInfo::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->skewedColValues.clear(); - uint32_t _size100; - ::apache::thrift::protocol::TType _etype103; - xfer += iprot->readListBegin(_etype103, _size100); - this->skewedColValues.resize(_size100); - uint32_t _i104; - for (_i104 = 0; _i104 < _size100; ++_i104) + uint32_t _size103; + ::apache::thrift::protocol::TType _etype106; + xfer += iprot->readListBegin(_etype106, _size103); + this->skewedColValues.resize(_size103); + uint32_t _i107; + for (_i107 = 0; _i107 < _size103; ++_i107) { { - this->skewedColValues[_i104].clear(); - uint32_t _size105; - ::apache::thrift::protocol::TType _etype108; - xfer += iprot->readListBegin(_etype108, _size105); - this->skewedColValues[_i104].resize(_size105); - uint32_t _i109; - for (_i109 = 0; _i109 < _size105; ++_i109) + this->skewedColValues[_i107].clear(); + uint32_t _size108; + ::apache::thrift::protocol::TType _etype111; + xfer += iprot->readListBegin(_etype111, _size108); + this->skewedColValues[_i107].resize(_size108); + uint32_t _i112; + for (_i112 = 0; _i112 < _size108; ++_i112) { - xfer += iprot->readString(this->skewedColValues[_i104][_i109]); + xfer += iprot->readString(this->skewedColValues[_i107][_i112]); } xfer += iprot->readListEnd(); } @@ -2051,29 +2279,29 @@ uint32_t SkewedInfo::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->skewedColValueLocationMaps.clear(); - uint32_t _size110; - ::apache::thrift::protocol::TType _ktype111; - ::apache::thrift::protocol::TType _vtype112; - xfer += iprot->readMapBegin(_ktype111, _vtype112, _size110); - uint32_t _i114; - for (_i114 = 0; _i114 < _size110; ++_i114) + uint32_t _size113; + ::apache::thrift::protocol::TType _ktype114; + ::apache::thrift::protocol::TType _vtype115; + xfer += iprot->readMapBegin(_ktype114, _vtype115, _size113); + uint32_t _i117; + for (_i117 = 0; _i117 < _size113; ++_i117) { - std::vector _key115; + std::vector _key118; { - _key115.clear(); - uint32_t _size117; - ::apache::thrift::protocol::TType _etype120; - xfer += iprot->readListBegin(_etype120, _size117); - _key115.resize(_size117); - uint32_t _i121; - for (_i121 = 0; _i121 < _size117; ++_i121) + _key118.clear(); + uint32_t _size120; + ::apache::thrift::protocol::TType _etype123; + xfer += iprot->readListBegin(_etype123, _size120); + _key118.resize(_size120); + uint32_t _i124; + for (_i124 = 0; _i124 < _size120; ++_i124) { - xfer += iprot->readString(_key115[_i121]); + xfer += iprot->readString(_key118[_i124]); } xfer += iprot->readListEnd(); } - std::string& _val116 = this->skewedColValueLocationMaps[_key115]; - xfer += iprot->readString(_val116); + std::string& _val119 = this->skewedColValueLocationMaps[_key118]; + xfer += iprot->readString(_val119); } xfer += iprot->readMapEnd(); } @@ -2101,10 +2329,10 @@ uint32_t SkewedInfo::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("skewedColNames", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->skewedColNames.size())); - std::vector ::const_iterator _iter122; - for (_iter122 = this->skewedColNames.begin(); _iter122 != this->skewedColNames.end(); ++_iter122) + std::vector ::const_iterator _iter125; + for (_iter125 = this->skewedColNames.begin(); _iter125 != this->skewedColNames.end(); ++_iter125) { - xfer += oprot->writeString((*_iter122)); + xfer += oprot->writeString((*_iter125)); } xfer += oprot->writeListEnd(); } @@ -2113,15 +2341,15 @@ uint32_t SkewedInfo::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("skewedColValues", ::apache::thrift::protocol::T_LIST, 2); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_LIST, static_cast(this->skewedColValues.size())); - std::vector > ::const_iterator _iter123; - for (_iter123 = this->skewedColValues.begin(); _iter123 != this->skewedColValues.end(); ++_iter123) + std::vector > ::const_iterator _iter126; + for (_iter126 = this->skewedColValues.begin(); _iter126 != this->skewedColValues.end(); ++_iter126) { { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*_iter123).size())); - std::vector ::const_iterator _iter124; - for (_iter124 = (*_iter123).begin(); _iter124 != (*_iter123).end(); ++_iter124) + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast((*_iter126).size())); + std::vector ::const_iterator _iter127; + for (_iter127 = (*_iter126).begin(); _iter127 != (*_iter126).end(); ++_iter127) { - xfer += oprot->writeString((*_iter124)); + xfer += oprot->writeString((*_iter127)); } xfer += oprot->writeListEnd(); } @@ -2133,19 +2361,19 @@ uint32_t SkewedInfo::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("skewedColValueLocationMaps", ::apache::thrift::protocol::T_MAP, 3); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_LIST, ::apache::thrift::protocol::T_STRING, static_cast(this->skewedColValueLocationMaps.size())); - std::map , std::string> ::const_iterator _iter125; - for (_iter125 = this->skewedColValueLocationMaps.begin(); _iter125 != this->skewedColValueLocationMaps.end(); ++_iter125) + std::map , std::string> ::const_iterator _iter128; + for (_iter128 = this->skewedColValueLocationMaps.begin(); _iter128 != this->skewedColValueLocationMaps.end(); ++_iter128) { { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(_iter125->first.size())); - std::vector ::const_iterator _iter126; - for (_iter126 = _iter125->first.begin(); _iter126 != _iter125->first.end(); ++_iter126) + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(_iter128->first.size())); + std::vector ::const_iterator _iter129; + for (_iter129 = _iter128->first.begin(); _iter129 != _iter128->first.end(); ++_iter129) { - xfer += oprot->writeString((*_iter126)); + xfer += oprot->writeString((*_iter129)); } xfer += oprot->writeListEnd(); } - xfer += oprot->writeString(_iter125->second); + xfer += oprot->writeString(_iter128->second); } xfer += oprot->writeMapEnd(); } @@ -2191,14 +2419,14 @@ uint32_t StorageDescriptor::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->cols.clear(); - uint32_t _size127; - ::apache::thrift::protocol::TType _etype130; - xfer += iprot->readListBegin(_etype130, _size127); - this->cols.resize(_size127); - uint32_t _i131; - for (_i131 = 0; _i131 < _size127; ++_i131) + uint32_t _size130; + ::apache::thrift::protocol::TType _etype133; + xfer += iprot->readListBegin(_etype133, _size130); + this->cols.resize(_size130); + uint32_t _i134; + for (_i134 = 0; _i134 < _size130; ++_i134) { - xfer += this->cols[_i131].read(iprot); + xfer += this->cols[_i134].read(iprot); } xfer += iprot->readListEnd(); } @@ -2259,14 +2487,14 @@ uint32_t StorageDescriptor::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->bucketCols.clear(); - uint32_t _size132; - ::apache::thrift::protocol::TType _etype135; - xfer += iprot->readListBegin(_etype135, _size132); - this->bucketCols.resize(_size132); - uint32_t _i136; - for (_i136 = 0; _i136 < _size132; ++_i136) + uint32_t _size135; + ::apache::thrift::protocol::TType _etype138; + xfer += iprot->readListBegin(_etype138, _size135); + this->bucketCols.resize(_size135); + uint32_t _i139; + for (_i139 = 0; _i139 < _size135; ++_i139) { - xfer += iprot->readString(this->bucketCols[_i136]); + xfer += iprot->readString(this->bucketCols[_i139]); } xfer += iprot->readListEnd(); } @@ -2279,14 +2507,14 @@ uint32_t StorageDescriptor::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->sortCols.clear(); - uint32_t _size137; - ::apache::thrift::protocol::TType _etype140; - xfer += iprot->readListBegin(_etype140, _size137); - this->sortCols.resize(_size137); - uint32_t _i141; - for (_i141 = 0; _i141 < _size137; ++_i141) + uint32_t _size140; + ::apache::thrift::protocol::TType _etype143; + xfer += iprot->readListBegin(_etype143, _size140); + this->sortCols.resize(_size140); + uint32_t _i144; + for (_i144 = 0; _i144 < _size140; ++_i144) { - xfer += this->sortCols[_i141].read(iprot); + xfer += this->sortCols[_i144].read(iprot); } xfer += iprot->readListEnd(); } @@ -2299,17 +2527,17 @@ uint32_t StorageDescriptor::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size142; - ::apache::thrift::protocol::TType _ktype143; - ::apache::thrift::protocol::TType _vtype144; - xfer += iprot->readMapBegin(_ktype143, _vtype144, _size142); - uint32_t _i146; - for (_i146 = 0; _i146 < _size142; ++_i146) + uint32_t _size145; + ::apache::thrift::protocol::TType _ktype146; + ::apache::thrift::protocol::TType _vtype147; + xfer += iprot->readMapBegin(_ktype146, _vtype147, _size145); + uint32_t _i149; + for (_i149 = 0; _i149 < _size145; ++_i149) { - std::string _key147; - xfer += iprot->readString(_key147); - std::string& _val148 = this->parameters[_key147]; - xfer += iprot->readString(_val148); + std::string _key150; + xfer += iprot->readString(_key150); + std::string& _val151 = this->parameters[_key150]; + xfer += iprot->readString(_val151); } xfer += iprot->readMapEnd(); } @@ -2353,10 +2581,10 @@ uint32_t StorageDescriptor::write(::apache::thrift::protocol::TProtocol* oprot) xfer += oprot->writeFieldBegin("cols", ::apache::thrift::protocol::T_LIST, 1); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->cols.size())); - std::vector ::const_iterator _iter149; - for (_iter149 = this->cols.begin(); _iter149 != this->cols.end(); ++_iter149) + std::vector ::const_iterator _iter152; + for (_iter152 = this->cols.begin(); _iter152 != this->cols.end(); ++_iter152) { - xfer += (*_iter149).write(oprot); + xfer += (*_iter152).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2389,10 +2617,10 @@ uint32_t StorageDescriptor::write(::apache::thrift::protocol::TProtocol* oprot) xfer += oprot->writeFieldBegin("bucketCols", ::apache::thrift::protocol::T_LIST, 8); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRING, static_cast(this->bucketCols.size())); - std::vector ::const_iterator _iter150; - for (_iter150 = this->bucketCols.begin(); _iter150 != this->bucketCols.end(); ++_iter150) + std::vector ::const_iterator _iter153; + for (_iter153 = this->bucketCols.begin(); _iter153 != this->bucketCols.end(); ++_iter153) { - xfer += oprot->writeString((*_iter150)); + xfer += oprot->writeString((*_iter153)); } xfer += oprot->writeListEnd(); } @@ -2401,10 +2629,10 @@ uint32_t StorageDescriptor::write(::apache::thrift::protocol::TProtocol* oprot) xfer += oprot->writeFieldBegin("sortCols", ::apache::thrift::protocol::T_LIST, 9); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->sortCols.size())); - std::vector ::const_iterator _iter151; - for (_iter151 = this->sortCols.begin(); _iter151 != this->sortCols.end(); ++_iter151) + std::vector ::const_iterator _iter154; + for (_iter154 = this->sortCols.begin(); _iter154 != this->sortCols.end(); ++_iter154) { - xfer += (*_iter151).write(oprot); + xfer += (*_iter154).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2413,11 +2641,11 @@ uint32_t StorageDescriptor::write(::apache::thrift::protocol::TProtocol* oprot) xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_MAP, 10); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); - std::map ::const_iterator _iter152; - for (_iter152 = this->parameters.begin(); _iter152 != this->parameters.end(); ++_iter152) + std::map ::const_iterator _iter155; + for (_iter155 = this->parameters.begin(); _iter155 != this->parameters.end(); ++_iter155) { - xfer += oprot->writeString(_iter152->first); - xfer += oprot->writeString(_iter152->second); + xfer += oprot->writeString(_iter155->first); + xfer += oprot->writeString(_iter155->second); } xfer += oprot->writeMapEnd(); } @@ -2538,14 +2766,14 @@ uint32_t Table::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitionKeys.clear(); - uint32_t _size153; - ::apache::thrift::protocol::TType _etype156; - xfer += iprot->readListBegin(_etype156, _size153); - this->partitionKeys.resize(_size153); - uint32_t _i157; - for (_i157 = 0; _i157 < _size153; ++_i157) + uint32_t _size156; + ::apache::thrift::protocol::TType _etype159; + xfer += iprot->readListBegin(_etype159, _size156); + this->partitionKeys.resize(_size156); + uint32_t _i160; + for (_i160 = 0; _i160 < _size156; ++_i160) { - xfer += this->partitionKeys[_i157].read(iprot); + xfer += this->partitionKeys[_i160].read(iprot); } xfer += iprot->readListEnd(); } @@ -2558,17 +2786,17 @@ uint32_t Table::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size158; - ::apache::thrift::protocol::TType _ktype159; - ::apache::thrift::protocol::TType _vtype160; - xfer += iprot->readMapBegin(_ktype159, _vtype160, _size158); - uint32_t _i162; - for (_i162 = 0; _i162 < _size158; ++_i162) + uint32_t _size161; + ::apache::thrift::protocol::TType _ktype162; + ::apache::thrift::protocol::TType _vtype163; + xfer += iprot->readMapBegin(_ktype162, _vtype163, _size161); + uint32_t _i165; + for (_i165 = 0; _i165 < _size161; ++_i165) { - std::string _key163; - xfer += iprot->readString(_key163); - std::string& _val164 = this->parameters[_key163]; - xfer += iprot->readString(_val164); + std::string _key166; + xfer += iprot->readString(_key166); + std::string& _val167 = this->parameters[_key166]; + xfer += iprot->readString(_val167); } xfer += iprot->readMapEnd(); } @@ -2664,10 +2892,10 @@ uint32_t Table::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("partitionKeys", ::apache::thrift::protocol::T_LIST, 8); { xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(this->partitionKeys.size())); - std::vector ::const_iterator _iter165; - for (_iter165 = this->partitionKeys.begin(); _iter165 != this->partitionKeys.end(); ++_iter165) + std::vector ::const_iterator _iter168; + for (_iter168 = this->partitionKeys.begin(); _iter168 != this->partitionKeys.end(); ++_iter168) { - xfer += (*_iter165).write(oprot); + xfer += (*_iter168).write(oprot); } xfer += oprot->writeListEnd(); } @@ -2676,11 +2904,11 @@ uint32_t Table::write(::apache::thrift::protocol::TProtocol* oprot) const { 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 _iter166; - for (_iter166 = this->parameters.begin(); _iter166 != this->parameters.end(); ++_iter166) + std::map ::const_iterator _iter169; + for (_iter169 = this->parameters.begin(); _iter169 != this->parameters.end(); ++_iter169) { - xfer += oprot->writeString(_iter166->first); - xfer += oprot->writeString(_iter166->second); + xfer += oprot->writeString(_iter169->first); + xfer += oprot->writeString(_iter169->second); } xfer += oprot->writeMapEnd(); } @@ -2759,14 +2987,14 @@ uint32_t Partition::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->values.clear(); - uint32_t _size167; - ::apache::thrift::protocol::TType _etype170; - xfer += iprot->readListBegin(_etype170, _size167); - this->values.resize(_size167); - uint32_t _i171; - for (_i171 = 0; _i171 < _size167; ++_i171) + uint32_t _size170; + ::apache::thrift::protocol::TType _etype173; + xfer += iprot->readListBegin(_etype173, _size170); + this->values.resize(_size170); + uint32_t _i174; + for (_i174 = 0; _i174 < _size170; ++_i174) { - xfer += iprot->readString(this->values[_i171]); + xfer += iprot->readString(this->values[_i174]); } xfer += iprot->readListEnd(); } @@ -2819,17 +3047,17 @@ uint32_t Partition::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size172; - ::apache::thrift::protocol::TType _ktype173; - ::apache::thrift::protocol::TType _vtype174; - xfer += iprot->readMapBegin(_ktype173, _vtype174, _size172); - uint32_t _i176; - for (_i176 = 0; _i176 < _size172; ++_i176) + uint32_t _size175; + ::apache::thrift::protocol::TType _ktype176; + ::apache::thrift::protocol::TType _vtype177; + xfer += iprot->readMapBegin(_ktype176, _vtype177, _size175); + uint32_t _i179; + for (_i179 = 0; _i179 < _size175; ++_i179) { - std::string _key177; - xfer += iprot->readString(_key177); - std::string& _val178 = this->parameters[_key177]; - xfer += iprot->readString(_val178); + std::string _key180; + xfer += iprot->readString(_key180); + std::string& _val181 = this->parameters[_key180]; + xfer += iprot->readString(_val181); } xfer += iprot->readMapEnd(); } @@ -2865,10 +3093,10 @@ uint32_t Partition::write(::apache::thrift::protocol::TProtocol* oprot) const { 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 _iter179; - for (_iter179 = this->values.begin(); _iter179 != this->values.end(); ++_iter179) + std::vector ::const_iterator _iter182; + for (_iter182 = this->values.begin(); _iter182 != this->values.end(); ++_iter182) { - xfer += oprot->writeString((*_iter179)); + xfer += oprot->writeString((*_iter182)); } xfer += oprot->writeListEnd(); } @@ -2897,11 +3125,11 @@ uint32_t Partition::write(::apache::thrift::protocol::TProtocol* oprot) const { xfer += oprot->writeFieldBegin("parameters", ::apache::thrift::protocol::T_MAP, 7); { xfer += oprot->writeMapBegin(::apache::thrift::protocol::T_STRING, ::apache::thrift::protocol::T_STRING, static_cast(this->parameters.size())); - std::map ::const_iterator _iter180; - for (_iter180 = this->parameters.begin(); _iter180 != this->parameters.end(); ++_iter180) + std::map ::const_iterator _iter183; + for (_iter183 = this->parameters.begin(); _iter183 != this->parameters.end(); ++_iter183) { - xfer += oprot->writeString(_iter180->first); - xfer += oprot->writeString(_iter180->second); + xfer += oprot->writeString(_iter183->first); + xfer += oprot->writeString(_iter183->second); } xfer += oprot->writeMapEnd(); } @@ -3021,17 +3249,17 @@ uint32_t Index::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->parameters.clear(); - uint32_t _size181; - ::apache::thrift::protocol::TType _ktype182; - ::apache::thrift::protocol::TType _vtype183; - xfer += iprot->readMapBegin(_ktype182, _vtype183, _size181); - uint32_t _i185; - for (_i185 = 0; _i185 < _size181; ++_i185) + uint32_t _size184; + ::apache::thrift::protocol::TType _ktype185; + ::apache::thrift::protocol::TType _vtype186; + xfer += iprot->readMapBegin(_ktype185, _vtype186, _size184); + uint32_t _i188; + for (_i188 = 0; _i188 < _size184; ++_i188) { - std::string _key186; - xfer += iprot->readString(_key186); - std::string& _val187 = this->parameters[_key186]; - xfer += iprot->readString(_val187); + std::string _key189; + xfer += iprot->readString(_key189); + std::string& _val190 = this->parameters[_key189]; + xfer += iprot->readString(_val190); } xfer += iprot->readMapEnd(); } @@ -3099,11 +3327,11 @@ uint32_t Index::write(::apache::thrift::protocol::TProtocol* oprot) const { 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 _iter188; - for (_iter188 = this->parameters.begin(); _iter188 != this->parameters.end(); ++_iter188) + std::map ::const_iterator _iter191; + for (_iter191 = this->parameters.begin(); _iter191 != this->parameters.end(); ++_iter191) { - xfer += oprot->writeString(_iter188->first); - xfer += oprot->writeString(_iter188->second); + xfer += oprot->writeString(_iter191->first); + xfer += oprot->writeString(_iter191->second); } xfer += oprot->writeMapEnd(); } @@ -4229,14 +4457,14 @@ uint32_t ColumnStatistics::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->statsObj.clear(); - uint32_t _size189; - ::apache::thrift::protocol::TType _etype192; - xfer += iprot->readListBegin(_etype192, _size189); - this->statsObj.resize(_size189); - uint32_t _i193; - for (_i193 = 0; _i193 < _size189; ++_i193) + uint32_t _size192; + ::apache::thrift::protocol::TType _etype195; + xfer += iprot->readListBegin(_etype195, _size192); + this->statsObj.resize(_size192); + uint32_t _i196; + for (_i196 = 0; _i196 < _size192; ++_i196) { - xfer += this->statsObj[_i193].read(iprot); + xfer += this->statsObj[_i196].read(iprot); } xfer += iprot->readListEnd(); } @@ -4272,10 +4500,10 @@ uint32_t ColumnStatistics::write(::apache::thrift::protocol::TProtocol* oprot) c 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 _iter194; - for (_iter194 = this->statsObj.begin(); _iter194 != this->statsObj.end(); ++_iter194) + std::vector ::const_iterator _iter197; + for (_iter197 = this->statsObj.begin(); _iter197 != this->statsObj.end(); ++_iter197) { - xfer += (*_iter194).write(oprot); + xfer += (*_iter197).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4319,14 +4547,14 @@ uint32_t Schema::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->fieldSchemas.clear(); - uint32_t _size195; - ::apache::thrift::protocol::TType _etype198; - xfer += iprot->readListBegin(_etype198, _size195); - this->fieldSchemas.resize(_size195); - uint32_t _i199; - for (_i199 = 0; _i199 < _size195; ++_i199) + uint32_t _size198; + ::apache::thrift::protocol::TType _etype201; + xfer += iprot->readListBegin(_etype201, _size198); + this->fieldSchemas.resize(_size198); + uint32_t _i202; + for (_i202 = 0; _i202 < _size198; ++_i202) { - xfer += this->fieldSchemas[_i199].read(iprot); + xfer += this->fieldSchemas[_i202].read(iprot); } xfer += iprot->readListEnd(); } @@ -4339,17 +4567,17 @@ uint32_t Schema::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_MAP) { { this->properties.clear(); - uint32_t _size200; - ::apache::thrift::protocol::TType _ktype201; - ::apache::thrift::protocol::TType _vtype202; - xfer += iprot->readMapBegin(_ktype201, _vtype202, _size200); - uint32_t _i204; - for (_i204 = 0; _i204 < _size200; ++_i204) + uint32_t _size203; + ::apache::thrift::protocol::TType _ktype204; + ::apache::thrift::protocol::TType _vtype205; + xfer += iprot->readMapBegin(_ktype204, _vtype205, _size203); + uint32_t _i207; + for (_i207 = 0; _i207 < _size203; ++_i207) { - std::string _key205; - xfer += iprot->readString(_key205); - std::string& _val206 = this->properties[_key205]; - xfer += iprot->readString(_val206); + std::string _key208; + xfer += iprot->readString(_key208); + std::string& _val209 = this->properties[_key208]; + xfer += iprot->readString(_val209); } xfer += iprot->readMapEnd(); } @@ -4377,10 +4605,10 @@ uint32_t Schema::write(::apache::thrift::protocol::TProtocol* oprot) const { 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 _iter207; - for (_iter207 = this->fieldSchemas.begin(); _iter207 != this->fieldSchemas.end(); ++_iter207) + std::vector ::const_iterator _iter210; + for (_iter210 = this->fieldSchemas.begin(); _iter210 != this->fieldSchemas.end(); ++_iter210) { - xfer += (*_iter207).write(oprot); + xfer += (*_iter210).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4389,11 +4617,11 @@ uint32_t Schema::write(::apache::thrift::protocol::TProtocol* oprot) const { 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 _iter208; - for (_iter208 = this->properties.begin(); _iter208 != this->properties.end(); ++_iter208) + std::map ::const_iterator _iter211; + for (_iter211 = this->properties.begin(); _iter211 != this->properties.end(); ++_iter211) { - xfer += oprot->writeString(_iter208->first); - xfer += oprot->writeString(_iter208->second); + xfer += oprot->writeString(_iter211->first); + xfer += oprot->writeString(_iter211->second); } xfer += oprot->writeMapEnd(); } @@ -4438,17 +4666,17 @@ uint32_t EnvironmentContext::read(::apache::thrift::protocol::TProtocol* iprot) if (ftype == ::apache::thrift::protocol::T_MAP) { { this->properties.clear(); - uint32_t _size209; - ::apache::thrift::protocol::TType _ktype210; - ::apache::thrift::protocol::TType _vtype211; - xfer += iprot->readMapBegin(_ktype210, _vtype211, _size209); - uint32_t _i213; - for (_i213 = 0; _i213 < _size209; ++_i213) + uint32_t _size212; + ::apache::thrift::protocol::TType _ktype213; + ::apache::thrift::protocol::TType _vtype214; + xfer += iprot->readMapBegin(_ktype213, _vtype214, _size212); + uint32_t _i216; + for (_i216 = 0; _i216 < _size212; ++_i216) { - std::string _key214; - xfer += iprot->readString(_key214); - std::string& _val215 = this->properties[_key214]; - xfer += iprot->readString(_val215); + std::string _key217; + xfer += iprot->readString(_key217); + std::string& _val218 = this->properties[_key217]; + xfer += iprot->readString(_val218); } xfer += iprot->readMapEnd(); } @@ -4476,11 +4704,11 @@ uint32_t EnvironmentContext::write(::apache::thrift::protocol::TProtocol* oprot) 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 _iter216; - for (_iter216 = this->properties.begin(); _iter216 != this->properties.end(); ++_iter216) + std::map ::const_iterator _iter219; + for (_iter219 = this->properties.begin(); _iter219 != this->properties.end(); ++_iter219) { - xfer += oprot->writeString(_iter216->first); - xfer += oprot->writeString(_iter216->second); + xfer += oprot->writeString(_iter219->first); + xfer += oprot->writeString(_iter219->second); } xfer += oprot->writeMapEnd(); } @@ -4526,14 +4754,14 @@ uint32_t PartitionsByExprResult::read(::apache::thrift::protocol::TProtocol* ipr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitions.clear(); - uint32_t _size217; - ::apache::thrift::protocol::TType _etype220; - xfer += iprot->readListBegin(_etype220, _size217); - this->partitions.resize(_size217); - uint32_t _i221; - for (_i221 = 0; _i221 < _size217; ++_i221) + uint32_t _size220; + ::apache::thrift::protocol::TType _etype223; + xfer += iprot->readListBegin(_etype223, _size220); + this->partitions.resize(_size220); + uint32_t _i224; + for (_i224 = 0; _i224 < _size220; ++_i224) { - xfer += this->partitions[_i221].read(iprot); + xfer += this->partitions[_i224].read(iprot); } xfer += iprot->readListEnd(); } @@ -4573,10 +4801,10 @@ uint32_t PartitionsByExprResult::write(::apache::thrift::protocol::TProtocol* op 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 _iter222; - for (_iter222 = this->partitions.begin(); _iter222 != this->partitions.end(); ++_iter222) + std::vector ::const_iterator _iter225; + for (_iter225 = this->partitions.begin(); _iter225 != this->partitions.end(); ++_iter225) { - xfer += (*_iter222).write(oprot); + xfer += (*_iter225).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4750,14 +4978,14 @@ uint32_t TableStatsResult::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->tableStats.clear(); - uint32_t _size223; - ::apache::thrift::protocol::TType _etype226; - xfer += iprot->readListBegin(_etype226, _size223); - this->tableStats.resize(_size223); - uint32_t _i227; - for (_i227 = 0; _i227 < _size223; ++_i227) + uint32_t _size226; + ::apache::thrift::protocol::TType _etype229; + xfer += iprot->readListBegin(_etype229, _size226); + this->tableStats.resize(_size226); + uint32_t _i230; + for (_i230 = 0; _i230 < _size226; ++_i230) { - xfer += this->tableStats[_i227].read(iprot); + xfer += this->tableStats[_i230].read(iprot); } xfer += iprot->readListEnd(); } @@ -4787,10 +5015,10 @@ uint32_t TableStatsResult::write(::apache::thrift::protocol::TProtocol* oprot) c 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 _iter228; - for (_iter228 = this->tableStats.begin(); _iter228 != this->tableStats.end(); ++_iter228) + std::vector ::const_iterator _iter231; + for (_iter231 = this->tableStats.begin(); _iter231 != this->tableStats.end(); ++_iter231) { - xfer += (*_iter228).write(oprot); + xfer += (*_iter231).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4834,26 +5062,26 @@ uint32_t PartitionsStatsResult::read(::apache::thrift::protocol::TProtocol* ipro if (ftype == ::apache::thrift::protocol::T_MAP) { { this->partStats.clear(); - uint32_t _size229; - ::apache::thrift::protocol::TType _ktype230; - ::apache::thrift::protocol::TType _vtype231; - xfer += iprot->readMapBegin(_ktype230, _vtype231, _size229); - uint32_t _i233; - for (_i233 = 0; _i233 < _size229; ++_i233) + uint32_t _size232; + ::apache::thrift::protocol::TType _ktype233; + ::apache::thrift::protocol::TType _vtype234; + xfer += iprot->readMapBegin(_ktype233, _vtype234, _size232); + uint32_t _i236; + for (_i236 = 0; _i236 < _size232; ++_i236) { - std::string _key234; - xfer += iprot->readString(_key234); - std::vector & _val235 = this->partStats[_key234]; + std::string _key237; + xfer += iprot->readString(_key237); + std::vector & _val238 = this->partStats[_key237]; { - _val235.clear(); - uint32_t _size236; - ::apache::thrift::protocol::TType _etype239; - xfer += iprot->readListBegin(_etype239, _size236); - _val235.resize(_size236); - uint32_t _i240; - for (_i240 = 0; _i240 < _size236; ++_i240) + _val238.clear(); + uint32_t _size239; + ::apache::thrift::protocol::TType _etype242; + xfer += iprot->readListBegin(_etype242, _size239); + _val238.resize(_size239); + uint32_t _i243; + for (_i243 = 0; _i243 < _size239; ++_i243) { - xfer += _val235[_i240].read(iprot); + xfer += _val238[_i243].read(iprot); } xfer += iprot->readListEnd(); } @@ -4886,16 +5114,16 @@ uint32_t PartitionsStatsResult::write(::apache::thrift::protocol::TProtocol* opr 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 _iter241; - for (_iter241 = this->partStats.begin(); _iter241 != this->partStats.end(); ++_iter241) + std::map > ::const_iterator _iter244; + for (_iter244 = this->partStats.begin(); _iter244 != this->partStats.end(); ++_iter244) { - xfer += oprot->writeString(_iter241->first); + xfer += oprot->writeString(_iter244->first); { - xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(_iter241->second.size())); - std::vector ::const_iterator _iter242; - for (_iter242 = _iter241->second.begin(); _iter242 != _iter241->second.end(); ++_iter242) + xfer += oprot->writeListBegin(::apache::thrift::protocol::T_STRUCT, static_cast(_iter244->second.size())); + std::vector ::const_iterator _iter245; + for (_iter245 = _iter244->second.begin(); _iter245 != _iter244->second.end(); ++_iter245) { - xfer += (*_iter242).write(oprot); + xfer += (*_iter245).write(oprot); } xfer += oprot->writeListEnd(); } @@ -4960,14 +5188,14 @@ uint32_t TableStatsRequest::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->colNames.clear(); - uint32_t _size243; - ::apache::thrift::protocol::TType _etype246; - xfer += iprot->readListBegin(_etype246, _size243); - this->colNames.resize(_size243); - uint32_t _i247; - for (_i247 = 0; _i247 < _size243; ++_i247) + uint32_t _size246; + ::apache::thrift::protocol::TType _etype249; + xfer += iprot->readListBegin(_etype249, _size246); + this->colNames.resize(_size246); + uint32_t _i250; + for (_i250 = 0; _i250 < _size246; ++_i250) { - xfer += iprot->readString(this->colNames[_i247]); + xfer += iprot->readString(this->colNames[_i250]); } xfer += iprot->readListEnd(); } @@ -5009,10 +5237,10 @@ uint32_t TableStatsRequest::write(::apache::thrift::protocol::TProtocol* oprot) 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 _iter248; - for (_iter248 = this->colNames.begin(); _iter248 != this->colNames.end(); ++_iter248) + std::vector ::const_iterator _iter251; + for (_iter251 = this->colNames.begin(); _iter251 != this->colNames.end(); ++_iter251) { - xfer += oprot->writeString((*_iter248)); + xfer += oprot->writeString((*_iter251)); } xfer += oprot->writeListEnd(); } @@ -5077,14 +5305,14 @@ uint32_t PartitionsStatsRequest::read(::apache::thrift::protocol::TProtocol* ipr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->colNames.clear(); - uint32_t _size249; - ::apache::thrift::protocol::TType _etype252; - xfer += iprot->readListBegin(_etype252, _size249); - this->colNames.resize(_size249); - uint32_t _i253; - for (_i253 = 0; _i253 < _size249; ++_i253) + uint32_t _size252; + ::apache::thrift::protocol::TType _etype255; + xfer += iprot->readListBegin(_etype255, _size252); + this->colNames.resize(_size252); + uint32_t _i256; + for (_i256 = 0; _i256 < _size252; ++_i256) { - xfer += iprot->readString(this->colNames[_i253]); + xfer += iprot->readString(this->colNames[_i256]); } xfer += iprot->readListEnd(); } @@ -5097,14 +5325,14 @@ uint32_t PartitionsStatsRequest::read(::apache::thrift::protocol::TProtocol* ipr if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partNames.clear(); - uint32_t _size254; - ::apache::thrift::protocol::TType _etype257; - xfer += iprot->readListBegin(_etype257, _size254); - this->partNames.resize(_size254); - uint32_t _i258; - for (_i258 = 0; _i258 < _size254; ++_i258) + uint32_t _size257; + ::apache::thrift::protocol::TType _etype260; + xfer += iprot->readListBegin(_etype260, _size257); + this->partNames.resize(_size257); + uint32_t _i261; + for (_i261 = 0; _i261 < _size257; ++_i261) { - xfer += iprot->readString(this->partNames[_i258]); + xfer += iprot->readString(this->partNames[_i261]); } xfer += iprot->readListEnd(); } @@ -5148,10 +5376,10 @@ uint32_t PartitionsStatsRequest::write(::apache::thrift::protocol::TProtocol* op 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 _iter259; - for (_iter259 = this->colNames.begin(); _iter259 != this->colNames.end(); ++_iter259) + std::vector ::const_iterator _iter262; + for (_iter262 = this->colNames.begin(); _iter262 != this->colNames.end(); ++_iter262) { - xfer += oprot->writeString((*_iter259)); + xfer += oprot->writeString((*_iter262)); } xfer += oprot->writeListEnd(); } @@ -5160,10 +5388,10 @@ uint32_t PartitionsStatsRequest::write(::apache::thrift::protocol::TProtocol* op 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 _iter260; - for (_iter260 = this->partNames.begin(); _iter260 != this->partNames.end(); ++_iter260) + std::vector ::const_iterator _iter263; + for (_iter263 = this->partNames.begin(); _iter263 != this->partNames.end(); ++_iter263) { - xfer += oprot->writeString((*_iter260)); + xfer += oprot->writeString((*_iter263)); } xfer += oprot->writeListEnd(); } @@ -5209,14 +5437,14 @@ uint32_t AddPartitionsResult::read(::apache::thrift::protocol::TProtocol* iprot) if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitions.clear(); - uint32_t _size261; - ::apache::thrift::protocol::TType _etype264; - xfer += iprot->readListBegin(_etype264, _size261); - this->partitions.resize(_size261); - uint32_t _i265; - for (_i265 = 0; _i265 < _size261; ++_i265) + uint32_t _size264; + ::apache::thrift::protocol::TType _etype267; + xfer += iprot->readListBegin(_etype267, _size264); + this->partitions.resize(_size264); + uint32_t _i268; + for (_i268 = 0; _i268 < _size264; ++_i268) { - xfer += this->partitions[_i265].read(iprot); + xfer += this->partitions[_i268].read(iprot); } xfer += iprot->readListEnd(); } @@ -5245,10 +5473,10 @@ uint32_t AddPartitionsResult::write(::apache::thrift::protocol::TProtocol* oprot 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 _iter266; - for (_iter266 = this->partitions.begin(); _iter266 != this->partitions.end(); ++_iter266) + std::vector ::const_iterator _iter269; + for (_iter269 = this->partitions.begin(); _iter269 != this->partitions.end(); ++_iter269) { - xfer += (*_iter266).write(oprot); + xfer += (*_iter269).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5312,14 +5540,14 @@ uint32_t AddPartitionsRequest::read(::apache::thrift::protocol::TProtocol* iprot if (ftype == ::apache::thrift::protocol::T_LIST) { { this->parts.clear(); - uint32_t _size267; - ::apache::thrift::protocol::TType _etype270; - xfer += iprot->readListBegin(_etype270, _size267); - this->parts.resize(_size267); - uint32_t _i271; - for (_i271 = 0; _i271 < _size267; ++_i271) + uint32_t _size270; + ::apache::thrift::protocol::TType _etype273; + xfer += iprot->readListBegin(_etype273, _size270); + this->parts.resize(_size270); + uint32_t _i274; + for (_i274 = 0; _i274 < _size270; ++_i274) { - xfer += this->parts[_i271].read(iprot); + xfer += this->parts[_i274].read(iprot); } xfer += iprot->readListEnd(); } @@ -5379,10 +5607,10 @@ uint32_t AddPartitionsRequest::write(::apache::thrift::protocol::TProtocol* opro 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 _iter272; - for (_iter272 = this->parts.begin(); _iter272 != this->parts.end(); ++_iter272) + std::vector ::const_iterator _iter275; + for (_iter275 = this->parts.begin(); _iter275 != this->parts.end(); ++_iter275) { - xfer += (*_iter272).write(oprot); + xfer += (*_iter275).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5439,14 +5667,14 @@ uint32_t DropPartitionsResult::read(::apache::thrift::protocol::TProtocol* iprot if (ftype == ::apache::thrift::protocol::T_LIST) { { this->partitions.clear(); - uint32_t _size273; - ::apache::thrift::protocol::TType _etype276; - xfer += iprot->readListBegin(_etype276, _size273); - this->partitions.resize(_size273); - uint32_t _i277; - for (_i277 = 0; _i277 < _size273; ++_i277) + uint32_t _size276; + ::apache::thrift::protocol::TType _etype279; + xfer += iprot->readListBegin(_etype279, _size276); + this->partitions.resize(_size276); + uint32_t _i280; + for (_i280 = 0; _i280 < _size276; ++_i280) { - xfer += this->partitions[_i277].read(iprot); + xfer += this->partitions[_i280].read(iprot); } xfer += iprot->readListEnd(); } @@ -5475,10 +5703,10 @@ uint32_t DropPartitionsResult::write(::apache::thrift::protocol::TProtocol* opro 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 _iter278; - for (_iter278 = this->partitions.begin(); _iter278 != this->partitions.end(); ++_iter278) + std::vector ::const_iterator _iter281; + for (_iter281 = this->partitions.begin(); _iter281 != this->partitions.end(); ++_iter281) { - xfer += (*_iter278).write(oprot); + xfer += (*_iter281).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5601,14 +5829,14 @@ uint32_t RequestPartsSpec::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->names.clear(); - uint32_t _size279; - ::apache::thrift::protocol::TType _etype282; - xfer += iprot->readListBegin(_etype282, _size279); - this->names.resize(_size279); - uint32_t _i283; - for (_i283 = 0; _i283 < _size279; ++_i283) + uint32_t _size282; + ::apache::thrift::protocol::TType _etype285; + xfer += iprot->readListBegin(_etype285, _size282); + this->names.resize(_size282); + uint32_t _i286; + for (_i286 = 0; _i286 < _size282; ++_i286) { - xfer += iprot->readString(this->names[_i283]); + xfer += iprot->readString(this->names[_i286]); } xfer += iprot->readListEnd(); } @@ -5621,14 +5849,14 @@ uint32_t RequestPartsSpec::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->exprs.clear(); - uint32_t _size284; - ::apache::thrift::protocol::TType _etype287; - xfer += iprot->readListBegin(_etype287, _size284); - this->exprs.resize(_size284); - uint32_t _i288; - for (_i288 = 0; _i288 < _size284; ++_i288) + uint32_t _size287; + ::apache::thrift::protocol::TType _etype290; + xfer += iprot->readListBegin(_etype290, _size287); + this->exprs.resize(_size287); + uint32_t _i291; + for (_i291 = 0; _i291 < _size287; ++_i291) { - xfer += this->exprs[_i288].read(iprot); + xfer += this->exprs[_i291].read(iprot); } xfer += iprot->readListEnd(); } @@ -5656,10 +5884,10 @@ uint32_t RequestPartsSpec::write(::apache::thrift::protocol::TProtocol* oprot) c 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 _iter289; - for (_iter289 = this->names.begin(); _iter289 != this->names.end(); ++_iter289) + std::vector ::const_iterator _iter292; + for (_iter292 = this->names.begin(); _iter292 != this->names.end(); ++_iter292) { - xfer += oprot->writeString((*_iter289)); + xfer += oprot->writeString((*_iter292)); } xfer += oprot->writeListEnd(); } @@ -5668,10 +5896,10 @@ uint32_t RequestPartsSpec::write(::apache::thrift::protocol::TProtocol* oprot) c 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 _iter290; - for (_iter290 = this->exprs.begin(); _iter290 != this->exprs.end(); ++_iter290) + std::vector ::const_iterator _iter293; + for (_iter293 = this->exprs.begin(); _iter293 != this->exprs.end(); ++_iter293) { - xfer += (*_iter290).write(oprot); + xfer += (*_iter293).write(oprot); } xfer += oprot->writeListEnd(); } @@ -5881,9 +6109,9 @@ uint32_t ResourceUri::read(::apache::thrift::protocol::TProtocol* iprot) { { case 1: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast291; - xfer += iprot->readI32(ecast291); - this->resourceType = (ResourceType::type)ecast291; + int32_t ecast294; + xfer += iprot->readI32(ecast294); + this->resourceType = (ResourceType::type)ecast294; this->__isset.resourceType = true; } else { xfer += iprot->skip(ftype); @@ -5990,9 +6218,9 @@ uint32_t Function::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast292; - xfer += iprot->readI32(ecast292); - this->ownerType = (PrincipalType::type)ecast292; + int32_t ecast295; + xfer += iprot->readI32(ecast295); + this->ownerType = (PrincipalType::type)ecast295; this->__isset.ownerType = true; } else { xfer += iprot->skip(ftype); @@ -6008,9 +6236,9 @@ uint32_t Function::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 7: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast293; - xfer += iprot->readI32(ecast293); - this->functionType = (FunctionType::type)ecast293; + int32_t ecast296; + xfer += iprot->readI32(ecast296); + this->functionType = (FunctionType::type)ecast296; this->__isset.functionType = true; } else { xfer += iprot->skip(ftype); @@ -6020,14 +6248,14 @@ uint32_t Function::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->resourceUris.clear(); - uint32_t _size294; - ::apache::thrift::protocol::TType _etype297; - xfer += iprot->readListBegin(_etype297, _size294); - this->resourceUris.resize(_size294); - uint32_t _i298; - for (_i298 = 0; _i298 < _size294; ++_i298) + uint32_t _size297; + ::apache::thrift::protocol::TType _etype300; + xfer += iprot->readListBegin(_etype300, _size297); + this->resourceUris.resize(_size297); + uint32_t _i301; + for (_i301 = 0; _i301 < _size297; ++_i301) { - xfer += this->resourceUris[_i298].read(iprot); + xfer += this->resourceUris[_i301].read(iprot); } xfer += iprot->readListEnd(); } @@ -6083,10 +6311,10 @@ uint32_t Function::write(::apache::thrift::protocol::TProtocol* oprot) const { 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 _iter299; - for (_iter299 = this->resourceUris.begin(); _iter299 != this->resourceUris.end(); ++_iter299) + std::vector ::const_iterator _iter302; + for (_iter302 = this->resourceUris.begin(); _iter302 != this->resourceUris.end(); ++_iter302) { - xfer += (*_iter299).write(oprot); + xfer += (*_iter302).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6147,9 +6375,9 @@ uint32_t TxnInfo::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast300; - xfer += iprot->readI32(ecast300); - this->state = (TxnState::type)ecast300; + int32_t ecast303; + xfer += iprot->readI32(ecast303); + this->state = (TxnState::type)ecast303; isset_state = true; } else { xfer += iprot->skip(ftype); @@ -6261,14 +6489,14 @@ uint32_t GetOpenTxnsInfoResponse::read(::apache::thrift::protocol::TProtocol* ip if (ftype == ::apache::thrift::protocol::T_LIST) { { this->open_txns.clear(); - uint32_t _size301; - ::apache::thrift::protocol::TType _etype304; - xfer += iprot->readListBegin(_etype304, _size301); - this->open_txns.resize(_size301); - uint32_t _i305; - for (_i305 = 0; _i305 < _size301; ++_i305) + uint32_t _size304; + ::apache::thrift::protocol::TType _etype307; + xfer += iprot->readListBegin(_etype307, _size304); + this->open_txns.resize(_size304); + uint32_t _i308; + for (_i308 = 0; _i308 < _size304; ++_i308) { - xfer += this->open_txns[_i305].read(iprot); + xfer += this->open_txns[_i308].read(iprot); } xfer += iprot->readListEnd(); } @@ -6304,10 +6532,10 @@ uint32_t GetOpenTxnsInfoResponse::write(::apache::thrift::protocol::TProtocol* o 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 _iter306; - for (_iter306 = this->open_txns.begin(); _iter306 != this->open_txns.end(); ++_iter306) + std::vector ::const_iterator _iter309; + for (_iter309 = this->open_txns.begin(); _iter309 != this->open_txns.end(); ++_iter309) { - xfer += (*_iter306).write(oprot); + xfer += (*_iter309).write(oprot); } xfer += oprot->writeListEnd(); } @@ -6361,15 +6589,15 @@ uint32_t GetOpenTxnsResponse::read(::apache::thrift::protocol::TProtocol* iprot) if (ftype == ::apache::thrift::protocol::T_SET) { { this->open_txns.clear(); - uint32_t _size307; - ::apache::thrift::protocol::TType _etype310; - xfer += iprot->readSetBegin(_etype310, _size307); - uint32_t _i311; - for (_i311 = 0; _i311 < _size307; ++_i311) + uint32_t _size310; + ::apache::thrift::protocol::TType _etype313; + xfer += iprot->readSetBegin(_etype313, _size310); + uint32_t _i314; + for (_i314 = 0; _i314 < _size310; ++_i314) { - int64_t _elem312; - xfer += iprot->readI64(_elem312); - this->open_txns.insert(_elem312); + int64_t _elem315; + xfer += iprot->readI64(_elem315); + this->open_txns.insert(_elem315); } xfer += iprot->readSetEnd(); } @@ -6405,10 +6633,10 @@ uint32_t GetOpenTxnsResponse::write(::apache::thrift::protocol::TProtocol* oprot 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 _iter313; - for (_iter313 = this->open_txns.begin(); _iter313 != this->open_txns.end(); ++_iter313) + std::set ::const_iterator _iter316; + for (_iter316 = this->open_txns.begin(); _iter316 != this->open_txns.end(); ++_iter316) { - xfer += oprot->writeI64((*_iter313)); + xfer += oprot->writeI64((*_iter316)); } xfer += oprot->writeSetEnd(); } @@ -6549,14 +6777,14 @@ uint32_t OpenTxnsResponse::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->txn_ids.clear(); - uint32_t _size314; - ::apache::thrift::protocol::TType _etype317; - xfer += iprot->readListBegin(_etype317, _size314); - this->txn_ids.resize(_size314); - uint32_t _i318; - for (_i318 = 0; _i318 < _size314; ++_i318) + uint32_t _size317; + ::apache::thrift::protocol::TType _etype320; + xfer += iprot->readListBegin(_etype320, _size317); + this->txn_ids.resize(_size317); + uint32_t _i321; + for (_i321 = 0; _i321 < _size317; ++_i321) { - xfer += iprot->readI64(this->txn_ids[_i318]); + xfer += iprot->readI64(this->txn_ids[_i321]); } xfer += iprot->readListEnd(); } @@ -6586,10 +6814,10 @@ uint32_t OpenTxnsResponse::write(::apache::thrift::protocol::TProtocol* oprot) c 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 _iter319; - for (_iter319 = this->txn_ids.begin(); _iter319 != this->txn_ids.end(); ++_iter319) + std::vector ::const_iterator _iter322; + for (_iter322 = this->txn_ids.begin(); _iter322 != this->txn_ids.end(); ++_iter322) { - xfer += oprot->writeI64((*_iter319)); + xfer += oprot->writeI64((*_iter322)); } xfer += oprot->writeListEnd(); } @@ -6761,9 +6989,9 @@ uint32_t LockComponent::read(::apache::thrift::protocol::TProtocol* iprot) { { case 1: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast320; - xfer += iprot->readI32(ecast320); - this->type = (LockType::type)ecast320; + int32_t ecast323; + xfer += iprot->readI32(ecast323); + this->type = (LockType::type)ecast323; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -6771,9 +6999,9 @@ uint32_t LockComponent::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast321; - xfer += iprot->readI32(ecast321); - this->level = (LockLevel::type)ecast321; + int32_t ecast324; + xfer += iprot->readI32(ecast324); + this->level = (LockLevel::type)ecast324; isset_level = true; } else { xfer += iprot->skip(ftype); @@ -6892,14 +7120,14 @@ uint32_t LockRequest::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->component.clear(); - uint32_t _size322; - ::apache::thrift::protocol::TType _etype325; - xfer += iprot->readListBegin(_etype325, _size322); - this->component.resize(_size322); - uint32_t _i326; - for (_i326 = 0; _i326 < _size322; ++_i326) + uint32_t _size325; + ::apache::thrift::protocol::TType _etype328; + xfer += iprot->readListBegin(_etype328, _size325); + this->component.resize(_size325); + uint32_t _i329; + for (_i329 = 0; _i329 < _size325; ++_i329) { - xfer += this->component[_i326].read(iprot); + xfer += this->component[_i329].read(iprot); } xfer += iprot->readListEnd(); } @@ -6957,10 +7185,10 @@ uint32_t LockRequest::write(::apache::thrift::protocol::TProtocol* oprot) const 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 _iter327; - for (_iter327 = this->component.begin(); _iter327 != this->component.end(); ++_iter327) + std::vector ::const_iterator _iter330; + for (_iter330 = this->component.begin(); _iter330 != this->component.end(); ++_iter330) { - xfer += (*_iter327).write(oprot); + xfer += (*_iter330).write(oprot); } xfer += oprot->writeListEnd(); } @@ -7028,9 +7256,9 @@ uint32_t LockResponse::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 2: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast328; - xfer += iprot->readI32(ecast328); - this->state = (LockState::type)ecast328; + int32_t ecast331; + xfer += iprot->readI32(ecast331); + this->state = (LockState::type)ecast331; isset_state = true; } else { xfer += iprot->skip(ftype); @@ -7312,9 +7540,9 @@ uint32_t ShowLocksResponseElement::read(::apache::thrift::protocol::TProtocol* i break; case 5: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast329; - xfer += iprot->readI32(ecast329); - this->state = (LockState::type)ecast329; + int32_t ecast332; + xfer += iprot->readI32(ecast332); + this->state = (LockState::type)ecast332; isset_state = true; } else { xfer += iprot->skip(ftype); @@ -7322,9 +7550,9 @@ uint32_t ShowLocksResponseElement::read(::apache::thrift::protocol::TProtocol* i break; case 6: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast330; - xfer += iprot->readI32(ecast330); - this->type = (LockType::type)ecast330; + int32_t ecast333; + xfer += iprot->readI32(ecast333); + this->type = (LockType::type)ecast333; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -7496,14 +7724,14 @@ uint32_t ShowLocksResponse::read(::apache::thrift::protocol::TProtocol* iprot) { if (ftype == ::apache::thrift::protocol::T_LIST) { { this->locks.clear(); - uint32_t _size331; - ::apache::thrift::protocol::TType _etype334; - xfer += iprot->readListBegin(_etype334, _size331); - this->locks.resize(_size331); - uint32_t _i335; - for (_i335 = 0; _i335 < _size331; ++_i335) + uint32_t _size334; + ::apache::thrift::protocol::TType _etype337; + xfer += iprot->readListBegin(_etype337, _size334); + this->locks.resize(_size334); + uint32_t _i338; + for (_i338 = 0; _i338 < _size334; ++_i338) { - xfer += this->locks[_i335].read(iprot); + xfer += this->locks[_i338].read(iprot); } xfer += iprot->readListEnd(); } @@ -7531,10 +7759,10 @@ uint32_t ShowLocksResponse::write(::apache::thrift::protocol::TProtocol* oprot) 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 _iter336; - for (_iter336 = this->locks.begin(); _iter336 != this->locks.end(); ++_iter336) + std::vector ::const_iterator _iter339; + for (_iter339 = this->locks.begin(); _iter339 != this->locks.end(); ++_iter339) { - xfer += (*_iter336).write(oprot); + xfer += (*_iter339).write(oprot); } xfer += oprot->writeListEnd(); } @@ -7737,15 +7965,15 @@ uint32_t HeartbeatTxnRangeResponse::read(::apache::thrift::protocol::TProtocol* if (ftype == ::apache::thrift::protocol::T_SET) { { this->aborted.clear(); - uint32_t _size337; - ::apache::thrift::protocol::TType _etype340; - xfer += iprot->readSetBegin(_etype340, _size337); - uint32_t _i341; - for (_i341 = 0; _i341 < _size337; ++_i341) + uint32_t _size340; + ::apache::thrift::protocol::TType _etype343; + xfer += iprot->readSetBegin(_etype343, _size340); + uint32_t _i344; + for (_i344 = 0; _i344 < _size340; ++_i344) { - int64_t _elem342; - xfer += iprot->readI64(_elem342); - this->aborted.insert(_elem342); + int64_t _elem345; + xfer += iprot->readI64(_elem345); + this->aborted.insert(_elem345); } xfer += iprot->readSetEnd(); } @@ -7758,15 +7986,15 @@ uint32_t HeartbeatTxnRangeResponse::read(::apache::thrift::protocol::TProtocol* if (ftype == ::apache::thrift::protocol::T_SET) { { this->nosuch.clear(); - uint32_t _size343; - ::apache::thrift::protocol::TType _etype346; - xfer += iprot->readSetBegin(_etype346, _size343); - uint32_t _i347; - for (_i347 = 0; _i347 < _size343; ++_i347) + uint32_t _size346; + ::apache::thrift::protocol::TType _etype349; + xfer += iprot->readSetBegin(_etype349, _size346); + uint32_t _i350; + for (_i350 = 0; _i350 < _size346; ++_i350) { - int64_t _elem348; - xfer += iprot->readI64(_elem348); - this->nosuch.insert(_elem348); + int64_t _elem351; + xfer += iprot->readI64(_elem351); + this->nosuch.insert(_elem351); } xfer += iprot->readSetEnd(); } @@ -7798,10 +8026,10 @@ uint32_t HeartbeatTxnRangeResponse::write(::apache::thrift::protocol::TProtocol* 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 _iter349; - for (_iter349 = this->aborted.begin(); _iter349 != this->aborted.end(); ++_iter349) + std::set ::const_iterator _iter352; + for (_iter352 = this->aborted.begin(); _iter352 != this->aborted.end(); ++_iter352) { - xfer += oprot->writeI64((*_iter349)); + xfer += oprot->writeI64((*_iter352)); } xfer += oprot->writeSetEnd(); } @@ -7810,10 +8038,10 @@ uint32_t HeartbeatTxnRangeResponse::write(::apache::thrift::protocol::TProtocol* 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 _iter350; - for (_iter350 = this->nosuch.begin(); _iter350 != this->nosuch.end(); ++_iter350) + std::set ::const_iterator _iter353; + for (_iter353 = this->nosuch.begin(); _iter353 != this->nosuch.end(); ++_iter353) { - xfer += oprot->writeI64((*_iter350)); + xfer += oprot->writeI64((*_iter353)); } xfer += oprot->writeSetEnd(); } @@ -7882,9 +8110,9 @@ uint32_t CompactionRequest::read(::apache::thrift::protocol::TProtocol* iprot) { break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast351; - xfer += iprot->readI32(ecast351); - this->type = (CompactionType::type)ecast351; + int32_t ecast354; + xfer += iprot->readI32(ecast354); + this->type = (CompactionType::type)ecast354; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -8059,9 +8287,9 @@ uint32_t ShowCompactResponseElement::read(::apache::thrift::protocol::TProtocol* break; case 4: if (ftype == ::apache::thrift::protocol::T_I32) { - int32_t ecast352; - xfer += iprot->readI32(ecast352); - this->type = (CompactionType::type)ecast352; + int32_t ecast355; + xfer += iprot->readI32(ecast355); + this->type = (CompactionType::type)ecast355; isset_type = true; } else { xfer += iprot->skip(ftype); @@ -8208,14 +8436,14 @@ uint32_t ShowCompactResponse::read(::apache::thrift::protocol::TProtocol* iprot) if (ftype == ::apache::thrift::protocol::T_LIST) { { this->compacts.clear(); - uint32_t _size353; - ::apache::thrift::protocol::TType _etype356; - xfer += iprot->readListBegin(_etype356, _size353); - this->compacts.resize(_size353); - uint32_t _i357; - for (_i357 = 0; _i357 < _size353; ++_i357) + uint32_t _size356; + ::apache::thrift::protocol::TType _etype359; + xfer += iprot->readListBegin(_etype359, _size356); + this->compacts.resize(_size356); + uint32_t _i360; + for (_i360 = 0; _i360 < _size356; ++_i360) { - xfer += this->compacts[_i357].read(iprot); + xfer += this->compacts[_i360].read(iprot); } xfer += iprot->readListEnd(); } @@ -8245,10 +8473,10 @@ uint32_t ShowCompactResponse::write(::apache::thrift::protocol::TProtocol* oprot 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 _iter358; - for (_iter358 = this->compacts.begin(); _iter358 != this->compacts.end(); ++_iter358) + std::vector ::const_iterator _iter361; + for (_iter361 = this->compacts.begin(); _iter361 != this->compacts.end(); ++_iter361) { - xfer += (*_iter358).write(oprot); + xfer += (*_iter361).write(oprot); } xfer += oprot->writeListEnd(); } diff --git metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h index a0f208a..5264533 100644 --- metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h +++ metastore/src/gen/thrift/gen-cpp/hive_metastore_types.h @@ -97,6 +97,15 @@ struct CompactionType { extern const std::map _CompactionType_VALUES_TO_NAMES; +struct GrantRevokeType { + enum type { + GRANT = 1, + REVOKE = 2 + }; +}; + +extern const std::map _GrantRevokeType_VALUES_TO_NAMES; + struct FunctionType { enum type { JAVA = 1 @@ -925,6 +934,160 @@ class GetPrincipalsInRoleResponse { void swap(GetPrincipalsInRoleResponse &a, GetPrincipalsInRoleResponse &b); +typedef struct _GrantRevokeRoleRequest__isset { + _GrantRevokeRoleRequest__isset() : roleName(false), principalName(false), principalType(false), grantor(false), grantorType(false), grantOption(false) {} + bool roleName; + bool principalName; + bool principalType; + bool grantor; + bool grantorType; + bool grantOption; +} _GrantRevokeRoleRequest__isset; + +class GrantRevokeRoleRequest { + public: + + static const char* ascii_fingerprint; // = "6E67525C3B3AE82051F0BE16EE91FDAD"; + static const uint8_t binary_fingerprint[16]; // = {0x6E,0x67,0x52,0x5C,0x3B,0x3A,0xE8,0x20,0x51,0xF0,0xBE,0x16,0xEE,0x91,0xFD,0xAD}; + + GrantRevokeRoleRequest() : requestType((GrantRevokeType::type)0), roleName(), principalName(), principalType((PrincipalType::type)0), grantor(), grantorType((PrincipalType::type)0), grantOption(0) { + } + + virtual ~GrantRevokeRoleRequest() throw() {} + + GrantRevokeType::type requestType; + std::string roleName; + std::string principalName; + PrincipalType::type principalType; + std::string grantor; + PrincipalType::type grantorType; + bool grantOption; + + _GrantRevokeRoleRequest__isset __isset; + + void __set_requestType(const GrantRevokeType::type val) { + requestType = val; + } + + void __set_roleName(const std::string& val) { + roleName = val; + __isset.roleName = true; + } + + void __set_principalName(const std::string& val) { + principalName = val; + __isset.principalName = true; + } + + void __set_principalType(const PrincipalType::type val) { + principalType = val; + __isset.principalType = true; + } + + void __set_grantor(const std::string& val) { + grantor = val; + __isset.grantor = true; + } + + void __set_grantorType(const PrincipalType::type val) { + grantorType = val; + __isset.grantorType = true; + } + + void __set_grantOption(const bool val) { + grantOption = val; + __isset.grantOption = true; + } + + bool operator == (const GrantRevokeRoleRequest & rhs) const + { + if (!(requestType == rhs.requestType)) + return false; + if (__isset.roleName != rhs.__isset.roleName) + return false; + else if (__isset.roleName && !(roleName == rhs.roleName)) + return false; + if (__isset.principalName != rhs.__isset.principalName) + return false; + else if (__isset.principalName && !(principalName == rhs.principalName)) + return false; + if (__isset.principalType != rhs.__isset.principalType) + return false; + else if (__isset.principalType && !(principalType == rhs.principalType)) + return false; + if (__isset.grantor != rhs.__isset.grantor) + return false; + else if (__isset.grantor && !(grantor == rhs.grantor)) + return false; + if (__isset.grantorType != rhs.__isset.grantorType) + return false; + else if (__isset.grantorType && !(grantorType == rhs.grantorType)) + return false; + if (__isset.grantOption != rhs.__isset.grantOption) + return false; + else if (__isset.grantOption && !(grantOption == rhs.grantOption)) + return false; + return true; + } + bool operator != (const GrantRevokeRoleRequest &rhs) const { + return !(*this == rhs); + } + + bool operator < (const GrantRevokeRoleRequest & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +void swap(GrantRevokeRoleRequest &a, GrantRevokeRoleRequest &b); + +typedef struct _GrantRevokeRoleResponse__isset { + _GrantRevokeRoleResponse__isset() : success(false) {} + bool success; +} _GrantRevokeRoleResponse__isset; + +class GrantRevokeRoleResponse { + public: + + static const char* ascii_fingerprint; // = "BF054652DEF86253C2BEE7D947F167DD"; + static const uint8_t binary_fingerprint[16]; // = {0xBF,0x05,0x46,0x52,0xDE,0xF8,0x62,0x53,0xC2,0xBE,0xE7,0xD9,0x47,0xF1,0x67,0xDD}; + + GrantRevokeRoleResponse() : success(0) { + } + + virtual ~GrantRevokeRoleResponse() throw() {} + + bool success; + + _GrantRevokeRoleResponse__isset __isset; + + void __set_success(const bool val) { + success = val; + __isset.success = true; + } + + bool operator == (const GrantRevokeRoleResponse & rhs) const + { + if (__isset.success != rhs.__isset.success) + return false; + else if (__isset.success && !(success == rhs.success)) + return false; + return true; + } + bool operator != (const GrantRevokeRoleResponse &rhs) const { + return !(*this == rhs); + } + + bool operator < (const GrantRevokeRoleResponse & ) const; + + uint32_t read(::apache::thrift::protocol::TProtocol* iprot); + uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const; + +}; + +void swap(GrantRevokeRoleResponse &a, GrantRevokeRoleResponse &b); + typedef struct _Database__isset { _Database__isset() : name(false), description(false), locationUri(false), parameters(false), privileges(false), ownerName(false), ownerType(false) {} bool name; diff --git 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 index 791c46b..4547970 100644 --- 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 @@ -704,7 +704,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, AddPartitionsReques struct.parts = new ArrayList(_list338.size); for (int _i339 = 0; _i339 < _list338.size; ++_i339) { - Partition _elem340; // required + Partition _elem340; // optional _elem340 = new Partition(); _elem340.read(iprot); struct.parts.add(_elem340); @@ -824,7 +824,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, AddPartitionsRequest struct.parts = new ArrayList(_list343.size); for (int _i344 = 0; _i344 < _list343.size; ++_i344) { - Partition _elem345; // required + Partition _elem345; // optional _elem345 = new Partition(); _elem345.read(iprot); struct.parts.add(_elem345); diff --git 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 index 2471690..68a4219 100644 --- 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 @@ -346,7 +346,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, AddPartitionsResult struct.partitions = new ArrayList(_list330.size); for (int _i331 = 0; _i331 < _list330.size; ++_i331) { - Partition _elem332; // required + Partition _elem332; // optional _elem332 = new Partition(); _elem332.read(iprot); struct.partitions.add(_elem332); @@ -428,7 +428,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, AddPartitionsResult struct.partitions = new ArrayList(_list335.size); for (int _i336 = 0; _i336 < _list335.size; ++_i336) { - Partition _elem337; // required + Partition _elem337; // optional _elem337 = new Partition(); _elem337.read(iprot); struct.partitions.add(_elem337); diff --git 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 index aa647d4..6aecf26 100644 --- 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 @@ -451,7 +451,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, ColumnStatistics st struct.statsObj = new ArrayList(_list236.size); for (int _i237 = 0; _i237 < _list236.size; ++_i237) { - ColumnStatisticsObj _elem238; // required + ColumnStatisticsObj _elem238; // optional _elem238 = new ColumnStatisticsObj(); _elem238.read(iprot); struct.statsObj.add(_elem238); @@ -531,7 +531,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, ColumnStatistics str struct.statsObj = new ArrayList(_list241.size); for (int _i242 = 0; _i242 < _list241.size; ++_i242) { - ColumnStatisticsObj _elem243; // required + ColumnStatisticsObj _elem243; // optional _elem243 = new ColumnStatisticsObj(); _elem243.read(iprot); struct.statsObj.add(_elem243); diff --git 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 index b8d5a56..a4ae892 100644 --- 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 @@ -346,7 +346,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, DropPartitionsResul struct.partitions = new ArrayList(_list346.size); for (int _i347 = 0; _i347 < _list346.size; ++_i347) { - Partition _elem348; // required + Partition _elem348; // optional _elem348 = new Partition(); _elem348.read(iprot); struct.partitions.add(_elem348); @@ -428,7 +428,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, DropPartitionsResult struct.partitions = new ArrayList(_list351.size); for (int _i352 = 0; _i352 < _list351.size; ++_i352) { - Partition _elem353; // required + Partition _elem353; // optional _elem353 = new Partition(); _elem353.read(iprot); struct.partitions.add(_elem353); diff --git 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 index 4a24bbf..781281a 100644 --- 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 @@ -997,7 +997,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, Function struct) th struct.resourceUris = new ArrayList(_list370.size); for (int _i371 = 0; _i371 < _list370.size; ++_i371) { - ResourceUri _elem372; // required + ResourceUri _elem372; // optional _elem372 = new ResourceUri(); _elem372.read(iprot); struct.resourceUris.add(_elem372); @@ -1180,7 +1180,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, Function struct) thr struct.resourceUris = new ArrayList(_list375.size); for (int _i376 = 0; _i376 < _list375.size; ++_i376) { - ResourceUri _elem377; // required + ResourceUri _elem377; // optional _elem377 = new ResourceUri(); _elem377.read(iprot); struct.resourceUris.add(_elem377); diff --git 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 index 427204e..b782d32 100644 --- 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 @@ -447,7 +447,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, GetOpenTxnsInfoResp struct.open_txns = new ArrayList(_list378.size); for (int _i379 = 0; _i379 < _list378.size; ++_i379) { - TxnInfo _elem380; // required + TxnInfo _elem380; // optional _elem380 = new TxnInfo(); _elem380.read(iprot); struct.open_txns.add(_elem380); @@ -524,7 +524,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, GetOpenTxnsInfoRespo struct.open_txns = new ArrayList(_list383.size); for (int _i384 = 0; _i384 < _list383.size; ++_i384) { - TxnInfo _elem385; // required + TxnInfo _elem385; // optional _elem385 = new TxnInfo(); _elem385.read(iprot); struct.open_txns.add(_elem385); diff --git 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 index eda18ad..d549ce9 100644 --- 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 @@ -447,7 +447,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, GetOpenTxnsResponse struct.open_txns = new HashSet(2*_set386.size); for (int _i387 = 0; _i387 < _set386.size; ++_i387) { - long _elem388; // required + long _elem388; // optional _elem388 = iprot.readI64(); struct.open_txns.add(_elem388); } @@ -523,7 +523,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, GetOpenTxnsResponse struct.open_txns = new HashSet(2*_set391.size); for (int _i392 = 0; _i392 < _set391.size; ++_i392) { - long _elem393; // required + long _elem393; // optional _elem393 = iprot.readI64(); struct.open_txns.add(_elem393); } diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetPrincipalsInRoleResponse.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetPrincipalsInRoleResponse.java index 083699b..3ef6224 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetPrincipalsInRoleResponse.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetPrincipalsInRoleResponse.java @@ -354,7 +354,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, GetPrincipalsInRole struct.principalGrants = new ArrayList(_list86.size); for (int _i87 = 0; _i87 < _list86.size; ++_i87) { - RolePrincipalGrant _elem88; // required + RolePrincipalGrant _elem88; // optional _elem88 = new RolePrincipalGrant(); _elem88.read(iprot); struct.principalGrants.add(_elem88); @@ -425,7 +425,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, GetPrincipalsInRoleR struct.principalGrants = new ArrayList(_list91.size); for (int _i92 = 0; _i92 < _list91.size; ++_i92) { - RolePrincipalGrant _elem93; // required + RolePrincipalGrant _elem93; // optional _elem93 = new RolePrincipalGrant(); _elem93.read(iprot); struct.principalGrants.add(_elem93); diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetRoleGrantsForPrincipalResponse.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetRoleGrantsForPrincipalResponse.java index f745c08..3ddc1ac 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetRoleGrantsForPrincipalResponse.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GetRoleGrantsForPrincipalResponse.java @@ -354,7 +354,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, GetRoleGrantsForPri struct.principalGrants = new ArrayList(_list78.size); for (int _i79 = 0; _i79 < _list78.size; ++_i79) { - RolePrincipalGrant _elem80; // required + RolePrincipalGrant _elem80; // optional _elem80 = new RolePrincipalGrant(); _elem80.read(iprot); struct.principalGrants.add(_elem80); @@ -425,7 +425,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, GetRoleGrantsForPrin struct.principalGrants = new ArrayList(_list83.size); for (int _i84 = 0; _i84 < _list83.size; ++_i84) { - RolePrincipalGrant _elem85; // required + RolePrincipalGrant _elem85; // optional _elem85 = new RolePrincipalGrant(); _elem85.read(iprot); struct.principalGrants.add(_elem85); diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeRoleRequest.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeRoleRequest.java new file mode 100644 index 0000000..323d825 --- /dev/null +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeRoleRequest.java @@ -0,0 +1,1058 @@ +/** + * 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 GrantRevokeRoleRequest 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("GrantRevokeRoleRequest"); + + private static final org.apache.thrift.protocol.TField REQUEST_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("requestType", org.apache.thrift.protocol.TType.I32, (short)1); + private static final org.apache.thrift.protocol.TField ROLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("roleName", org.apache.thrift.protocol.TType.STRING, (short)2); + private static final org.apache.thrift.protocol.TField PRINCIPAL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("principalName", org.apache.thrift.protocol.TType.STRING, (short)3); + private static final org.apache.thrift.protocol.TField PRINCIPAL_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("principalType", org.apache.thrift.protocol.TType.I32, (short)4); + private static final org.apache.thrift.protocol.TField GRANTOR_FIELD_DESC = new org.apache.thrift.protocol.TField("grantor", org.apache.thrift.protocol.TType.STRING, (short)5); + private static final org.apache.thrift.protocol.TField GRANTOR_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("grantorType", org.apache.thrift.protocol.TType.I32, (short)6); + private static final org.apache.thrift.protocol.TField GRANT_OPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("grantOption", org.apache.thrift.protocol.TType.BOOL, (short)7); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new GrantRevokeRoleRequestStandardSchemeFactory()); + schemes.put(TupleScheme.class, new GrantRevokeRoleRequestTupleSchemeFactory()); + } + + private GrantRevokeType requestType; // required + private String roleName; // optional + private String principalName; // optional + private PrincipalType principalType; // optional + private String grantor; // optional + private PrincipalType grantorType; // optional + private boolean grantOption; // 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 { + /** + * + * @see GrantRevokeType + */ + REQUEST_TYPE((short)1, "requestType"), + ROLE_NAME((short)2, "roleName"), + PRINCIPAL_NAME((short)3, "principalName"), + /** + * + * @see PrincipalType + */ + PRINCIPAL_TYPE((short)4, "principalType"), + GRANTOR((short)5, "grantor"), + /** + * + * @see PrincipalType + */ + GRANTOR_TYPE((short)6, "grantorType"), + GRANT_OPTION((short)7, "grantOption"); + + 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: // REQUEST_TYPE + return REQUEST_TYPE; + case 2: // ROLE_NAME + return ROLE_NAME; + case 3: // PRINCIPAL_NAME + return PRINCIPAL_NAME; + case 4: // PRINCIPAL_TYPE + return PRINCIPAL_TYPE; + case 5: // GRANTOR + return GRANTOR; + case 6: // GRANTOR_TYPE + return GRANTOR_TYPE; + case 7: // GRANT_OPTION + return GRANT_OPTION; + 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 __GRANTOPTION_ISSET_ID = 0; + private byte __isset_bitfield = 0; + private _Fields optionals[] = {_Fields.ROLE_NAME,_Fields.PRINCIPAL_NAME,_Fields.PRINCIPAL_TYPE,_Fields.GRANTOR,_Fields.GRANTOR_TYPE,_Fields.GRANT_OPTION}; + 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.REQUEST_TYPE, new org.apache.thrift.meta_data.FieldMetaData("requestType", org.apache.thrift.TFieldRequirementType.REQUIRED, + new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, GrantRevokeType.class))); + tmpMap.put(_Fields.ROLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("roleName", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.PRINCIPAL_NAME, new org.apache.thrift.meta_data.FieldMetaData("principalName", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.PRINCIPAL_TYPE, new org.apache.thrift.meta_data.FieldMetaData("principalType", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PrincipalType.class))); + tmpMap.put(_Fields.GRANTOR, new org.apache.thrift.meta_data.FieldMetaData("grantor", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.GRANTOR_TYPE, new org.apache.thrift.meta_data.FieldMetaData("grantorType", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PrincipalType.class))); + tmpMap.put(_Fields.GRANT_OPTION, new org.apache.thrift.meta_data.FieldMetaData("grantOption", org.apache.thrift.TFieldRequirementType.OPTIONAL, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(GrantRevokeRoleRequest.class, metaDataMap); + } + + public GrantRevokeRoleRequest() { + } + + public GrantRevokeRoleRequest( + GrantRevokeType requestType) + { + this(); + this.requestType = requestType; + } + + /** + * Performs a deep copy on other. + */ + public GrantRevokeRoleRequest(GrantRevokeRoleRequest other) { + __isset_bitfield = other.__isset_bitfield; + if (other.isSetRequestType()) { + this.requestType = other.requestType; + } + if (other.isSetRoleName()) { + this.roleName = other.roleName; + } + if (other.isSetPrincipalName()) { + this.principalName = other.principalName; + } + if (other.isSetPrincipalType()) { + this.principalType = other.principalType; + } + if (other.isSetGrantor()) { + this.grantor = other.grantor; + } + if (other.isSetGrantorType()) { + this.grantorType = other.grantorType; + } + this.grantOption = other.grantOption; + } + + public GrantRevokeRoleRequest deepCopy() { + return new GrantRevokeRoleRequest(this); + } + + @Override + public void clear() { + this.requestType = null; + this.roleName = null; + this.principalName = null; + this.principalType = null; + this.grantor = null; + this.grantorType = null; + setGrantOptionIsSet(false); + this.grantOption = false; + } + + /** + * + * @see GrantRevokeType + */ + public GrantRevokeType getRequestType() { + return this.requestType; + } + + /** + * + * @see GrantRevokeType + */ + public void setRequestType(GrantRevokeType requestType) { + this.requestType = requestType; + } + + public void unsetRequestType() { + this.requestType = null; + } + + /** Returns true if field requestType is set (has been assigned a value) and false otherwise */ + public boolean isSetRequestType() { + return this.requestType != null; + } + + public void setRequestTypeIsSet(boolean value) { + if (!value) { + this.requestType = null; + } + } + + public String getRoleName() { + return this.roleName; + } + + public void setRoleName(String roleName) { + this.roleName = roleName; + } + + public void unsetRoleName() { + this.roleName = null; + } + + /** Returns true if field roleName is set (has been assigned a value) and false otherwise */ + public boolean isSetRoleName() { + return this.roleName != null; + } + + public void setRoleNameIsSet(boolean value) { + if (!value) { + this.roleName = null; + } + } + + public String getPrincipalName() { + return this.principalName; + } + + public void setPrincipalName(String principalName) { + this.principalName = principalName; + } + + public void unsetPrincipalName() { + this.principalName = null; + } + + /** Returns true if field principalName is set (has been assigned a value) and false otherwise */ + public boolean isSetPrincipalName() { + return this.principalName != null; + } + + public void setPrincipalNameIsSet(boolean value) { + if (!value) { + this.principalName = null; + } + } + + /** + * + * @see PrincipalType + */ + public PrincipalType getPrincipalType() { + return this.principalType; + } + + /** + * + * @see PrincipalType + */ + public void setPrincipalType(PrincipalType principalType) { + this.principalType = principalType; + } + + public void unsetPrincipalType() { + this.principalType = null; + } + + /** Returns true if field principalType is set (has been assigned a value) and false otherwise */ + public boolean isSetPrincipalType() { + return this.principalType != null; + } + + public void setPrincipalTypeIsSet(boolean value) { + if (!value) { + this.principalType = null; + } + } + + public String getGrantor() { + return this.grantor; + } + + public void setGrantor(String grantor) { + this.grantor = grantor; + } + + public void unsetGrantor() { + this.grantor = null; + } + + /** Returns true if field grantor is set (has been assigned a value) and false otherwise */ + public boolean isSetGrantor() { + return this.grantor != null; + } + + public void setGrantorIsSet(boolean value) { + if (!value) { + this.grantor = null; + } + } + + /** + * + * @see PrincipalType + */ + public PrincipalType getGrantorType() { + return this.grantorType; + } + + /** + * + * @see PrincipalType + */ + public void setGrantorType(PrincipalType grantorType) { + this.grantorType = grantorType; + } + + public void unsetGrantorType() { + this.grantorType = null; + } + + /** Returns true if field grantorType is set (has been assigned a value) and false otherwise */ + public boolean isSetGrantorType() { + return this.grantorType != null; + } + + public void setGrantorTypeIsSet(boolean value) { + if (!value) { + this.grantorType = null; + } + } + + public boolean isGrantOption() { + return this.grantOption; + } + + public void setGrantOption(boolean grantOption) { + this.grantOption = grantOption; + setGrantOptionIsSet(true); + } + + public void unsetGrantOption() { + __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __GRANTOPTION_ISSET_ID); + } + + /** Returns true if field grantOption is set (has been assigned a value) and false otherwise */ + public boolean isSetGrantOption() { + return EncodingUtils.testBit(__isset_bitfield, __GRANTOPTION_ISSET_ID); + } + + public void setGrantOptionIsSet(boolean value) { + __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __GRANTOPTION_ISSET_ID, value); + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case REQUEST_TYPE: + if (value == null) { + unsetRequestType(); + } else { + setRequestType((GrantRevokeType)value); + } + break; + + case ROLE_NAME: + if (value == null) { + unsetRoleName(); + } else { + setRoleName((String)value); + } + break; + + case PRINCIPAL_NAME: + if (value == null) { + unsetPrincipalName(); + } else { + setPrincipalName((String)value); + } + break; + + case PRINCIPAL_TYPE: + if (value == null) { + unsetPrincipalType(); + } else { + setPrincipalType((PrincipalType)value); + } + break; + + case GRANTOR: + if (value == null) { + unsetGrantor(); + } else { + setGrantor((String)value); + } + break; + + case GRANTOR_TYPE: + if (value == null) { + unsetGrantorType(); + } else { + setGrantorType((PrincipalType)value); + } + break; + + case GRANT_OPTION: + if (value == null) { + unsetGrantOption(); + } else { + setGrantOption((Boolean)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case REQUEST_TYPE: + return getRequestType(); + + case ROLE_NAME: + return getRoleName(); + + case PRINCIPAL_NAME: + return getPrincipalName(); + + case PRINCIPAL_TYPE: + return getPrincipalType(); + + case GRANTOR: + return getGrantor(); + + case GRANTOR_TYPE: + return getGrantorType(); + + case GRANT_OPTION: + return Boolean.valueOf(isGrantOption()); + + } + 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 REQUEST_TYPE: + return isSetRequestType(); + case ROLE_NAME: + return isSetRoleName(); + case PRINCIPAL_NAME: + return isSetPrincipalName(); + case PRINCIPAL_TYPE: + return isSetPrincipalType(); + case GRANTOR: + return isSetGrantor(); + case GRANTOR_TYPE: + return isSetGrantorType(); + case GRANT_OPTION: + return isSetGrantOption(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof GrantRevokeRoleRequest) + return this.equals((GrantRevokeRoleRequest)that); + return false; + } + + public boolean equals(GrantRevokeRoleRequest that) { + if (that == null) + return false; + + boolean this_present_requestType = true && this.isSetRequestType(); + boolean that_present_requestType = true && that.isSetRequestType(); + if (this_present_requestType || that_present_requestType) { + if (!(this_present_requestType && that_present_requestType)) + return false; + if (!this.requestType.equals(that.requestType)) + return false; + } + + boolean this_present_roleName = true && this.isSetRoleName(); + boolean that_present_roleName = true && that.isSetRoleName(); + if (this_present_roleName || that_present_roleName) { + if (!(this_present_roleName && that_present_roleName)) + return false; + if (!this.roleName.equals(that.roleName)) + return false; + } + + boolean this_present_principalName = true && this.isSetPrincipalName(); + boolean that_present_principalName = true && that.isSetPrincipalName(); + if (this_present_principalName || that_present_principalName) { + if (!(this_present_principalName && that_present_principalName)) + return false; + if (!this.principalName.equals(that.principalName)) + return false; + } + + boolean this_present_principalType = true && this.isSetPrincipalType(); + boolean that_present_principalType = true && that.isSetPrincipalType(); + if (this_present_principalType || that_present_principalType) { + if (!(this_present_principalType && that_present_principalType)) + return false; + if (!this.principalType.equals(that.principalType)) + return false; + } + + boolean this_present_grantor = true && this.isSetGrantor(); + boolean that_present_grantor = true && that.isSetGrantor(); + if (this_present_grantor || that_present_grantor) { + if (!(this_present_grantor && that_present_grantor)) + return false; + if (!this.grantor.equals(that.grantor)) + return false; + } + + boolean this_present_grantorType = true && this.isSetGrantorType(); + boolean that_present_grantorType = true && that.isSetGrantorType(); + if (this_present_grantorType || that_present_grantorType) { + if (!(this_present_grantorType && that_present_grantorType)) + return false; + if (!this.grantorType.equals(that.grantorType)) + return false; + } + + boolean this_present_grantOption = true && this.isSetGrantOption(); + boolean that_present_grantOption = true && that.isSetGrantOption(); + if (this_present_grantOption || that_present_grantOption) { + if (!(this_present_grantOption && that_present_grantOption)) + return false; + if (this.grantOption != that.grantOption) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_requestType = true && (isSetRequestType()); + builder.append(present_requestType); + if (present_requestType) + builder.append(requestType.getValue()); + + boolean present_roleName = true && (isSetRoleName()); + builder.append(present_roleName); + if (present_roleName) + builder.append(roleName); + + boolean present_principalName = true && (isSetPrincipalName()); + builder.append(present_principalName); + if (present_principalName) + builder.append(principalName); + + boolean present_principalType = true && (isSetPrincipalType()); + builder.append(present_principalType); + if (present_principalType) + builder.append(principalType.getValue()); + + boolean present_grantor = true && (isSetGrantor()); + builder.append(present_grantor); + if (present_grantor) + builder.append(grantor); + + boolean present_grantorType = true && (isSetGrantorType()); + builder.append(present_grantorType); + if (present_grantorType) + builder.append(grantorType.getValue()); + + boolean present_grantOption = true && (isSetGrantOption()); + builder.append(present_grantOption); + if (present_grantOption) + builder.append(grantOption); + + return builder.toHashCode(); + } + + public int compareTo(GrantRevokeRoleRequest other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + GrantRevokeRoleRequest typedOther = (GrantRevokeRoleRequest)other; + + lastComparison = Boolean.valueOf(isSetRequestType()).compareTo(typedOther.isSetRequestType()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetRequestType()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.requestType, typedOther.requestType); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetRoleName()).compareTo(typedOther.isSetRoleName()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetRoleName()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.roleName, typedOther.roleName); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetPrincipalName()).compareTo(typedOther.isSetPrincipalName()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPrincipalName()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.principalName, typedOther.principalName); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetPrincipalType()).compareTo(typedOther.isSetPrincipalType()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPrincipalType()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.principalType, typedOther.principalType); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetGrantor()).compareTo(typedOther.isSetGrantor()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetGrantor()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.grantor, typedOther.grantor); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetGrantorType()).compareTo(typedOther.isSetGrantorType()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetGrantorType()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.grantorType, typedOther.grantorType); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetGrantOption()).compareTo(typedOther.isSetGrantOption()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetGrantOption()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.grantOption, typedOther.grantOption); + 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("GrantRevokeRoleRequest("); + boolean first = true; + + sb.append("requestType:"); + if (this.requestType == null) { + sb.append("null"); + } else { + sb.append(this.requestType); + } + first = false; + if (isSetRoleName()) { + if (!first) sb.append(", "); + sb.append("roleName:"); + if (this.roleName == null) { + sb.append("null"); + } else { + sb.append(this.roleName); + } + first = false; + } + if (isSetPrincipalName()) { + if (!first) sb.append(", "); + sb.append("principalName:"); + if (this.principalName == null) { + sb.append("null"); + } else { + sb.append(this.principalName); + } + first = false; + } + if (isSetPrincipalType()) { + if (!first) sb.append(", "); + sb.append("principalType:"); + if (this.principalType == null) { + sb.append("null"); + } else { + sb.append(this.principalType); + } + first = false; + } + if (isSetGrantor()) { + if (!first) sb.append(", "); + sb.append("grantor:"); + if (this.grantor == null) { + sb.append("null"); + } else { + sb.append(this.grantor); + } + first = false; + } + if (isSetGrantorType()) { + if (!first) sb.append(", "); + sb.append("grantorType:"); + if (this.grantorType == null) { + sb.append("null"); + } else { + sb.append(this.grantorType); + } + first = false; + } + if (isSetGrantOption()) { + if (!first) sb.append(", "); + sb.append("grantOption:"); + sb.append(this.grantOption); + first = false; + } + sb.append(")"); + return sb.toString(); + } + + public void validate() throws org.apache.thrift.TException { + // check for required fields + if (!isSetRequestType()) { + throw new org.apache.thrift.protocol.TProtocolException("Required field 'requestType' is unset! Struct:" + toString()); + } + + // 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 GrantRevokeRoleRequestStandardSchemeFactory implements SchemeFactory { + public GrantRevokeRoleRequestStandardScheme getScheme() { + return new GrantRevokeRoleRequestStandardScheme(); + } + } + + private static class GrantRevokeRoleRequestStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, GrantRevokeRoleRequest 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: // REQUEST_TYPE + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.requestType = GrantRevokeType.findByValue(iprot.readI32()); + struct.setRequestTypeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // ROLE_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.roleName = iprot.readString(); + struct.setRoleNameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // PRINCIPAL_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.principalName = iprot.readString(); + struct.setPrincipalNameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // PRINCIPAL_TYPE + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.principalType = PrincipalType.findByValue(iprot.readI32()); + struct.setPrincipalTypeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 5: // GRANTOR + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.grantor = iprot.readString(); + struct.setGrantorIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 6: // GRANTOR_TYPE + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.grantorType = PrincipalType.findByValue(iprot.readI32()); + struct.setGrantorTypeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 7: // GRANT_OPTION + if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) { + struct.grantOption = iprot.readBool(); + struct.setGrantOptionIsSet(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, GrantRevokeRoleRequest struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.requestType != null) { + oprot.writeFieldBegin(REQUEST_TYPE_FIELD_DESC); + oprot.writeI32(struct.requestType.getValue()); + oprot.writeFieldEnd(); + } + if (struct.roleName != null) { + if (struct.isSetRoleName()) { + oprot.writeFieldBegin(ROLE_NAME_FIELD_DESC); + oprot.writeString(struct.roleName); + oprot.writeFieldEnd(); + } + } + if (struct.principalName != null) { + if (struct.isSetPrincipalName()) { + oprot.writeFieldBegin(PRINCIPAL_NAME_FIELD_DESC); + oprot.writeString(struct.principalName); + oprot.writeFieldEnd(); + } + } + if (struct.principalType != null) { + if (struct.isSetPrincipalType()) { + oprot.writeFieldBegin(PRINCIPAL_TYPE_FIELD_DESC); + oprot.writeI32(struct.principalType.getValue()); + oprot.writeFieldEnd(); + } + } + if (struct.grantor != null) { + if (struct.isSetGrantor()) { + oprot.writeFieldBegin(GRANTOR_FIELD_DESC); + oprot.writeString(struct.grantor); + oprot.writeFieldEnd(); + } + } + if (struct.grantorType != null) { + if (struct.isSetGrantorType()) { + oprot.writeFieldBegin(GRANTOR_TYPE_FIELD_DESC); + oprot.writeI32(struct.grantorType.getValue()); + oprot.writeFieldEnd(); + } + } + if (struct.isSetGrantOption()) { + oprot.writeFieldBegin(GRANT_OPTION_FIELD_DESC); + oprot.writeBool(struct.grantOption); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class GrantRevokeRoleRequestTupleSchemeFactory implements SchemeFactory { + public GrantRevokeRoleRequestTupleScheme getScheme() { + return new GrantRevokeRoleRequestTupleScheme(); + } + } + + private static class GrantRevokeRoleRequestTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, GrantRevokeRoleRequest struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + oprot.writeI32(struct.requestType.getValue()); + BitSet optionals = new BitSet(); + if (struct.isSetRoleName()) { + optionals.set(0); + } + if (struct.isSetPrincipalName()) { + optionals.set(1); + } + if (struct.isSetPrincipalType()) { + optionals.set(2); + } + if (struct.isSetGrantor()) { + optionals.set(3); + } + if (struct.isSetGrantorType()) { + optionals.set(4); + } + if (struct.isSetGrantOption()) { + optionals.set(5); + } + oprot.writeBitSet(optionals, 6); + if (struct.isSetRoleName()) { + oprot.writeString(struct.roleName); + } + if (struct.isSetPrincipalName()) { + oprot.writeString(struct.principalName); + } + if (struct.isSetPrincipalType()) { + oprot.writeI32(struct.principalType.getValue()); + } + if (struct.isSetGrantor()) { + oprot.writeString(struct.grantor); + } + if (struct.isSetGrantorType()) { + oprot.writeI32(struct.grantorType.getValue()); + } + if (struct.isSetGrantOption()) { + oprot.writeBool(struct.grantOption); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, GrantRevokeRoleRequest struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + struct.requestType = GrantRevokeType.findByValue(iprot.readI32()); + struct.setRequestTypeIsSet(true); + BitSet incoming = iprot.readBitSet(6); + if (incoming.get(0)) { + struct.roleName = iprot.readString(); + struct.setRoleNameIsSet(true); + } + if (incoming.get(1)) { + struct.principalName = iprot.readString(); + struct.setPrincipalNameIsSet(true); + } + if (incoming.get(2)) { + struct.principalType = PrincipalType.findByValue(iprot.readI32()); + struct.setPrincipalTypeIsSet(true); + } + if (incoming.get(3)) { + struct.grantor = iprot.readString(); + struct.setGrantorIsSet(true); + } + if (incoming.get(4)) { + struct.grantorType = PrincipalType.findByValue(iprot.readI32()); + struct.setGrantorTypeIsSet(true); + } + if (incoming.get(5)) { + struct.grantOption = iprot.readBool(); + struct.setGrantOptionIsSet(true); + } + } + } + +} + diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeRoleResponse.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeRoleResponse.java new file mode 100644 index 0000000..b9acbb5 --- /dev/null +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeRoleResponse.java @@ -0,0 +1,386 @@ +/** + * 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 GrantRevokeRoleResponse 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("GrantRevokeRoleResponse"); + + private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)1); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new GrantRevokeRoleResponseStandardSchemeFactory()); + schemes.put(TupleScheme.class, new GrantRevokeRoleResponseTupleSchemeFactory()); + } + + private boolean success; // 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 { + SUCCESS((short)1, "success"); + + 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: // SUCCESS + return SUCCESS; + 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; + private _Fields optionals[] = {_Fields.SUCCESS}; + 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.OPTIONAL, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(GrantRevokeRoleResponse.class, metaDataMap); + } + + public GrantRevokeRoleResponse() { + } + + /** + * Performs a deep copy on other. + */ + public GrantRevokeRoleResponse(GrantRevokeRoleResponse other) { + __isset_bitfield = other.__isset_bitfield; + this.success = other.success; + } + + public GrantRevokeRoleResponse deepCopy() { + return new GrantRevokeRoleResponse(this); + } + + @Override + public void clear() { + setSuccessIsSet(false); + this.success = false; + } + + public boolean isSuccess() { + return this.success; + } + + public void setSuccess(boolean 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 void setFieldValue(_Fields field, Object value) { + switch (field) { + case SUCCESS: + if (value == null) { + unsetSuccess(); + } else { + setSuccess((Boolean)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case SUCCESS: + return Boolean.valueOf(isSuccess()); + + } + 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(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof GrantRevokeRoleResponse) + return this.equals((GrantRevokeRoleResponse)that); + return false; + } + + public boolean equals(GrantRevokeRoleResponse 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 != that.success) + 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); + + return builder.toHashCode(); + } + + public int compareTo(GrantRevokeRoleResponse other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + GrantRevokeRoleResponse typedOther = (GrantRevokeRoleResponse)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; + } + } + 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("GrantRevokeRoleResponse("); + boolean first = true; + + if (isSetSuccess()) { + sb.append("success:"); + sb.append(this.success); + 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 GrantRevokeRoleResponseStandardSchemeFactory implements SchemeFactory { + public GrantRevokeRoleResponseStandardScheme getScheme() { + return new GrantRevokeRoleResponseStandardScheme(); + } + } + + private static class GrantRevokeRoleResponseStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, GrantRevokeRoleResponse 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: // SUCCESS + if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) { + struct.success = iprot.readBool(); + struct.setSuccessIsSet(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, GrantRevokeRoleResponse struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + oprot.writeBool(struct.success); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class GrantRevokeRoleResponseTupleSchemeFactory implements SchemeFactory { + public GrantRevokeRoleResponseTupleScheme getScheme() { + return new GrantRevokeRoleResponseTupleScheme(); + } + } + + private static class GrantRevokeRoleResponseTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, GrantRevokeRoleResponse struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetSuccess()) { + optionals.set(0); + } + oprot.writeBitSet(optionals, 1); + if (struct.isSetSuccess()) { + oprot.writeBool(struct.success); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, GrantRevokeRoleResponse struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(1); + if (incoming.get(0)) { + struct.success = iprot.readBool(); + struct.setSuccessIsSet(true); + } + } + } + +} + diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeType.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeType.java new file mode 100644 index 0000000..c949637 --- /dev/null +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/GrantRevokeType.java @@ -0,0 +1,45 @@ +/** + * 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 java.util.Map; +import java.util.HashMap; +import org.apache.thrift.TEnum; + +public enum GrantRevokeType implements org.apache.thrift.TEnum { + GRANT(1), + REVOKE(2); + + private final int value; + + private GrantRevokeType(int value) { + this.value = value; + } + + /** + * Get the integer value of this enum value, as defined in the Thrift IDL. + */ + public int getValue() { + return value; + } + + /** + * Find a the enum type by its integer value, as defined in the Thrift IDL. + * @return null if the value is not found. + */ + public static GrantRevokeType findByValue(int value) { + switch (value) { + case 1: + return GRANT; + case 2: + return REVOKE; + default: + return null; + } + } +} diff --git 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 index 0fc4310..f3e3c07 100644 --- 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 @@ -459,7 +459,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, HeartbeatTxnRangeRe struct.aborted = new HashSet(2*_set418.size); for (int _i419 = 0; _i419 < _set418.size; ++_i419) { - long _elem420; // required + long _elem420; // optional _elem420 = iprot.readI64(); struct.aborted.add(_elem420); } @@ -477,7 +477,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, HeartbeatTxnRangeRe struct.nosuch = new HashSet(2*_set421.size); for (int _i422 = 0; _i422 < _set421.size; ++_i422) { - long _elem423; // required + long _elem423; // optional _elem423 = iprot.readI64(); struct.nosuch.add(_elem423); } @@ -566,7 +566,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, HeartbeatTxnRangeRes struct.aborted = new HashSet(2*_set428.size); for (int _i429 = 0; _i429 < _set428.size; ++_i429) { - long _elem430; // required + long _elem430; // optional _elem430 = iprot.readI64(); struct.aborted.add(_elem430); } @@ -577,7 +577,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, HeartbeatTxnRangeRes struct.nosuch = new HashSet(2*_set431.size); for (int _i432 = 0; _i432 < _set431.size; ++_i432) { - long _elem433; // required + long _elem433; // optional _elem433 = iprot.readI64(); struct.nosuch.add(_elem433); } diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HiveObjectRef.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HiveObjectRef.java index 997060f..b22b211 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HiveObjectRef.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/HiveObjectRef.java @@ -710,7 +710,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, HiveObjectRef struc struct.partValues = new ArrayList(_list8.size); for (int _i9 = 0; _i9 < _list8.size; ++_i9) { - String _elem10; // required + String _elem10; // optional _elem10 = iprot.readString(); struct.partValues.add(_elem10); } @@ -853,7 +853,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, HiveObjectRef struct struct.partValues = new ArrayList(_list13.size); for (int _i14 = 0; _i14 < _list13.size; ++_i14) { - String _elem15; // required + String _elem15; // optional _elem15 = iprot.readString(); struct.partValues.add(_elem15); } diff --git 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 index c35aadd..cdf6f30 100644 --- 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 @@ -605,7 +605,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, LockRequest struct) struct.component = new ArrayList(_list402.size); for (int _i403 = 0; _i403 < _list402.size; ++_i403) { - LockComponent _elem404; // required + LockComponent _elem404; // optional _elem404 = new LockComponent(); _elem404.read(iprot); struct.component.add(_elem404); @@ -725,7 +725,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, LockRequest struct) struct.component = new ArrayList(_list407.size); for (int _i408 = 0; _i408 < _list407.size; ++_i408) { - LockComponent _elem409; // required + LockComponent _elem409; // optional _elem409 = new LockComponent(); _elem409.read(iprot); struct.component.add(_elem409); diff --git 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 index 3d47286..54955c6 100644 --- 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 @@ -354,7 +354,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, OpenTxnsResponse st struct.txn_ids = new ArrayList(_list394.size); for (int _i395 = 0; _i395 < _list394.size; ++_i395) { - long _elem396; // required + long _elem396; // optional _elem396 = iprot.readI64(); struct.txn_ids.add(_elem396); } @@ -424,7 +424,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, OpenTxnsResponse str struct.txn_ids = new ArrayList(_list399.size); for (int _i400 = 0; _i400 < _list399.size; ++_i400) { - long _elem401; // required + long _elem401; // optional _elem401 = iprot.readI64(); struct.txn_ids.add(_elem401); } diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Partition.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Partition.java index 312807e..7d29d09 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Partition.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Partition.java @@ -945,7 +945,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, Partition struct) t struct.values = new ArrayList(_list208.size); for (int _i209 = 0; _i209 < _list208.size; ++_i209) { - String _elem210; // required + String _elem210; // optional _elem210 = iprot.readString(); struct.values.add(_elem210); } @@ -1184,7 +1184,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, Partition struct) th struct.values = new ArrayList(_list219.size); for (int _i220 = 0; _i220 < _list219.size; ++_i220) { - String _elem221; // required + String _elem221; // optional _elem221 = iprot.readString(); struct.values.add(_elem221); } diff --git 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 index ea8f0bb..5ea5a1b 100644 --- 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 @@ -439,7 +439,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionsByExprRes struct.partitions = new ArrayList(_list272.size); for (int _i273 = 0; _i273 < _list272.size; ++_i273) { - Partition _elem274; // required + Partition _elem274; // optional _elem274 = new Partition(); _elem274.read(iprot); struct.partitions.add(_elem274); @@ -522,7 +522,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PartitionsByExprResu struct.partitions = new ArrayList(_list277.size); for (int _i278 = 0; _i278 < _list277.size; ++_i278) { - Partition _elem279; // required + Partition _elem279; // optional _elem279 = new Partition(); _elem279.read(iprot); struct.partitions.add(_elem279); diff --git 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 index a46bdc8..80a151a 100644 --- 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 @@ -645,7 +645,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionsStatsRequ struct.colNames = new ArrayList(_list314.size); for (int _i315 = 0; _i315 < _list314.size; ++_i315) { - String _elem316; // required + String _elem316; // optional _elem316 = iprot.readString(); struct.colNames.add(_elem316); } @@ -663,7 +663,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionsStatsRequ struct.partNames = new ArrayList(_list317.size); for (int _i318 = 0; _i318 < _list317.size; ++_i318) { - String _elem319; // required + String _elem319; // optional _elem319 = iprot.readString(); struct.partNames.add(_elem319); } @@ -768,7 +768,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PartitionsStatsReque struct.colNames = new ArrayList(_list324.size); for (int _i325 = 0; _i325 < _list324.size; ++_i325) { - String _elem326; // required + String _elem326; // optional _elem326 = iprot.readString(); struct.colNames.add(_elem326); } @@ -779,7 +779,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PartitionsStatsReque struct.partNames = new ArrayList(_list327.size); for (int _i328 = 0; _i328 < _list327.size; ++_i328) { - String _elem329; // required + String _elem329; // optional _elem329 = iprot.readString(); struct.partNames.add(_elem329); } diff --git 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 index 27f654d..537db47 100644 --- 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 @@ -371,7 +371,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PartitionsStatsResu _val291 = new ArrayList(_list292.size); for (int _i293 = 0; _i293 < _list292.size; ++_i293) { - ColumnStatisticsObj _elem294; // required + ColumnStatisticsObj _elem294; // optional _elem294 = new ColumnStatisticsObj(); _elem294.read(iprot); _val291.add(_elem294); @@ -469,7 +469,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PartitionsStatsResul _val302 = new ArrayList(_list303.size); for (int _i304 = 0; _i304 < _list303.size; ++_i304) { - ColumnStatisticsObj _elem305; // required + ColumnStatisticsObj _elem305; // optional _elem305 = new ColumnStatisticsObj(); _elem305.read(iprot); _val302.add(_elem305); diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrincipalPrivilegeSet.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrincipalPrivilegeSet.java index eea86e5..0c9518a 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrincipalPrivilegeSet.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrincipalPrivilegeSet.java @@ -587,7 +587,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PrincipalPrivilegeS _val27 = new ArrayList(_list28.size); for (int _i29 = 0; _i29 < _list28.size; ++_i29) { - PrivilegeGrantInfo _elem30; // required + PrivilegeGrantInfo _elem30; // optional _elem30 = new PrivilegeGrantInfo(); _elem30.read(iprot); _val27.add(_elem30); @@ -618,7 +618,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PrincipalPrivilegeS _val34 = new ArrayList(_list35.size); for (int _i36 = 0; _i36 < _list35.size; ++_i36) { - PrivilegeGrantInfo _elem37; // required + PrivilegeGrantInfo _elem37; // optional _elem37 = new PrivilegeGrantInfo(); _elem37.read(iprot); _val34.add(_elem37); @@ -649,7 +649,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PrincipalPrivilegeS _val41 = new ArrayList(_list42.size); for (int _i43 = 0; _i43 < _list42.size; ++_i43) { - PrivilegeGrantInfo _elem44; // required + PrivilegeGrantInfo _elem44; // optional _elem44 = new PrivilegeGrantInfo(); _elem44.read(iprot); _val41.add(_elem44); @@ -834,7 +834,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PrincipalPrivilegeSe _val60 = new ArrayList(_list61.size); for (int _i62 = 0; _i62 < _list61.size; ++_i62) { - PrivilegeGrantInfo _elem63; // required + PrivilegeGrantInfo _elem63; // optional _elem63 = new PrivilegeGrantInfo(); _elem63.read(iprot); _val60.add(_elem63); @@ -859,7 +859,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PrincipalPrivilegeSe _val67 = new ArrayList(_list68.size); for (int _i69 = 0; _i69 < _list68.size; ++_i69) { - PrivilegeGrantInfo _elem70; // required + PrivilegeGrantInfo _elem70; // optional _elem70 = new PrivilegeGrantInfo(); _elem70.read(iprot); _val67.add(_elem70); @@ -884,7 +884,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PrincipalPrivilegeSe _val74 = new ArrayList(_list75.size); for (int _i76 = 0; _i76 < _list75.size; ++_i76) { - PrivilegeGrantInfo _elem77; // required + PrivilegeGrantInfo _elem77; // optional _elem77 = new PrivilegeGrantInfo(); _elem77.read(iprot); _val74.add(_elem77); diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrivilegeBag.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrivilegeBag.java index a4687ad..4285ed8 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrivilegeBag.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/PrivilegeBag.java @@ -350,7 +350,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, PrivilegeBag struct struct.privileges = new ArrayList(_list16.size); for (int _i17 = 0; _i17 < _list16.size; ++_i17) { - HiveObjectPrivilege _elem18; // required + HiveObjectPrivilege _elem18; // optional _elem18 = new HiveObjectPrivilege(); _elem18.read(iprot); struct.privileges.add(_elem18); @@ -430,7 +430,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, PrivilegeBag struct) struct.privileges = new ArrayList(_list21.size); for (int _i22 = 0; _i22 < _list21.size; ++_i22) { - HiveObjectPrivilege _elem23; // required + HiveObjectPrivilege _elem23; // optional _elem23 = new HiveObjectPrivilege(); _elem23.read(iprot); struct.privileges.add(_elem23); diff --git 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 index 5119b83..2fcb216 100644 --- 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 @@ -169,7 +169,7 @@ protected Object standardSchemeReadValue(org.apache.thrift.protocol.TProtocol ip names = new ArrayList(_list354.size); for (int _i355 = 0; _i355 < _list354.size; ++_i355) { - String _elem356; // required + String _elem356; // optional _elem356 = iprot.readString(); names.add(_elem356); } @@ -188,7 +188,7 @@ protected Object standardSchemeReadValue(org.apache.thrift.protocol.TProtocol ip exprs = new ArrayList(_list357.size); for (int _i358 = 0; _i358 < _list357.size; ++_i358) { - DropPartitionsExpr _elem359; // required + DropPartitionsExpr _elem359; // optional _elem359 = new DropPartitionsExpr(); _elem359.read(iprot); exprs.add(_elem359); @@ -250,7 +250,7 @@ protected Object tupleSchemeReadValue(org.apache.thrift.protocol.TProtocol iprot names = new ArrayList(_list362.size); for (int _i363 = 0; _i363 < _list362.size; ++_i363) { - String _elem364; // required + String _elem364; // optional _elem364 = iprot.readString(); names.add(_elem364); } @@ -264,7 +264,7 @@ protected Object tupleSchemeReadValue(org.apache.thrift.protocol.TProtocol iprot exprs = new ArrayList(_list365.size); for (int _i366 = 0; _i366 < _list365.size; ++_i366) { - DropPartitionsExpr _elem367; // required + DropPartitionsExpr _elem367; // optional _elem367 = new DropPartitionsExpr(); _elem367.read(iprot); exprs.add(_elem367); diff --git 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 index d91ca2d..58e9028 100644 --- 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 @@ -456,7 +456,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, Schema struct) thro struct.fieldSchemas = new ArrayList(_list244.size); for (int _i245 = 0; _i245 < _list244.size; ++_i245) { - FieldSchema _elem246; // required + FieldSchema _elem246; // optional _elem246 = new FieldSchema(); _elem246.read(iprot); struct.fieldSchemas.add(_elem246); @@ -582,7 +582,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, Schema struct) throw struct.fieldSchemas = new ArrayList(_list255.size); for (int _i256 = 0; _i256 < _list255.size; ++_i256) { - FieldSchema _elem257; // required + FieldSchema _elem257; // optional _elem257 = new FieldSchema(); _elem257.read(iprot); struct.fieldSchemas.add(_elem257); diff --git 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 index a9f9f7c..b962e27 100644 --- 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 @@ -354,7 +354,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, ShowCompactResponse struct.compacts = new ArrayList(_list434.size); for (int _i435 = 0; _i435 < _list434.size; ++_i435) { - ShowCompactResponseElement _elem436; // required + ShowCompactResponseElement _elem436; // optional _elem436 = new ShowCompactResponseElement(); _elem436.read(iprot); struct.compacts.add(_elem436); @@ -425,7 +425,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, ShowCompactResponse struct.compacts = new ArrayList(_list439.size); for (int _i440 = 0; _i440 < _list439.size; ++_i440) { - ShowCompactResponseElement _elem441; // required + ShowCompactResponseElement _elem441; // optional _elem441 = new ShowCompactResponseElement(); _elem441.read(iprot); struct.compacts.add(_elem441); diff --git 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 index d2657e0..1399f8b 100644 --- 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 @@ -350,7 +350,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, ShowLocksResponse s struct.locks = new ArrayList(_list410.size); for (int _i411 = 0; _i411 < _list410.size; ++_i411) { - ShowLocksResponseElement _elem412; // required + ShowLocksResponseElement _elem412; // optional _elem412 = new ShowLocksResponseElement(); _elem412.read(iprot); struct.locks.add(_elem412); @@ -430,7 +430,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, ShowLocksResponse st struct.locks = new ArrayList(_list415.size); for (int _i416 = 0; _i416 < _list415.size; ++_i416) { - ShowLocksResponseElement _elem417; // required + ShowLocksResponseElement _elem417; // optional _elem417 = new ShowLocksResponseElement(); _elem417.read(iprot); struct.locks.add(_elem417); diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/SkewedInfo.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/SkewedInfo.java index 83438c7..ab5c0ed 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/SkewedInfo.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/SkewedInfo.java @@ -566,7 +566,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, SkewedInfo struct) struct.skewedColNames = new ArrayList(_list114.size); for (int _i115 = 0; _i115 < _list114.size; ++_i115) { - String _elem116; // required + String _elem116; // optional _elem116 = iprot.readString(); struct.skewedColNames.add(_elem116); } @@ -584,13 +584,13 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, SkewedInfo struct) struct.skewedColValues = new ArrayList>(_list117.size); for (int _i118 = 0; _i118 < _list117.size; ++_i118) { - List _elem119; // required + List _elem119; // optional { org.apache.thrift.protocol.TList _list120 = iprot.readListBegin(); _elem119 = new ArrayList(_list120.size); for (int _i121 = 0; _i121 < _list120.size; ++_i121) { - String _elem122; // required + String _elem122; // optional _elem122 = iprot.readString(); _elem119.add(_elem122); } @@ -619,7 +619,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, SkewedInfo struct) _key125 = new ArrayList(_list127.size); for (int _i128 = 0; _i128 < _list127.size; ++_i128) { - String _elem129; // required + String _elem129; // optional _elem129 = iprot.readString(); _key125.add(_elem129); } @@ -779,7 +779,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, SkewedInfo struct) t struct.skewedColNames = new ArrayList(_list140.size); for (int _i141 = 0; _i141 < _list140.size; ++_i141) { - String _elem142; // required + String _elem142; // optional _elem142 = iprot.readString(); struct.skewedColNames.add(_elem142); } @@ -792,13 +792,13 @@ public void read(org.apache.thrift.protocol.TProtocol prot, SkewedInfo struct) t struct.skewedColValues = new ArrayList>(_list143.size); for (int _i144 = 0; _i144 < _list143.size; ++_i144) { - List _elem145; // required + List _elem145; // optional { org.apache.thrift.protocol.TList _list146 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); _elem145 = new ArrayList(_list146.size); for (int _i147 = 0; _i147 < _list146.size; ++_i147) { - String _elem148; // required + String _elem148; // optional _elem148 = iprot.readString(); _elem145.add(_elem148); } @@ -821,7 +821,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, SkewedInfo struct) t _key151 = new ArrayList(_list153.size); for (int _i154 = 0; _i154 < _list153.size; ++_i154) { - String _elem155; // required + String _elem155; // optional _elem155 = iprot.readString(); _key151.add(_elem155); } diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/StorageDescriptor.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/StorageDescriptor.java index d0b9843..813b4f0 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/StorageDescriptor.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/StorageDescriptor.java @@ -1304,7 +1304,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, StorageDescriptor s struct.cols = new ArrayList(_list156.size); for (int _i157 = 0; _i157 < _list156.size; ++_i157) { - FieldSchema _elem158; // required + FieldSchema _elem158; // optional _elem158 = new FieldSchema(); _elem158.read(iprot); struct.cols.add(_elem158); @@ -1372,7 +1372,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, StorageDescriptor s struct.bucketCols = new ArrayList(_list159.size); for (int _i160 = 0; _i160 < _list159.size; ++_i160) { - String _elem161; // required + String _elem161; // optional _elem161 = iprot.readString(); struct.bucketCols.add(_elem161); } @@ -1390,7 +1390,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, StorageDescriptor s struct.sortCols = new ArrayList(_list162.size); for (int _i163 = 0; _i163 < _list162.size; ++_i163) { - Order _elem164; // required + Order _elem164; // optional _elem164 = new Order(); _elem164.read(iprot); struct.sortCols.add(_elem164); @@ -1667,7 +1667,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, StorageDescriptor st struct.cols = new ArrayList(_list177.size); for (int _i178 = 0; _i178 < _list177.size; ++_i178) { - FieldSchema _elem179; // required + FieldSchema _elem179; // optional _elem179 = new FieldSchema(); _elem179.read(iprot); struct.cols.add(_elem179); @@ -1706,7 +1706,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, StorageDescriptor st struct.bucketCols = new ArrayList(_list180.size); for (int _i181 = 0; _i181 < _list180.size; ++_i181) { - String _elem182; // required + String _elem182; // optional _elem182 = iprot.readString(); struct.bucketCols.add(_elem182); } @@ -1719,7 +1719,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, StorageDescriptor st struct.sortCols = new ArrayList(_list183.size); for (int _i184 = 0; _i184 < _list183.size; ++_i184) { - Order _elem185; // required + Order _elem185; // optional _elem185 = new Order(); _elem185.read(iprot); struct.sortCols.add(_elem185); diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java index 229a819..484bd6a 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Table.java @@ -1481,7 +1481,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, Table struct) throw struct.partitionKeys = new ArrayList(_list190.size); for (int _i191 = 0; _i191 < _list190.size; ++_i191) { - FieldSchema _elem192; // required + FieldSchema _elem192; // optional _elem192 = new FieldSchema(); _elem192.read(iprot); struct.partitionKeys.add(_elem192); @@ -1805,7 +1805,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, Table struct) throws struct.partitionKeys = new ArrayList(_list201.size); for (int _i202 = 0; _i202 < _list201.size; ++_i202) { - FieldSchema _elem203; // required + FieldSchema _elem203; // optional _elem203 = new FieldSchema(); _elem203.read(iprot); struct.partitionKeys.add(_elem203); diff --git 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 index 48d16b7..ddfcccc 100644 --- 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 @@ -540,7 +540,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, TableStatsRequest s struct.colNames = new ArrayList(_list306.size); for (int _i307 = 0; _i307 < _list306.size; ++_i307) { - String _elem308; // required + String _elem308; // optional _elem308 = iprot.readString(); struct.colNames.add(_elem308); } @@ -626,7 +626,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, TableStatsRequest st struct.colNames = new ArrayList(_list311.size); for (int _i312 = 0; _i312 < _list311.size; ++_i312) { - String _elem313; // required + String _elem313; // optional _elem313 = iprot.readString(); struct.colNames.add(_elem313); } diff --git 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 index b25c6c2..e37b75c 100644 --- 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 @@ -354,7 +354,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, TableStatsResult st struct.tableStats = new ArrayList(_list280.size); for (int _i281 = 0; _i281 < _list280.size; ++_i281) { - ColumnStatisticsObj _elem282; // required + ColumnStatisticsObj _elem282; // optional _elem282 = new ColumnStatisticsObj(); _elem282.read(iprot); struct.tableStats.add(_elem282); @@ -425,7 +425,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, TableStatsResult str struct.tableStats = new ArrayList(_list285.size); for (int _i286 = 0; _i286 < _list285.size; ++_i286) { - ColumnStatisticsObj _elem287; // required + ColumnStatisticsObj _elem287; // optional _elem287 = new ColumnStatisticsObj(); _elem287.read(iprot); struct.tableStats.add(_elem287); diff --git 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 index 4f051af..ed059c5 100644 --- 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 @@ -206,6 +206,8 @@ public List list_roles(String principal_name, PrincipalType principal_type) throws MetaException, org.apache.thrift.TException; + public GrantRevokeRoleResponse grant_revoke_role(GrantRevokeRoleRequest request) throws MetaException, org.apache.thrift.TException; + public GetPrincipalsInRoleResponse get_principals_in_role(GetPrincipalsInRoleRequest request) throws MetaException, org.apache.thrift.TException; public GetRoleGrantsForPrincipalResponse get_role_grants_for_principal(GetRoleGrantsForPrincipalRequest request) throws MetaException, org.apache.thrift.TException; @@ -424,6 +426,8 @@ public void list_roles(String principal_name, PrincipalType principal_type, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void grant_revoke_role(GrantRevokeRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; + public void get_principals_in_role(GetPrincipalsInRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; public void get_role_grants_for_principal(GetRoleGrantsForPrincipalRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException; @@ -3086,6 +3090,32 @@ public void send_list_roles(String principal_name, PrincipalType principal_type) throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "list_roles failed: unknown result"); } + public GrantRevokeRoleResponse grant_revoke_role(GrantRevokeRoleRequest request) throws MetaException, org.apache.thrift.TException + { + send_grant_revoke_role(request); + return recv_grant_revoke_role(); + } + + public void send_grant_revoke_role(GrantRevokeRoleRequest request) throws org.apache.thrift.TException + { + grant_revoke_role_args args = new grant_revoke_role_args(); + args.setRequest(request); + sendBase("grant_revoke_role", args); + } + + public GrantRevokeRoleResponse recv_grant_revoke_role() throws MetaException, org.apache.thrift.TException + { + grant_revoke_role_result result = new grant_revoke_role_result(); + receiveBase(result, "grant_revoke_role"); + if (result.isSetSuccess()) { + return result.success; + } + if (result.o1 != null) { + throw result.o1; + } + throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "grant_revoke_role failed: unknown result"); + } + public GetPrincipalsInRoleResponse get_principals_in_role(GetPrincipalsInRoleRequest request) throws MetaException, org.apache.thrift.TException { send_get_principals_in_role(request); @@ -6778,6 +6808,38 @@ public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apa } } + public void grant_revoke_role(GrantRevokeRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { + checkReady(); + grant_revoke_role_call method_call = new grant_revoke_role_call(request, resultHandler, this, ___protocolFactory, ___transport); + this.___currentMethod = method_call; + ___manager.call(method_call); + } + + public static class grant_revoke_role_call extends org.apache.thrift.async.TAsyncMethodCall { + private GrantRevokeRoleRequest request; + public grant_revoke_role_call(GrantRevokeRoleRequest request, 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.request = request; + } + + public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException { + prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("grant_revoke_role", org.apache.thrift.protocol.TMessageType.CALL, 0)); + grant_revoke_role_args args = new grant_revoke_role_args(); + args.setRequest(request); + args.write(prot); + prot.writeMessageEnd(); + } + + public GrantRevokeRoleResponse getResult() throws 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_grant_revoke_role(); + } + } + public void get_principals_in_role(GetPrincipalsInRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException { checkReady(); get_principals_in_role_call method_call = new get_principals_in_role_call(request, resultHandler, this, ___protocolFactory, ___transport); @@ -7623,6 +7685,7 @@ protected Processor(I iface, Map extends org.apache.thrift.ProcessFunction { + public grant_revoke_role() { + super("grant_revoke_role"); + } + + public grant_revoke_role_args getEmptyArgsInstance() { + return new grant_revoke_role_args(); + } + + protected boolean isOneway() { + return false; + } + + public grant_revoke_role_result getResult(I iface, grant_revoke_role_args args) throws org.apache.thrift.TException { + grant_revoke_role_result result = new grant_revoke_role_result(); + try { + result.success = iface.grant_revoke_role(args.request); + } catch (MetaException o1) { + result.o1 = o1; + } + return result; + } + } + public static class get_principals_in_role extends org.apache.thrift.ProcessFunction { public get_principals_in_role() { super("get_principals_in_role"); @@ -14202,7 +14289,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_databases_resul struct.success = new ArrayList(_list442.size); for (int _i443 = 0; _i443 < _list442.size; ++_i443) { - String _elem444; // required + String _elem444; // optional _elem444 = iprot.readString(); struct.success.add(_elem444); } @@ -14301,7 +14388,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_databases_result struct.success = new ArrayList(_list447.size); for (int _i448 = 0; _i448 < _list447.size; ++_i448) { - String _elem449; // required + String _elem449; // optional _elem449 = iprot.readString(); struct.success.add(_elem449); } @@ -14964,7 +15051,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_all_databases_r struct.success = new ArrayList(_list450.size); for (int _i451 = 0; _i451 < _list450.size; ++_i451) { - String _elem452; // required + String _elem452; // optional _elem452 = iprot.readString(); struct.success.add(_elem452); } @@ -15063,7 +15150,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_all_databases_re struct.success = new ArrayList(_list455.size); for (int _i456 = 0; _i456 < _list455.size; ++_i456) { - String _elem457; // required + String _elem457; // optional _elem457 = iprot.readString(); struct.success.add(_elem457); } @@ -20824,7 +20911,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_fields_result s struct.success = new ArrayList(_list468.size); for (int _i469 = 0; _i469 < _list468.size; ++_i469) { - FieldSchema _elem470; // required + FieldSchema _elem470; // optional _elem470 = new FieldSchema(); _elem470.read(iprot); struct.success.add(_elem470); @@ -20964,7 +21051,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_fields_result st struct.success = new ArrayList(_list473.size); for (int _i474 = 0; _i474 < _list473.size; ++_i474) { - FieldSchema _elem475; // required + FieldSchema _elem475; // optional _elem475 = new FieldSchema(); _elem475.read(iprot); struct.success.add(_elem475); @@ -22016,7 +22103,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_schema_result s struct.success = new ArrayList(_list476.size); for (int _i477 = 0; _i477 < _list476.size; ++_i477) { - FieldSchema _elem478; // required + FieldSchema _elem478; // optional _elem478 = new FieldSchema(); _elem478.read(iprot); struct.success.add(_elem478); @@ -22156,7 +22243,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_schema_result st struct.success = new ArrayList(_list481.size); for (int _i482 = 0; _i482 < _list481.size; ++_i482) { - FieldSchema _elem483; // required + FieldSchema _elem483; // optional _elem483 = new FieldSchema(); _elem483.read(iprot); struct.success.add(_elem483); @@ -27406,7 +27493,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_tables_result s struct.success = new ArrayList(_list484.size); for (int _i485 = 0; _i485 < _list484.size; ++_i485) { - String _elem486; // required + String _elem486; // optional _elem486 = iprot.readString(); struct.success.add(_elem486); } @@ -27505,7 +27592,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_tables_result st struct.success = new ArrayList(_list489.size); for (int _i490 = 0; _i490 < _list489.size; ++_i490) { - String _elem491; // required + String _elem491; // optional _elem491 = iprot.readString(); struct.success.add(_elem491); } @@ -28280,7 +28367,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_all_tables_resu struct.success = new ArrayList(_list492.size); for (int _i493 = 0; _i493 < _list492.size; ++_i493) { - String _elem494; // required + String _elem494; // optional _elem494 = iprot.readString(); struct.success.add(_elem494); } @@ -28379,7 +28466,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_all_tables_resul struct.success = new ArrayList(_list497.size); for (int _i498 = 0; _i498 < _list497.size; ++_i498) { - String _elem499; // required + String _elem499; // optional _elem499 = iprot.readString(); struct.success.add(_elem499); } @@ -29841,7 +29928,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_table_objects_b struct.tbl_names = new ArrayList(_list500.size); for (int _i501 = 0; _i501 < _list500.size; ++_i501) { - String _elem502; // required + String _elem502; // optional _elem502 = iprot.readString(); struct.tbl_names.add(_elem502); } @@ -29935,7 +30022,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_table_objects_by struct.tbl_names = new ArrayList(_list505.size); for (int _i506 = 0; _i506 < _list505.size; ++_i506) { - String _elem507; // required + String _elem507; // optional _elem507 = iprot.readString(); struct.tbl_names.add(_elem507); } @@ -30509,7 +30596,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_table_objects_b struct.success = new ArrayList
(_list508.size); for (int _i509 = 0; _i509 < _list508.size; ++_i509) { - Table _elem510; // required + Table _elem510; // optional _elem510 = new Table(); _elem510.read(iprot); struct.success.add(_elem510); @@ -30649,7 +30736,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_table_objects_by struct.success = new ArrayList
(_list513.size); for (int _i514 = 0; _i514 < _list513.size; ++_i514) { - Table _elem515; // required + Table _elem515; // optional _elem515 = new Table(); _elem515.read(iprot); struct.success.add(_elem515); @@ -31805,7 +31892,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_table_names_by_ struct.success = new ArrayList(_list516.size); for (int _i517 = 0; _i517 < _list516.size; ++_i517) { - String _elem518; // required + String _elem518; // optional _elem518 = iprot.readString(); struct.success.add(_elem518); } @@ -31944,7 +32031,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_table_names_by_f struct.success = new ArrayList(_list521.size); for (int _i522 = 0; _i522 < _list521.size; ++_i522) { - String _elem523; // required + String _elem523; // optional _elem523 = iprot.readString(); struct.success.add(_elem523); } @@ -36670,7 +36757,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, add_partitions_args struct.new_parts = new ArrayList(_list524.size); for (int _i525 = 0; _i525 < _list524.size; ++_i525) { - Partition _elem526; // required + Partition _elem526; // optional _elem526 = new Partition(); _elem526.read(iprot); struct.new_parts.add(_elem526); @@ -36750,7 +36837,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, add_partitions_args struct.new_parts = new ArrayList(_list529.size); for (int _i530 = 0; _i530 < _list529.size; ++_i530) { - Partition _elem531; // required + Partition _elem531; // optional _elem531 = new Partition(); _elem531.read(iprot); struct.new_parts.add(_elem531); @@ -37936,7 +38023,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, append_partition_ar struct.part_vals = new ArrayList(_list532.size); for (int _i533 = 0; _i533 < _list532.size; ++_i533) { - String _elem534; // required + String _elem534; // optional _elem534 = iprot.readString(); struct.part_vals.add(_elem534); } @@ -38045,7 +38132,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, append_partition_arg struct.part_vals = new ArrayList(_list537.size); for (int _i538 = 0; _i538 < _list537.size; ++_i538) { - String _elem539; // required + String _elem539; // optional _elem539 = iprot.readString(); struct.part_vals.add(_elem539); } @@ -40363,7 +40450,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, append_partition_wi struct.part_vals = new ArrayList(_list540.size); for (int _i541 = 0; _i541 < _list540.size; ++_i541) { - String _elem542; // required + String _elem542; // optional _elem542 = iprot.readString(); struct.part_vals.add(_elem542); } @@ -40492,7 +40579,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, append_partition_wit struct.part_vals = new ArrayList(_list545.size); for (int _i546 = 0; _i546 < _list545.size; ++_i546) { - String _elem547; // required + String _elem547; // optional _elem547 = iprot.readString(); struct.part_vals.add(_elem547); } @@ -44371,7 +44458,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, drop_partition_args struct.part_vals = new ArrayList(_list548.size); for (int _i549 = 0; _i549 < _list548.size; ++_i549) { - String _elem550; // required + String _elem550; // optional _elem550 = iprot.readString(); struct.part_vals.add(_elem550); } @@ -44497,7 +44584,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, drop_partition_args struct.part_vals = new ArrayList(_list553.size); for (int _i554 = 0; _i554 < _list553.size; ++_i554) { - String _elem555; // required + String _elem555; // optional _elem555 = iprot.readString(); struct.part_vals.add(_elem555); } @@ -45745,7 +45832,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, drop_partition_with struct.part_vals = new ArrayList(_list556.size); for (int _i557 = 0; _i557 < _list556.size; ++_i557) { - String _elem558; // required + String _elem558; // optional _elem558 = iprot.readString(); struct.part_vals.add(_elem558); } @@ -45891,7 +45978,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, drop_partition_with_ struct.part_vals = new ArrayList(_list561.size); for (int _i562 = 0; _i562 < _list561.size; ++_i562) { - String _elem563; // required + String _elem563; // optional _elem563 = iprot.readString(); struct.part_vals.add(_elem563); } @@ -50502,7 +50589,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partition_args struct.part_vals = new ArrayList(_list564.size); for (int _i565 = 0; _i565 < _list564.size; ++_i565) { - String _elem566; // required + String _elem566; // optional _elem566 = iprot.readString(); struct.part_vals.add(_elem566); } @@ -50611,7 +50698,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partition_args s struct.part_vals = new ArrayList(_list569.size); for (int _i570 = 0; _i570 < _list569.size; ++_i570) { - String _elem571; // required + String _elem571; // optional _elem571 = iprot.readString(); struct.part_vals.add(_elem571); } @@ -53501,7 +53588,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partition_with_ struct.part_vals = new ArrayList(_list582.size); for (int _i583 = 0; _i583 < _list582.size; ++_i583) { - String _elem584; // required + String _elem584; // optional _elem584 = iprot.readString(); struct.part_vals.add(_elem584); } @@ -53527,7 +53614,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partition_with_ struct.group_names = new ArrayList(_list585.size); for (int _i586 = 0; _i586 < _list585.size; ++_i586) { - String _elem587; // required + String _elem587; // optional _elem587 = iprot.readString(); struct.group_names.add(_elem587); } @@ -53671,7 +53758,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partition_with_a struct.part_vals = new ArrayList(_list592.size); for (int _i593 = 0; _i593 < _list592.size; ++_i593) { - String _elem594; // required + String _elem594; // optional _elem594 = iprot.readString(); struct.part_vals.add(_elem594); } @@ -53688,7 +53775,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partition_with_a struct.group_names = new ArrayList(_list595.size); for (int _i596 = 0; _i596 < _list595.size; ++_i596) { - String _elem597; // required + String _elem597; // optional _elem597 = iprot.readString(); struct.group_names.add(_elem597); } @@ -56463,7 +56550,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_resu struct.success = new ArrayList(_list598.size); for (int _i599 = 0; _i599 < _list598.size; ++_i599) { - Partition _elem600; // required + Partition _elem600; // optional _elem600 = new Partition(); _elem600.read(iprot); struct.success.add(_elem600); @@ -56583,7 +56670,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_resul struct.success = new ArrayList(_list603.size); for (int _i604 = 0; _i604 < _list603.size; ++_i604) { - Partition _elem605; // required + Partition _elem605; // optional _elem605 = new Partition(); _elem605.read(iprot); struct.success.add(_elem605); @@ -57283,7 +57370,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_with struct.group_names = new ArrayList(_list606.size); for (int _i607 = 0; _i607 < _list606.size; ++_i607) { - String _elem608; // required + String _elem608; // optional _elem608 = iprot.readString(); struct.group_names.add(_elem608); } @@ -57420,7 +57507,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_with_ struct.group_names = new ArrayList(_list611.size); for (int _i612 = 0; _i612 < _list611.size; ++_i612) { - String _elem613; // required + String _elem613; // optional _elem613 = iprot.readString(); struct.group_names.add(_elem613); } @@ -57913,7 +58000,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_with struct.success = new ArrayList(_list614.size); for (int _i615 = 0; _i615 < _list614.size; ++_i615) { - Partition _elem616; // required + Partition _elem616; // optional _elem616 = new Partition(); _elem616.read(iprot); struct.success.add(_elem616); @@ -58033,7 +58120,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_with_ struct.success = new ArrayList(_list619.size); for (int _i620 = 0; _i620 < _list619.size; ++_i620) { - Partition _elem621; // required + Partition _elem621; // optional _elem621 = new Partition(); _elem621.read(iprot); struct.success.add(_elem621); @@ -59022,7 +59109,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partition_names struct.success = new ArrayList(_list622.size); for (int _i623 = 0; _i623 < _list622.size; ++_i623) { - String _elem624; // required + String _elem624; // optional _elem624 = iprot.readString(); struct.success.add(_elem624); } @@ -59121,7 +59208,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partition_names_ struct.success = new ArrayList(_list627.size); for (int _i628 = 0; _i628 < _list627.size; ++_i628) { - String _elem629; // required + String _elem629; // optional _elem629 = iprot.readString(); struct.success.add(_elem629); } @@ -59718,7 +59805,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_ps_a struct.part_vals = new ArrayList(_list630.size); for (int _i631 = 0; _i631 < _list630.size; ++_i631) { - String _elem632; // required + String _elem632; // optional _elem632 = iprot.readString(); struct.part_vals.add(_elem632); } @@ -59844,7 +59931,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_ps_ar struct.part_vals = new ArrayList(_list635.size); for (int _i636 = 0; _i636 < _list635.size; ++_i636) { - String _elem637; // required + String _elem637; // optional _elem637 = iprot.readString(); struct.part_vals.add(_elem637); } @@ -60341,7 +60428,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_ps_r struct.success = new ArrayList(_list638.size); for (int _i639 = 0; _i639 < _list638.size; ++_i639) { - Partition _elem640; // required + Partition _elem640; // optional _elem640 = new Partition(); _elem640.read(iprot); struct.success.add(_elem640); @@ -60461,7 +60548,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_ps_re struct.success = new ArrayList(_list643.size); for (int _i644 = 0; _i644 < _list643.size; ++_i644) { - Partition _elem645; // required + Partition _elem645; // optional _elem645 = new Partition(); _elem645.read(iprot); struct.success.add(_elem645); @@ -61246,7 +61333,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_ps_w struct.part_vals = new ArrayList(_list646.size); for (int _i647 = 0; _i647 < _list646.size; ++_i647) { - String _elem648; // required + String _elem648; // optional _elem648 = iprot.readString(); struct.part_vals.add(_elem648); } @@ -61280,7 +61367,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_ps_w struct.group_names = new ArrayList(_list649.size); for (int _i650 = 0; _i650 < _list649.size; ++_i650) { - String _elem651; // required + String _elem651; // optional _elem651 = iprot.readString(); struct.group_names.add(_elem651); } @@ -61433,7 +61520,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_ps_wi struct.part_vals = new ArrayList(_list656.size); for (int _i657 = 0; _i657 < _list656.size; ++_i657) { - String _elem658; // required + String _elem658; // optional _elem658 = iprot.readString(); struct.part_vals.add(_elem658); } @@ -61454,7 +61541,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_ps_wi struct.group_names = new ArrayList(_list659.size); for (int _i660 = 0; _i660 < _list659.size; ++_i660) { - String _elem661; // required + String _elem661; // optional _elem661 = iprot.readString(); struct.group_names.add(_elem661); } @@ -61947,7 +62034,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_ps_w struct.success = new ArrayList(_list662.size); for (int _i663 = 0; _i663 < _list662.size; ++_i663) { - Partition _elem664; // required + Partition _elem664; // optional _elem664 = new Partition(); _elem664.read(iprot); struct.success.add(_elem664); @@ -62067,7 +62154,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_ps_wi struct.success = new ArrayList(_list667.size); for (int _i668 = 0; _i668 < _list667.size; ++_i668) { - Partition _elem669; // required + Partition _elem669; // optional _elem669 = new Partition(); _elem669.read(iprot); struct.success.add(_elem669); @@ -62670,7 +62757,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partition_names struct.part_vals = new ArrayList(_list670.size); for (int _i671 = 0; _i671 < _list670.size; ++_i671) { - String _elem672; // required + String _elem672; // optional _elem672 = iprot.readString(); struct.part_vals.add(_elem672); } @@ -62796,7 +62883,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partition_names_ struct.part_vals = new ArrayList(_list675.size); for (int _i676 = 0; _i676 < _list675.size; ++_i676) { - String _elem677; // required + String _elem677; // optional _elem677 = iprot.readString(); struct.part_vals.add(_elem677); } @@ -63293,7 +63380,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partition_names struct.success = new ArrayList(_list678.size); for (int _i679 = 0; _i679 < _list678.size; ++_i679) { - String _elem680; // required + String _elem680; // optional _elem680 = iprot.readString(); struct.success.add(_elem680); } @@ -63412,7 +63499,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partition_names_ struct.success = new ArrayList(_list683.size); for (int _i684 = 0; _i684 < _list683.size; ++_i684) { - String _elem685; // required + String _elem685; // optional _elem685 = iprot.readString(); struct.success.add(_elem685); } @@ -64585,7 +64672,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_by_f struct.success = new ArrayList(_list686.size); for (int _i687 = 0; _i687 < _list686.size; ++_i687) { - Partition _elem688; // required + Partition _elem688; // optional _elem688 = new Partition(); _elem688.read(iprot); struct.success.add(_elem688); @@ -64705,7 +64792,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_by_fi struct.success = new ArrayList(_list691.size); for (int _i692 = 0; _i692 < _list691.size; ++_i692) { - Partition _elem693; // required + Partition _elem693; // optional _elem693 = new Partition(); _elem693.read(iprot); struct.success.add(_elem693); @@ -66163,7 +66250,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_by_n struct.names = new ArrayList(_list694.size); for (int _i695 = 0; _i695 < _list694.size; ++_i695) { - String _elem696; // required + String _elem696; // optional _elem696 = iprot.readString(); struct.names.add(_elem696); } @@ -66272,7 +66359,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_by_na struct.names = new ArrayList(_list699.size); for (int _i700 = 0; _i700 < _list699.size; ++_i700) { - String _elem701; // required + String _elem701; // optional _elem701 = iprot.readString(); struct.names.add(_elem701); } @@ -66765,7 +66852,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_partitions_by_n struct.success = new ArrayList(_list702.size); for (int _i703 = 0; _i703 < _list702.size; ++_i703) { - Partition _elem704; // required + Partition _elem704; // optional _elem704 = new Partition(); _elem704.read(iprot); struct.success.add(_elem704); @@ -66885,7 +66972,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_partitions_by_na struct.success = new ArrayList(_list707.size); for (int _i708 = 0; _i708 < _list707.size; ++_i708) { - Partition _elem709; // required + Partition _elem709; // optional _elem709 = new Partition(); _elem709.read(iprot); struct.success.add(_elem709); @@ -68442,7 +68529,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, alter_partitions_ar struct.new_parts = new ArrayList(_list710.size); for (int _i711 = 0; _i711 < _list710.size; ++_i711) { - Partition _elem712; // required + Partition _elem712; // optional _elem712 = new Partition(); _elem712.read(iprot); struct.new_parts.add(_elem712); @@ -68552,7 +68639,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, alter_partitions_arg struct.new_parts = new ArrayList(_list715.size); for (int _i716 = 0; _i716 < _list715.size; ++_i716) { - Partition _elem717; // required + Partition _elem717; // optional _elem717 = new Partition(); _elem717.read(iprot); struct.new_parts.add(_elem717); @@ -70758,7 +70845,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, rename_partition_ar struct.part_vals = new ArrayList(_list718.size); for (int _i719 = 0; _i719 < _list718.size; ++_i719) { - String _elem720; // required + String _elem720; // optional _elem720 = iprot.readString(); struct.part_vals.add(_elem720); } @@ -70887,7 +70974,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, rename_partition_arg struct.part_vals = new ArrayList(_list723.size); for (int _i724 = 0; _i724 < _list723.size; ++_i724) { - String _elem725; // required + String _elem725; // optional _elem725 = iprot.readString(); struct.part_vals.add(_elem725); } @@ -71770,7 +71857,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, partition_name_has_ struct.part_vals = new ArrayList(_list726.size); for (int _i727 = 0; _i727 < _list726.size; ++_i727) { - String _elem728; // required + String _elem728; // optional _elem728 = iprot.readString(); struct.part_vals.add(_elem728); } @@ -71866,7 +71953,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, partition_name_has_v struct.part_vals = new ArrayList(_list731.size); for (int _i732 = 0; _i732 < _list731.size; ++_i732) { - String _elem733; // required + String _elem733; // optional _elem733 = iprot.readString(); struct.part_vals.add(_elem733); } @@ -74030,7 +74117,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, partition_name_to_v struct.success = new ArrayList(_list734.size); for (int _i735 = 0; _i735 < _list734.size; ++_i735) { - String _elem736; // required + String _elem736; // optional _elem736 = iprot.readString(); struct.success.add(_elem736); } @@ -74129,7 +74216,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, partition_name_to_va struct.success = new ArrayList(_list739.size); for (int _i740 = 0; _i740 < _list739.size; ++_i740) { - String _elem741; // required + String _elem741; // optional _elem741 = iprot.readString(); struct.success.add(_elem741); } @@ -84125,7 +84212,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_indexes_result struct.success = new ArrayList(_list772.size); for (int _i773 = 0; _i773 < _list772.size; ++_i773) { - Index _elem774; // required + Index _elem774; // optional _elem774 = new Index(); _elem774.read(iprot); struct.success.add(_elem774); @@ -84245,7 +84332,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_indexes_result s struct.success = new ArrayList(_list777.size); for (int _i778 = 0; _i778 < _list777.size; ++_i778) { - Index _elem779; // required + Index _elem779; // optional _elem779 = new Index(); _elem779.read(iprot); struct.success.add(_elem779); @@ -85234,7 +85321,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_index_names_res struct.success = new ArrayList(_list780.size); for (int _i781 = 0; _i781 < _list780.size; ++_i781) { - String _elem782; // required + String _elem782; // optional _elem782 = iprot.readString(); struct.success.add(_elem782); } @@ -85333,7 +85420,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_index_names_resu struct.success = new ArrayList(_list785.size); for (int _i786 = 0; _i786 < _list785.size; ++_i786) { - String _elem787; // required + String _elem787; // optional _elem787 = iprot.readString(); struct.success.add(_elem787); } @@ -98994,7 +99081,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_functions_resul struct.success = new ArrayList(_list788.size); for (int _i789 = 0; _i789 < _list788.size; ++_i789) { - String _elem790; // required + String _elem790; // optional _elem790 = iprot.readString(); struct.success.add(_elem790); } @@ -99093,7 +99180,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_functions_result struct.success = new ArrayList(_list793.size); for (int _i794 = 0; _i794 < _list793.size; ++_i794) { - String _elem795; // required + String _elem795; // optional _elem795 = iprot.readString(); struct.success.add(_elem795); } @@ -102442,7 +102529,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_role_names_resu struct.success = new ArrayList(_list796.size); for (int _i797 = 0; _i797 < _list796.size; ++_i797) { - String _elem798; // required + String _elem798; // optional _elem798 = iprot.readString(); struct.success.add(_elem798); } @@ -102541,7 +102628,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_role_names_resul struct.success = new ArrayList(_list801.size); for (int _i802 = 0; _i802 < _list801.size; ++_i802) { - String _elem803; // required + String _elem803; // optional _elem803 = iprot.readString(); struct.success.add(_elem803); } @@ -103214,26 +103301,1137 @@ public String toString() { sb.append(this.principal_type); } first = false; - if (!first) sb.append(", "); - sb.append("grantor:"); - if (this.grantor == null) { - sb.append("null"); - } else { - sb.append(this.grantor); - } - first = false; - if (!first) sb.append(", "); - sb.append("grantorType:"); - if (this.grantorType == null) { - sb.append("null"); - } else { - sb.append(this.grantorType); - } - first = false; - if (!first) sb.append(", "); - sb.append("grant_option:"); - sb.append(this.grant_option); - first = false; + if (!first) sb.append(", "); + sb.append("grantor:"); + if (this.grantor == null) { + sb.append("null"); + } else { + sb.append(this.grantor); + } + first = false; + if (!first) sb.append(", "); + sb.append("grantorType:"); + if (this.grantorType == null) { + sb.append("null"); + } else { + sb.append(this.grantorType); + } + first = false; + if (!first) sb.append(", "); + sb.append("grant_option:"); + sb.append(this.grant_option); + 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 grant_role_argsStandardSchemeFactory implements SchemeFactory { + public grant_role_argsStandardScheme getScheme() { + return new grant_role_argsStandardScheme(); + } + } + + private static class grant_role_argsStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_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: // ROLE_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.role_name = iprot.readString(); + struct.setRole_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 2: // PRINCIPAL_NAME + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.principal_name = iprot.readString(); + struct.setPrincipal_nameIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 3: // PRINCIPAL_TYPE + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.principal_type = PrincipalType.findByValue(iprot.readI32()); + struct.setPrincipal_typeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 4: // GRANTOR + if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { + struct.grantor = iprot.readString(); + struct.setGrantorIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 5: // GRANTOR_TYPE + if (schemeField.type == org.apache.thrift.protocol.TType.I32) { + struct.grantorType = PrincipalType.findByValue(iprot.readI32()); + struct.setGrantorTypeIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; + case 6: // GRANT_OPTION + if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) { + struct.grant_option = iprot.readBool(); + struct.setGrant_optionIsSet(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, grant_role_args struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.role_name != null) { + oprot.writeFieldBegin(ROLE_NAME_FIELD_DESC); + oprot.writeString(struct.role_name); + oprot.writeFieldEnd(); + } + if (struct.principal_name != null) { + oprot.writeFieldBegin(PRINCIPAL_NAME_FIELD_DESC); + oprot.writeString(struct.principal_name); + oprot.writeFieldEnd(); + } + if (struct.principal_type != null) { + oprot.writeFieldBegin(PRINCIPAL_TYPE_FIELD_DESC); + oprot.writeI32(struct.principal_type.getValue()); + oprot.writeFieldEnd(); + } + if (struct.grantor != null) { + oprot.writeFieldBegin(GRANTOR_FIELD_DESC); + oprot.writeString(struct.grantor); + oprot.writeFieldEnd(); + } + if (struct.grantorType != null) { + oprot.writeFieldBegin(GRANTOR_TYPE_FIELD_DESC); + oprot.writeI32(struct.grantorType.getValue()); + oprot.writeFieldEnd(); + } + oprot.writeFieldBegin(GRANT_OPTION_FIELD_DESC); + oprot.writeBool(struct.grant_option); + oprot.writeFieldEnd(); + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class grant_role_argsTupleSchemeFactory implements SchemeFactory { + public grant_role_argsTupleScheme getScheme() { + return new grant_role_argsTupleScheme(); + } + } + + private static class grant_role_argsTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_args struct) throws org.apache.thrift.TException { + TTupleProtocol oprot = (TTupleProtocol) prot; + BitSet optionals = new BitSet(); + if (struct.isSetRole_name()) { + optionals.set(0); + } + if (struct.isSetPrincipal_name()) { + optionals.set(1); + } + if (struct.isSetPrincipal_type()) { + optionals.set(2); + } + if (struct.isSetGrantor()) { + optionals.set(3); + } + if (struct.isSetGrantorType()) { + optionals.set(4); + } + if (struct.isSetGrant_option()) { + optionals.set(5); + } + oprot.writeBitSet(optionals, 6); + if (struct.isSetRole_name()) { + oprot.writeString(struct.role_name); + } + if (struct.isSetPrincipal_name()) { + oprot.writeString(struct.principal_name); + } + if (struct.isSetPrincipal_type()) { + oprot.writeI32(struct.principal_type.getValue()); + } + if (struct.isSetGrantor()) { + oprot.writeString(struct.grantor); + } + if (struct.isSetGrantorType()) { + oprot.writeI32(struct.grantorType.getValue()); + } + if (struct.isSetGrant_option()) { + oprot.writeBool(struct.grant_option); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_args struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(6); + if (incoming.get(0)) { + struct.role_name = iprot.readString(); + struct.setRole_nameIsSet(true); + } + if (incoming.get(1)) { + struct.principal_name = iprot.readString(); + struct.setPrincipal_nameIsSet(true); + } + if (incoming.get(2)) { + struct.principal_type = PrincipalType.findByValue(iprot.readI32()); + struct.setPrincipal_typeIsSet(true); + } + if (incoming.get(3)) { + struct.grantor = iprot.readString(); + struct.setGrantorIsSet(true); + } + if (incoming.get(4)) { + struct.grantorType = PrincipalType.findByValue(iprot.readI32()); + struct.setGrantorTypeIsSet(true); + } + if (incoming.get(5)) { + struct.grant_option = iprot.readBool(); + struct.setGrant_optionIsSet(true); + } + } + } + + } + + public static class grant_role_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("grant_role_result"); + + private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (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 Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new grant_role_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new grant_role_resultTupleSchemeFactory()); + } + + private boolean success; // required + private MetaException o1; // 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"); + + 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; + 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.BOOL))); + 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))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(grant_role_result.class, metaDataMap); + } + + public grant_role_result() { + } + + public grant_role_result( + boolean success, + MetaException o1) + { + this(); + this.success = success; + setSuccessIsSet(true); + this.o1 = o1; + } + + /** + * Performs a deep copy on other. + */ + public grant_role_result(grant_role_result other) { + __isset_bitfield = other.__isset_bitfield; + this.success = other.success; + if (other.isSetO1()) { + this.o1 = new MetaException(other.o1); + } + } + + public grant_role_result deepCopy() { + return new grant_role_result(this); + } + + @Override + public void clear() { + setSuccessIsSet(false); + this.success = false; + this.o1 = null; + } + + public boolean isSuccess() { + return this.success; + } + + public void setSuccess(boolean 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 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 void setFieldValue(_Fields field, Object value) { + switch (field) { + case SUCCESS: + if (value == null) { + unsetSuccess(); + } else { + setSuccess((Boolean)value); + } + break; + + case O1: + if (value == null) { + unsetO1(); + } else { + setO1((MetaException)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case SUCCESS: + return Boolean.valueOf(isSuccess()); + + case O1: + return getO1(); + + } + 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(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof grant_role_result) + return this.equals((grant_role_result)that); + return false; + } + + public boolean equals(grant_role_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; + } + + 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); + + return builder.toHashCode(); + } + + public int compareTo(grant_role_result other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + grant_role_result typedOther = (grant_role_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; + } + } + 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("grant_role_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; + 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 grant_role_resultStandardSchemeFactory implements SchemeFactory { + public grant_role_resultStandardScheme getScheme() { + return new grant_role_resultStandardScheme(); + } + } + + private static class grant_role_resultStandardScheme extends StandardScheme { + + public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_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.BOOL) { + struct.success = iprot.readBool(); + 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; + 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, grant_role_result struct) throws org.apache.thrift.TException { + struct.validate(); + + oprot.writeStructBegin(STRUCT_DESC); + if (struct.isSetSuccess()) { + oprot.writeFieldBegin(SUCCESS_FIELD_DESC); + oprot.writeBool(struct.success); + oprot.writeFieldEnd(); + } + if (struct.o1 != null) { + oprot.writeFieldBegin(O1_FIELD_DESC); + struct.o1.write(oprot); + oprot.writeFieldEnd(); + } + oprot.writeFieldStop(); + oprot.writeStructEnd(); + } + + } + + private static class grant_role_resultTupleSchemeFactory implements SchemeFactory { + public grant_role_resultTupleScheme getScheme() { + return new grant_role_resultTupleScheme(); + } + } + + private static class grant_role_resultTupleScheme extends TupleScheme { + + @Override + public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_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); + } + oprot.writeBitSet(optionals, 2); + if (struct.isSetSuccess()) { + oprot.writeBool(struct.success); + } + if (struct.isSetO1()) { + struct.o1.write(oprot); + } + } + + @Override + public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_result struct) throws org.apache.thrift.TException { + TTupleProtocol iprot = (TTupleProtocol) prot; + BitSet incoming = iprot.readBitSet(2); + if (incoming.get(0)) { + struct.success = iprot.readBool(); + struct.setSuccessIsSet(true); + } + if (incoming.get(1)) { + struct.o1 = new MetaException(); + struct.o1.read(iprot); + struct.setO1IsSet(true); + } + } + } + + } + + public static class revoke_role_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("revoke_role_args"); + + private static final org.apache.thrift.protocol.TField ROLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("role_name", org.apache.thrift.protocol.TType.STRING, (short)1); + private static final org.apache.thrift.protocol.TField PRINCIPAL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_name", org.apache.thrift.protocol.TType.STRING, (short)2); + private static final org.apache.thrift.protocol.TField PRINCIPAL_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_type", org.apache.thrift.protocol.TType.I32, (short)3); + + private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); + static { + schemes.put(StandardScheme.class, new revoke_role_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new revoke_role_argsTupleSchemeFactory()); + } + + private String role_name; // required + private String principal_name; // required + private PrincipalType principal_type; // 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 { + ROLE_NAME((short)1, "role_name"), + PRINCIPAL_NAME((short)2, "principal_name"), + /** + * + * @see PrincipalType + */ + PRINCIPAL_TYPE((short)3, "principal_type"); + + 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: // ROLE_NAME + return ROLE_NAME; + case 2: // PRINCIPAL_NAME + return PRINCIPAL_NAME; + case 3: // PRINCIPAL_TYPE + return PRINCIPAL_TYPE; + 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.ROLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("role_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.PRINCIPAL_NAME, new org.apache.thrift.meta_data.FieldMetaData("principal_name", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); + tmpMap.put(_Fields.PRINCIPAL_TYPE, new org.apache.thrift.meta_data.FieldMetaData("principal_type", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PrincipalType.class))); + metaDataMap = Collections.unmodifiableMap(tmpMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(revoke_role_args.class, metaDataMap); + } + + public revoke_role_args() { + } + + public revoke_role_args( + String role_name, + String principal_name, + PrincipalType principal_type) + { + this(); + this.role_name = role_name; + this.principal_name = principal_name; + this.principal_type = principal_type; + } + + /** + * Performs a deep copy on other. + */ + public revoke_role_args(revoke_role_args other) { + if (other.isSetRole_name()) { + this.role_name = other.role_name; + } + if (other.isSetPrincipal_name()) { + this.principal_name = other.principal_name; + } + if (other.isSetPrincipal_type()) { + this.principal_type = other.principal_type; + } + } + + public revoke_role_args deepCopy() { + return new revoke_role_args(this); + } + + @Override + public void clear() { + this.role_name = null; + this.principal_name = null; + this.principal_type = null; + } + + public String getRole_name() { + return this.role_name; + } + + public void setRole_name(String role_name) { + this.role_name = role_name; + } + + public void unsetRole_name() { + this.role_name = null; + } + + /** Returns true if field role_name is set (has been assigned a value) and false otherwise */ + public boolean isSetRole_name() { + return this.role_name != null; + } + + public void setRole_nameIsSet(boolean value) { + if (!value) { + this.role_name = null; + } + } + + public String getPrincipal_name() { + return this.principal_name; + } + + public void setPrincipal_name(String principal_name) { + this.principal_name = principal_name; + } + + public void unsetPrincipal_name() { + this.principal_name = null; + } + + /** Returns true if field principal_name is set (has been assigned a value) and false otherwise */ + public boolean isSetPrincipal_name() { + return this.principal_name != null; + } + + public void setPrincipal_nameIsSet(boolean value) { + if (!value) { + this.principal_name = null; + } + } + + /** + * + * @see PrincipalType + */ + public PrincipalType getPrincipal_type() { + return this.principal_type; + } + + /** + * + * @see PrincipalType + */ + public void setPrincipal_type(PrincipalType principal_type) { + this.principal_type = principal_type; + } + + public void unsetPrincipal_type() { + this.principal_type = null; + } + + /** Returns true if field principal_type is set (has been assigned a value) and false otherwise */ + public boolean isSetPrincipal_type() { + return this.principal_type != null; + } + + public void setPrincipal_typeIsSet(boolean value) { + if (!value) { + this.principal_type = null; + } + } + + public void setFieldValue(_Fields field, Object value) { + switch (field) { + case ROLE_NAME: + if (value == null) { + unsetRole_name(); + } else { + setRole_name((String)value); + } + break; + + case PRINCIPAL_NAME: + if (value == null) { + unsetPrincipal_name(); + } else { + setPrincipal_name((String)value); + } + break; + + case PRINCIPAL_TYPE: + if (value == null) { + unsetPrincipal_type(); + } else { + setPrincipal_type((PrincipalType)value); + } + break; + + } + } + + public Object getFieldValue(_Fields field) { + switch (field) { + case ROLE_NAME: + return getRole_name(); + + case PRINCIPAL_NAME: + return getPrincipal_name(); + + case PRINCIPAL_TYPE: + return getPrincipal_type(); + + } + 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 ROLE_NAME: + return isSetRole_name(); + case PRINCIPAL_NAME: + return isSetPrincipal_name(); + case PRINCIPAL_TYPE: + return isSetPrincipal_type(); + } + throw new IllegalStateException(); + } + + @Override + public boolean equals(Object that) { + if (that == null) + return false; + if (that instanceof revoke_role_args) + return this.equals((revoke_role_args)that); + return false; + } + + public boolean equals(revoke_role_args that) { + if (that == null) + return false; + + boolean this_present_role_name = true && this.isSetRole_name(); + boolean that_present_role_name = true && that.isSetRole_name(); + if (this_present_role_name || that_present_role_name) { + if (!(this_present_role_name && that_present_role_name)) + return false; + if (!this.role_name.equals(that.role_name)) + return false; + } + + boolean this_present_principal_name = true && this.isSetPrincipal_name(); + boolean that_present_principal_name = true && that.isSetPrincipal_name(); + if (this_present_principal_name || that_present_principal_name) { + if (!(this_present_principal_name && that_present_principal_name)) + return false; + if (!this.principal_name.equals(that.principal_name)) + return false; + } + + boolean this_present_principal_type = true && this.isSetPrincipal_type(); + boolean that_present_principal_type = true && that.isSetPrincipal_type(); + if (this_present_principal_type || that_present_principal_type) { + if (!(this_present_principal_type && that_present_principal_type)) + return false; + if (!this.principal_type.equals(that.principal_type)) + return false; + } + + return true; + } + + @Override + public int hashCode() { + HashCodeBuilder builder = new HashCodeBuilder(); + + boolean present_role_name = true && (isSetRole_name()); + builder.append(present_role_name); + if (present_role_name) + builder.append(role_name); + + boolean present_principal_name = true && (isSetPrincipal_name()); + builder.append(present_principal_name); + if (present_principal_name) + builder.append(principal_name); + + boolean present_principal_type = true && (isSetPrincipal_type()); + builder.append(present_principal_type); + if (present_principal_type) + builder.append(principal_type.getValue()); + + return builder.toHashCode(); + } + + public int compareTo(revoke_role_args other) { + if (!getClass().equals(other.getClass())) { + return getClass().getName().compareTo(other.getClass().getName()); + } + + int lastComparison = 0; + revoke_role_args typedOther = (revoke_role_args)other; + + lastComparison = Boolean.valueOf(isSetRole_name()).compareTo(typedOther.isSetRole_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetRole_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.role_name, typedOther.role_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetPrincipal_name()).compareTo(typedOther.isSetPrincipal_name()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPrincipal_name()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.principal_name, typedOther.principal_name); + if (lastComparison != 0) { + return lastComparison; + } + } + lastComparison = Boolean.valueOf(isSetPrincipal_type()).compareTo(typedOther.isSetPrincipal_type()); + if (lastComparison != 0) { + return lastComparison; + } + if (isSetPrincipal_type()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.principal_type, typedOther.principal_type); + 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("revoke_role_args("); + boolean first = true; + + sb.append("role_name:"); + if (this.role_name == null) { + sb.append("null"); + } else { + sb.append(this.role_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("principal_name:"); + if (this.principal_name == null) { + sb.append("null"); + } else { + sb.append(this.principal_name); + } + first = false; + if (!first) sb.append(", "); + sb.append("principal_type:"); + if (this.principal_type == null) { + sb.append("null"); + } else { + sb.append(this.principal_type); + } + first = false; sb.append(")"); return sb.toString(); } @@ -103253,23 +104451,21 @@ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOExcept 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 grant_role_argsStandardSchemeFactory implements SchemeFactory { - public grant_role_argsStandardScheme getScheme() { - return new grant_role_argsStandardScheme(); + private static class revoke_role_argsStandardSchemeFactory implements SchemeFactory { + public revoke_role_argsStandardScheme getScheme() { + return new revoke_role_argsStandardScheme(); } } - private static class grant_role_argsStandardScheme extends StandardScheme { + private static class revoke_role_argsStandardScheme extends StandardScheme { - public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_args struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_args struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; iprot.readStructBegin(); while (true) @@ -103303,30 +104499,6 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_args str org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; - case 4: // GRANTOR - if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { - struct.grantor = iprot.readString(); - struct.setGrantorIsSet(true); - } else { - org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); - } - break; - case 5: // GRANTOR_TYPE - if (schemeField.type == org.apache.thrift.protocol.TType.I32) { - struct.grantorType = PrincipalType.findByValue(iprot.readI32()); - struct.setGrantorTypeIsSet(true); - } else { - org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); - } - break; - case 6: // GRANT_OPTION - if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) { - struct.grant_option = iprot.readBool(); - struct.setGrant_optionIsSet(true); - } else { - org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); - } - break; default: org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } @@ -103336,7 +104508,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_args str struct.validate(); } - public void write(org.apache.thrift.protocol.TProtocol oprot, grant_role_args struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol oprot, revoke_role_args struct) throws org.apache.thrift.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); @@ -103355,35 +104527,22 @@ public void write(org.apache.thrift.protocol.TProtocol oprot, grant_role_args st oprot.writeI32(struct.principal_type.getValue()); oprot.writeFieldEnd(); } - if (struct.grantor != null) { - oprot.writeFieldBegin(GRANTOR_FIELD_DESC); - oprot.writeString(struct.grantor); - oprot.writeFieldEnd(); - } - if (struct.grantorType != null) { - oprot.writeFieldBegin(GRANTOR_TYPE_FIELD_DESC); - oprot.writeI32(struct.grantorType.getValue()); - oprot.writeFieldEnd(); - } - oprot.writeFieldBegin(GRANT_OPTION_FIELD_DESC); - oprot.writeBool(struct.grant_option); - oprot.writeFieldEnd(); oprot.writeFieldStop(); oprot.writeStructEnd(); } } - private static class grant_role_argsTupleSchemeFactory implements SchemeFactory { - public grant_role_argsTupleScheme getScheme() { - return new grant_role_argsTupleScheme(); + private static class revoke_role_argsTupleSchemeFactory implements SchemeFactory { + public revoke_role_argsTupleScheme getScheme() { + return new revoke_role_argsTupleScheme(); } } - private static class grant_role_argsTupleScheme extends TupleScheme { + private static class revoke_role_argsTupleScheme extends TupleScheme { @Override - public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_args struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_args struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); if (struct.isSetRole_name()) { @@ -103395,16 +104554,7 @@ public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_args str if (struct.isSetPrincipal_type()) { optionals.set(2); } - if (struct.isSetGrantor()) { - optionals.set(3); - } - if (struct.isSetGrantorType()) { - optionals.set(4); - } - if (struct.isSetGrant_option()) { - optionals.set(5); - } - oprot.writeBitSet(optionals, 6); + oprot.writeBitSet(optionals, 3); if (struct.isSetRole_name()) { oprot.writeString(struct.role_name); } @@ -103414,21 +104564,12 @@ public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_args str if (struct.isSetPrincipal_type()) { oprot.writeI32(struct.principal_type.getValue()); } - if (struct.isSetGrantor()) { - oprot.writeString(struct.grantor); - } - if (struct.isSetGrantorType()) { - oprot.writeI32(struct.grantorType.getValue()); - } - if (struct.isSetGrant_option()) { - oprot.writeBool(struct.grant_option); - } } @Override - public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_args struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_args struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(6); + BitSet incoming = iprot.readBitSet(3); if (incoming.get(0)) { struct.role_name = iprot.readString(); struct.setRole_nameIsSet(true); @@ -103441,33 +104582,21 @@ public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_args stru struct.principal_type = PrincipalType.findByValue(iprot.readI32()); struct.setPrincipal_typeIsSet(true); } - if (incoming.get(3)) { - struct.grantor = iprot.readString(); - struct.setGrantorIsSet(true); - } - if (incoming.get(4)) { - struct.grantorType = PrincipalType.findByValue(iprot.readI32()); - struct.setGrantorTypeIsSet(true); - } - if (incoming.get(5)) { - struct.grant_option = iprot.readBool(); - struct.setGrant_optionIsSet(true); - } } } } - public static class grant_role_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("grant_role_result"); + public static class revoke_role_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("revoke_role_result"); private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (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 Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); static { - schemes.put(StandardScheme.class, new grant_role_resultStandardSchemeFactory()); - schemes.put(TupleScheme.class, new grant_role_resultTupleSchemeFactory()); + schemes.put(StandardScheme.class, new revoke_role_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new revoke_role_resultTupleSchemeFactory()); } private boolean success; // required @@ -103545,13 +104674,13 @@ public String getFieldName() { 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))); metaDataMap = Collections.unmodifiableMap(tmpMap); - org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(grant_role_result.class, metaDataMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(revoke_role_result.class, metaDataMap); } - public grant_role_result() { + public revoke_role_result() { } - public grant_role_result( + public revoke_role_result( boolean success, MetaException o1) { @@ -103564,7 +104693,7 @@ public grant_role_result( /** * Performs a deep copy on other. */ - public grant_role_result(grant_role_result other) { + public revoke_role_result(revoke_role_result other) { __isset_bitfield = other.__isset_bitfield; this.success = other.success; if (other.isSetO1()) { @@ -103572,8 +104701,8 @@ public grant_role_result(grant_role_result other) { } } - public grant_role_result deepCopy() { - return new grant_role_result(this); + public revoke_role_result deepCopy() { + return new revoke_role_result(this); } @Override @@ -103680,12 +104809,12 @@ public boolean isSet(_Fields field) { public boolean equals(Object that) { if (that == null) return false; - if (that instanceof grant_role_result) - return this.equals((grant_role_result)that); + if (that instanceof revoke_role_result) + return this.equals((revoke_role_result)that); return false; } - public boolean equals(grant_role_result that) { + public boolean equals(revoke_role_result that) { if (that == null) return false; @@ -103727,13 +104856,13 @@ public int hashCode() { return builder.toHashCode(); } - public int compareTo(grant_role_result other) { + public int compareTo(revoke_role_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - grant_role_result typedOther = (grant_role_result)other; + revoke_role_result typedOther = (revoke_role_result)other; lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); if (lastComparison != 0) { @@ -103772,7 +104901,7 @@ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache. @Override public String toString() { - StringBuilder sb = new StringBuilder("grant_role_result("); + StringBuilder sb = new StringBuilder("revoke_role_result("); boolean first = true; sb.append("success:"); @@ -103813,15 +104942,15 @@ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException } } - private static class grant_role_resultStandardSchemeFactory implements SchemeFactory { - public grant_role_resultStandardScheme getScheme() { - return new grant_role_resultStandardScheme(); + private static class revoke_role_resultStandardSchemeFactory implements SchemeFactory { + public revoke_role_resultStandardScheme getScheme() { + return new revoke_role_resultStandardScheme(); } } - private static class grant_role_resultStandardScheme extends StandardScheme { + private static class revoke_role_resultStandardScheme extends StandardScheme { - public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_result struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_result struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; iprot.readStructBegin(); while (true) @@ -103857,7 +104986,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, grant_role_result s struct.validate(); } - public void write(org.apache.thrift.protocol.TProtocol oprot, grant_role_result struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol oprot, revoke_role_result struct) throws org.apache.thrift.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); @@ -103877,16 +105006,16 @@ public void write(org.apache.thrift.protocol.TProtocol oprot, grant_role_result } - private static class grant_role_resultTupleSchemeFactory implements SchemeFactory { - public grant_role_resultTupleScheme getScheme() { - return new grant_role_resultTupleScheme(); + private static class revoke_role_resultTupleSchemeFactory implements SchemeFactory { + public revoke_role_resultTupleScheme getScheme() { + return new revoke_role_resultTupleScheme(); } } - private static class grant_role_resultTupleScheme extends TupleScheme { + private static class revoke_role_resultTupleScheme extends TupleScheme { @Override - public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_result struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_result struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); if (struct.isSetSuccess()) { @@ -103905,7 +105034,7 @@ public void write(org.apache.thrift.protocol.TProtocol prot, grant_role_result s } @Override - public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_result struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_result struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { @@ -103922,32 +105051,29 @@ public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_result st } - public static class revoke_role_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("revoke_role_args"); + public static class list_roles_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("list_roles_args"); - private static final org.apache.thrift.protocol.TField ROLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("role_name", org.apache.thrift.protocol.TType.STRING, (short)1); - private static final org.apache.thrift.protocol.TField PRINCIPAL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_name", org.apache.thrift.protocol.TType.STRING, (short)2); - private static final org.apache.thrift.protocol.TField PRINCIPAL_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_type", org.apache.thrift.protocol.TType.I32, (short)3); + private static final org.apache.thrift.protocol.TField PRINCIPAL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_name", org.apache.thrift.protocol.TType.STRING, (short)1); + private static final org.apache.thrift.protocol.TField PRINCIPAL_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_type", org.apache.thrift.protocol.TType.I32, (short)2); private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); static { - schemes.put(StandardScheme.class, new revoke_role_argsStandardSchemeFactory()); - schemes.put(TupleScheme.class, new revoke_role_argsTupleSchemeFactory()); + schemes.put(StandardScheme.class, new list_roles_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new list_roles_argsTupleSchemeFactory()); } - private String role_name; // required private String principal_name; // required private PrincipalType principal_type; // 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 { - ROLE_NAME((short)1, "role_name"), - PRINCIPAL_NAME((short)2, "principal_name"), + PRINCIPAL_NAME((short)1, "principal_name"), /** * * @see PrincipalType */ - PRINCIPAL_TYPE((short)3, "principal_type"); + PRINCIPAL_TYPE((short)2, "principal_type"); private static final Map byName = new HashMap(); @@ -103962,11 +105088,9 @@ public void read(org.apache.thrift.protocol.TProtocol prot, grant_role_result st */ public static _Fields findByThriftId(int fieldId) { switch(fieldId) { - case 1: // ROLE_NAME - return ROLE_NAME; - case 2: // PRINCIPAL_NAME + case 1: // PRINCIPAL_NAME return PRINCIPAL_NAME; - case 3: // PRINCIPAL_TYPE + case 2: // PRINCIPAL_TYPE return PRINCIPAL_TYPE; default: return null; @@ -104011,26 +105135,22 @@ public String getFieldName() { 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.ROLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("role_name", org.apache.thrift.TFieldRequirementType.DEFAULT, - new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.PRINCIPAL_NAME, new org.apache.thrift.meta_data.FieldMetaData("principal_name", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); tmpMap.put(_Fields.PRINCIPAL_TYPE, new org.apache.thrift.meta_data.FieldMetaData("principal_type", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PrincipalType.class))); metaDataMap = Collections.unmodifiableMap(tmpMap); - org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(revoke_role_args.class, metaDataMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(list_roles_args.class, metaDataMap); } - public revoke_role_args() { + public list_roles_args() { } - public revoke_role_args( - String role_name, + public list_roles_args( String principal_name, PrincipalType principal_type) { this(); - this.role_name = role_name; this.principal_name = principal_name; this.principal_type = principal_type; } @@ -104038,10 +105158,7 @@ public revoke_role_args( /** * Performs a deep copy on other. */ - public revoke_role_args(revoke_role_args other) { - if (other.isSetRole_name()) { - this.role_name = other.role_name; - } + public list_roles_args(list_roles_args other) { if (other.isSetPrincipal_name()) { this.principal_name = other.principal_name; } @@ -104050,40 +105167,16 @@ public revoke_role_args(revoke_role_args other) { } } - public revoke_role_args deepCopy() { - return new revoke_role_args(this); + public list_roles_args deepCopy() { + return new list_roles_args(this); } @Override public void clear() { - this.role_name = null; this.principal_name = null; this.principal_type = null; } - public String getRole_name() { - return this.role_name; - } - - public void setRole_name(String role_name) { - this.role_name = role_name; - } - - public void unsetRole_name() { - this.role_name = null; - } - - /** Returns true if field role_name is set (has been assigned a value) and false otherwise */ - public boolean isSetRole_name() { - return this.role_name != null; - } - - public void setRole_nameIsSet(boolean value) { - if (!value) { - this.role_name = null; - } - } - public String getPrincipal_name() { return this.principal_name; } @@ -104140,14 +105233,6 @@ public void setPrincipal_typeIsSet(boolean value) { public void setFieldValue(_Fields field, Object value) { switch (field) { - case ROLE_NAME: - if (value == null) { - unsetRole_name(); - } else { - setRole_name((String)value); - } - break; - case PRINCIPAL_NAME: if (value == null) { unsetPrincipal_name(); @@ -104169,9 +105254,6 @@ public void setFieldValue(_Fields field, Object value) { public Object getFieldValue(_Fields field) { switch (field) { - case ROLE_NAME: - return getRole_name(); - case PRINCIPAL_NAME: return getPrincipal_name(); @@ -104189,8 +105271,6 @@ public boolean isSet(_Fields field) { } switch (field) { - case ROLE_NAME: - return isSetRole_name(); case PRINCIPAL_NAME: return isSetPrincipal_name(); case PRINCIPAL_TYPE: @@ -104203,24 +105283,15 @@ public boolean isSet(_Fields field) { public boolean equals(Object that) { if (that == null) return false; - if (that instanceof revoke_role_args) - return this.equals((revoke_role_args)that); + if (that instanceof list_roles_args) + return this.equals((list_roles_args)that); return false; } - public boolean equals(revoke_role_args that) { + public boolean equals(list_roles_args that) { if (that == null) return false; - boolean this_present_role_name = true && this.isSetRole_name(); - boolean that_present_role_name = true && that.isSetRole_name(); - if (this_present_role_name || that_present_role_name) { - if (!(this_present_role_name && that_present_role_name)) - return false; - if (!this.role_name.equals(that.role_name)) - return false; - } - boolean this_present_principal_name = true && this.isSetPrincipal_name(); boolean that_present_principal_name = true && that.isSetPrincipal_name(); if (this_present_principal_name || that_present_principal_name) { @@ -104246,11 +105317,6 @@ public boolean equals(revoke_role_args that) { public int hashCode() { HashCodeBuilder builder = new HashCodeBuilder(); - boolean present_role_name = true && (isSetRole_name()); - builder.append(present_role_name); - if (present_role_name) - builder.append(role_name); - boolean present_principal_name = true && (isSetPrincipal_name()); builder.append(present_principal_name); if (present_principal_name) @@ -104264,24 +105330,14 @@ public int hashCode() { return builder.toHashCode(); } - public int compareTo(revoke_role_args other) { + public int compareTo(list_roles_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - revoke_role_args typedOther = (revoke_role_args)other; + list_roles_args typedOther = (list_roles_args)other; - lastComparison = Boolean.valueOf(isSetRole_name()).compareTo(typedOther.isSetRole_name()); - if (lastComparison != 0) { - return lastComparison; - } - if (isSetRole_name()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.role_name, typedOther.role_name); - if (lastComparison != 0) { - return lastComparison; - } - } lastComparison = Boolean.valueOf(isSetPrincipal_name()).compareTo(typedOther.isSetPrincipal_name()); if (lastComparison != 0) { return lastComparison; @@ -104319,17 +105375,9 @@ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache. @Override public String toString() { - StringBuilder sb = new StringBuilder("revoke_role_args("); + StringBuilder sb = new StringBuilder("list_roles_args("); boolean first = true; - sb.append("role_name:"); - if (this.role_name == null) { - sb.append("null"); - } else { - sb.append(this.role_name); - } - first = false; - if (!first) sb.append(", "); sb.append("principal_name:"); if (this.principal_name == null) { sb.append("null"); @@ -104370,15 +105418,15 @@ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException } } - private static class revoke_role_argsStandardSchemeFactory implements SchemeFactory { - public revoke_role_argsStandardScheme getScheme() { - return new revoke_role_argsStandardScheme(); + private static class list_roles_argsStandardSchemeFactory implements SchemeFactory { + public list_roles_argsStandardScheme getScheme() { + return new list_roles_argsStandardScheme(); } } - private static class revoke_role_argsStandardScheme extends StandardScheme { + private static class list_roles_argsStandardScheme extends StandardScheme { - public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_args struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_args struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; iprot.readStructBegin(); while (true) @@ -104388,15 +105436,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_args st break; } switch (schemeField.id) { - case 1: // ROLE_NAME - if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { - struct.role_name = iprot.readString(); - struct.setRole_nameIsSet(true); - } else { - org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); - } - break; - case 2: // PRINCIPAL_NAME + case 1: // PRINCIPAL_NAME if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { struct.principal_name = iprot.readString(); struct.setPrincipal_nameIsSet(true); @@ -104404,7 +105444,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_args st org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } break; - case 3: // PRINCIPAL_TYPE + case 2: // PRINCIPAL_TYPE if (schemeField.type == org.apache.thrift.protocol.TType.I32) { struct.principal_type = PrincipalType.findByValue(iprot.readI32()); struct.setPrincipal_typeIsSet(true); @@ -104421,15 +105461,10 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_args st struct.validate(); } - public void write(org.apache.thrift.protocol.TProtocol oprot, revoke_role_args struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol oprot, list_roles_args struct) throws org.apache.thrift.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); - if (struct.role_name != null) { - oprot.writeFieldBegin(ROLE_NAME_FIELD_DESC); - oprot.writeString(struct.role_name); - oprot.writeFieldEnd(); - } if (struct.principal_name != null) { oprot.writeFieldBegin(PRINCIPAL_NAME_FIELD_DESC); oprot.writeString(struct.principal_name); @@ -104446,31 +105481,25 @@ public void write(org.apache.thrift.protocol.TProtocol oprot, revoke_role_args s } - private static class revoke_role_argsTupleSchemeFactory implements SchemeFactory { - public revoke_role_argsTupleScheme getScheme() { - return new revoke_role_argsTupleScheme(); + private static class list_roles_argsTupleSchemeFactory implements SchemeFactory { + public list_roles_argsTupleScheme getScheme() { + return new list_roles_argsTupleScheme(); } } - private static class revoke_role_argsTupleScheme extends TupleScheme { + private static class list_roles_argsTupleScheme extends TupleScheme { @Override - public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_args struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol prot, list_roles_args struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); - if (struct.isSetRole_name()) { - optionals.set(0); - } if (struct.isSetPrincipal_name()) { - optionals.set(1); + optionals.set(0); } if (struct.isSetPrincipal_type()) { - optionals.set(2); - } - oprot.writeBitSet(optionals, 3); - if (struct.isSetRole_name()) { - oprot.writeString(struct.role_name); + optionals.set(1); } + oprot.writeBitSet(optionals, 2); if (struct.isSetPrincipal_name()) { oprot.writeString(struct.principal_name); } @@ -104480,18 +105509,14 @@ public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_args st } @Override - public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_args struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol prot, list_roles_args struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(3); + BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { - struct.role_name = iprot.readString(); - struct.setRole_nameIsSet(true); - } - if (incoming.get(1)) { struct.principal_name = iprot.readString(); struct.setPrincipal_nameIsSet(true); } - if (incoming.get(2)) { + if (incoming.get(1)) { struct.principal_type = PrincipalType.findByValue(iprot.readI32()); struct.setPrincipal_typeIsSet(true); } @@ -104500,19 +105525,19 @@ public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_args str } - public static class revoke_role_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("revoke_role_result"); + public static class list_roles_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("list_roles_result"); - private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0); + 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 Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); static { - schemes.put(StandardScheme.class, new revoke_role_resultStandardSchemeFactory()); - schemes.put(TupleScheme.class, new revoke_role_resultTupleSchemeFactory()); + schemes.put(StandardScheme.class, new list_roles_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new list_roles_resultTupleSchemeFactory()); } - private boolean success; // required + private List success; // required private MetaException o1; // required /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ @@ -104577,74 +105602,92 @@ public String getFieldName() { } // 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.BOOL))); + 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, Role.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))); metaDataMap = Collections.unmodifiableMap(tmpMap); - org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(revoke_role_result.class, metaDataMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(list_roles_result.class, metaDataMap); } - public revoke_role_result() { + public list_roles_result() { } - public revoke_role_result( - boolean success, + public list_roles_result( + List success, MetaException o1) { this(); this.success = success; - setSuccessIsSet(true); this.o1 = o1; } /** * Performs a deep copy on other. */ - public revoke_role_result(revoke_role_result other) { - __isset_bitfield = other.__isset_bitfield; - this.success = other.success; + public list_roles_result(list_roles_result other) { + if (other.isSetSuccess()) { + List __this__success = new ArrayList(); + for (Role other_element : other.success) { + __this__success.add(new Role(other_element)); + } + this.success = __this__success; + } if (other.isSetO1()) { this.o1 = new MetaException(other.o1); } } - public revoke_role_result deepCopy() { - return new revoke_role_result(this); + public list_roles_result deepCopy() { + return new list_roles_result(this); } @Override public void clear() { - setSuccessIsSet(false); - this.success = false; + this.success = null; this.o1 = null; } - public boolean isSuccess() { + 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(Role elem) { + if (this.success == null) { + this.success = new ArrayList(); + } + this.success.add(elem); + } + + public List getSuccess() { return this.success; } - public void setSuccess(boolean success) { + public void setSuccess(List success) { this.success = success; - setSuccessIsSet(true); } public void unsetSuccess() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SUCCESS_ISSET_ID); + this.success = null; } /** 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); + return this.success != null; } public void setSuccessIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SUCCESS_ISSET_ID, value); + if (!value) { + this.success = null; + } } public MetaException getO1() { @@ -104676,7 +105719,7 @@ public void setFieldValue(_Fields field, Object value) { if (value == null) { unsetSuccess(); } else { - setSuccess((Boolean)value); + setSuccess((List)value); } break; @@ -104694,7 +105737,7 @@ public void setFieldValue(_Fields field, Object value) { public Object getFieldValue(_Fields field) { switch (field) { case SUCCESS: - return Boolean.valueOf(isSuccess()); + return getSuccess(); case O1: return getO1(); @@ -104722,21 +105765,21 @@ public boolean isSet(_Fields field) { public boolean equals(Object that) { if (that == null) return false; - if (that instanceof revoke_role_result) - return this.equals((revoke_role_result)that); + if (that instanceof list_roles_result) + return this.equals((list_roles_result)that); return false; } - public boolean equals(revoke_role_result that) { + public boolean equals(list_roles_result that) { if (that == null) return false; - boolean this_present_success = true; - boolean that_present_success = true; + 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 != that.success) + if (!this.success.equals(that.success)) return false; } @@ -104756,7 +105799,7 @@ public boolean equals(revoke_role_result that) { public int hashCode() { HashCodeBuilder builder = new HashCodeBuilder(); - boolean present_success = true; + boolean present_success = true && (isSetSuccess()); builder.append(present_success); if (present_success) builder.append(success); @@ -104769,13 +105812,13 @@ public int hashCode() { return builder.toHashCode(); } - public int compareTo(revoke_role_result other) { + public int compareTo(list_roles_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - revoke_role_result typedOther = (revoke_role_result)other; + list_roles_result typedOther = (list_roles_result)other; lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); if (lastComparison != 0) { @@ -104814,11 +105857,15 @@ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache. @Override public String toString() { - StringBuilder sb = new StringBuilder("revoke_role_result("); + StringBuilder sb = new StringBuilder("list_roles_result("); boolean first = true; sb.append("success:"); - sb.append(this.success); + if (this.success == null) { + sb.append("null"); + } else { + sb.append(this.success); + } first = false; if (!first) sb.append(", "); sb.append("o1:"); @@ -104847,23 +105894,21 @@ private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOExcept 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 revoke_role_resultStandardSchemeFactory implements SchemeFactory { - public revoke_role_resultStandardScheme getScheme() { - return new revoke_role_resultStandardScheme(); + private static class list_roles_resultStandardSchemeFactory implements SchemeFactory { + public list_roles_resultStandardScheme getScheme() { + return new list_roles_resultStandardScheme(); } } - private static class revoke_role_resultStandardScheme extends StandardScheme { + private static class list_roles_resultStandardScheme extends StandardScheme { - public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_result struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_result struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; iprot.readStructBegin(); while (true) @@ -104874,8 +105919,19 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_result } switch (schemeField.id) { case 0: // SUCCESS - if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) { - struct.success = iprot.readBool(); + 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) + { + Role _elem806; // optional + _elem806 = new Role(); + _elem806.read(iprot); + struct.success.add(_elem806); + } + iprot.readListEnd(); + } struct.setSuccessIsSet(true); } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); @@ -104899,13 +105955,20 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, revoke_role_result struct.validate(); } - public void write(org.apache.thrift.protocol.TProtocol oprot, revoke_role_result struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol oprot, list_roles_result struct) throws org.apache.thrift.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); - if (struct.isSetSuccess()) { + if (struct.success != null) { oprot.writeFieldBegin(SUCCESS_FIELD_DESC); - oprot.writeBool(struct.success); + { + oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.success.size())); + for (Role _iter807 : struct.success) + { + _iter807.write(oprot); + } + oprot.writeListEnd(); + } oprot.writeFieldEnd(); } if (struct.o1 != null) { @@ -104919,16 +105982,16 @@ public void write(org.apache.thrift.protocol.TProtocol oprot, revoke_role_result } - private static class revoke_role_resultTupleSchemeFactory implements SchemeFactory { - public revoke_role_resultTupleScheme getScheme() { - return new revoke_role_resultTupleScheme(); + private static class list_roles_resultTupleSchemeFactory implements SchemeFactory { + public list_roles_resultTupleScheme getScheme() { + return new list_roles_resultTupleScheme(); } } - private static class revoke_role_resultTupleScheme extends TupleScheme { + private static class list_roles_resultTupleScheme extends TupleScheme { @Override - public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_result struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol prot, list_roles_result struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); if (struct.isSetSuccess()) { @@ -104939,7 +106002,13 @@ public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_result } oprot.writeBitSet(optionals, 2); if (struct.isSetSuccess()) { - oprot.writeBool(struct.success); + { + oprot.writeI32(struct.success.size()); + for (Role _iter808 : struct.success) + { + _iter808.write(oprot); + } + } } if (struct.isSetO1()) { struct.o1.write(oprot); @@ -104947,11 +106016,21 @@ public void write(org.apache.thrift.protocol.TProtocol prot, revoke_role_result } @Override - public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_result struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol prot, list_roles_result struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; BitSet incoming = iprot.readBitSet(2); if (incoming.get(0)) { - struct.success = iprot.readBool(); + { + org.apache.thrift.protocol.TList _list809 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.success = new ArrayList(_list809.size); + for (int _i810 = 0; _i810 < _list809.size; ++_i810) + { + Role _elem811; // optional + _elem811 = new Role(); + _elem811.read(iprot); + struct.success.add(_elem811); + } + } struct.setSuccessIsSet(true); } if (incoming.get(1)) { @@ -104964,29 +106043,22 @@ public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_result s } - public static class list_roles_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("list_roles_args"); + public static class grant_revoke_role_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("grant_revoke_role_args"); - private static final org.apache.thrift.protocol.TField PRINCIPAL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_name", org.apache.thrift.protocol.TType.STRING, (short)1); - private static final org.apache.thrift.protocol.TField PRINCIPAL_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("principal_type", org.apache.thrift.protocol.TType.I32, (short)2); + private static final org.apache.thrift.protocol.TField REQUEST_FIELD_DESC = new org.apache.thrift.protocol.TField("request", org.apache.thrift.protocol.TType.STRUCT, (short)-1); private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); static { - schemes.put(StandardScheme.class, new list_roles_argsStandardSchemeFactory()); - schemes.put(TupleScheme.class, new list_roles_argsTupleSchemeFactory()); + schemes.put(StandardScheme.class, new grant_revoke_role_argsStandardSchemeFactory()); + schemes.put(TupleScheme.class, new grant_revoke_role_argsTupleSchemeFactory()); } - private String principal_name; // required - private PrincipalType principal_type; // required + private GrantRevokeRoleRequest request; // 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 { - PRINCIPAL_NAME((short)1, "principal_name"), - /** - * - * @see PrincipalType - */ - PRINCIPAL_TYPE((short)2, "principal_type"); + REQUEST((short)-1, "request"); private static final Map byName = new HashMap(); @@ -105001,10 +106073,8 @@ public void read(org.apache.thrift.protocol.TProtocol prot, revoke_role_result s */ public static _Fields findByThriftId(int fieldId) { switch(fieldId) { - case 1: // PRINCIPAL_NAME - return PRINCIPAL_NAME; - case 2: // PRINCIPAL_TYPE - return PRINCIPAL_TYPE; + case -1: // REQUEST + return REQUEST; default: return null; } @@ -105048,117 +106118,70 @@ public String getFieldName() { 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.PRINCIPAL_NAME, new org.apache.thrift.meta_data.FieldMetaData("principal_name", org.apache.thrift.TFieldRequirementType.DEFAULT, - new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))); - tmpMap.put(_Fields.PRINCIPAL_TYPE, new org.apache.thrift.meta_data.FieldMetaData("principal_type", org.apache.thrift.TFieldRequirementType.DEFAULT, - new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PrincipalType.class))); + tmpMap.put(_Fields.REQUEST, new org.apache.thrift.meta_data.FieldMetaData("request", org.apache.thrift.TFieldRequirementType.DEFAULT, + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, GrantRevokeRoleRequest.class))); metaDataMap = Collections.unmodifiableMap(tmpMap); - org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(list_roles_args.class, metaDataMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(grant_revoke_role_args.class, metaDataMap); } - public list_roles_args() { + public grant_revoke_role_args() { } - public list_roles_args( - String principal_name, - PrincipalType principal_type) + public grant_revoke_role_args( + GrantRevokeRoleRequest request) { this(); - this.principal_name = principal_name; - this.principal_type = principal_type; + this.request = request; } /** * Performs a deep copy on other. */ - public list_roles_args(list_roles_args other) { - if (other.isSetPrincipal_name()) { - this.principal_name = other.principal_name; - } - if (other.isSetPrincipal_type()) { - this.principal_type = other.principal_type; + public grant_revoke_role_args(grant_revoke_role_args other) { + if (other.isSetRequest()) { + this.request = new GrantRevokeRoleRequest(other.request); } } - public list_roles_args deepCopy() { - return new list_roles_args(this); + public grant_revoke_role_args deepCopy() { + return new grant_revoke_role_args(this); } @Override public void clear() { - this.principal_name = null; - this.principal_type = null; - } - - public String getPrincipal_name() { - return this.principal_name; - } - - public void setPrincipal_name(String principal_name) { - this.principal_name = principal_name; - } - - public void unsetPrincipal_name() { - this.principal_name = null; - } - - /** Returns true if field principal_name is set (has been assigned a value) and false otherwise */ - public boolean isSetPrincipal_name() { - return this.principal_name != null; - } - - public void setPrincipal_nameIsSet(boolean value) { - if (!value) { - this.principal_name = null; - } + this.request = null; } - /** - * - * @see PrincipalType - */ - public PrincipalType getPrincipal_type() { - return this.principal_type; + public GrantRevokeRoleRequest getRequest() { + return this.request; } - /** - * - * @see PrincipalType - */ - public void setPrincipal_type(PrincipalType principal_type) { - this.principal_type = principal_type; + public void setRequest(GrantRevokeRoleRequest request) { + this.request = request; } - public void unsetPrincipal_type() { - this.principal_type = null; + public void unsetRequest() { + this.request = null; } - /** Returns true if field principal_type is set (has been assigned a value) and false otherwise */ - public boolean isSetPrincipal_type() { - return this.principal_type != null; + /** Returns true if field request is set (has been assigned a value) and false otherwise */ + public boolean isSetRequest() { + return this.request != null; } - public void setPrincipal_typeIsSet(boolean value) { + public void setRequestIsSet(boolean value) { if (!value) { - this.principal_type = null; + this.request = null; } } public void setFieldValue(_Fields field, Object value) { switch (field) { - case PRINCIPAL_NAME: - if (value == null) { - unsetPrincipal_name(); - } else { - setPrincipal_name((String)value); - } - break; - - case PRINCIPAL_TYPE: + case REQUEST: if (value == null) { - unsetPrincipal_type(); + unsetRequest(); } else { - setPrincipal_type((PrincipalType)value); + setRequest((GrantRevokeRoleRequest)value); } break; @@ -105167,11 +106190,8 @@ public void setFieldValue(_Fields field, Object value) { public Object getFieldValue(_Fields field) { switch (field) { - case PRINCIPAL_NAME: - return getPrincipal_name(); - - case PRINCIPAL_TYPE: - return getPrincipal_type(); + case REQUEST: + return getRequest(); } throw new IllegalStateException(); @@ -105184,10 +106204,8 @@ public boolean isSet(_Fields field) { } switch (field) { - case PRINCIPAL_NAME: - return isSetPrincipal_name(); - case PRINCIPAL_TYPE: - return isSetPrincipal_type(); + case REQUEST: + return isSetRequest(); } throw new IllegalStateException(); } @@ -105196,30 +106214,21 @@ public boolean isSet(_Fields field) { public boolean equals(Object that) { if (that == null) return false; - if (that instanceof list_roles_args) - return this.equals((list_roles_args)that); + if (that instanceof grant_revoke_role_args) + return this.equals((grant_revoke_role_args)that); return false; } - public boolean equals(list_roles_args that) { + public boolean equals(grant_revoke_role_args that) { if (that == null) return false; - boolean this_present_principal_name = true && this.isSetPrincipal_name(); - boolean that_present_principal_name = true && that.isSetPrincipal_name(); - if (this_present_principal_name || that_present_principal_name) { - if (!(this_present_principal_name && that_present_principal_name)) - return false; - if (!this.principal_name.equals(that.principal_name)) - return false; - } - - boolean this_present_principal_type = true && this.isSetPrincipal_type(); - boolean that_present_principal_type = true && that.isSetPrincipal_type(); - if (this_present_principal_type || that_present_principal_type) { - if (!(this_present_principal_type && that_present_principal_type)) + boolean this_present_request = true && this.isSetRequest(); + boolean that_present_request = true && that.isSetRequest(); + if (this_present_request || that_present_request) { + if (!(this_present_request && that_present_request)) return false; - if (!this.principal_type.equals(that.principal_type)) + if (!this.request.equals(that.request)) return false; } @@ -105230,43 +106239,28 @@ public boolean equals(list_roles_args that) { public int hashCode() { HashCodeBuilder builder = new HashCodeBuilder(); - boolean present_principal_name = true && (isSetPrincipal_name()); - builder.append(present_principal_name); - if (present_principal_name) - builder.append(principal_name); - - boolean present_principal_type = true && (isSetPrincipal_type()); - builder.append(present_principal_type); - if (present_principal_type) - builder.append(principal_type.getValue()); + boolean present_request = true && (isSetRequest()); + builder.append(present_request); + if (present_request) + builder.append(request); return builder.toHashCode(); } - public int compareTo(list_roles_args other) { + public int compareTo(grant_revoke_role_args other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - list_roles_args typedOther = (list_roles_args)other; + grant_revoke_role_args typedOther = (grant_revoke_role_args)other; - lastComparison = Boolean.valueOf(isSetPrincipal_name()).compareTo(typedOther.isSetPrincipal_name()); - if (lastComparison != 0) { - return lastComparison; - } - if (isSetPrincipal_name()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.principal_name, typedOther.principal_name); - if (lastComparison != 0) { - return lastComparison; - } - } - lastComparison = Boolean.valueOf(isSetPrincipal_type()).compareTo(typedOther.isSetPrincipal_type()); + lastComparison = Boolean.valueOf(isSetRequest()).compareTo(typedOther.isSetRequest()); if (lastComparison != 0) { return lastComparison; } - if (isSetPrincipal_type()) { - lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.principal_type, typedOther.principal_type); + if (isSetRequest()) { + lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.request, typedOther.request); if (lastComparison != 0) { return lastComparison; } @@ -105288,22 +106282,14 @@ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache. @Override public String toString() { - StringBuilder sb = new StringBuilder("list_roles_args("); + StringBuilder sb = new StringBuilder("grant_revoke_role_args("); boolean first = true; - sb.append("principal_name:"); - if (this.principal_name == null) { - sb.append("null"); - } else { - sb.append(this.principal_name); - } - first = false; - if (!first) sb.append(", "); - sb.append("principal_type:"); - if (this.principal_type == null) { + sb.append("request:"); + if (this.request == null) { sb.append("null"); } else { - sb.append(this.principal_type); + sb.append(this.request); } first = false; sb.append(")"); @@ -105313,6 +106299,9 @@ public String toString() { public void validate() throws org.apache.thrift.TException { // check for required fields // check for sub-struct validity + if (request != null) { + request.validate(); + } } private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { @@ -105331,15 +106320,15 @@ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException } } - private static class list_roles_argsStandardSchemeFactory implements SchemeFactory { - public list_roles_argsStandardScheme getScheme() { - return new list_roles_argsStandardScheme(); + private static class grant_revoke_role_argsStandardSchemeFactory implements SchemeFactory { + public grant_revoke_role_argsStandardScheme getScheme() { + return new grant_revoke_role_argsStandardScheme(); } } - private static class list_roles_argsStandardScheme extends StandardScheme { + private static class grant_revoke_role_argsStandardScheme extends StandardScheme { - public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_args struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol iprot, grant_revoke_role_args struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; iprot.readStructBegin(); while (true) @@ -105349,18 +106338,11 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_args str break; } switch (schemeField.id) { - case 1: // PRINCIPAL_NAME - if (schemeField.type == org.apache.thrift.protocol.TType.STRING) { - struct.principal_name = iprot.readString(); - struct.setPrincipal_nameIsSet(true); - } else { - org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); - } - break; - case 2: // PRINCIPAL_TYPE - if (schemeField.type == org.apache.thrift.protocol.TType.I32) { - struct.principal_type = PrincipalType.findByValue(iprot.readI32()); - struct.setPrincipal_typeIsSet(true); + case -1: // REQUEST + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.request = new GrantRevokeRoleRequest(); + struct.request.read(iprot); + struct.setRequestIsSet(true); } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } @@ -105374,18 +106356,13 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_args str struct.validate(); } - public void write(org.apache.thrift.protocol.TProtocol oprot, list_roles_args struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol oprot, grant_revoke_role_args struct) throws org.apache.thrift.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); - if (struct.principal_name != null) { - oprot.writeFieldBegin(PRINCIPAL_NAME_FIELD_DESC); - oprot.writeString(struct.principal_name); - oprot.writeFieldEnd(); - } - if (struct.principal_type != null) { - oprot.writeFieldBegin(PRINCIPAL_TYPE_FIELD_DESC); - oprot.writeI32(struct.principal_type.getValue()); + if (struct.request != null) { + oprot.writeFieldBegin(REQUEST_FIELD_DESC); + struct.request.write(oprot); oprot.writeFieldEnd(); } oprot.writeFieldStop(); @@ -105394,63 +106371,54 @@ public void write(org.apache.thrift.protocol.TProtocol oprot, list_roles_args st } - private static class list_roles_argsTupleSchemeFactory implements SchemeFactory { - public list_roles_argsTupleScheme getScheme() { - return new list_roles_argsTupleScheme(); + private static class grant_revoke_role_argsTupleSchemeFactory implements SchemeFactory { + public grant_revoke_role_argsTupleScheme getScheme() { + return new grant_revoke_role_argsTupleScheme(); } } - private static class list_roles_argsTupleScheme extends TupleScheme { + private static class grant_revoke_role_argsTupleScheme extends TupleScheme { @Override - public void write(org.apache.thrift.protocol.TProtocol prot, list_roles_args struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol prot, grant_revoke_role_args struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); - if (struct.isSetPrincipal_name()) { + if (struct.isSetRequest()) { optionals.set(0); } - if (struct.isSetPrincipal_type()) { - optionals.set(1); - } - oprot.writeBitSet(optionals, 2); - if (struct.isSetPrincipal_name()) { - oprot.writeString(struct.principal_name); - } - if (struct.isSetPrincipal_type()) { - oprot.writeI32(struct.principal_type.getValue()); + oprot.writeBitSet(optionals, 1); + if (struct.isSetRequest()) { + struct.request.write(oprot); } } @Override - public void read(org.apache.thrift.protocol.TProtocol prot, list_roles_args struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol prot, grant_revoke_role_args struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(2); + BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { - struct.principal_name = iprot.readString(); - struct.setPrincipal_nameIsSet(true); - } - if (incoming.get(1)) { - struct.principal_type = PrincipalType.findByValue(iprot.readI32()); - struct.setPrincipal_typeIsSet(true); + struct.request = new GrantRevokeRoleRequest(); + struct.request.read(iprot); + struct.setRequestIsSet(true); } } } } - public static class list_roles_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("list_roles_result"); + public static class grant_revoke_role_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("grant_revoke_role_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 SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0); private static final org.apache.thrift.protocol.TField O1_FIELD_DESC = new org.apache.thrift.protocol.TField("o1", org.apache.thrift.protocol.TType.STRUCT, (short)1); private static final Map, SchemeFactory> schemes = new HashMap, SchemeFactory>(); static { - schemes.put(StandardScheme.class, new list_roles_resultStandardSchemeFactory()); - schemes.put(TupleScheme.class, new list_roles_resultTupleSchemeFactory()); + schemes.put(StandardScheme.class, new grant_revoke_role_resultStandardSchemeFactory()); + schemes.put(TupleScheme.class, new grant_revoke_role_resultTupleSchemeFactory()); } - private List success; // required + private GrantRevokeRoleResponse success; // required private MetaException o1; // required /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */ @@ -105519,19 +106487,18 @@ public String getFieldName() { 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, Role.class)))); + new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, GrantRevokeRoleResponse.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))); metaDataMap = Collections.unmodifiableMap(tmpMap); - org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(list_roles_result.class, metaDataMap); + org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(grant_revoke_role_result.class, metaDataMap); } - public list_roles_result() { + public grant_revoke_role_result() { } - public list_roles_result( - List success, + public grant_revoke_role_result( + GrantRevokeRoleResponse success, MetaException o1) { this(); @@ -105542,21 +106509,17 @@ public list_roles_result( /** * Performs a deep copy on other. */ - public list_roles_result(list_roles_result other) { + public grant_revoke_role_result(grant_revoke_role_result other) { if (other.isSetSuccess()) { - List __this__success = new ArrayList(); - for (Role other_element : other.success) { - __this__success.add(new Role(other_element)); - } - this.success = __this__success; + this.success = new GrantRevokeRoleResponse(other.success); } if (other.isSetO1()) { this.o1 = new MetaException(other.o1); } } - public list_roles_result deepCopy() { - return new list_roles_result(this); + public grant_revoke_role_result deepCopy() { + return new grant_revoke_role_result(this); } @Override @@ -105565,26 +106528,11 @@ public void clear() { this.o1 = 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(Role elem) { - if (this.success == null) { - this.success = new ArrayList(); - } - this.success.add(elem); - } - - public List getSuccess() { + public GrantRevokeRoleResponse getSuccess() { return this.success; } - public void setSuccess(List success) { + public void setSuccess(GrantRevokeRoleResponse success) { this.success = success; } @@ -105632,7 +106580,7 @@ public void setFieldValue(_Fields field, Object value) { if (value == null) { unsetSuccess(); } else { - setSuccess((List)value); + setSuccess((GrantRevokeRoleResponse)value); } break; @@ -105678,12 +106626,12 @@ public boolean isSet(_Fields field) { public boolean equals(Object that) { if (that == null) return false; - if (that instanceof list_roles_result) - return this.equals((list_roles_result)that); + if (that instanceof grant_revoke_role_result) + return this.equals((grant_revoke_role_result)that); return false; } - public boolean equals(list_roles_result that) { + public boolean equals(grant_revoke_role_result that) { if (that == null) return false; @@ -105725,13 +106673,13 @@ public int hashCode() { return builder.toHashCode(); } - public int compareTo(list_roles_result other) { + public int compareTo(grant_revoke_role_result other) { if (!getClass().equals(other.getClass())) { return getClass().getName().compareTo(other.getClass().getName()); } int lastComparison = 0; - list_roles_result typedOther = (list_roles_result)other; + grant_revoke_role_result typedOther = (grant_revoke_role_result)other; lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess()); if (lastComparison != 0) { @@ -105770,7 +106718,7 @@ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache. @Override public String toString() { - StringBuilder sb = new StringBuilder("list_roles_result("); + StringBuilder sb = new StringBuilder("grant_revoke_role_result("); boolean first = true; sb.append("success:"); @@ -105795,6 +106743,9 @@ public String toString() { public void validate() throws org.apache.thrift.TException { // check for required fields // check for sub-struct validity + if (success != null) { + success.validate(); + } } private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException { @@ -105813,15 +106764,15 @@ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException } } - private static class list_roles_resultStandardSchemeFactory implements SchemeFactory { - public list_roles_resultStandardScheme getScheme() { - return new list_roles_resultStandardScheme(); + private static class grant_revoke_role_resultStandardSchemeFactory implements SchemeFactory { + public grant_revoke_role_resultStandardScheme getScheme() { + return new grant_revoke_role_resultStandardScheme(); } } - private static class list_roles_resultStandardScheme extends StandardScheme { + private static class grant_revoke_role_resultStandardScheme extends StandardScheme { - public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_result struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol iprot, grant_revoke_role_result struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; iprot.readStructBegin(); while (true) @@ -105832,19 +106783,9 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_result s } switch (schemeField.id) { 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) - { - Role _elem806; // required - _elem806 = new Role(); - _elem806.read(iprot); - struct.success.add(_elem806); - } - iprot.readListEnd(); - } + if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) { + struct.success = new GrantRevokeRoleResponse(); + struct.success.read(iprot); struct.setSuccessIsSet(true); } else { org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); @@ -105868,20 +106809,13 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, list_roles_result s struct.validate(); } - public void write(org.apache.thrift.protocol.TProtocol oprot, list_roles_result struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol oprot, grant_revoke_role_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 (Role _iter807 : struct.success) - { - _iter807.write(oprot); - } - oprot.writeListEnd(); - } + struct.success.write(oprot); oprot.writeFieldEnd(); } if (struct.o1 != null) { @@ -105895,16 +106829,16 @@ public void write(org.apache.thrift.protocol.TProtocol oprot, list_roles_result } - private static class list_roles_resultTupleSchemeFactory implements SchemeFactory { - public list_roles_resultTupleScheme getScheme() { - return new list_roles_resultTupleScheme(); + private static class grant_revoke_role_resultTupleSchemeFactory implements SchemeFactory { + public grant_revoke_role_resultTupleScheme getScheme() { + return new grant_revoke_role_resultTupleScheme(); } } - private static class list_roles_resultTupleScheme extends TupleScheme { + private static class grant_revoke_role_resultTupleScheme extends TupleScheme { @Override - public void write(org.apache.thrift.protocol.TProtocol prot, list_roles_result struct) throws org.apache.thrift.TException { + public void write(org.apache.thrift.protocol.TProtocol prot, grant_revoke_role_result struct) throws org.apache.thrift.TException { TTupleProtocol oprot = (TTupleProtocol) prot; BitSet optionals = new BitSet(); if (struct.isSetSuccess()) { @@ -105915,13 +106849,7 @@ public void write(org.apache.thrift.protocol.TProtocol prot, list_roles_result s } oprot.writeBitSet(optionals, 2); if (struct.isSetSuccess()) { - { - oprot.writeI32(struct.success.size()); - for (Role _iter808 : struct.success) - { - _iter808.write(oprot); - } - } + struct.success.write(oprot); } if (struct.isSetO1()) { struct.o1.write(oprot); @@ -105929,21 +106857,12 @@ public void write(org.apache.thrift.protocol.TProtocol prot, list_roles_result s } @Override - public void read(org.apache.thrift.protocol.TProtocol prot, list_roles_result struct) throws org.apache.thrift.TException { + public void read(org.apache.thrift.protocol.TProtocol prot, grant_revoke_role_result struct) throws org.apache.thrift.TException { TTupleProtocol iprot = (TTupleProtocol) prot; 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.STRUCT, iprot.readI32()); - struct.success = new ArrayList(_list809.size); - for (int _i810 = 0; _i810 < _list809.size; ++_i810) - { - Role _elem811; // required - _elem811 = new Role(); - _elem811.read(iprot); - struct.success.add(_elem811); - } - } + struct.success = new GrantRevokeRoleResponse(); + struct.success.read(iprot); struct.setSuccessIsSet(true); } if (incoming.get(1)) { @@ -108121,7 +109040,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, get_privilege_set_a struct.group_names = new ArrayList(_list812.size); for (int _i813 = 0; _i813 < _list812.size; ++_i813) { - String _elem814; // required + String _elem814; // optional _elem814 = iprot.readString(); struct.group_names.add(_elem814); } @@ -108231,7 +109150,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, get_privilege_set_ar struct.group_names = new ArrayList(_list817.size); for (int _i818 = 0; _i818 < _list817.size; ++_i818) { - String _elem819; // required + String _elem819; // optional _elem819 = iprot.readString(); struct.group_names.add(_elem819); } @@ -109695,7 +110614,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, list_privileges_res struct.success = new ArrayList(_list820.size); for (int _i821 = 0; _i821 < _list820.size; ++_i821) { - HiveObjectPrivilege _elem822; // required + HiveObjectPrivilege _elem822; // optional _elem822 = new HiveObjectPrivilege(); _elem822.read(iprot); struct.success.add(_elem822); @@ -109795,7 +110714,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, list_privileges_resu struct.success = new ArrayList(_list825.size); for (int _i826 = 0; _i826 < _list825.size; ++_i826) { - HiveObjectPrivilege _elem827; // required + HiveObjectPrivilege _elem827; // optional _elem827 = new HiveObjectPrivilege(); _elem827.read(iprot); struct.success.add(_elem827); @@ -111875,7 +112794,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, set_ugi_args struct struct.group_names = new ArrayList(_list828.size); for (int _i829 = 0; _i829 < _list828.size; ++_i829) { - String _elem830; // required + String _elem830; // optional _elem830 = iprot.readString(); struct.group_names.add(_elem830); } @@ -111969,7 +112888,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, set_ugi_args struct) struct.group_names = new ArrayList(_list833.size); for (int _i834 = 0; _i834 < _list833.size; ++_i834) { - String _elem835; // required + String _elem835; // optional _elem835 = iprot.readString(); struct.group_names.add(_elem835); } @@ -112381,7 +113300,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, set_ugi_result stru struct.success = new ArrayList(_list836.size); for (int _i837 = 0; _i837 < _list836.size; ++_i837) { - String _elem838; // required + String _elem838; // optional _elem838 = iprot.readString(); struct.success.add(_elem838); } @@ -112480,7 +113399,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, set_ugi_result struc struct.success = new ArrayList(_list841.size); for (int _i842 = 0; _i842 < _list841.size; ++_i842) { - String _elem843; // required + String _elem843; // optional _elem843 = iprot.readString(); struct.success.add(_elem843); } diff --git metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Type.java metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Type.java index bb81e3c..1882b57 100644 --- metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Type.java +++ metastore/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Type.java @@ -618,7 +618,7 @@ public void read(org.apache.thrift.protocol.TProtocol iprot, Type struct) throws struct.fields = new ArrayList(_list0.size); for (int _i1 = 0; _i1 < _list0.size; ++_i1) { - FieldSchema _elem2; // required + FieldSchema _elem2; // optional _elem2 = new FieldSchema(); _elem2.read(iprot); struct.fields.add(_elem2); @@ -749,7 +749,7 @@ public void read(org.apache.thrift.protocol.TProtocol prot, Type struct) throws struct.fields = new ArrayList(_list5.size); for (int _i6 = 0; _i6 < _list5.size; ++_i6) { - FieldSchema _elem7; // required + FieldSchema _elem7; // optional _elem7 = new FieldSchema(); _elem7.read(iprot); struct.fields.add(_elem7); diff --git metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php index c79624f..23a4c1d 100644 --- metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php +++ metastore/src/gen/thrift/gen-php/metastore/ThriftHiveMetastore.php @@ -100,6 +100,7 @@ interface ThriftHiveMetastoreIf extends \FacebookServiceIf { public function grant_role($role_name, $principal_name, $principal_type, $grantor, $grantorType, $grant_option); public function revoke_role($role_name, $principal_name, $principal_type); public function list_roles($principal_name, $principal_type); + public function grant_revoke_role(\metastore\GrantRevokeRoleRequest $request); public function get_principals_in_role(\metastore\GetPrincipalsInRoleRequest $request); public function get_role_grants_for_principal(\metastore\GetRoleGrantsForPrincipalRequest $request); public function get_privilege_set(\metastore\HiveObjectRef $hiveObject, $user_name, $group_names); @@ -5076,6 +5077,60 @@ class ThriftHiveMetastoreClient extends \FacebookServiceClient implements \metas throw new \Exception("list_roles failed: unknown result"); } + public function grant_revoke_role(\metastore\GrantRevokeRoleRequest $request) + { + $this->send_grant_revoke_role($request); + return $this->recv_grant_revoke_role(); + } + + public function send_grant_revoke_role(\metastore\GrantRevokeRoleRequest $request) + { + $args = new \metastore\ThriftHiveMetastore_grant_revoke_role_args(); + $args->request = $request; + $bin_accel = ($this->output_ instanceof TProtocol::$TBINARYPROTOCOLACCELERATED) && function_exists('thrift_protocol_write_binary'); + if ($bin_accel) + { + thrift_protocol_write_binary($this->output_, 'grant_revoke_role', TMessageType::CALL, $args, $this->seqid_, $this->output_->isStrictWrite()); + } + else + { + $this->output_->writeMessageBegin('grant_revoke_role', TMessageType::CALL, $this->seqid_); + $args->write($this->output_); + $this->output_->writeMessageEnd(); + $this->output_->getTransport()->flush(); + } + } + + public function recv_grant_revoke_role() + { + $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_grant_revoke_role_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_grant_revoke_role_result(); + $result->read($this->input_); + $this->input_->readMessageEnd(); + } + if ($result->success !== null) { + return $result->success; + } + if ($result->o1 !== null) { + throw $result->o1; + } + throw new \Exception("grant_revoke_role failed: unknown result"); + } + public function get_principals_in_role(\metastore\GetPrincipalsInRoleRequest $request) { $this->send_get_principals_in_role($request); @@ -26511,6 +26566,182 @@ class ThriftHiveMetastore_list_roles_result { } +class ThriftHiveMetastore_grant_revoke_role_args { + static $_TSPEC; + + public $request = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + -1 => array( + 'var' => 'request', + 'type' => TType::STRUCT, + 'class' => '\metastore\GrantRevokeRoleRequest', + ), + ); + } + if (is_array($vals)) { + if (isset($vals['request'])) { + $this->request = $vals['request']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_grant_revoke_role_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::STRUCT) { + $this->request = new \metastore\GrantRevokeRoleRequest(); + $xfer += $this->request->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_grant_revoke_role_args'); + if ($this->request !== null) { + if (!is_object($this->request)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('request', TType::STRUCT, -1); + $xfer += $this->request->write($output); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class ThriftHiveMetastore_grant_revoke_role_result { + static $_TSPEC; + + public $success = null; + public $o1 = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 0 => array( + 'var' => 'success', + 'type' => TType::STRUCT, + 'class' => '\metastore\GrantRevokeRoleResponse', + ), + 1 => array( + 'var' => 'o1', + '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']; + } + } + } + + public function getName() { + return 'ThriftHiveMetastore_grant_revoke_role_result'; + } + + public function read($input) + { + $xfer = 0; + $fname = null; + $ftype = 0; + $fid = 0; + $xfer += $input->readStructBegin($fname); + while (true) + { + $xfer += $input->readFieldBegin($fname, $ftype, $fid); + if ($ftype == TType::STOP) { + break; + } + switch ($fid) + { + case 0: + if ($ftype == TType::STRUCT) { + $this->success = new \metastore\GrantRevokeRoleResponse(); + $xfer += $this->success->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + case 1: + if ($ftype == TType::STRUCT) { + $this->o1 = new \metastore\MetaException(); + $xfer += $this->o1->read($input); + } else { + $xfer += $input->skip($ftype); + } + break; + default: + $xfer += $input->skip($ftype); + break; + } + $xfer += $input->readFieldEnd(); + } + $xfer += $input->readStructEnd(); + return $xfer; + } + + public function write($output) { + $xfer = 0; + $xfer += $output->writeStructBegin('ThriftHiveMetastore_grant_revoke_role_result'); + if ($this->success !== null) { + if (!is_object($this->success)) { + throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA); + } + $xfer += $output->writeFieldBegin('success', TType::STRUCT, 0); + $xfer += $this->success->write($output); + $xfer += $output->writeFieldEnd(); + } + if ($this->o1 !== null) { + $xfer += $output->writeFieldBegin('o1', TType::STRUCT, 1); + $xfer += $this->o1->write($output); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class ThriftHiveMetastore_get_principals_in_role_args { static $_TSPEC; diff --git metastore/src/gen/thrift/gen-php/metastore/Types.php metastore/src/gen/thrift/gen-php/metastore/Types.php index 3db3ded..32d2cb7 100644 --- metastore/src/gen/thrift/gen-php/metastore/Types.php +++ metastore/src/gen/thrift/gen-php/metastore/Types.php @@ -104,6 +104,15 @@ final class CompactionType { ); } +final class GrantRevokeType { + const GRANT = 1; + const REVOKE = 2; + static public $__names = array( + 1 => 'GRANT', + 2 => 'REVOKE', + ); +} + final class FunctionType { const JAVA = 1; static public $__names = array( @@ -2015,6 +2024,270 @@ class GetPrincipalsInRoleResponse { } +class GrantRevokeRoleRequest { + static $_TSPEC; + + public $requestType = null; + public $roleName = null; + public $principalName = null; + public $principalType = null; + public $grantor = null; + public $grantorType = null; + public $grantOption = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'requestType', + 'type' => TType::I32, + ), + 2 => array( + 'var' => 'roleName', + 'type' => TType::STRING, + ), + 3 => array( + 'var' => 'principalName', + 'type' => TType::STRING, + ), + 4 => array( + 'var' => 'principalType', + 'type' => TType::I32, + ), + 5 => array( + 'var' => 'grantor', + 'type' => TType::STRING, + ), + 6 => array( + 'var' => 'grantorType', + 'type' => TType::I32, + ), + 7 => array( + 'var' => 'grantOption', + 'type' => TType::BOOL, + ), + ); + } + if (is_array($vals)) { + if (isset($vals['requestType'])) { + $this->requestType = $vals['requestType']; + } + if (isset($vals['roleName'])) { + $this->roleName = $vals['roleName']; + } + if (isset($vals['principalName'])) { + $this->principalName = $vals['principalName']; + } + if (isset($vals['principalType'])) { + $this->principalType = $vals['principalType']; + } + if (isset($vals['grantor'])) { + $this->grantor = $vals['grantor']; + } + if (isset($vals['grantorType'])) { + $this->grantorType = $vals['grantorType']; + } + if (isset($vals['grantOption'])) { + $this->grantOption = $vals['grantOption']; + } + } + } + + public function getName() { + return 'GrantRevokeRoleRequest'; + } + + 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::I32) { + $xfer += $input->readI32($this->requestType); + } else { + $xfer += $input->skip($ftype); + } + break; + case 2: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->roleName); + } else { + $xfer += $input->skip($ftype); + } + break; + case 3: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->principalName); + } else { + $xfer += $input->skip($ftype); + } + break; + case 4: + if ($ftype == TType::I32) { + $xfer += $input->readI32($this->principalType); + } else { + $xfer += $input->skip($ftype); + } + break; + case 5: + if ($ftype == TType::STRING) { + $xfer += $input->readString($this->grantor); + } else { + $xfer += $input->skip($ftype); + } + break; + case 6: + if ($ftype == TType::I32) { + $xfer += $input->readI32($this->grantorType); + } else { + $xfer += $input->skip($ftype); + } + break; + case 7: + if ($ftype == TType::BOOL) { + $xfer += $input->readBool($this->grantOption); + } 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('GrantRevokeRoleRequest'); + if ($this->requestType !== null) { + $xfer += $output->writeFieldBegin('requestType', TType::I32, 1); + $xfer += $output->writeI32($this->requestType); + $xfer += $output->writeFieldEnd(); + } + if ($this->roleName !== null) { + $xfer += $output->writeFieldBegin('roleName', TType::STRING, 2); + $xfer += $output->writeString($this->roleName); + $xfer += $output->writeFieldEnd(); + } + if ($this->principalName !== null) { + $xfer += $output->writeFieldBegin('principalName', TType::STRING, 3); + $xfer += $output->writeString($this->principalName); + $xfer += $output->writeFieldEnd(); + } + if ($this->principalType !== null) { + $xfer += $output->writeFieldBegin('principalType', TType::I32, 4); + $xfer += $output->writeI32($this->principalType); + $xfer += $output->writeFieldEnd(); + } + if ($this->grantor !== null) { + $xfer += $output->writeFieldBegin('grantor', TType::STRING, 5); + $xfer += $output->writeString($this->grantor); + $xfer += $output->writeFieldEnd(); + } + if ($this->grantorType !== null) { + $xfer += $output->writeFieldBegin('grantorType', TType::I32, 6); + $xfer += $output->writeI32($this->grantorType); + $xfer += $output->writeFieldEnd(); + } + if ($this->grantOption !== null) { + $xfer += $output->writeFieldBegin('grantOption', TType::BOOL, 7); + $xfer += $output->writeBool($this->grantOption); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + +class GrantRevokeRoleResponse { + static $_TSPEC; + + public $success = null; + + public function __construct($vals=null) { + if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( + 1 => array( + 'var' => 'success', + 'type' => TType::BOOL, + ), + ); + } + if (is_array($vals)) { + if (isset($vals['success'])) { + $this->success = $vals['success']; + } + } + } + + public function getName() { + return 'GrantRevokeRoleResponse'; + } + + 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::BOOL) { + $xfer += $input->readBool($this->success); + } 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('GrantRevokeRoleResponse'); + if ($this->success !== null) { + $xfer += $output->writeFieldBegin('success', TType::BOOL, 1); + $xfer += $output->writeBool($this->success); + $xfer += $output->writeFieldEnd(); + } + $xfer += $output->writeFieldStop(); + $xfer += $output->writeStructEnd(); + return $xfer; + } + +} + class Database { static $_TSPEC; diff --git metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote old mode 100644 new mode 100755 index fdedb57..c4eb7a9 --- metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote +++ metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore-remote @@ -107,6 +107,7 @@ if len(sys.argv) <= 1 or sys.argv[1] == '--help': print ' bool grant_role(string role_name, string principal_name, PrincipalType principal_type, string grantor, PrincipalType grantorType, bool grant_option)' print ' bool revoke_role(string role_name, string principal_name, PrincipalType principal_type)' print ' list_roles(string principal_name, PrincipalType principal_type)' + print ' GrantRevokeRoleResponse grant_revoke_role(GrantRevokeRoleRequest request)' print ' GetPrincipalsInRoleResponse get_principals_in_role(GetPrincipalsInRoleRequest request)' print ' GetRoleGrantsForPrincipalResponse get_role_grants_for_principal(GetRoleGrantsForPrincipalRequest request)' print ' PrincipalPrivilegeSet get_privilege_set(HiveObjectRef hiveObject, string user_name, group_names)' @@ -685,6 +686,12 @@ elif cmd == 'list_roles': sys.exit(1) pp.pprint(client.list_roles(args[0],eval(args[1]),)) +elif cmd == 'grant_revoke_role': + if len(args) != 1: + print 'grant_revoke_role requires 1 args' + sys.exit(1) + pp.pprint(client.grant_revoke_role(eval(args[0]),)) + elif cmd == 'get_principals_in_role': if len(args) != 1: print 'get_principals_in_role requires 1 args' diff --git metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py index 23679be..d764651 100644 --- metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py +++ metastore/src/gen/thrift/gen-py/hive_metastore/ThriftHiveMetastore.py @@ -738,6 +738,13 @@ def list_roles(self, principal_name, principal_type): """ pass + def grant_revoke_role(self, request): + """ + Parameters: + - request + """ + pass + def get_principals_in_role(self, request): """ Parameters: @@ -4039,6 +4046,38 @@ def recv_list_roles(self, ): raise result.o1 raise TApplicationException(TApplicationException.MISSING_RESULT, "list_roles failed: unknown result"); + def grant_revoke_role(self, request): + """ + Parameters: + - request + """ + self.send_grant_revoke_role(request) + return self.recv_grant_revoke_role() + + def send_grant_revoke_role(self, request): + self._oprot.writeMessageBegin('grant_revoke_role', TMessageType.CALL, self._seqid) + args = grant_revoke_role_args() + args.request = request + args.write(self._oprot) + self._oprot.writeMessageEnd() + self._oprot.trans.flush() + + def recv_grant_revoke_role(self, ): + (fname, mtype, rseqid) = self._iprot.readMessageBegin() + if mtype == TMessageType.EXCEPTION: + x = TApplicationException() + x.read(self._iprot) + self._iprot.readMessageEnd() + raise x + result = grant_revoke_role_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 + raise TApplicationException(TApplicationException.MISSING_RESULT, "grant_revoke_role failed: unknown result"); + def get_principals_in_role(self, request): """ Parameters: @@ -4853,6 +4892,7 @@ def __init__(self, handler): self._processMap["grant_role"] = Processor.process_grant_role self._processMap["revoke_role"] = Processor.process_revoke_role self._processMap["list_roles"] = Processor.process_list_roles + self._processMap["grant_revoke_role"] = Processor.process_grant_revoke_role self._processMap["get_principals_in_role"] = Processor.process_get_principals_in_role self._processMap["get_role_grants_for_principal"] = Processor.process_get_role_grants_for_principal self._processMap["get_privilege_set"] = Processor.process_get_privilege_set @@ -6288,6 +6328,20 @@ def process_list_roles(self, seqid, iprot, oprot): oprot.writeMessageEnd() oprot.trans.flush() + def process_grant_revoke_role(self, seqid, iprot, oprot): + args = grant_revoke_role_args() + args.read(iprot) + iprot.readMessageEnd() + result = grant_revoke_role_result() + try: + result.success = self._handler.grant_revoke_role(args.request) + except MetaException as o1: + result.o1 = o1 + oprot.writeMessageBegin("grant_revoke_role", TMessageType.REPLY, seqid) + result.write(oprot) + oprot.writeMessageEnd() + oprot.trans.flush() + def process_get_principals_in_role(self, seqid, iprot, oprot): args = get_principals_in_role_args() args.read(iprot) @@ -20963,6 +21017,136 @@ def __eq__(self, other): def __ne__(self, other): return not (self == other) +class grant_revoke_role_args: + """ + Attributes: + - request + """ + + thrift_spec = None + def __init__(self, request=None,): + self.request = request + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == -1: + if ftype == TType.STRUCT: + self.request = GrantRevokeRoleRequest() + self.request.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('grant_revoke_role_args') + if self.request is not None: + oprot.writeFieldBegin('request', TType.STRUCT, -1) + self.request.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 grant_revoke_role_result: + """ + Attributes: + - success + - o1 + """ + + thrift_spec = ( + (0, TType.STRUCT, 'success', (GrantRevokeRoleResponse, GrantRevokeRoleResponse.thrift_spec), None, ), # 0 + (1, TType.STRUCT, 'o1', (MetaException, MetaException.thrift_spec), None, ), # 1 + ) + + def __init__(self, success=None, o1=None,): + self.success = success + self.o1 = o1 + + def read(self, iprot): + if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None: + fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec)) + return + iprot.readStructBegin() + while True: + (fname, ftype, fid) = iprot.readFieldBegin() + if ftype == TType.STOP: + break + if fid == 0: + if ftype == TType.STRUCT: + self.success = GrantRevokeRoleResponse() + self.success.read(iprot) + else: + iprot.skip(ftype) + elif fid == 1: + if ftype == TType.STRUCT: + self.o1 = MetaException() + self.o1.read(iprot) + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('grant_revoke_role_result') + if self.success is not None: + oprot.writeFieldBegin('success', TType.STRUCT, 0) + self.success.write(oprot) + oprot.writeFieldEnd() + if self.o1 is not None: + oprot.writeFieldBegin('o1', TType.STRUCT, 1) + self.o1.write(oprot) + oprot.writeFieldEnd() + 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_principals_in_role_args: """ Attributes: diff --git metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py index 43a498a..5caf1ae 100644 --- metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py +++ metastore/src/gen/thrift/gen-py/hive_metastore/ttypes.py @@ -154,6 +154,20 @@ class CompactionType: "MAJOR": 2, } +class GrantRevokeType: + GRANT = 1 + REVOKE = 2 + + _VALUES_TO_NAMES = { + 1: "GRANT", + 2: "REVOKE", + } + + _NAMES_TO_VALUES = { + "GRANT": 1, + "REVOKE": 2, + } + class FunctionType: JAVA = 1 @@ -1472,6 +1486,200 @@ def __eq__(self, other): def __ne__(self, other): return not (self == other) +class GrantRevokeRoleRequest: + """ + Attributes: + - requestType + - roleName + - principalName + - principalType + - grantor + - grantorType + - grantOption + """ + + thrift_spec = ( + None, # 0 + (1, TType.I32, 'requestType', None, None, ), # 1 + (2, TType.STRING, 'roleName', None, None, ), # 2 + (3, TType.STRING, 'principalName', None, None, ), # 3 + (4, TType.I32, 'principalType', None, None, ), # 4 + (5, TType.STRING, 'grantor', None, None, ), # 5 + (6, TType.I32, 'grantorType', None, None, ), # 6 + (7, TType.BOOL, 'grantOption', None, None, ), # 7 + ) + + def __init__(self, requestType=None, roleName=None, principalName=None, principalType=None, grantor=None, grantorType=None, grantOption=None,): + self.requestType = requestType + self.roleName = roleName + self.principalName = principalName + self.principalType = principalType + self.grantor = grantor + self.grantorType = grantorType + self.grantOption = grantOption + + 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.I32: + self.requestType = iprot.readI32(); + else: + iprot.skip(ftype) + elif fid == 2: + if ftype == TType.STRING: + self.roleName = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 3: + if ftype == TType.STRING: + self.principalName = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 4: + if ftype == TType.I32: + self.principalType = iprot.readI32(); + else: + iprot.skip(ftype) + elif fid == 5: + if ftype == TType.STRING: + self.grantor = iprot.readString(); + else: + iprot.skip(ftype) + elif fid == 6: + if ftype == TType.I32: + self.grantorType = iprot.readI32(); + else: + iprot.skip(ftype) + elif fid == 7: + if ftype == TType.BOOL: + self.grantOption = iprot.readBool(); + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('GrantRevokeRoleRequest') + if self.requestType is not None: + oprot.writeFieldBegin('requestType', TType.I32, 1) + oprot.writeI32(self.requestType) + oprot.writeFieldEnd() + if self.roleName is not None: + oprot.writeFieldBegin('roleName', TType.STRING, 2) + oprot.writeString(self.roleName) + oprot.writeFieldEnd() + if self.principalName is not None: + oprot.writeFieldBegin('principalName', TType.STRING, 3) + oprot.writeString(self.principalName) + oprot.writeFieldEnd() + if self.principalType is not None: + oprot.writeFieldBegin('principalType', TType.I32, 4) + oprot.writeI32(self.principalType) + oprot.writeFieldEnd() + if self.grantor is not None: + oprot.writeFieldBegin('grantor', TType.STRING, 5) + oprot.writeString(self.grantor) + oprot.writeFieldEnd() + if self.grantorType is not None: + oprot.writeFieldBegin('grantorType', TType.I32, 6) + oprot.writeI32(self.grantorType) + oprot.writeFieldEnd() + if self.grantOption is not None: + oprot.writeFieldBegin('grantOption', TType.BOOL, 7) + oprot.writeBool(self.grantOption) + oprot.writeFieldEnd() + oprot.writeFieldStop() + oprot.writeStructEnd() + + def validate(self): + if self.requestType is None: + raise TProtocol.TProtocolException(message='Required field requestType is unset!') + 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 GrantRevokeRoleResponse: + """ + Attributes: + - success + """ + + thrift_spec = ( + None, # 0 + (1, TType.BOOL, 'success', None, None, ), # 1 + ) + + def __init__(self, success=None,): + self.success = success + + 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.BOOL: + self.success = iprot.readBool(); + else: + iprot.skip(ftype) + else: + iprot.skip(ftype) + iprot.readFieldEnd() + iprot.readStructEnd() + + def write(self, oprot): + if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None: + oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec))) + return + oprot.writeStructBegin('GrantRevokeRoleResponse') + if self.success is not None: + oprot.writeFieldBegin('success', TType.BOOL, 1) + oprot.writeBool(self.success) + 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 Database: """ Attributes: diff --git metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb index feb99db..2629132 100644 --- metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb +++ metastore/src/gen/thrift/gen-rb/hive_metastore_types.rb @@ -72,6 +72,13 @@ module CompactionType VALID_VALUES = Set.new([MINOR, MAJOR]).freeze end +module GrantRevokeType + GRANT = 1 + REVOKE = 2 + VALUE_MAP = {1 => "GRANT", 2 => "REVOKE"} + VALID_VALUES = Set.new([GRANT, REVOKE]).freeze +end + module FunctionType JAVA = 1 VALUE_MAP = {1 => "JAVA"} @@ -389,6 +396,60 @@ class GetPrincipalsInRoleResponse ::Thrift::Struct.generate_accessors self end +class GrantRevokeRoleRequest + include ::Thrift::Struct, ::Thrift::Struct_Union + REQUESTTYPE = 1 + ROLENAME = 2 + PRINCIPALNAME = 3 + PRINCIPALTYPE = 4 + GRANTOR = 5 + GRANTORTYPE = 6 + GRANTOPTION = 7 + + FIELDS = { + REQUESTTYPE => {:type => ::Thrift::Types::I32, :name => 'requestType', :enum_class => ::GrantRevokeType}, + ROLENAME => {:type => ::Thrift::Types::STRING, :name => 'roleName', :optional => true}, + PRINCIPALNAME => {:type => ::Thrift::Types::STRING, :name => 'principalName', :optional => true}, + PRINCIPALTYPE => {:type => ::Thrift::Types::I32, :name => 'principalType', :optional => true, :enum_class => ::PrincipalType}, + GRANTOR => {:type => ::Thrift::Types::STRING, :name => 'grantor', :optional => true}, + GRANTORTYPE => {:type => ::Thrift::Types::I32, :name => 'grantorType', :optional => true, :enum_class => ::PrincipalType}, + GRANTOPTION => {:type => ::Thrift::Types::BOOL, :name => 'grantOption', :optional => true} + } + + def struct_fields; FIELDS; end + + def validate + raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field requestType is unset!') unless @requestType + unless @requestType.nil? || ::GrantRevokeType::VALID_VALUES.include?(@requestType) + raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field requestType!') + end + unless @principalType.nil? || ::PrincipalType::VALID_VALUES.include?(@principalType) + raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field principalType!') + end + unless @grantorType.nil? || ::PrincipalType::VALID_VALUES.include?(@grantorType) + raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field grantorType!') + end + end + + ::Thrift::Struct.generate_accessors self +end + +class GrantRevokeRoleResponse + include ::Thrift::Struct, ::Thrift::Struct_Union + SUCCESS = 1 + + FIELDS = { + SUCCESS => {:type => ::Thrift::Types::BOOL, :name => 'success', :optional => true} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self +end + class Database include ::Thrift::Struct, ::Thrift::Struct_Union NAME = 1 diff --git metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb index 56c23e6..c469137 100644 --- metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb +++ metastore/src/gen/thrift/gen-rb/thrift_hive_metastore.rb @@ -1448,6 +1448,22 @@ module ThriftHiveMetastore raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'list_roles failed: unknown result') end + def grant_revoke_role(request) + send_grant_revoke_role(request) + return recv_grant_revoke_role() + end + + def send_grant_revoke_role(request) + send_message('grant_revoke_role', Grant_revoke_role_args, :request => request) + end + + def recv_grant_revoke_role() + result = receive_message(Grant_revoke_role_result) + return result.success unless result.success.nil? + raise result.o1 unless result.o1.nil? + raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'grant_revoke_role failed: unknown result') + end + def get_principals_in_role(request) send_get_principals_in_role(request) return recv_get_principals_in_role() @@ -2959,6 +2975,17 @@ module ThriftHiveMetastore write_result(result, oprot, 'list_roles', seqid) end + def process_grant_revoke_role(seqid, iprot, oprot) + args = read_args(iprot, Grant_revoke_role_args) + result = Grant_revoke_role_result.new() + begin + result.success = @handler.grant_revoke_role(args.request) + rescue ::MetaException => o1 + result.o1 = o1 + end + write_result(result, oprot, 'grant_revoke_role', seqid) + end + def process_get_principals_in_role(seqid, iprot, oprot) args = read_args(iprot, Get_principals_in_role_args) result = Get_principals_in_role_result.new() @@ -6530,6 +6557,40 @@ module ThriftHiveMetastore ::Thrift::Struct.generate_accessors self end + class Grant_revoke_role_args + include ::Thrift::Struct, ::Thrift::Struct_Union + REQUEST = -1 + + FIELDS = { + REQUEST => {:type => ::Thrift::Types::STRUCT, :name => 'request', :class => ::GrantRevokeRoleRequest} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + + class Grant_revoke_role_result + include ::Thrift::Struct, ::Thrift::Struct_Union + SUCCESS = 0 + O1 = 1 + + FIELDS = { + SUCCESS => {:type => ::Thrift::Types::STRUCT, :name => 'success', :class => ::GrantRevokeRoleResponse}, + O1 => {:type => ::Thrift::Types::STRUCT, :name => 'o1', :class => ::MetaException} + } + + def struct_fields; FIELDS; end + + def validate + end + + ::Thrift::Struct.generate_accessors self + end + class Get_principals_in_role_args include ::Thrift::Struct, ::Thrift::Struct_Union REQUEST = 1 diff --git metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java index acef599..bace609 100644 --- metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java +++ metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java @@ -85,6 +85,9 @@ import org.apache.hadoop.hive.metastore.api.GetPrincipalsInRoleResponse; import org.apache.hadoop.hive.metastore.api.GetRoleGrantsForPrincipalRequest; import org.apache.hadoop.hive.metastore.api.GetRoleGrantsForPrincipalResponse; +import org.apache.hadoop.hive.metastore.api.GrantRevokeRoleRequest; +import org.apache.hadoop.hive.metastore.api.GrantRevokeRoleResponse; +import org.apache.hadoop.hive.metastore.api.GrantRevokeType; import org.apache.hadoop.hive.metastore.api.HeartbeatRequest; import org.apache.hadoop.hive.metastore.api.HeartbeatTxnRangeRequest; import org.apache.hadoop.hive.metastore.api.HeartbeatTxnRangeResponse; @@ -4073,6 +4076,11 @@ public boolean grant_privileges(final PrivilegeBag privileges) throws MetaExcept @Override public boolean revoke_role(final String roleName, final String userName, final PrincipalType principalType) throws MetaException, TException { + return revoke_role(roleName, userName, principalType, false); + } + + private boolean revoke_role(final String roleName, final String userName, + final PrincipalType principalType, boolean grantOption) throws MetaException, TException { incrementCounter("remove_role_member"); firePreEvent(new PreAuthorizationCallEvent(this)); if (PUBLIC.equals(roleName)) { @@ -4082,7 +4090,7 @@ public boolean revoke_role(final String roleName, final String userName, try { RawStore ms = getMS(); Role mRole = ms.getRole(roleName); - ret = ms.revokeRole(mRole, userName, principalType); + ret = ms.revokeRole(mRole, userName, principalType, grantOption); } catch (MetaException e) { throw e; } catch (Exception e) { @@ -4091,6 +4099,34 @@ public boolean revoke_role(final String roleName, final String userName, return ret; } + public GrantRevokeRoleResponse grant_revoke_role(GrantRevokeRoleRequest request) + throws MetaException, org.apache.thrift.TException { + GrantRevokeRoleResponse response = new GrantRevokeRoleResponse(); + boolean grantOption = false; + if (request.isSetGrantOption()) { + grantOption = request.isGrantOption(); + } + switch (request.getRequestType()) { + case GRANT: { + boolean result = grant_role(request.getRoleName(), + request.getPrincipalName(), request.getPrincipalType(), + request.getGrantor(), request.getGrantorType(), grantOption); + response.setSuccess(result); + break; + } + case REVOKE: { + boolean result = revoke_role(request.getRoleName(), request.getPrincipalName(), + request.getPrincipalType(), grantOption); + response.setSuccess(result); + break; + } + default: + throw new MetaException("Unknown request type " + request.getRequestType()); + } + + return response; + } + @Override public boolean revoke_privileges(final PrivilegeBag privileges) throws MetaException, TException { diff --git metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java index 0595b09..32da869 100644 --- metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java +++ metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStoreClient.java @@ -73,6 +73,9 @@ import org.apache.hadoop.hive.metastore.api.GetPrincipalsInRoleResponse; import org.apache.hadoop.hive.metastore.api.GetRoleGrantsForPrincipalRequest; import org.apache.hadoop.hive.metastore.api.GetRoleGrantsForPrincipalResponse; +import org.apache.hadoop.hive.metastore.api.GrantRevokeRoleRequest; +import org.apache.hadoop.hive.metastore.api.GrantRevokeRoleResponse; +import org.apache.hadoop.hive.metastore.api.GrantRevokeType; import org.apache.hadoop.hive.metastore.api.HeartbeatRequest; import org.apache.hadoop.hive.metastore.api.HeartbeatTxnRangeRequest; import org.apache.hadoop.hive.metastore.api.HeartbeatTxnRangeResponse; @@ -1443,8 +1446,19 @@ public boolean dropIndex(String dbName, String tblName, String name, public boolean grant_role(String roleName, String userName, PrincipalType principalType, String grantor, PrincipalType grantorType, boolean grantOption) throws MetaException, TException { - return client.grant_role(roleName, userName, principalType, grantor, - grantorType, grantOption); + GrantRevokeRoleRequest req = new GrantRevokeRoleRequest(); + req.setRequestType(GrantRevokeType.GRANT); + req.setRoleName(roleName); + req.setPrincipalName(userName); + req.setPrincipalType(principalType); + req.setGrantor(grantor); + req.setGrantorType(grantorType); + req.setGrantOption(grantOption); + GrantRevokeRoleResponse res = client.grant_revoke_role(req); + if (!res.isSetSuccess()) { + throw new MetaException("GrantRevokeResponse missing success field"); + } + return res.isSuccess(); } @Override @@ -1489,8 +1503,18 @@ public boolean grant_privileges(PrivilegeBag privileges) @Override public boolean revoke_role(String roleName, String userName, - PrincipalType principalType) throws MetaException, TException { - return client.revoke_role(roleName, userName, principalType); + PrincipalType principalType, boolean grantOption) throws MetaException, TException { + GrantRevokeRoleRequest req = new GrantRevokeRoleRequest(); + req.setRequestType(GrantRevokeType.REVOKE); + req.setRoleName(roleName); + req.setPrincipalName(userName); + req.setPrincipalType(principalType); + req.setGrantOption(grantOption); + GrantRevokeRoleResponse res = client.grant_revoke_role(req); + if (!res.isSetSuccess()) { + throw new MetaException("GrantRevokeResponse missing success field"); + } + return res.isSuccess(); } @Override diff --git metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java index 0c2209b..9ce717a 100644 --- metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java +++ metastore/src/java/org/apache/hadoop/hive/metastore/IMetaStoreClient.java @@ -955,7 +955,7 @@ public boolean grant_role(String role_name, String user_name, * @throws TException */ public boolean revoke_role(String role_name, String user_name, - PrincipalType principalType) throws MetaException, TException; + PrincipalType principalType, boolean grantOption) throws MetaException, TException; /** * diff --git metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java index 911c997..5e2cad7 100644 --- metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java +++ metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java @@ -3083,13 +3083,25 @@ private void validateRole(String roleName) throws NoSuchObjectException { } @Override - public boolean revokeRole(Role role, String userName, PrincipalType principalType) throws MetaException, NoSuchObjectException { + public boolean revokeRole(Role role, String userName, PrincipalType principalType, + boolean grantOption) throws MetaException, NoSuchObjectException { boolean success = false; try { openTransaction(); MRoleMap roleMember = getMSecurityUserRoleMap(userName, principalType, role.getRoleName()); - pm.deletePersistent(roleMember); + if (grantOption) { + // Revoke with grant option - only remove the grant option but keep the role. + if (roleMember.getGrantOption()) { + roleMember.setGrantOption(false); + } else { + throw new MetaException("User " + userName + + " does not have grant option with role " + role.getRoleName()); + } + } else { + // No grant option in revoke, remove the whole role. + pm.deletePersistent(roleMember); + } success = commitTransaction(); } finally { if (!success) { diff --git metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java index e0de0e0..c9c3037 100644 --- metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java +++ metastore/src/java/org/apache/hadoop/hive/metastore/RawStore.java @@ -230,8 +230,8 @@ public abstract boolean grantRole(Role role, String userName, PrincipalType prin String grantor, PrincipalType grantorType, boolean grantOption) throws MetaException, NoSuchObjectException, InvalidObjectException; - public abstract boolean revokeRole(Role role, String userName, PrincipalType principalType) - throws MetaException, NoSuchObjectException; + public abstract boolean revokeRole(Role role, String userName, PrincipalType principalType, + boolean grantOption) throws MetaException, NoSuchObjectException; public abstract PrincipalPrivilegeSet getUserPrivilegeSet(String userName, List groupNames) throws InvalidObjectException, MetaException; diff --git metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java index 5c00aa1..5f9ab4d 100644 --- metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java +++ metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreControlledCommit.java @@ -349,9 +349,9 @@ public boolean grantRole(Role role, String userName, PrincipalType principalType } @Override - public boolean revokeRole(Role role, String userName, PrincipalType principalType) + public boolean revokeRole(Role role, String userName, PrincipalType principalType, boolean grantOption) throws MetaException, NoSuchObjectException { - return objectStore.revokeRole(role, userName, principalType); + return objectStore.revokeRole(role, userName, principalType, grantOption); } @Override diff --git metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java index 5025b83..b7997c0 100644 --- metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java +++ metastore/src/test/org/apache/hadoop/hive/metastore/DummyRawStoreForJdoConnection.java @@ -368,7 +368,7 @@ public boolean grantRole(Role role, String userName, PrincipalType principalType } @Override - public boolean revokeRole(Role role, String userName, PrincipalType principalType) + public boolean revokeRole(Role role, String userName, PrincipalType principalType, boolean grantOption) throws MetaException, NoSuchObjectException { return false; diff --git ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java index bbf89ef..69f44a8 100644 --- ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java +++ ql/src/java/org/apache/hadoop/hive/ql/exec/DDLTask.java @@ -542,7 +542,8 @@ private int grantOrRevokeRole(GrantRevokeRoleDDL grantOrRevokeRoleDDL) grantOrRevokeRoleDDL.getGrantor(), grantOrRevokeRoleDDL .getGrantorType(), grantOrRevokeRoleDDL.isGrantOption()); } else { - db.revokeRole(roleName, userName, principal.getType()); + db.revokeRole(roleName, userName, principal.getType(), + grantOrRevokeRoleDDL.isGrantOption()); } } } diff --git ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java index fea1e47..d41615e 100644 --- ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java +++ ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java @@ -2072,9 +2072,9 @@ public boolean grantRole(String roleName, String userName, } public boolean revokeRole(String roleName, String userName, - PrincipalType principalType) throws HiveException { + PrincipalType principalType, boolean grantOption) throws HiveException { try { - return getMSC().revoke_role(roleName, userName, principalType); + return getMSC().revoke_role(roleName, userName, principalType, grantOption); } catch (Exception e) { throw new HiveException(e); } diff --git ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g index 5ac6452..23c9d5c 100644 --- ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g +++ ql/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g @@ -267,6 +267,7 @@ TOK_ROLE; TOK_RESOURCE_ALL; TOK_GRANT_WITH_OPTION; TOK_GRANT_WITH_ADMIN_OPTION; +TOK_ADMIN_OPTION_FOR; TOK_PRIV_ALL; TOK_PRIV_ALTER_METADATA; TOK_PRIV_ALTER_DATA; @@ -1409,8 +1410,8 @@ grantRole revokeRole @init {pushMsg("revoke role", state);} @after {popMsg(state);} - : KW_REVOKE KW_ROLE? identifier (COMMA identifier)* KW_FROM principalSpecification withAdminOption? - -> ^(TOK_REVOKE_ROLE principalSpecification withAdminOption? identifier+) + : KW_REVOKE adminOptionFor? KW_ROLE? identifier (COMMA identifier)* KW_FROM principalSpecification + -> ^(TOK_REVOKE_ROLE principalSpecification adminOptionFor? identifier+) ; showRoleGrants @@ -1533,6 +1534,13 @@ withGrantOption -> ^(TOK_GRANT_WITH_OPTION) ; +adminOptionFor +@init {pushMsg("admin option for", state);} +@after {popMsg(state);} + : KW_ADMIN KW_OPTION KW_FOR + -> ^(TOK_ADMIN_OPTION_FOR) +; + withAdminOption @init {pushMsg("with admin option", state);} @after {popMsg(state);} diff --git ql/src/java/org/apache/hadoop/hive/ql/parse/authorization/HiveAuthorizationTaskFactoryImpl.java ql/src/java/org/apache/hadoop/hive/ql/parse/authorization/HiveAuthorizationTaskFactoryImpl.java index 419117c..c32d81e 100644 --- ql/src/java/org/apache/hadoop/hive/ql/parse/authorization/HiveAuthorizationTaskFactoryImpl.java +++ ql/src/java/org/apache/hadoop/hive/ql/parse/authorization/HiveAuthorizationTaskFactoryImpl.java @@ -212,7 +212,8 @@ public HiveAuthorizationTaskFactoryImpl(HiveConf conf, Hive db) { int rolesStartPos = 1; ASTNode wAdminOption = (ASTNode) ast.getChild(1); boolean isAdmin = false; - if(wAdminOption.getToken().getType() == HiveParser.TOK_GRANT_WITH_ADMIN_OPTION){ + if((isGrant && wAdminOption.getToken().getType() == HiveParser.TOK_GRANT_WITH_ADMIN_OPTION) || + (!isGrant && wAdminOption.getToken().getType() == HiveParser.TOK_ADMIN_OPTION_FOR)){ rolesStartPos = 2; //start reading role names from next postion isAdmin = true; } diff --git ql/src/java/org/apache/hadoop/hive/ql/security/authorization/plugin/sqlstd/SQLStdHiveAccessController.java ql/src/java/org/apache/hadoop/hive/ql/security/authorization/plugin/sqlstd/SQLStdHiveAccessController.java index 6ede03c..abb3d5a 100644 --- ql/src/java/org/apache/hadoop/hive/ql/security/authorization/plugin/sqlstd/SQLStdHiveAccessController.java +++ ql/src/java/org/apache/hadoop/hive/ql/security/authorization/plugin/sqlstd/SQLStdHiveAccessController.java @@ -308,11 +308,6 @@ public void grantRole(List hivePrincipals, List roleNames public void revokeRole(List hivePrincipals, List roleNames, boolean grantOption, HivePrincipal grantorPrinc) throws HiveAuthzPluginException, HiveAccessControlException { - if (grantOption) { - // removing grant privileges only is not supported in metastore api - throw new HiveAuthzPluginException("Revoking only the admin privileges on " - + "role is not currently supported"); - } if (!(isUserAdmin() || doesUserHasAdminOption(roleNames))) { throw new HiveAccessControlException("Current user : " + currentUserName+ " is not" + " allowed to revoke role. " + ADMIN_ONLY_MSG + " Otherwise, " + HAS_ADMIN_PRIV_MSG); @@ -322,7 +317,7 @@ public void revokeRole(List hivePrincipals, List roleName try { IMetaStoreClient mClient = metastoreClientFactory.getHiveMetastoreClient(); mClient.revoke_role(roleName, hivePrincipal.getName(), - AuthorizationUtils.getThriftPrincipalType(hivePrincipal.getType())); + AuthorizationUtils.getThriftPrincipalType(hivePrincipal.getType()), grantOption); } catch (Exception e) { String msg = "Error revoking roles for " + hivePrincipal.getName() + " to role " + roleName + ": " + e.getMessage(); diff --git ql/src/test/queries/clientnegative/authorization_role_grant2.q ql/src/test/queries/clientnegative/authorization_role_grant2.q new file mode 100644 index 0000000..7fdf157 --- /dev/null +++ ql/src/test/queries/clientnegative/authorization_role_grant2.q @@ -0,0 +1,30 @@ +set hive.users.in.admin.role=hive_admin_user; +set hive.security.authorization.manager=org.apache.hadoop.hive.ql.security.authorization.plugin.sqlstd.SQLStdHiveAuthorizerFactoryForTest; +set hive.security.authenticator.manager=org.apache.hadoop.hive.ql.security.SessionStateConfigUserAuthenticator; +set user.name=hive_admin_user; + +set role ADMIN; + +---------------------------------------- +-- grant role with admin option, then revoke admin option +-- once the admin option has been revoked, last grant should fail +---------------------------------------- + +create role src_role_wadmin; +grant src_role_wadmin to user user2 with admin option; +show role grant user user2; + + +set user.name=user2; +set role src_role_wadmin; +grant src_role_wadmin to user user3; +revoke src_role_wadmin from user user3; + +set user.name=hive_admin_user; +set role ADMIN; +revoke admin option for src_role_wadmin from user user2; +show role grant user user2; +set user.name=user2; +set role src_role_wadmin; +-- grant/revoke should now fail +grant src_role_wadmin to user user3; diff --git ql/src/test/queries/clientpositive/authorization_role_grant1.q ql/src/test/queries/clientpositive/authorization_role_grant1.q index 051bdee..c062ef2 100644 --- ql/src/test/queries/clientpositive/authorization_role_grant1.q +++ ql/src/test/queries/clientpositive/authorization_role_grant1.q @@ -26,6 +26,10 @@ create role src_role_wadmin; grant src_role_wadmin to user user2 with admin option; show role grant user user2; +-- revoke admin option +revoke admin option for src_role_wadmin from user user2; +show role grant user user2; + -- revoke role without role keyword revoke src_role_wadmin from user user2; show role grant user user2; diff --git ql/src/test/results/clientnegative/authorization_role_grant2.q.out ql/src/test/results/clientnegative/authorization_role_grant2.q.out new file mode 100644 index 0000000..6bff176 --- /dev/null +++ ql/src/test/results/clientnegative/authorization_role_grant2.q.out @@ -0,0 +1,62 @@ +PREHOOK: query: set role ADMIN +PREHOOK: type: SHOW_ROLES +POSTHOOK: query: set role ADMIN +POSTHOOK: type: SHOW_ROLES +PREHOOK: query: ---------------------------------------- +-- grant role with admin option, then revoke admin option +-- once the admin option has been revoked, last grant should fail +---------------------------------------- + +create role src_role_wadmin +PREHOOK: type: CREATEROLE +POSTHOOK: query: ---------------------------------------- +-- grant role with admin option, then revoke admin option +-- once the admin option has been revoked, last grant should fail +---------------------------------------- + +create role src_role_wadmin +POSTHOOK: type: CREATEROLE +PREHOOK: query: grant src_role_wadmin to user user2 with admin option +PREHOOK: type: GRANT_ROLE +POSTHOOK: query: grant src_role_wadmin to user user2 with admin option +POSTHOOK: type: GRANT_ROLE +PREHOOK: query: show role grant user user2 +PREHOOK: type: SHOW_ROLE_GRANT +POSTHOOK: query: show role grant user user2 +POSTHOOK: type: SHOW_ROLE_GRANT +public false -1 +src_role_wadmin true -1 hive_admin_user +PREHOOK: query: set role src_role_wadmin +PREHOOK: type: SHOW_ROLES +POSTHOOK: query: set role src_role_wadmin +POSTHOOK: type: SHOW_ROLES +PREHOOK: query: grant src_role_wadmin to user user3 +PREHOOK: type: GRANT_ROLE +POSTHOOK: query: grant src_role_wadmin to user user3 +POSTHOOK: type: GRANT_ROLE +PREHOOK: query: revoke src_role_wadmin from user user3 +PREHOOK: type: REVOKE_ROLE +POSTHOOK: query: revoke src_role_wadmin from user user3 +POSTHOOK: type: REVOKE_ROLE +PREHOOK: query: set role ADMIN +PREHOOK: type: SHOW_ROLES +POSTHOOK: query: set role ADMIN +POSTHOOK: type: SHOW_ROLES +PREHOOK: query: revoke admin option for src_role_wadmin from user user2 +PREHOOK: type: REVOKE_ROLE +POSTHOOK: query: revoke admin option for src_role_wadmin from user user2 +POSTHOOK: type: REVOKE_ROLE +PREHOOK: query: show role grant user user2 +PREHOOK: type: SHOW_ROLE_GRANT +POSTHOOK: query: show role grant user user2 +POSTHOOK: type: SHOW_ROLE_GRANT +public false -1 +src_role_wadmin false -1 hive_admin_user +PREHOOK: query: set role src_role_wadmin +PREHOOK: type: SHOW_ROLES +POSTHOOK: query: set role src_role_wadmin +POSTHOOK: type: SHOW_ROLES +PREHOOK: query: -- grant/revoke should now fail +grant src_role_wadmin to user user3 +PREHOOK: type: GRANT_ROLE +FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask. org.apache.hadoop.hive.ql.security.authorization.plugin.HiveAccessControlException: Current user : user2 is not allowed to grant role. User has to belong to ADMIN role and have it as current role, for this action. Otherwise, grantor need to have ADMIN privileges on role being granted and have it as a current role for this action. diff --git ql/src/test/results/clientpositive/authorization_role_grant1.q.out ql/src/test/results/clientpositive/authorization_role_grant1.q.out index cdbcb26..702eb68 100644 --- ql/src/test/results/clientpositive/authorization_role_grant1.q.out +++ ql/src/test/results/clientpositive/authorization_role_grant1.q.out @@ -71,6 +71,18 @@ POSTHOOK: query: show role grant user user2 POSTHOOK: type: SHOW_ROLE_GRANT public false -1 src_role_wadmin true -1 hive_admin_user +PREHOOK: query: -- revoke admin option +revoke admin option for src_role_wadmin from user user2 +PREHOOK: type: REVOKE_ROLE +POSTHOOK: query: -- revoke admin option +revoke admin option for src_role_wadmin from user user2 +POSTHOOK: type: REVOKE_ROLE +PREHOOK: query: show role grant user user2 +PREHOOK: type: SHOW_ROLE_GRANT +POSTHOOK: query: show role grant user user2 +POSTHOOK: type: SHOW_ROLE_GRANT +public false -1 +src_role_wadmin false -1 hive_admin_user PREHOOK: query: -- revoke role without role keyword revoke src_role_wadmin from user user2 PREHOOK: type: REVOKE_ROLE