From 4010e25ea09bf0a3ef359b946376da67d0323c5d Mon Sep 17 00:00:00 2001 From: shuiyisong <113876041+shuiyisong@users.noreply.github.com> Date: Mon, 2 Mar 2026 16:26:36 +0800 Subject: [PATCH] feat: add pull meta config API (#311) * chore: add meta config rpc Signed-off-by: shuiyisong * chore: update payload to simple string Signed-off-by: shuiyisong * chore: wrap string with message to enable option in rust Signed-off-by: shuiyisong * chore: replace content with vec Signed-off-by: shuiyisong * chore: fix format Signed-off-by: shuiyisong * chore: remove repeated Signed-off-by: shuiyisong * chore: update comment Co-authored-by: fys <40801205+fengys1996@users.noreply.github.com> * chore: update comment Signed-off-by: shuiyisong * chore: move pull config to a separate config service Signed-off-by: shuiyisong --------- Signed-off-by: shuiyisong Co-authored-by: fys <40801205+fengys1996@users.noreply.github.com> --- build.rs | 1 + c++/greptime/v1/meta/config.grpc.pb.cc | 90 + c++/greptime/v1/meta/config.grpc.pb.h | 262 +++ c++/greptime/v1/meta/config.pb.cc | 588 +++++++ c++/greptime/v1/meta/config.pb.h | 648 ++++++++ go/greptime/v1/meta/config.pb.go | 253 +++ go/greptime/v1/meta/config_grpc.pb.go | 107 ++ .../greptime/v1/meta/ConfigOuterClass.java | 1465 +++++++++++++++++ proto/greptime/v1/meta/config.proto | 35 + 9 files changed, 3449 insertions(+) create mode 100644 c++/greptime/v1/meta/config.grpc.pb.cc create mode 100644 c++/greptime/v1/meta/config.grpc.pb.h create mode 100644 c++/greptime/v1/meta/config.pb.cc create mode 100644 c++/greptime/v1/meta/config.pb.h create mode 100644 go/greptime/v1/meta/config.pb.go create mode 100644 go/greptime/v1/meta/config_grpc.pb.go create mode 100644 java/src/main/java/greptime/v1/meta/ConfigOuterClass.java create mode 100644 proto/greptime/v1/meta/config.proto diff --git a/build.rs b/build.rs index 0e34f42..5fde545 100644 --- a/build.rs +++ b/build.rs @@ -58,6 +58,7 @@ fn main() { "proto/greptime/v1/wal.proto", "proto/greptime/v1/meta/common.proto", "proto/greptime/v1/meta/heartbeat.proto", + "proto/greptime/v1/meta/config.proto", "proto/greptime/v1/meta/route.proto", "proto/greptime/v1/meta/ddl.proto", "proto/greptime/v1/meta/region.proto", diff --git a/c++/greptime/v1/meta/config.grpc.pb.cc b/c++/greptime/v1/meta/config.grpc.pb.cc new file mode 100644 index 0000000..0c57914 --- /dev/null +++ b/c++/greptime/v1/meta/config.grpc.pb.cc @@ -0,0 +1,90 @@ +// Generated by the gRPC C++ plugin. +// If you make any local change, they will be lost. +// source: greptime/v1/meta/config.proto + +#include "greptime/v1/meta/config.pb.h" +#include "greptime/v1/meta/config.grpc.pb.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +namespace greptime { +namespace v1 { +namespace meta { + +static const char* Config_method_names[] = { + "/greptime.v1.meta.Config/PullConfig", +}; + +std::unique_ptr< Config::Stub> Config::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) { + (void)options; + std::unique_ptr< Config::Stub> stub(new Config::Stub(channel, options)); + return stub; +} + +Config::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) + : channel_(channel), rpcmethod_PullConfig_(Config_method_names[0], options.suffix_for_stats(),::grpc::internal::RpcMethod::NORMAL_RPC, channel) + {} + +::grpc::Status Config::Stub::PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::greptime::v1::meta::PullConfigResponse* response) { + return ::grpc::internal::BlockingUnaryCall< ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), rpcmethod_PullConfig_, context, request, response); +} + +void Config::Stub::async::PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response, std::function f) { + ::grpc::internal::CallbackUnaryCall< ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_PullConfig_, context, request, response, std::move(f)); +} + +void Config::Stub::async::PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response, ::grpc::ClientUnaryReactor* reactor) { + ::grpc::internal::ClientCallbackUnaryFactory::Create< ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(stub_->channel_.get(), stub_->rpcmethod_PullConfig_, context, request, response, reactor); +} + +::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>* Config::Stub::PrepareAsyncPullConfigRaw(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) { + return ::grpc::internal::ClientAsyncResponseReaderHelper::Create< ::greptime::v1::meta::PullConfigResponse, ::greptime::v1::meta::PullConfigRequest, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>(channel_.get(), cq, rpcmethod_PullConfig_, context, request); +} + +::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>* Config::Stub::AsyncPullConfigRaw(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) { + auto* result = + this->PrepareAsyncPullConfigRaw(context, request, cq); + result->StartCall(); + return result; +} + +Config::Service::Service() { + AddMethod(new ::grpc::internal::RpcServiceMethod( + Config_method_names[0], + ::grpc::internal::RpcMethod::NORMAL_RPC, + new ::grpc::internal::RpcMethodHandler< Config::Service, ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse, ::grpc::protobuf::MessageLite, ::grpc::protobuf::MessageLite>( + [](Config::Service* service, + ::grpc::ServerContext* ctx, + const ::greptime::v1::meta::PullConfigRequest* req, + ::greptime::v1::meta::PullConfigResponse* resp) { + return service->PullConfig(ctx, req, resp); + }, this))); +} + +Config::Service::~Service() { +} + +::grpc::Status Config::Service::PullConfig(::grpc::ServerContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response) { + (void) context; + (void) request; + (void) response; + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); +} + + +} // namespace greptime +} // namespace v1 +} // namespace meta + diff --git a/c++/greptime/v1/meta/config.grpc.pb.h b/c++/greptime/v1/meta/config.grpc.pb.h new file mode 100644 index 0000000..0a72a38 --- /dev/null +++ b/c++/greptime/v1/meta/config.grpc.pb.h @@ -0,0 +1,262 @@ +// Generated by the gRPC C++ plugin. +// If you make any local change, they will be lost. +// source: greptime/v1/meta/config.proto +// Original file comments: +// Copyright 2023 Greptime Team +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +#ifndef GRPC_greptime_2fv1_2fmeta_2fconfig_2eproto__INCLUDED +#define GRPC_greptime_2fv1_2fmeta_2fconfig_2eproto__INCLUDED + +#include "greptime/v1/meta/config.pb.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +namespace greptime { +namespace v1 { +namespace meta { + +class Config final { + public: + static constexpr char const* service_full_name() { + return "greptime.v1.meta.Config"; + } + class StubInterface { + public: + virtual ~StubInterface() {} + // Pull configuration from meta server. + virtual ::grpc::Status PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::greptime::v1::meta::PullConfigResponse* response) = 0; + std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::greptime::v1::meta::PullConfigResponse>> AsyncPullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::greptime::v1::meta::PullConfigResponse>>(AsyncPullConfigRaw(context, request, cq)); + } + std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::greptime::v1::meta::PullConfigResponse>> PrepareAsyncPullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::greptime::v1::meta::PullConfigResponse>>(PrepareAsyncPullConfigRaw(context, request, cq)); + } + class async_interface { + public: + virtual ~async_interface() {} + // Pull configuration from meta server. + virtual void PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response, std::function) = 0; + virtual void PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response, ::grpc::ClientUnaryReactor* reactor) = 0; + }; + typedef class async_interface experimental_async_interface; + virtual class async_interface* async() { return nullptr; } + class async_interface* experimental_async() { return async(); } + private: + virtual ::grpc::ClientAsyncResponseReaderInterface< ::greptime::v1::meta::PullConfigResponse>* AsyncPullConfigRaw(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) = 0; + virtual ::grpc::ClientAsyncResponseReaderInterface< ::greptime::v1::meta::PullConfigResponse>* PrepareAsyncPullConfigRaw(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) = 0; + }; + class Stub final : public StubInterface { + public: + Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions()); + ::grpc::Status PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::greptime::v1::meta::PullConfigResponse* response) override; + std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>> AsyncPullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>>(AsyncPullConfigRaw(context, request, cq)); + } + std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>> PrepareAsyncPullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>>(PrepareAsyncPullConfigRaw(context, request, cq)); + } + class async final : + public StubInterface::async_interface { + public: + void PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response, std::function) override; + void PullConfig(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response, ::grpc::ClientUnaryReactor* reactor) override; + private: + friend class Stub; + explicit async(Stub* stub): stub_(stub) { } + Stub* stub() { return stub_; } + Stub* stub_; + }; + class async* async() override { return &async_stub_; } + + private: + std::shared_ptr< ::grpc::ChannelInterface> channel_; + class async async_stub_{this}; + ::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>* AsyncPullConfigRaw(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) override; + ::grpc::ClientAsyncResponseReader< ::greptime::v1::meta::PullConfigResponse>* PrepareAsyncPullConfigRaw(::grpc::ClientContext* context, const ::greptime::v1::meta::PullConfigRequest& request, ::grpc::CompletionQueue* cq) override; + const ::grpc::internal::RpcMethod rpcmethod_PullConfig_; + }; + static std::unique_ptr NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions()); + + class Service : public ::grpc::Service { + public: + Service(); + virtual ~Service(); + // Pull configuration from meta server. + virtual ::grpc::Status PullConfig(::grpc::ServerContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response); + }; + template + class WithAsyncMethod_PullConfig : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithAsyncMethod_PullConfig() { + ::grpc::Service::MarkMethodAsync(0); + } + ~WithAsyncMethod_PullConfig() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status PullConfig(::grpc::ServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + void RequestPullConfig(::grpc::ServerContext* context, ::greptime::v1::meta::PullConfigRequest* request, ::grpc::ServerAsyncResponseWriter< ::greptime::v1::meta::PullConfigResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { + ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag); + } + }; + typedef WithAsyncMethod_PullConfig AsyncService; + template + class WithCallbackMethod_PullConfig : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithCallbackMethod_PullConfig() { + ::grpc::Service::MarkMethodCallback(0, + new ::grpc::internal::CallbackUnaryHandler< ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse>( + [this]( + ::grpc::CallbackServerContext* context, const ::greptime::v1::meta::PullConfigRequest* request, ::greptime::v1::meta::PullConfigResponse* response) { return this->PullConfig(context, request, response); }));} + void SetMessageAllocatorFor_PullConfig( + ::grpc::MessageAllocator< ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse>* allocator) { + ::grpc::internal::MethodHandler* const handler = ::grpc::Service::GetHandler(0); + static_cast<::grpc::internal::CallbackUnaryHandler< ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse>*>(handler) + ->SetMessageAllocator(allocator); + } + ~WithCallbackMethod_PullConfig() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status PullConfig(::grpc::ServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + virtual ::grpc::ServerUnaryReactor* PullConfig( + ::grpc::CallbackServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) { return nullptr; } + }; + typedef WithCallbackMethod_PullConfig CallbackService; + typedef CallbackService ExperimentalCallbackService; + template + class WithGenericMethod_PullConfig : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithGenericMethod_PullConfig() { + ::grpc::Service::MarkMethodGeneric(0); + } + ~WithGenericMethod_PullConfig() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status PullConfig(::grpc::ServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + }; + template + class WithRawMethod_PullConfig : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithRawMethod_PullConfig() { + ::grpc::Service::MarkMethodRaw(0); + } + ~WithRawMethod_PullConfig() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status PullConfig(::grpc::ServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + void RequestPullConfig(::grpc::ServerContext* context, ::grpc::ByteBuffer* request, ::grpc::ServerAsyncResponseWriter< ::grpc::ByteBuffer>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { + ::grpc::Service::RequestAsyncUnary(0, context, request, response, new_call_cq, notification_cq, tag); + } + }; + template + class WithRawCallbackMethod_PullConfig : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithRawCallbackMethod_PullConfig() { + ::grpc::Service::MarkMethodRawCallback(0, + new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( + [this]( + ::grpc::CallbackServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response) { return this->PullConfig(context, request, response); })); + } + ~WithRawCallbackMethod_PullConfig() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status PullConfig(::grpc::ServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + virtual ::grpc::ServerUnaryReactor* PullConfig( + ::grpc::CallbackServerContext* /*context*/, const ::grpc::ByteBuffer* /*request*/, ::grpc::ByteBuffer* /*response*/) { return nullptr; } + }; + template + class WithStreamedUnaryMethod_PullConfig : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service* /*service*/) {} + public: + WithStreamedUnaryMethod_PullConfig() { + ::grpc::Service::MarkMethodStreamed(0, + new ::grpc::internal::StreamedUnaryHandler< + ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse>( + [this](::grpc::ServerContext* context, + ::grpc::ServerUnaryStreamer< + ::greptime::v1::meta::PullConfigRequest, ::greptime::v1::meta::PullConfigResponse>* streamer) { + return this->StreamedPullConfig(context, + streamer); + })); + } + ~WithStreamedUnaryMethod_PullConfig() override { + BaseClassMustBeDerivedFromService(this); + } + // disable regular version of this method + ::grpc::Status PullConfig(::grpc::ServerContext* /*context*/, const ::greptime::v1::meta::PullConfigRequest* /*request*/, ::greptime::v1::meta::PullConfigResponse* /*response*/) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + // replace default version of method with streamed unary + virtual ::grpc::Status StreamedPullConfig(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::greptime::v1::meta::PullConfigRequest,::greptime::v1::meta::PullConfigResponse>* server_unary_streamer) = 0; + }; + typedef WithStreamedUnaryMethod_PullConfig StreamedUnaryService; + typedef Service SplitStreamedService; + typedef WithStreamedUnaryMethod_PullConfig StreamedService; +}; + +} // namespace meta +} // namespace v1 +} // namespace greptime + + +#endif // GRPC_greptime_2fv1_2fmeta_2fconfig_2eproto__INCLUDED diff --git a/c++/greptime/v1/meta/config.pb.cc b/c++/greptime/v1/meta/config.pb.cc new file mode 100644 index 0000000..b5d457e --- /dev/null +++ b/c++/greptime/v1/meta/config.pb.cc @@ -0,0 +1,588 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: greptime/v1/meta/config.proto + +#include "greptime/v1/meta/config.pb.h" + +#include + +#include +#include +#include +#include +#include +#include +#include +// @@protoc_insertion_point(includes) +#include + +PROTOBUF_PRAGMA_INIT_SEG + +namespace _pb = ::PROTOBUF_NAMESPACE_ID; +namespace _pbi = _pb::internal; + +namespace greptime { +namespace v1 { +namespace meta { +PROTOBUF_CONSTEXPR PullConfigRequest::PullConfigRequest( + ::_pbi::ConstantInitialized): _impl_{ + /*decltype(_impl_.header_)*/nullptr + , /*decltype(_impl_._cached_size_)*/{}} {} +struct PullConfigRequestDefaultTypeInternal { + PROTOBUF_CONSTEXPR PullConfigRequestDefaultTypeInternal() + : _instance(::_pbi::ConstantInitialized{}) {} + ~PullConfigRequestDefaultTypeInternal() {} + union { + PullConfigRequest _instance; + }; +}; +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PullConfigRequestDefaultTypeInternal _PullConfigRequest_default_instance_; +PROTOBUF_CONSTEXPR PullConfigResponse::PullConfigResponse( + ::_pbi::ConstantInitialized): _impl_{ + /*decltype(_impl_.payload_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.header_)*/nullptr + , /*decltype(_impl_._cached_size_)*/{}} {} +struct PullConfigResponseDefaultTypeInternal { + PROTOBUF_CONSTEXPR PullConfigResponseDefaultTypeInternal() + : _instance(::_pbi::ConstantInitialized{}) {} + ~PullConfigResponseDefaultTypeInternal() {} + union { + PullConfigResponse _instance; + }; +}; +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 PullConfigResponseDefaultTypeInternal _PullConfigResponse_default_instance_; +} // namespace meta +} // namespace v1 +} // namespace greptime +static ::_pb::Metadata file_level_metadata_greptime_2fv1_2fmeta_2fconfig_2eproto[2]; +static constexpr ::_pb::EnumDescriptor const** file_level_enum_descriptors_greptime_2fv1_2fmeta_2fconfig_2eproto = nullptr; +static constexpr ::_pb::ServiceDescriptor const** file_level_service_descriptors_greptime_2fv1_2fmeta_2fconfig_2eproto = nullptr; + +const uint32_t TableStruct_greptime_2fv1_2fmeta_2fconfig_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::greptime::v1::meta::PullConfigRequest, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::greptime::v1::meta::PullConfigRequest, _impl_.header_), + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::greptime::v1::meta::PullConfigResponse, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::greptime::v1::meta::PullConfigResponse, _impl_.header_), + PROTOBUF_FIELD_OFFSET(::greptime::v1::meta::PullConfigResponse, _impl_.payload_), +}; +static const ::_pbi::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { + { 0, -1, -1, sizeof(::greptime::v1::meta::PullConfigRequest)}, + { 7, -1, -1, sizeof(::greptime::v1::meta::PullConfigResponse)}, +}; + +static const ::_pb::Message* const file_default_instances[] = { + &::greptime::v1::meta::_PullConfigRequest_default_instance_._instance, + &::greptime::v1::meta::_PullConfigResponse_default_instance_._instance, +}; + +const char descriptor_table_protodef_greptime_2fv1_2fmeta_2fconfig_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = + "\n\035greptime/v1/meta/config.proto\022\020greptim" + "e.v1.meta\032\035greptime/v1/meta/common.proto" + "\"D\n\021PullConfigRequest\022/\n\006header\030\001 \001(\0132\037." + "greptime.v1.meta.RequestHeader\"W\n\022PullCo" + "nfigResponse\0220\n\006header\030\001 \001(\0132 .greptime." + "v1.meta.ResponseHeader\022\017\n\007payload\030\002 \001(\t2" + "c\n\006Config\022Y\n\nPullConfig\022#.greptime.v1.me" + "ta.PullConfigRequest\032$.greptime.v1.meta." + "PullConfigResponse\"\000B_impl_.header_; +} +void PullConfigRequest::clear_header() { + if (GetArenaForAllocation() == nullptr && _impl_.header_ != nullptr) { + delete _impl_.header_; + } + _impl_.header_ = nullptr; +} +PullConfigRequest::PullConfigRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned) + : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) { + SharedCtor(arena, is_message_owned); + // @@protoc_insertion_point(arena_constructor:greptime.v1.meta.PullConfigRequest) +} +PullConfigRequest::PullConfigRequest(const PullConfigRequest& from) + : ::PROTOBUF_NAMESPACE_ID::Message() { + PullConfigRequest* const _this = this; (void)_this; + new (&_impl_) Impl_{ + decltype(_impl_.header_){nullptr} + , /*decltype(_impl_._cached_size_)*/{}}; + + _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + if (from._internal_has_header()) { + _this->_impl_.header_ = new ::greptime::v1::meta::RequestHeader(*from._impl_.header_); + } + // @@protoc_insertion_point(copy_constructor:greptime.v1.meta.PullConfigRequest) +} + +inline void PullConfigRequest::SharedCtor( + ::_pb::Arena* arena, bool is_message_owned) { + (void)arena; + (void)is_message_owned; + new (&_impl_) Impl_{ + decltype(_impl_.header_){nullptr} + , /*decltype(_impl_._cached_size_)*/{} + }; +} + +PullConfigRequest::~PullConfigRequest() { + // @@protoc_insertion_point(destructor:greptime.v1.meta.PullConfigRequest) + if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) { + (void)arena; + return; + } + SharedDtor(); +} + +inline void PullConfigRequest::SharedDtor() { + GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); + if (this != internal_default_instance()) delete _impl_.header_; +} + +void PullConfigRequest::SetCachedSize(int size) const { + _impl_._cached_size_.Set(size); +} + +void PullConfigRequest::Clear() { +// @@protoc_insertion_point(message_clear_start:greptime.v1.meta.PullConfigRequest) + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + if (GetArenaForAllocation() == nullptr && _impl_.header_ != nullptr) { + delete _impl_.header_; + } + _impl_.header_ = nullptr; + _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); +} + +const char* PullConfigRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) { +#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure + while (!ctx->Done(&ptr)) { + uint32_t tag; + ptr = ::_pbi::ReadTag(ptr, &tag); + switch (tag >> 3) { + // .greptime.v1.meta.RequestHeader header = 1; + case 1: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 10)) { + ptr = ctx->ParseMessage(_internal_mutable_header(), ptr); + CHK_(ptr); + } else + goto handle_unusual; + continue; + default: + goto handle_unusual; + } // switch + handle_unusual: + if ((tag == 0) || ((tag & 7) == 4)) { + CHK_(ptr); + ctx->SetLastTag(tag); + goto message_done; + } + ptr = UnknownFieldParse( + tag, + _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), + ptr, ctx); + CHK_(ptr != nullptr); + } // while +message_done: + return ptr; +failure: + ptr = nullptr; + goto message_done; +#undef CHK_ +} + +uint8_t* PullConfigRequest::_InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { + // @@protoc_insertion_point(serialize_to_array_start:greptime.v1.meta.PullConfigRequest) + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + // .greptime.v1.meta.RequestHeader header = 1; + if (this->_internal_has_header()) { + target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: + InternalWriteMessage(1, _Internal::header(this), + _Internal::header(this).GetCachedSize(), target, stream); + } + + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { + target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); + } + // @@protoc_insertion_point(serialize_to_array_end:greptime.v1.meta.PullConfigRequest) + return target; +} + +size_t PullConfigRequest::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:greptime.v1.meta.PullConfigRequest) + size_t total_size = 0; + + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + // .greptime.v1.meta.RequestHeader header = 1; + if (this->_internal_has_header()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize( + *_impl_.header_); + } + + return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); +} + +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData PullConfigRequest::_class_data_ = { + ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, + PullConfigRequest::MergeImpl +}; +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*PullConfigRequest::GetClassData() const { return &_class_data_; } + + +void PullConfigRequest::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:greptime.v1.meta.PullConfigRequest) + GOOGLE_DCHECK_NE(&from, _this); + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + if (from._internal_has_header()) { + _this->_internal_mutable_header()->::greptime::v1::meta::RequestHeader::MergeFrom( + from._internal_header()); + } + _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); +} + +void PullConfigRequest::CopyFrom(const PullConfigRequest& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:greptime.v1.meta.PullConfigRequest) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool PullConfigRequest::IsInitialized() const { + return true; +} + +void PullConfigRequest::InternalSwap(PullConfigRequest* other) { + using std::swap; + _internal_metadata_.InternalSwap(&other->_internal_metadata_); + swap(_impl_.header_, other->_impl_.header_); +} + +::PROTOBUF_NAMESPACE_ID::Metadata PullConfigRequest::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_greptime_2fv1_2fmeta_2fconfig_2eproto_getter, &descriptor_table_greptime_2fv1_2fmeta_2fconfig_2eproto_once, + file_level_metadata_greptime_2fv1_2fmeta_2fconfig_2eproto[0]); +} + +// =================================================================== + +class PullConfigResponse::_Internal { + public: + static const ::greptime::v1::meta::ResponseHeader& header(const PullConfigResponse* msg); +}; + +const ::greptime::v1::meta::ResponseHeader& +PullConfigResponse::_Internal::header(const PullConfigResponse* msg) { + return *msg->_impl_.header_; +} +void PullConfigResponse::clear_header() { + if (GetArenaForAllocation() == nullptr && _impl_.header_ != nullptr) { + delete _impl_.header_; + } + _impl_.header_ = nullptr; +} +PullConfigResponse::PullConfigResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned) + : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) { + SharedCtor(arena, is_message_owned); + // @@protoc_insertion_point(arena_constructor:greptime.v1.meta.PullConfigResponse) +} +PullConfigResponse::PullConfigResponse(const PullConfigResponse& from) + : ::PROTOBUF_NAMESPACE_ID::Message() { + PullConfigResponse* const _this = this; (void)_this; + new (&_impl_) Impl_{ + decltype(_impl_.payload_){} + , decltype(_impl_.header_){nullptr} + , /*decltype(_impl_._cached_size_)*/{}}; + + _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + _impl_.payload_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.payload_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_payload().empty()) { + _this->_impl_.payload_.Set(from._internal_payload(), + _this->GetArenaForAllocation()); + } + if (from._internal_has_header()) { + _this->_impl_.header_ = new ::greptime::v1::meta::ResponseHeader(*from._impl_.header_); + } + // @@protoc_insertion_point(copy_constructor:greptime.v1.meta.PullConfigResponse) +} + +inline void PullConfigResponse::SharedCtor( + ::_pb::Arena* arena, bool is_message_owned) { + (void)arena; + (void)is_message_owned; + new (&_impl_) Impl_{ + decltype(_impl_.payload_){} + , decltype(_impl_.header_){nullptr} + , /*decltype(_impl_._cached_size_)*/{} + }; + _impl_.payload_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.payload_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING +} + +PullConfigResponse::~PullConfigResponse() { + // @@protoc_insertion_point(destructor:greptime.v1.meta.PullConfigResponse) + if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) { + (void)arena; + return; + } + SharedDtor(); +} + +inline void PullConfigResponse::SharedDtor() { + GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); + _impl_.payload_.Destroy(); + if (this != internal_default_instance()) delete _impl_.header_; +} + +void PullConfigResponse::SetCachedSize(int size) const { + _impl_._cached_size_.Set(size); +} + +void PullConfigResponse::Clear() { +// @@protoc_insertion_point(message_clear_start:greptime.v1.meta.PullConfigResponse) + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + _impl_.payload_.ClearToEmpty(); + if (GetArenaForAllocation() == nullptr && _impl_.header_ != nullptr) { + delete _impl_.header_; + } + _impl_.header_ = nullptr; + _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); +} + +const char* PullConfigResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) { +#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure + while (!ctx->Done(&ptr)) { + uint32_t tag; + ptr = ::_pbi::ReadTag(ptr, &tag); + switch (tag >> 3) { + // .greptime.v1.meta.ResponseHeader header = 1; + case 1: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 10)) { + ptr = ctx->ParseMessage(_internal_mutable_header(), ptr); + CHK_(ptr); + } else + goto handle_unusual; + continue; + // string payload = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 18)) { + auto str = _internal_mutable_payload(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "greptime.v1.meta.PullConfigResponse.payload")); + } else + goto handle_unusual; + continue; + default: + goto handle_unusual; + } // switch + handle_unusual: + if ((tag == 0) || ((tag & 7) == 4)) { + CHK_(ptr); + ctx->SetLastTag(tag); + goto message_done; + } + ptr = UnknownFieldParse( + tag, + _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), + ptr, ctx); + CHK_(ptr != nullptr); + } // while +message_done: + return ptr; +failure: + ptr = nullptr; + goto message_done; +#undef CHK_ +} + +uint8_t* PullConfigResponse::_InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { + // @@protoc_insertion_point(serialize_to_array_start:greptime.v1.meta.PullConfigResponse) + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + // .greptime.v1.meta.ResponseHeader header = 1; + if (this->_internal_has_header()) { + target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: + InternalWriteMessage(1, _Internal::header(this), + _Internal::header(this).GetCachedSize(), target, stream); + } + + // string payload = 2; + if (!this->_internal_payload().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_payload().data(), static_cast(this->_internal_payload().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "greptime.v1.meta.PullConfigResponse.payload"); + target = stream->WriteStringMaybeAliased( + 2, this->_internal_payload(), target); + } + + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { + target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); + } + // @@protoc_insertion_point(serialize_to_array_end:greptime.v1.meta.PullConfigResponse) + return target; +} + +size_t PullConfigResponse::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:greptime.v1.meta.PullConfigResponse) + size_t total_size = 0; + + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + // string payload = 2; + if (!this->_internal_payload().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_payload()); + } + + // .greptime.v1.meta.ResponseHeader header = 1; + if (this->_internal_has_header()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize( + *_impl_.header_); + } + + return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); +} + +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData PullConfigResponse::_class_data_ = { + ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, + PullConfigResponse::MergeImpl +}; +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*PullConfigResponse::GetClassData() const { return &_class_data_; } + + +void PullConfigResponse::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:greptime.v1.meta.PullConfigResponse) + GOOGLE_DCHECK_NE(&from, _this); + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + if (!from._internal_payload().empty()) { + _this->_internal_set_payload(from._internal_payload()); + } + if (from._internal_has_header()) { + _this->_internal_mutable_header()->::greptime::v1::meta::ResponseHeader::MergeFrom( + from._internal_header()); + } + _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); +} + +void PullConfigResponse::CopyFrom(const PullConfigResponse& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:greptime.v1.meta.PullConfigResponse) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool PullConfigResponse::IsInitialized() const { + return true; +} + +void PullConfigResponse::InternalSwap(PullConfigResponse* other) { + using std::swap; + auto* lhs_arena = GetArenaForAllocation(); + auto* rhs_arena = other->GetArenaForAllocation(); + _internal_metadata_.InternalSwap(&other->_internal_metadata_); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.payload_, lhs_arena, + &other->_impl_.payload_, rhs_arena + ); + swap(_impl_.header_, other->_impl_.header_); +} + +::PROTOBUF_NAMESPACE_ID::Metadata PullConfigResponse::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_greptime_2fv1_2fmeta_2fconfig_2eproto_getter, &descriptor_table_greptime_2fv1_2fmeta_2fconfig_2eproto_once, + file_level_metadata_greptime_2fv1_2fmeta_2fconfig_2eproto[1]); +} + +// @@protoc_insertion_point(namespace_scope) +} // namespace meta +} // namespace v1 +} // namespace greptime +PROTOBUF_NAMESPACE_OPEN +template<> PROTOBUF_NOINLINE ::greptime::v1::meta::PullConfigRequest* +Arena::CreateMaybeMessage< ::greptime::v1::meta::PullConfigRequest >(Arena* arena) { + return Arena::CreateMessageInternal< ::greptime::v1::meta::PullConfigRequest >(arena); +} +template<> PROTOBUF_NOINLINE ::greptime::v1::meta::PullConfigResponse* +Arena::CreateMaybeMessage< ::greptime::v1::meta::PullConfigResponse >(Arena* arena) { + return Arena::CreateMessageInternal< ::greptime::v1::meta::PullConfigResponse >(arena); +} +PROTOBUF_NAMESPACE_CLOSE + +// @@protoc_insertion_point(global_scope) +#include diff --git a/c++/greptime/v1/meta/config.pb.h b/c++/greptime/v1/meta/config.pb.h new file mode 100644 index 0000000..a115044 --- /dev/null +++ b/c++/greptime/v1/meta/config.pb.h @@ -0,0 +1,648 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: greptime/v1/meta/config.proto + +#ifndef GOOGLE_PROTOBUF_INCLUDED_greptime_2fv1_2fmeta_2fconfig_2eproto +#define GOOGLE_PROTOBUF_INCLUDED_greptime_2fv1_2fmeta_2fconfig_2eproto + +#include +#include + +#include +#if PROTOBUF_VERSION < 3021000 +#error This file was generated by a newer version of protoc which is +#error incompatible with your Protocol Buffer headers. Please update +#error your headers. +#endif +#if 3021006 < PROTOBUF_MIN_PROTOC_VERSION +#error This file was generated by an older version of protoc which is +#error incompatible with your Protocol Buffer headers. Please +#error regenerate this file with a newer version of protoc. +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include // IWYU pragma: export +#include // IWYU pragma: export +#include +#include "greptime/v1/meta/common.pb.h" +// @@protoc_insertion_point(includes) +#include +#define PROTOBUF_INTERNAL_EXPORT_greptime_2fv1_2fmeta_2fconfig_2eproto +PROTOBUF_NAMESPACE_OPEN +namespace internal { +class AnyMetadata; +} // namespace internal +PROTOBUF_NAMESPACE_CLOSE + +// Internal implementation detail -- do not use these members. +struct TableStruct_greptime_2fv1_2fmeta_2fconfig_2eproto { + static const uint32_t offsets[]; +}; +extern const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_greptime_2fv1_2fmeta_2fconfig_2eproto; +namespace greptime { +namespace v1 { +namespace meta { +class PullConfigRequest; +struct PullConfigRequestDefaultTypeInternal; +extern PullConfigRequestDefaultTypeInternal _PullConfigRequest_default_instance_; +class PullConfigResponse; +struct PullConfigResponseDefaultTypeInternal; +extern PullConfigResponseDefaultTypeInternal _PullConfigResponse_default_instance_; +} // namespace meta +} // namespace v1 +} // namespace greptime +PROTOBUF_NAMESPACE_OPEN +template<> ::greptime::v1::meta::PullConfigRequest* Arena::CreateMaybeMessage<::greptime::v1::meta::PullConfigRequest>(Arena*); +template<> ::greptime::v1::meta::PullConfigResponse* Arena::CreateMaybeMessage<::greptime::v1::meta::PullConfigResponse>(Arena*); +PROTOBUF_NAMESPACE_CLOSE +namespace greptime { +namespace v1 { +namespace meta { + +// =================================================================== + +class PullConfigRequest final : + public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:greptime.v1.meta.PullConfigRequest) */ { + public: + inline PullConfigRequest() : PullConfigRequest(nullptr) {} + ~PullConfigRequest() override; + explicit PROTOBUF_CONSTEXPR PullConfigRequest(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + + PullConfigRequest(const PullConfigRequest& from); + PullConfigRequest(PullConfigRequest&& from) noexcept + : PullConfigRequest() { + *this = ::std::move(from); + } + + inline PullConfigRequest& operator=(const PullConfigRequest& from) { + CopyFrom(from); + return *this; + } + inline PullConfigRequest& operator=(PullConfigRequest&& from) noexcept { + if (this == &from) return *this; + if (GetOwningArena() == from.GetOwningArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetOwningArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const PullConfigRequest& default_instance() { + return *internal_default_instance(); + } + static inline const PullConfigRequest* internal_default_instance() { + return reinterpret_cast( + &_PullConfigRequest_default_instance_); + } + static constexpr int kIndexInFileMessages = + 0; + + friend void swap(PullConfigRequest& a, PullConfigRequest& b) { + a.Swap(&b); + } + inline void Swap(PullConfigRequest* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() != nullptr && + GetOwningArena() == other->GetOwningArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() == other->GetOwningArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(PullConfigRequest* other) { + if (other == this) return; + GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + PullConfigRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; + void CopyFrom(const PullConfigRequest& from); + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + void MergeFrom( const PullConfigRequest& from) { + PullConfigRequest::MergeImpl(*this, from); + } + private: + static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); + public: + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; + uint8_t* _InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; + int GetCachedSize() const final { return _impl_._cached_size_.Get(); } + + private: + void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(PullConfigRequest* other); + + private: + friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; + static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { + return "greptime.v1.meta.PullConfigRequest"; + } + protected: + explicit PullConfigRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned = false); + public: + + static const ClassData _class_data_; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*GetClassData() const final; + + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int { + kHeaderFieldNumber = 1, + }; + // .greptime.v1.meta.RequestHeader header = 1; + bool has_header() const; + private: + bool _internal_has_header() const; + public: + void clear_header(); + const ::greptime::v1::meta::RequestHeader& header() const; + PROTOBUF_NODISCARD ::greptime::v1::meta::RequestHeader* release_header(); + ::greptime::v1::meta::RequestHeader* mutable_header(); + void set_allocated_header(::greptime::v1::meta::RequestHeader* header); + private: + const ::greptime::v1::meta::RequestHeader& _internal_header() const; + ::greptime::v1::meta::RequestHeader* _internal_mutable_header(); + public: + void unsafe_arena_set_allocated_header( + ::greptime::v1::meta::RequestHeader* header); + ::greptime::v1::meta::RequestHeader* unsafe_arena_release_header(); + + // @@protoc_insertion_point(class_scope:greptime.v1.meta.PullConfigRequest) + private: + class _Internal; + + template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; + typedef void InternalArenaConstructable_; + typedef void DestructorSkippable_; + struct Impl_ { + ::greptime::v1::meta::RequestHeader* header_; + mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_greptime_2fv1_2fmeta_2fconfig_2eproto; +}; +// ------------------------------------------------------------------- + +class PullConfigResponse final : + public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:greptime.v1.meta.PullConfigResponse) */ { + public: + inline PullConfigResponse() : PullConfigResponse(nullptr) {} + ~PullConfigResponse() override; + explicit PROTOBUF_CONSTEXPR PullConfigResponse(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + + PullConfigResponse(const PullConfigResponse& from); + PullConfigResponse(PullConfigResponse&& from) noexcept + : PullConfigResponse() { + *this = ::std::move(from); + } + + inline PullConfigResponse& operator=(const PullConfigResponse& from) { + CopyFrom(from); + return *this; + } + inline PullConfigResponse& operator=(PullConfigResponse&& from) noexcept { + if (this == &from) return *this; + if (GetOwningArena() == from.GetOwningArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetOwningArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const PullConfigResponse& default_instance() { + return *internal_default_instance(); + } + static inline const PullConfigResponse* internal_default_instance() { + return reinterpret_cast( + &_PullConfigResponse_default_instance_); + } + static constexpr int kIndexInFileMessages = + 1; + + friend void swap(PullConfigResponse& a, PullConfigResponse& b) { + a.Swap(&b); + } + inline void Swap(PullConfigResponse* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() != nullptr && + GetOwningArena() == other->GetOwningArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() == other->GetOwningArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(PullConfigResponse* other) { + if (other == this) return; + GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + PullConfigResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; + void CopyFrom(const PullConfigResponse& from); + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + void MergeFrom( const PullConfigResponse& from) { + PullConfigResponse::MergeImpl(*this, from); + } + private: + static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); + public: + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; + uint8_t* _InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; + int GetCachedSize() const final { return _impl_._cached_size_.Get(); } + + private: + void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(PullConfigResponse* other); + + private: + friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; + static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { + return "greptime.v1.meta.PullConfigResponse"; + } + protected: + explicit PullConfigResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned = false); + public: + + static const ClassData _class_data_; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*GetClassData() const final; + + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + enum : int { + kPayloadFieldNumber = 2, + kHeaderFieldNumber = 1, + }; + // string payload = 2; + void clear_payload(); + const std::string& payload() const; + template + void set_payload(ArgT0&& arg0, ArgT... args); + std::string* mutable_payload(); + PROTOBUF_NODISCARD std::string* release_payload(); + void set_allocated_payload(std::string* payload); + private: + const std::string& _internal_payload() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_payload(const std::string& value); + std::string* _internal_mutable_payload(); + public: + + // .greptime.v1.meta.ResponseHeader header = 1; + bool has_header() const; + private: + bool _internal_has_header() const; + public: + void clear_header(); + const ::greptime::v1::meta::ResponseHeader& header() const; + PROTOBUF_NODISCARD ::greptime::v1::meta::ResponseHeader* release_header(); + ::greptime::v1::meta::ResponseHeader* mutable_header(); + void set_allocated_header(::greptime::v1::meta::ResponseHeader* header); + private: + const ::greptime::v1::meta::ResponseHeader& _internal_header() const; + ::greptime::v1::meta::ResponseHeader* _internal_mutable_header(); + public: + void unsafe_arena_set_allocated_header( + ::greptime::v1::meta::ResponseHeader* header); + ::greptime::v1::meta::ResponseHeader* unsafe_arena_release_header(); + + // @@protoc_insertion_point(class_scope:greptime.v1.meta.PullConfigResponse) + private: + class _Internal; + + template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; + typedef void InternalArenaConstructable_; + typedef void DestructorSkippable_; + struct Impl_ { + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr payload_; + ::greptime::v1::meta::ResponseHeader* header_; + mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_greptime_2fv1_2fmeta_2fconfig_2eproto; +}; +// =================================================================== + + +// =================================================================== + +#ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wstrict-aliasing" +#endif // __GNUC__ +// PullConfigRequest + +// .greptime.v1.meta.RequestHeader header = 1; +inline bool PullConfigRequest::_internal_has_header() const { + return this != internal_default_instance() && _impl_.header_ != nullptr; +} +inline bool PullConfigRequest::has_header() const { + return _internal_has_header(); +} +inline const ::greptime::v1::meta::RequestHeader& PullConfigRequest::_internal_header() const { + const ::greptime::v1::meta::RequestHeader* p = _impl_.header_; + return p != nullptr ? *p : reinterpret_cast( + ::greptime::v1::meta::_RequestHeader_default_instance_); +} +inline const ::greptime::v1::meta::RequestHeader& PullConfigRequest::header() const { + // @@protoc_insertion_point(field_get:greptime.v1.meta.PullConfigRequest.header) + return _internal_header(); +} +inline void PullConfigRequest::unsafe_arena_set_allocated_header( + ::greptime::v1::meta::RequestHeader* header) { + if (GetArenaForAllocation() == nullptr) { + delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.header_); + } + _impl_.header_ = header; + if (header) { + + } else { + + } + // @@protoc_insertion_point(field_unsafe_arena_set_allocated:greptime.v1.meta.PullConfigRequest.header) +} +inline ::greptime::v1::meta::RequestHeader* PullConfigRequest::release_header() { + + ::greptime::v1::meta::RequestHeader* temp = _impl_.header_; + _impl_.header_ = nullptr; +#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE + auto* old = reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp); + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + if (GetArenaForAllocation() == nullptr) { delete old; } +#else // PROTOBUF_FORCE_COPY_IN_RELEASE + if (GetArenaForAllocation() != nullptr) { + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + } +#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE + return temp; +} +inline ::greptime::v1::meta::RequestHeader* PullConfigRequest::unsafe_arena_release_header() { + // @@protoc_insertion_point(field_release:greptime.v1.meta.PullConfigRequest.header) + + ::greptime::v1::meta::RequestHeader* temp = _impl_.header_; + _impl_.header_ = nullptr; + return temp; +} +inline ::greptime::v1::meta::RequestHeader* PullConfigRequest::_internal_mutable_header() { + + if (_impl_.header_ == nullptr) { + auto* p = CreateMaybeMessage<::greptime::v1::meta::RequestHeader>(GetArenaForAllocation()); + _impl_.header_ = p; + } + return _impl_.header_; +} +inline ::greptime::v1::meta::RequestHeader* PullConfigRequest::mutable_header() { + ::greptime::v1::meta::RequestHeader* _msg = _internal_mutable_header(); + // @@protoc_insertion_point(field_mutable:greptime.v1.meta.PullConfigRequest.header) + return _msg; +} +inline void PullConfigRequest::set_allocated_header(::greptime::v1::meta::RequestHeader* header) { + ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); + if (message_arena == nullptr) { + delete reinterpret_cast< ::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.header_); + } + if (header) { + ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = + ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena( + reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(header)); + if (message_arena != submessage_arena) { + header = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( + message_arena, header, submessage_arena); + } + + } else { + + } + _impl_.header_ = header; + // @@protoc_insertion_point(field_set_allocated:greptime.v1.meta.PullConfigRequest.header) +} + +// ------------------------------------------------------------------- + +// PullConfigResponse + +// .greptime.v1.meta.ResponseHeader header = 1; +inline bool PullConfigResponse::_internal_has_header() const { + return this != internal_default_instance() && _impl_.header_ != nullptr; +} +inline bool PullConfigResponse::has_header() const { + return _internal_has_header(); +} +inline const ::greptime::v1::meta::ResponseHeader& PullConfigResponse::_internal_header() const { + const ::greptime::v1::meta::ResponseHeader* p = _impl_.header_; + return p != nullptr ? *p : reinterpret_cast( + ::greptime::v1::meta::_ResponseHeader_default_instance_); +} +inline const ::greptime::v1::meta::ResponseHeader& PullConfigResponse::header() const { + // @@protoc_insertion_point(field_get:greptime.v1.meta.PullConfigResponse.header) + return _internal_header(); +} +inline void PullConfigResponse::unsafe_arena_set_allocated_header( + ::greptime::v1::meta::ResponseHeader* header) { + if (GetArenaForAllocation() == nullptr) { + delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.header_); + } + _impl_.header_ = header; + if (header) { + + } else { + + } + // @@protoc_insertion_point(field_unsafe_arena_set_allocated:greptime.v1.meta.PullConfigResponse.header) +} +inline ::greptime::v1::meta::ResponseHeader* PullConfigResponse::release_header() { + + ::greptime::v1::meta::ResponseHeader* temp = _impl_.header_; + _impl_.header_ = nullptr; +#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE + auto* old = reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp); + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + if (GetArenaForAllocation() == nullptr) { delete old; } +#else // PROTOBUF_FORCE_COPY_IN_RELEASE + if (GetArenaForAllocation() != nullptr) { + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + } +#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE + return temp; +} +inline ::greptime::v1::meta::ResponseHeader* PullConfigResponse::unsafe_arena_release_header() { + // @@protoc_insertion_point(field_release:greptime.v1.meta.PullConfigResponse.header) + + ::greptime::v1::meta::ResponseHeader* temp = _impl_.header_; + _impl_.header_ = nullptr; + return temp; +} +inline ::greptime::v1::meta::ResponseHeader* PullConfigResponse::_internal_mutable_header() { + + if (_impl_.header_ == nullptr) { + auto* p = CreateMaybeMessage<::greptime::v1::meta::ResponseHeader>(GetArenaForAllocation()); + _impl_.header_ = p; + } + return _impl_.header_; +} +inline ::greptime::v1::meta::ResponseHeader* PullConfigResponse::mutable_header() { + ::greptime::v1::meta::ResponseHeader* _msg = _internal_mutable_header(); + // @@protoc_insertion_point(field_mutable:greptime.v1.meta.PullConfigResponse.header) + return _msg; +} +inline void PullConfigResponse::set_allocated_header(::greptime::v1::meta::ResponseHeader* header) { + ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); + if (message_arena == nullptr) { + delete reinterpret_cast< ::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.header_); + } + if (header) { + ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = + ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena( + reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(header)); + if (message_arena != submessage_arena) { + header = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( + message_arena, header, submessage_arena); + } + + } else { + + } + _impl_.header_ = header; + // @@protoc_insertion_point(field_set_allocated:greptime.v1.meta.PullConfigResponse.header) +} + +// string payload = 2; +inline void PullConfigResponse::clear_payload() { + _impl_.payload_.ClearToEmpty(); +} +inline const std::string& PullConfigResponse::payload() const { + // @@protoc_insertion_point(field_get:greptime.v1.meta.PullConfigResponse.payload) + return _internal_payload(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void PullConfigResponse::set_payload(ArgT0&& arg0, ArgT... args) { + + _impl_.payload_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:greptime.v1.meta.PullConfigResponse.payload) +} +inline std::string* PullConfigResponse::mutable_payload() { + std::string* _s = _internal_mutable_payload(); + // @@protoc_insertion_point(field_mutable:greptime.v1.meta.PullConfigResponse.payload) + return _s; +} +inline const std::string& PullConfigResponse::_internal_payload() const { + return _impl_.payload_.Get(); +} +inline void PullConfigResponse::_internal_set_payload(const std::string& value) { + + _impl_.payload_.Set(value, GetArenaForAllocation()); +} +inline std::string* PullConfigResponse::_internal_mutable_payload() { + + return _impl_.payload_.Mutable(GetArenaForAllocation()); +} +inline std::string* PullConfigResponse::release_payload() { + // @@protoc_insertion_point(field_release:greptime.v1.meta.PullConfigResponse.payload) + return _impl_.payload_.Release(); +} +inline void PullConfigResponse::set_allocated_payload(std::string* payload) { + if (payload != nullptr) { + + } else { + + } + _impl_.payload_.SetAllocated(payload, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.payload_.IsDefault()) { + _impl_.payload_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:greptime.v1.meta.PullConfigResponse.payload) +} + +#ifdef __GNUC__ + #pragma GCC diagnostic pop +#endif // __GNUC__ +// ------------------------------------------------------------------- + + +// @@protoc_insertion_point(namespace_scope) + +} // namespace meta +} // namespace v1 +} // namespace greptime + +// @@protoc_insertion_point(global_scope) + +#include +#endif // GOOGLE_PROTOBUF_INCLUDED_GOOGLE_PROTOBUF_INCLUDED_greptime_2fv1_2fmeta_2fconfig_2eproto diff --git a/go/greptime/v1/meta/config.pb.go b/go/greptime/v1/meta/config.pb.go new file mode 100644 index 0000000..c28a21d --- /dev/null +++ b/go/greptime/v1/meta/config.pb.go @@ -0,0 +1,253 @@ +// Copyright 2023 Greptime Team +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.28.1 +// protoc v3.21.6 +// source: greptime/v1/meta/config.proto + +package meta + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type PullConfigRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Header *RequestHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` +} + +func (x *PullConfigRequest) Reset() { + *x = PullConfigRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_greptime_v1_meta_config_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PullConfigRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PullConfigRequest) ProtoMessage() {} + +func (x *PullConfigRequest) ProtoReflect() protoreflect.Message { + mi := &file_greptime_v1_meta_config_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PullConfigRequest.ProtoReflect.Descriptor instead. +func (*PullConfigRequest) Descriptor() ([]byte, []int) { + return file_greptime_v1_meta_config_proto_rawDescGZIP(), []int{0} +} + +func (x *PullConfigRequest) GetHeader() *RequestHeader { + if x != nil { + return x.Header + } + return nil +} + +type PullConfigResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Header *ResponseHeader `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"` + Payload string `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` +} + +func (x *PullConfigResponse) Reset() { + *x = PullConfigResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_greptime_v1_meta_config_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *PullConfigResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*PullConfigResponse) ProtoMessage() {} + +func (x *PullConfigResponse) ProtoReflect() protoreflect.Message { + mi := &file_greptime_v1_meta_config_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use PullConfigResponse.ProtoReflect.Descriptor instead. +func (*PullConfigResponse) Descriptor() ([]byte, []int) { + return file_greptime_v1_meta_config_proto_rawDescGZIP(), []int{1} +} + +func (x *PullConfigResponse) GetHeader() *ResponseHeader { + if x != nil { + return x.Header + } + return nil +} + +func (x *PullConfigResponse) GetPayload() string { + if x != nil { + return x.Payload + } + return "" +} + +var File_greptime_v1_meta_config_proto protoreflect.FileDescriptor + +var file_greptime_v1_meta_config_proto_rawDesc = []byte{ + 0x0a, 0x1d, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x65, + 0x74, 0x61, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, + 0x10, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x6d, 0x65, 0x74, + 0x61, 0x1a, 0x1d, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, + 0x65, 0x74, 0x61, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x22, 0x4c, 0x0a, 0x11, 0x50, 0x75, 0x6c, 0x6c, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x37, 0x0a, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x6d, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x22, 0x68, + 0x0a, 0x12, 0x50, 0x75, 0x6c, 0x6c, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x6d, 0x65, 0x74, 0x61, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x18, + 0x0a, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x32, 0x63, 0x0a, 0x06, 0x43, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x12, 0x59, 0x0a, 0x0a, 0x50, 0x75, 0x6c, 0x6c, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, + 0x12, 0x23, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x6d, + 0x65, 0x74, 0x61, 0x2e, 0x50, 0x75, 0x6c, 0x6c, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x2e, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x6d, 0x65, 0x74, 0x61, 0x2e, 0x50, 0x75, 0x6c, 0x6c, 0x43, 0x6f, 0x6e, + 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x3c, 0x5a, + 0x3a, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x47, 0x72, 0x65, 0x70, + 0x74, 0x69, 0x6d, 0x65, 0x54, 0x65, 0x61, 0x6d, 0x2f, 0x67, 0x72, 0x65, 0x70, 0x74, 0x69, 0x6d, + 0x65, 0x2d, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x2f, 0x67, 0x72, 0x65, 0x70, 0x74, + 0x69, 0x6d, 0x65, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x65, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x33, +} + +var ( + file_greptime_v1_meta_config_proto_rawDescOnce sync.Once + file_greptime_v1_meta_config_proto_rawDescData = file_greptime_v1_meta_config_proto_rawDesc +) + +func file_greptime_v1_meta_config_proto_rawDescGZIP() []byte { + file_greptime_v1_meta_config_proto_rawDescOnce.Do(func() { + file_greptime_v1_meta_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_greptime_v1_meta_config_proto_rawDescData) + }) + return file_greptime_v1_meta_config_proto_rawDescData +} + +var file_greptime_v1_meta_config_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_greptime_v1_meta_config_proto_goTypes = []interface{}{ + (*PullConfigRequest)(nil), // 0: greptime.v1.meta.PullConfigRequest + (*PullConfigResponse)(nil), // 1: greptime.v1.meta.PullConfigResponse + (*RequestHeader)(nil), // 2: greptime.v1.meta.RequestHeader + (*ResponseHeader)(nil), // 3: greptime.v1.meta.ResponseHeader +} +var file_greptime_v1_meta_config_proto_depIdxs = []int32{ + 2, // 0: greptime.v1.meta.PullConfigRequest.header:type_name -> greptime.v1.meta.RequestHeader + 3, // 1: greptime.v1.meta.PullConfigResponse.header:type_name -> greptime.v1.meta.ResponseHeader + 0, // 2: greptime.v1.meta.Config.PullConfig:input_type -> greptime.v1.meta.PullConfigRequest + 1, // 3: greptime.v1.meta.Config.PullConfig:output_type -> greptime.v1.meta.PullConfigResponse + 3, // [3:4] is the sub-list for method output_type + 2, // [2:3] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name +} + +func init() { file_greptime_v1_meta_config_proto_init() } +func file_greptime_v1_meta_config_proto_init() { + if File_greptime_v1_meta_config_proto != nil { + return + } + file_greptime_v1_meta_common_proto_init() + if !protoimpl.UnsafeEnabled { + file_greptime_v1_meta_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PullConfigRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_greptime_v1_meta_config_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*PullConfigResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_greptime_v1_meta_config_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 1, + }, + GoTypes: file_greptime_v1_meta_config_proto_goTypes, + DependencyIndexes: file_greptime_v1_meta_config_proto_depIdxs, + MessageInfos: file_greptime_v1_meta_config_proto_msgTypes, + }.Build() + File_greptime_v1_meta_config_proto = out.File + file_greptime_v1_meta_config_proto_rawDesc = nil + file_greptime_v1_meta_config_proto_goTypes = nil + file_greptime_v1_meta_config_proto_depIdxs = nil +} diff --git a/go/greptime/v1/meta/config_grpc.pb.go b/go/greptime/v1/meta/config_grpc.pb.go new file mode 100644 index 0000000..2318df1 --- /dev/null +++ b/go/greptime/v1/meta/config_grpc.pb.go @@ -0,0 +1,107 @@ +// Code generated by protoc-gen-go-grpc. DO NOT EDIT. +// versions: +// - protoc-gen-go-grpc v1.2.0 +// - protoc v3.21.6 +// source: greptime/v1/meta/config.proto + +package meta + +import ( + context "context" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" +) + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +// Requires gRPC-Go v1.32.0 or later. +const _ = grpc.SupportPackageIsVersion7 + +// ConfigClient is the client API for Config service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. +type ConfigClient interface { + // Pull configuration from meta server. + PullConfig(ctx context.Context, in *PullConfigRequest, opts ...grpc.CallOption) (*PullConfigResponse, error) +} + +type configClient struct { + cc grpc.ClientConnInterface +} + +func NewConfigClient(cc grpc.ClientConnInterface) ConfigClient { + return &configClient{cc} +} + +func (c *configClient) PullConfig(ctx context.Context, in *PullConfigRequest, opts ...grpc.CallOption) (*PullConfigResponse, error) { + out := new(PullConfigResponse) + err := c.cc.Invoke(ctx, "/greptime.v1.meta.Config/PullConfig", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// ConfigServer is the server API for Config service. +// All implementations must embed UnimplementedConfigServer +// for forward compatibility +type ConfigServer interface { + // Pull configuration from meta server. + PullConfig(context.Context, *PullConfigRequest) (*PullConfigResponse, error) + mustEmbedUnimplementedConfigServer() +} + +// UnimplementedConfigServer must be embedded to have forward compatible implementations. +type UnimplementedConfigServer struct { +} + +func (UnimplementedConfigServer) PullConfig(context.Context, *PullConfigRequest) (*PullConfigResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method PullConfig not implemented") +} +func (UnimplementedConfigServer) mustEmbedUnimplementedConfigServer() {} + +// UnsafeConfigServer may be embedded to opt out of forward compatibility for this service. +// Use of this interface is not recommended, as added methods to ConfigServer will +// result in compilation errors. +type UnsafeConfigServer interface { + mustEmbedUnimplementedConfigServer() +} + +func RegisterConfigServer(s grpc.ServiceRegistrar, srv ConfigServer) { + s.RegisterService(&Config_ServiceDesc, srv) +} + +func _Config_PullConfig_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(PullConfigRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ConfigServer).PullConfig(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/greptime.v1.meta.Config/PullConfig", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ConfigServer).PullConfig(ctx, req.(*PullConfigRequest)) + } + return interceptor(ctx, in, info, handler) +} + +// Config_ServiceDesc is the grpc.ServiceDesc for Config service. +// It's only intended for direct use with grpc.RegisterService, +// and not to be introspected or modified (even as a copy) +var Config_ServiceDesc = grpc.ServiceDesc{ + ServiceName: "greptime.v1.meta.Config", + HandlerType: (*ConfigServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "PullConfig", + Handler: _Config_PullConfig_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "greptime/v1/meta/config.proto", +} diff --git a/java/src/main/java/greptime/v1/meta/ConfigOuterClass.java b/java/src/main/java/greptime/v1/meta/ConfigOuterClass.java new file mode 100644 index 0000000..8266c0f --- /dev/null +++ b/java/src/main/java/greptime/v1/meta/ConfigOuterClass.java @@ -0,0 +1,1465 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: greptime/v1/meta/config.proto + +package greptime.v1.meta; + +public final class ConfigOuterClass { + private ConfigOuterClass() {} + public static void registerAllExtensions( + com.google.protobuf.ExtensionRegistryLite registry) { + } + + public static void registerAllExtensions( + com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions( + (com.google.protobuf.ExtensionRegistryLite) registry); + } + public interface PullConfigRequestOrBuilder extends + // @@protoc_insertion_point(interface_extends:greptime.v1.meta.PullConfigRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * .greptime.v1.meta.RequestHeader header = 1; + * @return Whether the header field is set. + */ + boolean hasHeader(); + /** + * .greptime.v1.meta.RequestHeader header = 1; + * @return The header. + */ + greptime.v1.meta.Common.RequestHeader getHeader(); + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + greptime.v1.meta.Common.RequestHeaderOrBuilder getHeaderOrBuilder(); + } + /** + * Protobuf type {@code greptime.v1.meta.PullConfigRequest} + */ + public static final class PullConfigRequest extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:greptime.v1.meta.PullConfigRequest) + PullConfigRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use PullConfigRequest.newBuilder() to construct. + private PullConfigRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private PullConfigRequest() { + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance( + UnusedPrivateParameter unused) { + return new PullConfigRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private PullConfigRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + greptime.v1.meta.Common.RequestHeader.Builder subBuilder = null; + if (header_ != null) { + subBuilder = header_.toBuilder(); + } + header_ = input.readMessage(greptime.v1.meta.Common.RequestHeader.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(header_); + header_ = subBuilder.buildPartial(); + } + + break; + } + default: { + if (!parseUnknownField( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + greptime.v1.meta.ConfigOuterClass.PullConfigRequest.class, greptime.v1.meta.ConfigOuterClass.PullConfigRequest.Builder.class); + } + + public static final int HEADER_FIELD_NUMBER = 1; + private greptime.v1.meta.Common.RequestHeader header_; + /** + * .greptime.v1.meta.RequestHeader header = 1; + * @return Whether the header field is set. + */ + @java.lang.Override + public boolean hasHeader() { + return header_ != null; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + * @return The header. + */ + @java.lang.Override + public greptime.v1.meta.Common.RequestHeader getHeader() { + return header_ == null ? greptime.v1.meta.Common.RequestHeader.getDefaultInstance() : header_; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + @java.lang.Override + public greptime.v1.meta.Common.RequestHeaderOrBuilder getHeaderOrBuilder() { + return getHeader(); + } + + private byte memoizedIsInitialized = -1; + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (header_ != null) { + output.writeMessage(1, getHeader()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (header_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getHeader()); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof greptime.v1.meta.ConfigOuterClass.PullConfigRequest)) { + return super.equals(obj); + } + greptime.v1.meta.ConfigOuterClass.PullConfigRequest other = (greptime.v1.meta.ConfigOuterClass.PullConfigRequest) obj; + + if (hasHeader() != other.hasHeader()) return false; + if (hasHeader()) { + if (!getHeader() + .equals(other.getHeader())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasHeader()) { + hash = (37 * hash) + HEADER_FIELD_NUMBER; + hash = (53 * hash) + getHeader().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + java.nio.ByteBuffer data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(greptime.v1.meta.ConfigOuterClass.PullConfigRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE + ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * Protobuf type {@code greptime.v1.meta.PullConfigRequest} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:greptime.v1.meta.PullConfigRequest) + greptime.v1.meta.ConfigOuterClass.PullConfigRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + greptime.v1.meta.ConfigOuterClass.PullConfigRequest.class, greptime.v1.meta.ConfigOuterClass.PullConfigRequest.Builder.class); + } + + // Construct using greptime.v1.meta.ConfigOuterClass.PullConfigRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + @java.lang.Override + public Builder clear() { + super.clear(); + if (headerBuilder_ == null) { + header_ = null; + } else { + header_ = null; + headerBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigRequest_descriptor; + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigRequest getDefaultInstanceForType() { + return greptime.v1.meta.ConfigOuterClass.PullConfigRequest.getDefaultInstance(); + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigRequest build() { + greptime.v1.meta.ConfigOuterClass.PullConfigRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigRequest buildPartial() { + greptime.v1.meta.ConfigOuterClass.PullConfigRequest result = new greptime.v1.meta.ConfigOuterClass.PullConfigRequest(this); + if (headerBuilder_ == null) { + result.header_ = header_; + } else { + result.header_ = headerBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return super.setField(field, value); + } + @java.lang.Override + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + @java.lang.Override + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return super.addRepeatedField(field, value); + } + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof greptime.v1.meta.ConfigOuterClass.PullConfigRequest) { + return mergeFrom((greptime.v1.meta.ConfigOuterClass.PullConfigRequest)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(greptime.v1.meta.ConfigOuterClass.PullConfigRequest other) { + if (other == greptime.v1.meta.ConfigOuterClass.PullConfigRequest.getDefaultInstance()) return this; + if (other.hasHeader()) { + mergeHeader(other.getHeader()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + greptime.v1.meta.ConfigOuterClass.PullConfigRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (greptime.v1.meta.ConfigOuterClass.PullConfigRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private greptime.v1.meta.Common.RequestHeader header_; + private com.google.protobuf.SingleFieldBuilderV3< + greptime.v1.meta.Common.RequestHeader, greptime.v1.meta.Common.RequestHeader.Builder, greptime.v1.meta.Common.RequestHeaderOrBuilder> headerBuilder_; + /** + * .greptime.v1.meta.RequestHeader header = 1; + * @return Whether the header field is set. + */ + public boolean hasHeader() { + return headerBuilder_ != null || header_ != null; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + * @return The header. + */ + public greptime.v1.meta.Common.RequestHeader getHeader() { + if (headerBuilder_ == null) { + return header_ == null ? greptime.v1.meta.Common.RequestHeader.getDefaultInstance() : header_; + } else { + return headerBuilder_.getMessage(); + } + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + public Builder setHeader(greptime.v1.meta.Common.RequestHeader value) { + if (headerBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + header_ = value; + onChanged(); + } else { + headerBuilder_.setMessage(value); + } + + return this; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + public Builder setHeader( + greptime.v1.meta.Common.RequestHeader.Builder builderForValue) { + if (headerBuilder_ == null) { + header_ = builderForValue.build(); + onChanged(); + } else { + headerBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + public Builder mergeHeader(greptime.v1.meta.Common.RequestHeader value) { + if (headerBuilder_ == null) { + if (header_ != null) { + header_ = + greptime.v1.meta.Common.RequestHeader.newBuilder(header_).mergeFrom(value).buildPartial(); + } else { + header_ = value; + } + onChanged(); + } else { + headerBuilder_.mergeFrom(value); + } + + return this; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + public Builder clearHeader() { + if (headerBuilder_ == null) { + header_ = null; + onChanged(); + } else { + header_ = null; + headerBuilder_ = null; + } + + return this; + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + public greptime.v1.meta.Common.RequestHeader.Builder getHeaderBuilder() { + + onChanged(); + return getHeaderFieldBuilder().getBuilder(); + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + public greptime.v1.meta.Common.RequestHeaderOrBuilder getHeaderOrBuilder() { + if (headerBuilder_ != null) { + return headerBuilder_.getMessageOrBuilder(); + } else { + return header_ == null ? + greptime.v1.meta.Common.RequestHeader.getDefaultInstance() : header_; + } + } + /** + * .greptime.v1.meta.RequestHeader header = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + greptime.v1.meta.Common.RequestHeader, greptime.v1.meta.Common.RequestHeader.Builder, greptime.v1.meta.Common.RequestHeaderOrBuilder> + getHeaderFieldBuilder() { + if (headerBuilder_ == null) { + headerBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + greptime.v1.meta.Common.RequestHeader, greptime.v1.meta.Common.RequestHeader.Builder, greptime.v1.meta.Common.RequestHeaderOrBuilder>( + getHeader(), + getParentForChildren(), + isClean()); + header_ = null; + } + return headerBuilder_; + } + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:greptime.v1.meta.PullConfigRequest) + } + + // @@protoc_insertion_point(class_scope:greptime.v1.meta.PullConfigRequest) + private static final greptime.v1.meta.ConfigOuterClass.PullConfigRequest DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new greptime.v1.meta.ConfigOuterClass.PullConfigRequest(); + } + + public static greptime.v1.meta.ConfigOuterClass.PullConfigRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + @java.lang.Override + public PullConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new PullConfigRequest(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + + } + + public interface PullConfigResponseOrBuilder extends + // @@protoc_insertion_point(interface_extends:greptime.v1.meta.PullConfigResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * .greptime.v1.meta.ResponseHeader header = 1; + * @return Whether the header field is set. + */ + boolean hasHeader(); + /** + * .greptime.v1.meta.ResponseHeader header = 1; + * @return The header. + */ + greptime.v1.meta.Common.ResponseHeader getHeader(); + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + greptime.v1.meta.Common.ResponseHeaderOrBuilder getHeaderOrBuilder(); + + /** + * string payload = 2; + * @return The payload. + */ + java.lang.String getPayload(); + /** + * string payload = 2; + * @return The bytes for payload. + */ + com.google.protobuf.ByteString + getPayloadBytes(); + } + /** + * Protobuf type {@code greptime.v1.meta.PullConfigResponse} + */ + public static final class PullConfigResponse extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:greptime.v1.meta.PullConfigResponse) + PullConfigResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use PullConfigResponse.newBuilder() to construct. + private PullConfigResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private PullConfigResponse() { + payload_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance( + UnusedPrivateParameter unused) { + return new PullConfigResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private PullConfigResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: { + greptime.v1.meta.Common.ResponseHeader.Builder subBuilder = null; + if (header_ != null) { + subBuilder = header_.toBuilder(); + } + header_ = input.readMessage(greptime.v1.meta.Common.ResponseHeader.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(header_); + header_ = subBuilder.buildPartial(); + } + + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + payload_ = s; + break; + } + default: { + if (!parseUnknownField( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + greptime.v1.meta.ConfigOuterClass.PullConfigResponse.class, greptime.v1.meta.ConfigOuterClass.PullConfigResponse.Builder.class); + } + + public static final int HEADER_FIELD_NUMBER = 1; + private greptime.v1.meta.Common.ResponseHeader header_; + /** + * .greptime.v1.meta.ResponseHeader header = 1; + * @return Whether the header field is set. + */ + @java.lang.Override + public boolean hasHeader() { + return header_ != null; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + * @return The header. + */ + @java.lang.Override + public greptime.v1.meta.Common.ResponseHeader getHeader() { + return header_ == null ? greptime.v1.meta.Common.ResponseHeader.getDefaultInstance() : header_; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + @java.lang.Override + public greptime.v1.meta.Common.ResponseHeaderOrBuilder getHeaderOrBuilder() { + return getHeader(); + } + + public static final int PAYLOAD_FIELD_NUMBER = 2; + private volatile java.lang.Object payload_; + /** + * string payload = 2; + * @return The payload. + */ + @java.lang.Override + public java.lang.String getPayload() { + java.lang.Object ref = payload_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + payload_ = s; + return s; + } + } + /** + * string payload = 2; + * @return The bytes for payload. + */ + @java.lang.Override + public com.google.protobuf.ByteString + getPayloadBytes() { + java.lang.Object ref = payload_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + payload_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + if (header_ != null) { + output.writeMessage(1, getHeader()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(payload_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, payload_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (header_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getHeader()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(payload_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, payload_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof greptime.v1.meta.ConfigOuterClass.PullConfigResponse)) { + return super.equals(obj); + } + greptime.v1.meta.ConfigOuterClass.PullConfigResponse other = (greptime.v1.meta.ConfigOuterClass.PullConfigResponse) obj; + + if (hasHeader() != other.hasHeader()) return false; + if (hasHeader()) { + if (!getHeader() + .equals(other.getHeader())) return false; + } + if (!getPayload() + .equals(other.getPayload())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasHeader()) { + hash = (37 * hash) + HEADER_FIELD_NUMBER; + hash = (53 * hash) + getHeader().hashCode(); + } + hash = (37 * hash) + PAYLOAD_FIELD_NUMBER; + hash = (53 * hash) + getPayload().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + java.nio.ByteBuffer data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + public static Builder newBuilder(greptime.v1.meta.ConfigOuterClass.PullConfigResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE + ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * Protobuf type {@code greptime.v1.meta.PullConfigResponse} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:greptime.v1.meta.PullConfigResponse) + greptime.v1.meta.ConfigOuterClass.PullConfigResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + greptime.v1.meta.ConfigOuterClass.PullConfigResponse.class, greptime.v1.meta.ConfigOuterClass.PullConfigResponse.Builder.class); + } + + // Construct using greptime.v1.meta.ConfigOuterClass.PullConfigResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3 + .alwaysUseFieldBuilders) { + } + } + @java.lang.Override + public Builder clear() { + super.clear(); + if (headerBuilder_ == null) { + header_ = null; + } else { + header_ = null; + headerBuilder_ = null; + } + payload_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return greptime.v1.meta.ConfigOuterClass.internal_static_greptime_v1_meta_PullConfigResponse_descriptor; + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigResponse getDefaultInstanceForType() { + return greptime.v1.meta.ConfigOuterClass.PullConfigResponse.getDefaultInstance(); + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigResponse build() { + greptime.v1.meta.ConfigOuterClass.PullConfigResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigResponse buildPartial() { + greptime.v1.meta.ConfigOuterClass.PullConfigResponse result = new greptime.v1.meta.ConfigOuterClass.PullConfigResponse(this); + if (headerBuilder_ == null) { + result.header_ = header_; + } else { + result.header_ = headerBuilder_.build(); + } + result.payload_ = payload_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return super.setField(field, value); + } + @java.lang.Override + public Builder clearField( + com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + @java.lang.Override + public Builder clearOneof( + com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + java.lang.Object value) { + return super.addRepeatedField(field, value); + } + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof greptime.v1.meta.ConfigOuterClass.PullConfigResponse) { + return mergeFrom((greptime.v1.meta.ConfigOuterClass.PullConfigResponse)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(greptime.v1.meta.ConfigOuterClass.PullConfigResponse other) { + if (other == greptime.v1.meta.ConfigOuterClass.PullConfigResponse.getDefaultInstance()) return this; + if (other.hasHeader()) { + mergeHeader(other.getHeader()); + } + if (!other.getPayload().isEmpty()) { + payload_ = other.payload_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + greptime.v1.meta.ConfigOuterClass.PullConfigResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (greptime.v1.meta.ConfigOuterClass.PullConfigResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private greptime.v1.meta.Common.ResponseHeader header_; + private com.google.protobuf.SingleFieldBuilderV3< + greptime.v1.meta.Common.ResponseHeader, greptime.v1.meta.Common.ResponseHeader.Builder, greptime.v1.meta.Common.ResponseHeaderOrBuilder> headerBuilder_; + /** + * .greptime.v1.meta.ResponseHeader header = 1; + * @return Whether the header field is set. + */ + public boolean hasHeader() { + return headerBuilder_ != null || header_ != null; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + * @return The header. + */ + public greptime.v1.meta.Common.ResponseHeader getHeader() { + if (headerBuilder_ == null) { + return header_ == null ? greptime.v1.meta.Common.ResponseHeader.getDefaultInstance() : header_; + } else { + return headerBuilder_.getMessage(); + } + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + public Builder setHeader(greptime.v1.meta.Common.ResponseHeader value) { + if (headerBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + header_ = value; + onChanged(); + } else { + headerBuilder_.setMessage(value); + } + + return this; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + public Builder setHeader( + greptime.v1.meta.Common.ResponseHeader.Builder builderForValue) { + if (headerBuilder_ == null) { + header_ = builderForValue.build(); + onChanged(); + } else { + headerBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + public Builder mergeHeader(greptime.v1.meta.Common.ResponseHeader value) { + if (headerBuilder_ == null) { + if (header_ != null) { + header_ = + greptime.v1.meta.Common.ResponseHeader.newBuilder(header_).mergeFrom(value).buildPartial(); + } else { + header_ = value; + } + onChanged(); + } else { + headerBuilder_.mergeFrom(value); + } + + return this; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + public Builder clearHeader() { + if (headerBuilder_ == null) { + header_ = null; + onChanged(); + } else { + header_ = null; + headerBuilder_ = null; + } + + return this; + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + public greptime.v1.meta.Common.ResponseHeader.Builder getHeaderBuilder() { + + onChanged(); + return getHeaderFieldBuilder().getBuilder(); + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + public greptime.v1.meta.Common.ResponseHeaderOrBuilder getHeaderOrBuilder() { + if (headerBuilder_ != null) { + return headerBuilder_.getMessageOrBuilder(); + } else { + return header_ == null ? + greptime.v1.meta.Common.ResponseHeader.getDefaultInstance() : header_; + } + } + /** + * .greptime.v1.meta.ResponseHeader header = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + greptime.v1.meta.Common.ResponseHeader, greptime.v1.meta.Common.ResponseHeader.Builder, greptime.v1.meta.Common.ResponseHeaderOrBuilder> + getHeaderFieldBuilder() { + if (headerBuilder_ == null) { + headerBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + greptime.v1.meta.Common.ResponseHeader, greptime.v1.meta.Common.ResponseHeader.Builder, greptime.v1.meta.Common.ResponseHeaderOrBuilder>( + getHeader(), + getParentForChildren(), + isClean()); + header_ = null; + } + return headerBuilder_; + } + + private java.lang.Object payload_ = ""; + /** + * string payload = 2; + * @return The payload. + */ + public java.lang.String getPayload() { + java.lang.Object ref = payload_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + payload_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * string payload = 2; + * @return The bytes for payload. + */ + public com.google.protobuf.ByteString + getPayloadBytes() { + java.lang.Object ref = payload_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + payload_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * string payload = 2; + * @param value The payload to set. + * @return This builder for chaining. + */ + public Builder setPayload( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + payload_ = value; + onChanged(); + return this; + } + /** + * string payload = 2; + * @return This builder for chaining. + */ + public Builder clearPayload() { + + payload_ = getDefaultInstance().getPayload(); + onChanged(); + return this; + } + /** + * string payload = 2; + * @param value The bytes for payload to set. + * @return This builder for chaining. + */ + public Builder setPayloadBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + payload_ = value; + onChanged(); + return this; + } + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + + // @@protoc_insertion_point(builder_scope:greptime.v1.meta.PullConfigResponse) + } + + // @@protoc_insertion_point(class_scope:greptime.v1.meta.PullConfigResponse) + private static final greptime.v1.meta.ConfigOuterClass.PullConfigResponse DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new greptime.v1.meta.ConfigOuterClass.PullConfigResponse(); + } + + public static greptime.v1.meta.ConfigOuterClass.PullConfigResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + @java.lang.Override + public PullConfigResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new PullConfigResponse(input, extensionRegistry); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public greptime.v1.meta.ConfigOuterClass.PullConfigResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + + } + + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_greptime_v1_meta_PullConfigRequest_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_greptime_v1_meta_PullConfigRequest_fieldAccessorTable; + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_greptime_v1_meta_PullConfigResponse_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_greptime_v1_meta_PullConfigResponse_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor + getDescriptor() { + return descriptor; + } + private static com.google.protobuf.Descriptors.FileDescriptor + descriptor; + static { + java.lang.String[] descriptorData = { + "\n\035greptime/v1/meta/config.proto\022\020greptim" + + "e.v1.meta\032\035greptime/v1/meta/common.proto" + + "\"D\n\021PullConfigRequest\022/\n\006header\030\001 \001(\0132\037." + + "greptime.v1.meta.RequestHeader\"W\n\022PullCo" + + "nfigResponse\0220\n\006header\030\001 \001(\0132 .greptime." + + "v1.meta.ResponseHeader\022\017\n\007payload\030\002 \001(\t2" + + "c\n\006Config\022Y\n\nPullConfig\022#.greptime.v1.me" + + "ta.PullConfigRequest\032$.greptime.v1.meta." + + "PullConfigResponse\"\000B