You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by ai...@apache.org on 2016/01/13 16:03:10 UTC
[4/6] hive git commit: HIVE-12215: Exchange partition does not show
outputs field for post/pre execute hooks (Aihua Xu, reviewed by Xuefu Zhang)
http://git-wip-us.apache.org/repos/asf/hive/blob/96c9ee64/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h
----------------------------------------------------------------------
diff --git a/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h b/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h
index 520c6e3..ed3ce0f 100644
--- a/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h
+++ b/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore.h
@@ -60,6 +60,7 @@ class ThriftHiveMetastoreIf : virtual public ::facebook::fb303::FacebookService
virtual void drop_partitions_req(DropPartitionsResult& _return, const DropPartitionsRequest& req) = 0;
virtual void get_partition(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector<std::string> & part_vals) = 0;
virtual void exchange_partition(Partition& _return, const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) = 0;
+ virtual void exchange_partitions(std::vector<Partition> & _return, const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) = 0;
virtual void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector<std::string> & part_vals, const std::string& user_name, const std::vector<std::string> & group_names) = 0;
virtual void get_partition_by_name(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::string& part_name) = 0;
virtual void get_partitions(std::vector<Partition> & _return, const std::string& db_name, const std::string& tbl_name, const int16_t max_parts) = 0;
@@ -309,6 +310,9 @@ class ThriftHiveMetastoreNull : virtual public ThriftHiveMetastoreIf , virtual p
void exchange_partition(Partition& /* _return */, const std::map<std::string, std::string> & /* partitionSpecs */, const std::string& /* source_db */, const std::string& /* source_table_name */, const std::string& /* dest_db */, const std::string& /* dest_table_name */) {
return;
}
+ void exchange_partitions(std::vector<Partition> & /* _return */, const std::map<std::string, std::string> & /* partitionSpecs */, const std::string& /* source_db */, const std::string& /* source_table_name */, const std::string& /* dest_db */, const std::string& /* dest_table_name */) {
+ return;
+ }
void get_partition_with_auth(Partition& /* _return */, const std::string& /* db_name */, const std::string& /* tbl_name */, const std::vector<std::string> & /* part_vals */, const std::string& /* user_name */, const std::vector<std::string> & /* group_names */) {
return;
}
@@ -7006,6 +7010,186 @@ class ThriftHiveMetastore_exchange_partition_presult {
friend std::ostream& operator<<(std::ostream& out, const ThriftHiveMetastore_exchange_partition_presult& obj);
};
+typedef struct _ThriftHiveMetastore_exchange_partitions_args__isset {
+ _ThriftHiveMetastore_exchange_partitions_args__isset() : partitionSpecs(false), source_db(false), source_table_name(false), dest_db(false), dest_table_name(false) {}
+ bool partitionSpecs :1;
+ bool source_db :1;
+ bool source_table_name :1;
+ bool dest_db :1;
+ bool dest_table_name :1;
+} _ThriftHiveMetastore_exchange_partitions_args__isset;
+
+class ThriftHiveMetastore_exchange_partitions_args {
+ public:
+
+ static const char* ascii_fingerprint; // = "14D07CC2D6D857D1A741287E7A6EBF6E";
+ static const uint8_t binary_fingerprint[16]; // = {0x14,0xD0,0x7C,0xC2,0xD6,0xD8,0x57,0xD1,0xA7,0x41,0x28,0x7E,0x7A,0x6E,0xBF,0x6E};
+
+ ThriftHiveMetastore_exchange_partitions_args(const ThriftHiveMetastore_exchange_partitions_args&);
+ ThriftHiveMetastore_exchange_partitions_args& operator=(const ThriftHiveMetastore_exchange_partitions_args&);
+ ThriftHiveMetastore_exchange_partitions_args() : source_db(), source_table_name(), dest_db(), dest_table_name() {
+ }
+
+ virtual ~ThriftHiveMetastore_exchange_partitions_args() throw();
+ std::map<std::string, std::string> partitionSpecs;
+ std::string source_db;
+ std::string source_table_name;
+ std::string dest_db;
+ std::string dest_table_name;
+
+ _ThriftHiveMetastore_exchange_partitions_args__isset __isset;
+
+ void __set_partitionSpecs(const std::map<std::string, std::string> & val);
+
+ void __set_source_db(const std::string& val);
+
+ void __set_source_table_name(const std::string& val);
+
+ void __set_dest_db(const std::string& val);
+
+ void __set_dest_table_name(const std::string& val);
+
+ bool operator == (const ThriftHiveMetastore_exchange_partitions_args & rhs) const
+ {
+ if (!(partitionSpecs == rhs.partitionSpecs))
+ return false;
+ if (!(source_db == rhs.source_db))
+ return false;
+ if (!(source_table_name == rhs.source_table_name))
+ return false;
+ if (!(dest_db == rhs.dest_db))
+ return false;
+ if (!(dest_table_name == rhs.dest_table_name))
+ return false;
+ return true;
+ }
+ bool operator != (const ThriftHiveMetastore_exchange_partitions_args &rhs) const {
+ return !(*this == rhs);
+ }
+
+ bool operator < (const ThriftHiveMetastore_exchange_partitions_args & ) const;
+
+ uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
+ uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
+
+ friend std::ostream& operator<<(std::ostream& out, const ThriftHiveMetastore_exchange_partitions_args& obj);
+};
+
+
+class ThriftHiveMetastore_exchange_partitions_pargs {
+ public:
+
+ static const char* ascii_fingerprint; // = "14D07CC2D6D857D1A741287E7A6EBF6E";
+ static const uint8_t binary_fingerprint[16]; // = {0x14,0xD0,0x7C,0xC2,0xD6,0xD8,0x57,0xD1,0xA7,0x41,0x28,0x7E,0x7A,0x6E,0xBF,0x6E};
+
+
+ virtual ~ThriftHiveMetastore_exchange_partitions_pargs() throw();
+ const std::map<std::string, std::string> * partitionSpecs;
+ const std::string* source_db;
+ const std::string* source_table_name;
+ const std::string* dest_db;
+ const std::string* dest_table_name;
+
+ uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
+
+ friend std::ostream& operator<<(std::ostream& out, const ThriftHiveMetastore_exchange_partitions_pargs& obj);
+};
+
+typedef struct _ThriftHiveMetastore_exchange_partitions_result__isset {
+ _ThriftHiveMetastore_exchange_partitions_result__isset() : success(false), o1(false), o2(false), o3(false), o4(false) {}
+ bool success :1;
+ bool o1 :1;
+ bool o2 :1;
+ bool o3 :1;
+ bool o4 :1;
+} _ThriftHiveMetastore_exchange_partitions_result__isset;
+
+class ThriftHiveMetastore_exchange_partitions_result {
+ public:
+
+ static const char* ascii_fingerprint; // = "6DC72289D4DE76AA1484E58C41EBF31F";
+ static const uint8_t binary_fingerprint[16]; // = {0x6D,0xC7,0x22,0x89,0xD4,0xDE,0x76,0xAA,0x14,0x84,0xE5,0x8C,0x41,0xEB,0xF3,0x1F};
+
+ ThriftHiveMetastore_exchange_partitions_result(const ThriftHiveMetastore_exchange_partitions_result&);
+ ThriftHiveMetastore_exchange_partitions_result& operator=(const ThriftHiveMetastore_exchange_partitions_result&);
+ ThriftHiveMetastore_exchange_partitions_result() {
+ }
+
+ virtual ~ThriftHiveMetastore_exchange_partitions_result() throw();
+ std::vector<Partition> success;
+ MetaException o1;
+ NoSuchObjectException o2;
+ InvalidObjectException o3;
+ InvalidInputException o4;
+
+ _ThriftHiveMetastore_exchange_partitions_result__isset __isset;
+
+ void __set_success(const std::vector<Partition> & val);
+
+ void __set_o1(const MetaException& val);
+
+ void __set_o2(const NoSuchObjectException& val);
+
+ void __set_o3(const InvalidObjectException& val);
+
+ void __set_o4(const InvalidInputException& val);
+
+ bool operator == (const ThriftHiveMetastore_exchange_partitions_result & rhs) const
+ {
+ if (!(success == rhs.success))
+ return false;
+ if (!(o1 == rhs.o1))
+ return false;
+ if (!(o2 == rhs.o2))
+ return false;
+ if (!(o3 == rhs.o3))
+ return false;
+ if (!(o4 == rhs.o4))
+ return false;
+ return true;
+ }
+ bool operator != (const ThriftHiveMetastore_exchange_partitions_result &rhs) const {
+ return !(*this == rhs);
+ }
+
+ bool operator < (const ThriftHiveMetastore_exchange_partitions_result & ) const;
+
+ uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
+ uint32_t write(::apache::thrift::protocol::TProtocol* oprot) const;
+
+ friend std::ostream& operator<<(std::ostream& out, const ThriftHiveMetastore_exchange_partitions_result& obj);
+};
+
+typedef struct _ThriftHiveMetastore_exchange_partitions_presult__isset {
+ _ThriftHiveMetastore_exchange_partitions_presult__isset() : success(false), o1(false), o2(false), o3(false), o4(false) {}
+ bool success :1;
+ bool o1 :1;
+ bool o2 :1;
+ bool o3 :1;
+ bool o4 :1;
+} _ThriftHiveMetastore_exchange_partitions_presult__isset;
+
+class ThriftHiveMetastore_exchange_partitions_presult {
+ public:
+
+ static const char* ascii_fingerprint; // = "6DC72289D4DE76AA1484E58C41EBF31F";
+ static const uint8_t binary_fingerprint[16]; // = {0x6D,0xC7,0x22,0x89,0xD4,0xDE,0x76,0xAA,0x14,0x84,0xE5,0x8C,0x41,0xEB,0xF3,0x1F};
+
+
+ virtual ~ThriftHiveMetastore_exchange_partitions_presult() throw();
+ std::vector<Partition> * success;
+ MetaException o1;
+ NoSuchObjectException o2;
+ InvalidObjectException o3;
+ InvalidInputException o4;
+
+ _ThriftHiveMetastore_exchange_partitions_presult__isset __isset;
+
+ uint32_t read(::apache::thrift::protocol::TProtocol* iprot);
+
+ friend std::ostream& operator<<(std::ostream& out, const ThriftHiveMetastore_exchange_partitions_presult& obj);
+};
+
typedef struct _ThriftHiveMetastore_get_partition_with_auth_args__isset {
_ThriftHiveMetastore_get_partition_with_auth_args__isset() : db_name(false), tbl_name(false), part_vals(false), user_name(false), group_names(false) {}
bool db_name :1;
@@ -18336,6 +18520,9 @@ class ThriftHiveMetastoreClient : virtual public ThriftHiveMetastoreIf, public
void exchange_partition(Partition& _return, const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name);
void send_exchange_partition(const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name);
void recv_exchange_partition(Partition& _return);
+ void exchange_partitions(std::vector<Partition> & _return, const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name);
+ void send_exchange_partitions(const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name);
+ void recv_exchange_partitions(std::vector<Partition> & _return);
void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector<std::string> & part_vals, const std::string& user_name, const std::vector<std::string> & group_names);
void send_get_partition_with_auth(const std::string& db_name, const std::string& tbl_name, const std::vector<std::string> & part_vals, const std::string& user_name, const std::vector<std::string> & group_names);
void recv_get_partition_with_auth(Partition& _return);
@@ -18630,6 +18817,7 @@ class ThriftHiveMetastoreProcessor : public ::facebook::fb303::FacebookServiceP
void process_drop_partitions_req(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
void process_get_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
void process_exchange_partition(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
+ void process_exchange_partitions(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
void process_get_partition_with_auth(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
void process_get_partition_by_name(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
void process_get_partitions(int32_t seqid, ::apache::thrift::protocol::TProtocol* iprot, ::apache::thrift::protocol::TProtocol* oprot, void* callContext);
@@ -18758,6 +18946,7 @@ class ThriftHiveMetastoreProcessor : public ::facebook::fb303::FacebookServiceP
processMap_["drop_partitions_req"] = &ThriftHiveMetastoreProcessor::process_drop_partitions_req;
processMap_["get_partition"] = &ThriftHiveMetastoreProcessor::process_get_partition;
processMap_["exchange_partition"] = &ThriftHiveMetastoreProcessor::process_exchange_partition;
+ processMap_["exchange_partitions"] = &ThriftHiveMetastoreProcessor::process_exchange_partitions;
processMap_["get_partition_with_auth"] = &ThriftHiveMetastoreProcessor::process_get_partition_with_auth;
processMap_["get_partition_by_name"] = &ThriftHiveMetastoreProcessor::process_get_partition_by_name;
processMap_["get_partitions"] = &ThriftHiveMetastoreProcessor::process_get_partitions;
@@ -19292,6 +19481,16 @@ class ThriftHiveMetastoreMultiface : virtual public ThriftHiveMetastoreIf, publi
return;
}
+ void exchange_partitions(std::vector<Partition> & _return, const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) {
+ size_t sz = ifaces_.size();
+ size_t i = 0;
+ for (; i < (sz - 1); ++i) {
+ ifaces_[i]->exchange_partitions(_return, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name);
+ }
+ ifaces_[i]->exchange_partitions(_return, partitionSpecs, source_db, source_table_name, dest_db, dest_table_name);
+ return;
+ }
+
void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector<std::string> & part_vals, const std::string& user_name, const std::vector<std::string> & group_names) {
size_t sz = ifaces_.size();
size_t i = 0;
http://git-wip-us.apache.org/repos/asf/hive/blob/96c9ee64/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp
----------------------------------------------------------------------
diff --git a/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp b/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp
index 0afcf8c..32cf67c 100644
--- a/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp
+++ b/metastore/src/gen/thrift/gen-cpp/ThriftHiveMetastore_server.skeleton.cpp
@@ -242,6 +242,11 @@ class ThriftHiveMetastoreHandler : virtual public ThriftHiveMetastoreIf {
printf("exchange_partition\n");
}
+ void exchange_partitions(std::vector<Partition> & _return, const std::map<std::string, std::string> & partitionSpecs, const std::string& source_db, const std::string& source_table_name, const std::string& dest_db, const std::string& dest_table_name) {
+ // Your implementation goes here
+ printf("exchange_partitions\n");
+ }
+
void get_partition_with_auth(Partition& _return, const std::string& db_name, const std::string& tbl_name, const std::vector<std::string> & part_vals, const std::string& user_name, const std::vector<std::string> & group_names) {
// Your implementation goes here
printf("get_partition_with_auth\n");