From 9cfde7e5422b34c942522c2e0b3bbbb0dc2a47a7 Mon Sep 17 00:00:00 2001 From: Chao-Han Tsai Date: Wed, 14 Apr 2021 16:15:42 -0700 Subject: [PATCH] add generated code --- .../go/datacatalog/mocks/DataCatalogClient.go | 48 + .../datacatalog/datacatalog.grpc.pb.cc | 42 + .../datacatalog/datacatalog.grpc.pb.h | 184 +- .../flyteidl/datacatalog/datacatalog.pb.cc | 1403 +++++++++-- .../flyteidl/datacatalog/datacatalog.pb.h | 555 +++- .../flyteidl/datacatalog/datacatalog.pb.go | 392 ++- .../datacatalog/datacatalog.pb.validate.go | 170 ++ gen/pb-java/datacatalog/Datacatalog.java | 2236 +++++++++++++++-- .../datacatalog/datacatalog.proto.rst | 142 +- .../flyteidl/datacatalog/datacatalog_pb2.py | 221 +- .../datacatalog/datacatalog_pb2_grpc.py | 21 + 11 files changed, 4714 insertions(+), 700 deletions(-) diff --git a/clients/go/datacatalog/mocks/DataCatalogClient.go b/clients/go/datacatalog/mocks/DataCatalogClient.go index 972497a2f..77d386f58 100644 --- a/clients/go/datacatalog/mocks/DataCatalogClient.go +++ b/clients/go/datacatalog/mocks/DataCatalogClient.go @@ -256,6 +256,54 @@ func (_m *DataCatalogClient) GetDataset(ctx context.Context, in *datacatalog.Get return r0, r1 } +type DataCatalogClient_GetOrReserveArtifact struct { + *mock.Call +} + +func (_m DataCatalogClient_GetOrReserveArtifact) Return(_a0 *datacatalog.GetOrReserveArtifactResponse, _a1 error) *DataCatalogClient_GetOrReserveArtifact { + return &DataCatalogClient_GetOrReserveArtifact{Call: _m.Call.Return(_a0, _a1)} +} + +func (_m *DataCatalogClient) OnGetOrReserveArtifact(ctx context.Context, in *datacatalog.GetOrReserveArtifactRequest, opts ...grpc.CallOption) *DataCatalogClient_GetOrReserveArtifact { + c := _m.On("GetOrReserveArtifact", ctx, in, opts) + return &DataCatalogClient_GetOrReserveArtifact{Call: c} +} + +func (_m *DataCatalogClient) OnGetOrReserveArtifactMatch(matchers ...interface{}) *DataCatalogClient_GetOrReserveArtifact { + c := _m.On("GetOrReserveArtifact", matchers...) + return &DataCatalogClient_GetOrReserveArtifact{Call: c} +} + +// GetOrReserveArtifact provides a mock function with given fields: ctx, in, opts +func (_m *DataCatalogClient) GetOrReserveArtifact(ctx context.Context, in *datacatalog.GetOrReserveArtifactRequest, opts ...grpc.CallOption) (*datacatalog.GetOrReserveArtifactResponse, error) { + _va := make([]interface{}, len(opts)) + for _i := range opts { + _va[_i] = opts[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, in) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 *datacatalog.GetOrReserveArtifactResponse + if rf, ok := ret.Get(0).(func(context.Context, *datacatalog.GetOrReserveArtifactRequest, ...grpc.CallOption) *datacatalog.GetOrReserveArtifactResponse); ok { + r0 = rf(ctx, in, opts...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*datacatalog.GetOrReserveArtifactResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *datacatalog.GetOrReserveArtifactRequest, ...grpc.CallOption) error); ok { + r1 = rf(ctx, in, opts...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + type DataCatalogClient_ListArtifacts struct { *mock.Call } diff --git a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.cc b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.cc index d6c615aed..dff95c3d5 100644 --- a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.cc +++ b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.cc @@ -26,6 +26,7 @@ static const char* DataCatalog_method_names[] = { "/datacatalog.DataCatalog/AddTag", "/datacatalog.DataCatalog/ListArtifacts", "/datacatalog.DataCatalog/ListDatasets", + "/datacatalog.DataCatalog/GetOrReserveArtifact", }; std::unique_ptr< DataCatalog::Stub> DataCatalog::NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options) { @@ -42,6 +43,7 @@ DataCatalog::Stub::Stub(const std::shared_ptr< ::grpc::ChannelInterface>& channe , rpcmethod_AddTag_(DataCatalog_method_names[4], ::grpc::internal::RpcMethod::NORMAL_RPC, channel) , rpcmethod_ListArtifacts_(DataCatalog_method_names[5], ::grpc::internal::RpcMethod::NORMAL_RPC, channel) , rpcmethod_ListDatasets_(DataCatalog_method_names[6], ::grpc::internal::RpcMethod::NORMAL_RPC, channel) + , rpcmethod_GetOrReserveArtifact_(DataCatalog_method_names[7], ::grpc::internal::RpcMethod::NORMAL_RPC, channel) {} ::grpc::Status DataCatalog::Stub::CreateDataset(::grpc::ClientContext* context, const ::datacatalog::CreateDatasetRequest& request, ::datacatalog::CreateDatasetResponse* response) { @@ -240,6 +242,34 @@ ::grpc::ClientAsyncResponseReader< ::datacatalog::ListDatasetsResponse>* DataCat return ::grpc::internal::ClientAsyncResponseReaderFactory< ::datacatalog::ListDatasetsResponse>::Create(channel_.get(), cq, rpcmethod_ListDatasets_, context, request, false); } +::grpc::Status DataCatalog::Stub::GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::datacatalog::GetOrReserveArtifactResponse* response) { + return ::grpc::internal::BlockingUnaryCall(channel_.get(), rpcmethod_GetOrReserveArtifact_, context, request, response); +} + +void DataCatalog::Stub::experimental_async::GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, std::function f) { + ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_GetOrReserveArtifact_, context, request, response, std::move(f)); +} + +void DataCatalog::Stub::experimental_async::GetOrReserveArtifact(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::GetOrReserveArtifactResponse* response, std::function f) { + ::grpc::internal::CallbackUnaryCall(stub_->channel_.get(), stub_->rpcmethod_GetOrReserveArtifact_, context, request, response, std::move(f)); +} + +void DataCatalog::Stub::experimental_async::GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) { + ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_GetOrReserveArtifact_, context, request, response, reactor); +} + +void DataCatalog::Stub::experimental_async::GetOrReserveArtifact(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) { + ::grpc::internal::ClientCallbackUnaryFactory::Create(stub_->channel_.get(), stub_->rpcmethod_GetOrReserveArtifact_, context, request, response, reactor); +} + +::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>* DataCatalog::Stub::AsyncGetOrReserveArtifactRaw(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) { + return ::grpc::internal::ClientAsyncResponseReaderFactory< ::datacatalog::GetOrReserveArtifactResponse>::Create(channel_.get(), cq, rpcmethod_GetOrReserveArtifact_, context, request, true); +} + +::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>* DataCatalog::Stub::PrepareAsyncGetOrReserveArtifactRaw(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) { + return ::grpc::internal::ClientAsyncResponseReaderFactory< ::datacatalog::GetOrReserveArtifactResponse>::Create(channel_.get(), cq, rpcmethod_GetOrReserveArtifact_, context, request, false); +} + DataCatalog::Service::Service() { AddMethod(new ::grpc::internal::RpcServiceMethod( DataCatalog_method_names[0], @@ -276,6 +306,11 @@ DataCatalog::Service::Service() { ::grpc::internal::RpcMethod::NORMAL_RPC, new ::grpc::internal::RpcMethodHandler< DataCatalog::Service, ::datacatalog::ListDatasetsRequest, ::datacatalog::ListDatasetsResponse>( std::mem_fn(&DataCatalog::Service::ListDatasets), this))); + AddMethod(new ::grpc::internal::RpcServiceMethod( + DataCatalog_method_names[7], + ::grpc::internal::RpcMethod::NORMAL_RPC, + new ::grpc::internal::RpcMethodHandler< DataCatalog::Service, ::datacatalog::GetOrReserveArtifactRequest, ::datacatalog::GetOrReserveArtifactResponse>( + std::mem_fn(&DataCatalog::Service::GetOrReserveArtifact), this))); } DataCatalog::Service::~Service() { @@ -330,6 +365,13 @@ ::grpc::Status DataCatalog::Service::ListDatasets(::grpc::ServerContext* context return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); } +::grpc::Status DataCatalog::Service::GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) { + (void) context; + (void) request; + (void) response; + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); +} + } // namespace datacatalog diff --git a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.h b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.h index 354b924e3..cffef1a35 100644 --- a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.h +++ b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.grpc.pb.h @@ -109,6 +109,18 @@ class DataCatalog final { std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::ListDatasetsResponse>> PrepareAsyncListDatasets(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest& request, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::ListDatasetsResponse>>(PrepareAsyncListDatasetsRaw(context, request, cq)); } + // Get an artifact and the corresponding data. If the artifact does not exist, + // try to reserve a spot for populating the artifact. We may have multiple + // concurrent tasks with the same signature and the same input that try to populate + // the same artifact at the same time. Thus with reservation, only one task + // can run at a time. + virtual ::grpc::Status GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::datacatalog::GetOrReserveArtifactResponse* response) = 0; + std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::GetOrReserveArtifactResponse>> AsyncGetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::GetOrReserveArtifactResponse>>(AsyncGetOrReserveArtifactRaw(context, request, cq)); + } + std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::GetOrReserveArtifactResponse>> PrepareAsyncGetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::GetOrReserveArtifactResponse>>(PrepareAsyncGetOrReserveArtifactRaw(context, request, cq)); + } class experimental_async_interface { public: virtual ~experimental_async_interface() {} @@ -149,6 +161,15 @@ class DataCatalog final { virtual void ListDatasets(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::ListDatasetsResponse* response, std::function) = 0; virtual void ListDatasets(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest* request, ::datacatalog::ListDatasetsResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0; virtual void ListDatasets(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::ListDatasetsResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0; + // Get an artifact and the corresponding data. If the artifact does not exist, + // try to reserve a spot for populating the artifact. We may have multiple + // concurrent tasks with the same signature and the same input that try to populate + // the same artifact at the same time. Thus with reservation, only one task + // can run at a time. + virtual void GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, std::function) = 0; + virtual void GetOrReserveArtifact(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::GetOrReserveArtifactResponse* response, std::function) = 0; + virtual void GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0; + virtual void GetOrReserveArtifact(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) = 0; }; virtual class experimental_async_interface* experimental_async() { return nullptr; } private: @@ -166,6 +187,8 @@ class DataCatalog final { virtual ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::ListArtifactsResponse>* PrepareAsyncListArtifactsRaw(::grpc::ClientContext* context, const ::datacatalog::ListArtifactsRequest& request, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::ListDatasetsResponse>* AsyncListDatasetsRaw(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest& request, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::ListDatasetsResponse>* PrepareAsyncListDatasetsRaw(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest& request, ::grpc::CompletionQueue* cq) = 0; + virtual ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::GetOrReserveArtifactResponse>* AsyncGetOrReserveArtifactRaw(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) = 0; + virtual ::grpc::ClientAsyncResponseReaderInterface< ::datacatalog::GetOrReserveArtifactResponse>* PrepareAsyncGetOrReserveArtifactRaw(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) = 0; }; class Stub final : public StubInterface { public: @@ -219,6 +242,13 @@ class DataCatalog final { std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::datacatalog::ListDatasetsResponse>> PrepareAsyncListDatasets(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest& request, ::grpc::CompletionQueue* cq) { return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::datacatalog::ListDatasetsResponse>>(PrepareAsyncListDatasetsRaw(context, request, cq)); } + ::grpc::Status GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::datacatalog::GetOrReserveArtifactResponse* response) override; + std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>> AsyncGetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>>(AsyncGetOrReserveArtifactRaw(context, request, cq)); + } + std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>> PrepareAsyncGetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) { + return std::unique_ptr< ::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>>(PrepareAsyncGetOrReserveArtifactRaw(context, request, cq)); + } class experimental_async final : public StubInterface::experimental_async_interface { public: @@ -250,6 +280,10 @@ class DataCatalog final { void ListDatasets(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::ListDatasetsResponse* response, std::function) override; void ListDatasets(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest* request, ::datacatalog::ListDatasetsResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override; void ListDatasets(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::ListDatasetsResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override; + void GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, std::function) override; + void GetOrReserveArtifact(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::GetOrReserveArtifactResponse* response, std::function) override; + void GetOrReserveArtifact(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override; + void GetOrReserveArtifact(::grpc::ClientContext* context, const ::grpc::ByteBuffer* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ClientUnaryReactor* reactor) override; private: friend class Stub; explicit experimental_async(Stub* stub): stub_(stub) { } @@ -275,6 +309,8 @@ class DataCatalog final { ::grpc::ClientAsyncResponseReader< ::datacatalog::ListArtifactsResponse>* PrepareAsyncListArtifactsRaw(::grpc::ClientContext* context, const ::datacatalog::ListArtifactsRequest& request, ::grpc::CompletionQueue* cq) override; ::grpc::ClientAsyncResponseReader< ::datacatalog::ListDatasetsResponse>* AsyncListDatasetsRaw(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest& request, ::grpc::CompletionQueue* cq) override; ::grpc::ClientAsyncResponseReader< ::datacatalog::ListDatasetsResponse>* PrepareAsyncListDatasetsRaw(::grpc::ClientContext* context, const ::datacatalog::ListDatasetsRequest& request, ::grpc::CompletionQueue* cq) override; + ::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>* AsyncGetOrReserveArtifactRaw(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) override; + ::grpc::ClientAsyncResponseReader< ::datacatalog::GetOrReserveArtifactResponse>* PrepareAsyncGetOrReserveArtifactRaw(::grpc::ClientContext* context, const ::datacatalog::GetOrReserveArtifactRequest& request, ::grpc::CompletionQueue* cq) override; const ::grpc::internal::RpcMethod rpcmethod_CreateDataset_; const ::grpc::internal::RpcMethod rpcmethod_GetDataset_; const ::grpc::internal::RpcMethod rpcmethod_CreateArtifact_; @@ -282,6 +318,7 @@ class DataCatalog final { const ::grpc::internal::RpcMethod rpcmethod_AddTag_; const ::grpc::internal::RpcMethod rpcmethod_ListArtifacts_; const ::grpc::internal::RpcMethod rpcmethod_ListDatasets_; + const ::grpc::internal::RpcMethod rpcmethod_GetOrReserveArtifact_; }; static std::unique_ptr NewStub(const std::shared_ptr< ::grpc::ChannelInterface>& channel, const ::grpc::StubOptions& options = ::grpc::StubOptions()); @@ -305,6 +342,12 @@ class DataCatalog final { virtual ::grpc::Status ListArtifacts(::grpc::ServerContext* context, const ::datacatalog::ListArtifactsRequest* request, ::datacatalog::ListArtifactsResponse* response); // Return a paginated list of datasets virtual ::grpc::Status ListDatasets(::grpc::ServerContext* context, const ::datacatalog::ListDatasetsRequest* request, ::datacatalog::ListDatasetsResponse* response); + // Get an artifact and the corresponding data. If the artifact does not exist, + // try to reserve a spot for populating the artifact. We may have multiple + // concurrent tasks with the same signature and the same input that try to populate + // the same artifact at the same time. Thus with reservation, only one task + // can run at a time. + virtual ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response); }; template class WithAsyncMethod_CreateDataset : public BaseClass { @@ -446,7 +489,27 @@ class DataCatalog final { ::grpc::Service::RequestAsyncUnary(6, context, request, response, new_call_cq, notification_cq, tag); } }; - typedef WithAsyncMethod_CreateDataset > > > > > > AsyncService; + template + class WithAsyncMethod_GetOrReserveArtifact : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service *service) {} + public: + WithAsyncMethod_GetOrReserveArtifact() { + ::grpc::Service::MarkMethodAsync(7); + } + ~WithAsyncMethod_GetOrReserveArtifact() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + void RequestGetOrReserveArtifact(::grpc::ServerContext* context, ::datacatalog::GetOrReserveArtifactRequest* request, ::grpc::ServerAsyncResponseWriter< ::datacatalog::GetOrReserveArtifactResponse>* response, ::grpc::CompletionQueue* new_call_cq, ::grpc::ServerCompletionQueue* notification_cq, void *tag) { + ::grpc::Service::RequestAsyncUnary(7, context, request, response, new_call_cq, notification_cq, tag); + } + }; + typedef WithAsyncMethod_CreateDataset > > > > > > > AsyncService; template class ExperimentalWithCallbackMethod_CreateDataset : public BaseClass { private: @@ -664,7 +727,38 @@ class DataCatalog final { } virtual void ListDatasets(::grpc::ServerContext* context, const ::datacatalog::ListDatasetsRequest* request, ::datacatalog::ListDatasetsResponse* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); } }; - typedef ExperimentalWithCallbackMethod_CreateDataset > > > > > > ExperimentalCallbackService; + template + class ExperimentalWithCallbackMethod_GetOrReserveArtifact : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service *service) {} + public: + ExperimentalWithCallbackMethod_GetOrReserveArtifact() { + ::grpc::Service::experimental().MarkMethodCallback(7, + new ::grpc::internal::CallbackUnaryHandler< ::datacatalog::GetOrReserveArtifactRequest, ::datacatalog::GetOrReserveArtifactResponse>( + [this](::grpc::ServerContext* context, + const ::datacatalog::GetOrReserveArtifactRequest* request, + ::datacatalog::GetOrReserveArtifactResponse* response, + ::grpc::experimental::ServerCallbackRpcController* controller) { + return this->GetOrReserveArtifact(context, request, response, controller); + })); + } + void SetMessageAllocatorFor_GetOrReserveArtifact( + ::grpc::experimental::MessageAllocator< ::datacatalog::GetOrReserveArtifactRequest, ::datacatalog::GetOrReserveArtifactResponse>* allocator) { + static_cast<::grpc::internal::CallbackUnaryHandler< ::datacatalog::GetOrReserveArtifactRequest, ::datacatalog::GetOrReserveArtifactResponse>*>( + ::grpc::Service::experimental().GetHandler(7)) + ->SetMessageAllocator(allocator); + } + ~ExperimentalWithCallbackMethod_GetOrReserveArtifact() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + virtual void GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); } + }; + typedef ExperimentalWithCallbackMethod_CreateDataset > > > > > > > ExperimentalCallbackService; template class WithGenericMethod_CreateDataset : public BaseClass { private: @@ -785,6 +879,23 @@ class DataCatalog final { } }; template + class WithGenericMethod_GetOrReserveArtifact : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service *service) {} + public: + WithGenericMethod_GetOrReserveArtifact() { + ::grpc::Service::MarkMethodGeneric(7); + } + ~WithGenericMethod_GetOrReserveArtifact() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + }; + template class WithRawMethod_CreateDataset : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service *service) {} @@ -925,6 +1036,26 @@ class DataCatalog final { } }; template + class WithRawMethod_GetOrReserveArtifact : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service *service) {} + public: + WithRawMethod_GetOrReserveArtifact() { + ::grpc::Service::MarkMethodRaw(7); + } + ~WithRawMethod_GetOrReserveArtifact() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + void RequestGetOrReserveArtifact(::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(7, context, request, response, new_call_cq, notification_cq, tag); + } + }; + template class ExperimentalWithRawCallbackMethod_CreateDataset : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service *service) {} @@ -1100,6 +1231,31 @@ class DataCatalog final { virtual void ListDatasets(::grpc::ServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); } }; template + class ExperimentalWithRawCallbackMethod_GetOrReserveArtifact : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service *service) {} + public: + ExperimentalWithRawCallbackMethod_GetOrReserveArtifact() { + ::grpc::Service::experimental().MarkMethodRawCallback(7, + new ::grpc::internal::CallbackUnaryHandler< ::grpc::ByteBuffer, ::grpc::ByteBuffer>( + [this](::grpc::ServerContext* context, + const ::grpc::ByteBuffer* request, + ::grpc::ByteBuffer* response, + ::grpc::experimental::ServerCallbackRpcController* controller) { + this->GetOrReserveArtifact(context, request, response, controller); + })); + } + ~ExperimentalWithRawCallbackMethod_GetOrReserveArtifact() override { + BaseClassMustBeDerivedFromService(this); + } + // disable synchronous version of this method + ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + virtual void GetOrReserveArtifact(::grpc::ServerContext* context, const ::grpc::ByteBuffer* request, ::grpc::ByteBuffer* response, ::grpc::experimental::ServerCallbackRpcController* controller) { controller->Finish(::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, "")); } + }; + template class WithStreamedUnaryMethod_CreateDataset : public BaseClass { private: void BaseClassMustBeDerivedFromService(const Service *service) {} @@ -1239,9 +1395,29 @@ class DataCatalog final { // replace default version of method with streamed unary virtual ::grpc::Status StreamedListDatasets(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::datacatalog::ListDatasetsRequest,::datacatalog::ListDatasetsResponse>* server_unary_streamer) = 0; }; - typedef WithStreamedUnaryMethod_CreateDataset > > > > > > StreamedUnaryService; + template + class WithStreamedUnaryMethod_GetOrReserveArtifact : public BaseClass { + private: + void BaseClassMustBeDerivedFromService(const Service *service) {} + public: + WithStreamedUnaryMethod_GetOrReserveArtifact() { + ::grpc::Service::MarkMethodStreamed(7, + new ::grpc::internal::StreamedUnaryHandler< ::datacatalog::GetOrReserveArtifactRequest, ::datacatalog::GetOrReserveArtifactResponse>(std::bind(&WithStreamedUnaryMethod_GetOrReserveArtifact::StreamedGetOrReserveArtifact, this, std::placeholders::_1, std::placeholders::_2))); + } + ~WithStreamedUnaryMethod_GetOrReserveArtifact() override { + BaseClassMustBeDerivedFromService(this); + } + // disable regular version of this method + ::grpc::Status GetOrReserveArtifact(::grpc::ServerContext* context, const ::datacatalog::GetOrReserveArtifactRequest* request, ::datacatalog::GetOrReserveArtifactResponse* response) override { + abort(); + return ::grpc::Status(::grpc::StatusCode::UNIMPLEMENTED, ""); + } + // replace default version of method with streamed unary + virtual ::grpc::Status StreamedGetOrReserveArtifact(::grpc::ServerContext* context, ::grpc::ServerUnaryStreamer< ::datacatalog::GetOrReserveArtifactRequest,::datacatalog::GetOrReserveArtifactResponse>* server_unary_streamer) = 0; + }; + typedef WithStreamedUnaryMethod_CreateDataset > > > > > > > StreamedUnaryService; typedef Service SplitStreamedService; - typedef WithStreamedUnaryMethod_CreateDataset > > > > > > StreamedService; + typedef WithStreamedUnaryMethod_CreateDataset > > > > > > > StreamedService; }; } // namespace datacatalog diff --git a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.cc b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.cc index b0c37cc9f..caf172837 100644 --- a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.cc +++ b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.cc @@ -93,6 +93,14 @@ class ListDatasetsResponseDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; } _ListDatasetsResponse_default_instance_; +class GetOrReserveArtifactRequestDefaultTypeInternal { + public: + ::google::protobuf::internal::ExplicitlyConstructed _instance; +} _GetOrReserveArtifactRequest_default_instance_; +class GetOrReserveArtifactResponseDefaultTypeInternal { + public: + ::google::protobuf::internal::ExplicitlyConstructed _instance; +} _GetOrReserveArtifactResponse_default_instance_; class DatasetDefaultTypeInternal { public: ::google::protobuf::internal::ExplicitlyConstructed _instance; @@ -379,6 +387,37 @@ ::google::protobuf::internal::SCCInfo<1> scc_info_ListDatasetsResponse_flyteidl_ {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsListDatasetsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto}, { &scc_info_Dataset_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base,}}; +static void InitDefaultsGetOrReserveArtifactRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto() { + GOOGLE_PROTOBUF_VERIFY_VERSION; + + { + void* ptr = &::datacatalog::_GetOrReserveArtifactRequest_default_instance_; + new (ptr) ::datacatalog::GetOrReserveArtifactRequest(); + ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); + } + ::datacatalog::GetOrReserveArtifactRequest::InitAsDefaultInstance(); +} + +::google::protobuf::internal::SCCInfo<2> scc_info_GetOrReserveArtifactRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto = + {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 2, InitDefaultsGetOrReserveArtifactRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto}, { + &scc_info_DatasetID_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base, + &scc_info_Timestamp_google_2fprotobuf_2ftimestamp_2eproto.base,}}; + +static void InitDefaultsGetOrReserveArtifactResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto() { + GOOGLE_PROTOBUF_VERIFY_VERSION; + + { + void* ptr = &::datacatalog::_GetOrReserveArtifactResponse_default_instance_; + new (ptr) ::datacatalog::GetOrReserveArtifactResponse(); + ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); + } + ::datacatalog::GetOrReserveArtifactResponse::InitAsDefaultInstance(); +} + +::google::protobuf::internal::SCCInfo<1> scc_info_GetOrReserveArtifactResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto = + {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsGetOrReserveArtifactResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto}, { + &scc_info_Artifact_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base,}}; + static void InitDefaultsDataset_flyteidl_2fdatacatalog_2fdatacatalog_2eproto() { GOOGLE_PROTOBUF_VERIFY_VERSION; @@ -634,6 +673,8 @@ void InitDefaults_flyteidl_2fdatacatalog_2fdatacatalog_2eproto() { ::google::protobuf::internal::InitSCC(&scc_info_ListArtifactsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); ::google::protobuf::internal::InitSCC(&scc_info_ListDatasetsRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); ::google::protobuf::internal::InitSCC(&scc_info_ListDatasetsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + ::google::protobuf::internal::InitSCC(&scc_info_GetOrReserveArtifactRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + ::google::protobuf::internal::InitSCC(&scc_info_GetOrReserveArtifactResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); ::google::protobuf::internal::InitSCC(&scc_info_Dataset_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); ::google::protobuf::internal::InitSCC(&scc_info_Partition_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); ::google::protobuf::internal::InitSCC(&scc_info_DatasetID_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); @@ -652,8 +693,8 @@ void InitDefaults_flyteidl_2fdatacatalog_2fdatacatalog_2eproto() { ::google::protobuf::internal::InitSCC(&scc_info_PaginationOptions_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); } -::google::protobuf::Metadata file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[30]; -const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[3]; +::google::protobuf::Metadata file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[32]; +const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[4]; constexpr ::google::protobuf::ServiceDescriptor const** file_level_service_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto = nullptr; const ::google::protobuf::uint32 TableStruct_flyteidl_2fdatacatalog_2fdatacatalog_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { @@ -747,6 +788,21 @@ const ::google::protobuf::uint32 TableStruct_flyteidl_2fdatacatalog_2fdatacatalo PROTOBUF_FIELD_OFFSET(::datacatalog::ListDatasetsResponse, datasets_), PROTOBUF_FIELD_OFFSET(::datacatalog::ListDatasetsResponse, next_token_), ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactRequest, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactRequest, dataset_id_), + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactRequest, tag_name_), + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactRequest, expire_at_), + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactResponse, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactResponse, artifact_), + PROTOBUF_FIELD_OFFSET(::datacatalog::GetOrReserveArtifactResponse, reservation_status_), + ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::datacatalog::Dataset, _internal_metadata_), ~0u, // no _extensions_ ~0u, // no _oneof_case_ @@ -893,22 +949,24 @@ static const ::google::protobuf::internal::MigrationSchema schemas[] PROTOBUF_SE { 68, -1, sizeof(::datacatalog::ListArtifactsResponse)}, { 75, -1, sizeof(::datacatalog::ListDatasetsRequest)}, { 82, -1, sizeof(::datacatalog::ListDatasetsResponse)}, - { 89, -1, sizeof(::datacatalog::Dataset)}, - { 97, -1, sizeof(::datacatalog::Partition)}, - { 104, -1, sizeof(::datacatalog::DatasetID)}, - { 114, -1, sizeof(::datacatalog::Artifact)}, - { 126, -1, sizeof(::datacatalog::ArtifactData)}, - { 133, -1, sizeof(::datacatalog::Tag)}, - { 141, 148, sizeof(::datacatalog::Metadata_KeyMapEntry_DoNotUse)}, - { 150, -1, sizeof(::datacatalog::Metadata)}, - { 156, -1, sizeof(::datacatalog::FilterExpression)}, - { 162, -1, sizeof(::datacatalog::SinglePropertyFilter)}, - { 173, -1, sizeof(::datacatalog::ArtifactPropertyFilter)}, - { 180, -1, sizeof(::datacatalog::TagPropertyFilter)}, - { 187, -1, sizeof(::datacatalog::PartitionPropertyFilter)}, - { 194, -1, sizeof(::datacatalog::KeyValuePair)}, - { 201, -1, sizeof(::datacatalog::DatasetPropertyFilter)}, - { 211, -1, sizeof(::datacatalog::PaginationOptions)}, + { 89, -1, sizeof(::datacatalog::GetOrReserveArtifactRequest)}, + { 97, -1, sizeof(::datacatalog::GetOrReserveArtifactResponse)}, + { 104, -1, sizeof(::datacatalog::Dataset)}, + { 112, -1, sizeof(::datacatalog::Partition)}, + { 119, -1, sizeof(::datacatalog::DatasetID)}, + { 129, -1, sizeof(::datacatalog::Artifact)}, + { 141, -1, sizeof(::datacatalog::ArtifactData)}, + { 148, -1, sizeof(::datacatalog::Tag)}, + { 156, 163, sizeof(::datacatalog::Metadata_KeyMapEntry_DoNotUse)}, + { 165, -1, sizeof(::datacatalog::Metadata)}, + { 171, -1, sizeof(::datacatalog::FilterExpression)}, + { 177, -1, sizeof(::datacatalog::SinglePropertyFilter)}, + { 188, -1, sizeof(::datacatalog::ArtifactPropertyFilter)}, + { 195, -1, sizeof(::datacatalog::TagPropertyFilter)}, + { 202, -1, sizeof(::datacatalog::PartitionPropertyFilter)}, + { 209, -1, sizeof(::datacatalog::KeyValuePair)}, + { 216, -1, sizeof(::datacatalog::DatasetPropertyFilter)}, + { 226, -1, sizeof(::datacatalog::PaginationOptions)}, }; static ::google::protobuf::Message const * const file_default_instances[] = { @@ -926,6 +984,8 @@ static ::google::protobuf::Message const * const file_default_instances[] = { reinterpret_cast(&::datacatalog::_ListArtifactsResponse_default_instance_), reinterpret_cast(&::datacatalog::_ListDatasetsRequest_default_instance_), reinterpret_cast(&::datacatalog::_ListDatasetsResponse_default_instance_), + reinterpret_cast(&::datacatalog::_GetOrReserveArtifactRequest_default_instance_), + reinterpret_cast(&::datacatalog::_GetOrReserveArtifactResponse_default_instance_), reinterpret_cast(&::datacatalog::_Dataset_default_instance_), reinterpret_cast(&::datacatalog::_Partition_default_instance_), reinterpret_cast(&::datacatalog::_DatasetID_default_instance_), @@ -947,7 +1007,7 @@ static ::google::protobuf::Message const * const file_default_instances[] = { ::google::protobuf::internal::AssignDescriptorsTable assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto = { {}, AddDescriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, "flyteidl/datacatalog/datacatalog.proto", schemas, file_default_instances, TableStruct_flyteidl_2fdatacatalog_2fdatacatalog_2eproto::offsets, - file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, 30, file_level_enum_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, file_level_service_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, + file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, 32, file_level_enum_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, file_level_service_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, }; const char descriptor_table_protodef_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[] = @@ -979,73 +1039,84 @@ const char descriptor_table_protodef_flyteidl_2fdatacatalog_2fdatacatalog_2eprot "ination\030\002 \001(\0132\036.datacatalog.PaginationOp" "tions\"R\n\024ListDatasetsResponse\022&\n\010dataset" "s\030\001 \003(\0132\024.datacatalog.Dataset\022\022\n\nnext_to" - "ken\030\002 \001(\t\"m\n\007Dataset\022\"\n\002id\030\001 \001(\0132\026.datac" - "atalog.DatasetID\022\'\n\010metadata\030\002 \001(\0132\025.dat" - "acatalog.Metadata\022\025\n\rpartitionKeys\030\003 \003(\t" - "\"\'\n\tPartition\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" - "\t\"Y\n\tDatasetID\022\017\n\007project\030\001 \001(\t\022\014\n\004name\030" - "\002 \001(\t\022\016\n\006domain\030\003 \001(\t\022\017\n\007version\030\004 \001(\t\022\014" - "\n\004UUID\030\005 \001(\t\"\215\002\n\010Artifact\022\n\n\002id\030\001 \001(\t\022\'\n" - "\007dataset\030\002 \001(\0132\026.datacatalog.DatasetID\022\'" - "\n\004data\030\003 \003(\0132\031.datacatalog.ArtifactData\022" - "\'\n\010metadata\030\004 \001(\0132\025.datacatalog.Metadata" - "\022*\n\npartitions\030\005 \003(\0132\026.datacatalog.Parti" - "tion\022\036\n\004tags\030\006 \003(\0132\020.datacatalog.Tag\022.\n\n" - "created_at\030\007 \001(\0132\032.google.protobuf.Times" - "tamp\"C\n\014ArtifactData\022\014\n\004name\030\001 \001(\t\022%\n\005va" - "lue\030\002 \001(\0132\026.flyteidl.core.Literal\"Q\n\003Tag" - "\022\014\n\004name\030\001 \001(\t\022\023\n\013artifact_id\030\002 \001(\t\022\'\n\007d" - "ataset\030\003 \001(\0132\026.datacatalog.DatasetID\"m\n\010" - "Metadata\0222\n\007key_map\030\001 \003(\0132!.datacatalog." - "Metadata.KeyMapEntry\032-\n\013KeyMapEntry\022\013\n\003k" - "ey\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"F\n\020FilterExp" - "ression\0222\n\007filters\030\001 \003(\0132!.datacatalog.S" - "inglePropertyFilter\"\211\003\n\024SinglePropertyFi" - "lter\0224\n\ntag_filter\030\001 \001(\0132\036.datacatalog.T" - "agPropertyFilterH\000\022@\n\020partition_filter\030\002" - " \001(\0132$.datacatalog.PartitionPropertyFilt" - "erH\000\022>\n\017artifact_filter\030\003 \001(\0132#.datacata" - "log.ArtifactPropertyFilterH\000\022<\n\016dataset_" - "filter\030\004 \001(\0132\".datacatalog.DatasetProper" - "tyFilterH\000\022F\n\010operator\030\n \001(\01624.datacatal" - "og.SinglePropertyFilter.ComparisonOperat" - "or\" \n\022ComparisonOperator\022\n\n\006EQUALS\020\000B\021\n\017" - "property_filter\";\n\026ArtifactPropertyFilte" - "r\022\025\n\013artifact_id\030\001 \001(\tH\000B\n\n\010property\"3\n\021" - "TagPropertyFilter\022\022\n\010tag_name\030\001 \001(\tH\000B\n\n" - "\010property\"S\n\027PartitionPropertyFilter\022,\n\007" - "key_val\030\001 \001(\0132\031.datacatalog.KeyValuePair" - "H\000B\n\n\010property\"*\n\014KeyValuePair\022\013\n\003key\030\001 " - "\001(\t\022\r\n\005value\030\002 \001(\t\"k\n\025DatasetPropertyFil" - "ter\022\021\n\007project\030\001 \001(\tH\000\022\016\n\004name\030\002 \001(\tH\000\022\020" - "\n\006domain\030\003 \001(\tH\000\022\021\n\007version\030\004 \001(\tH\000B\n\n\010p" - "roperty\"\361\001\n\021PaginationOptions\022\r\n\005limit\030\001" - " \001(\r\022\r\n\005token\030\002 \001(\t\0227\n\007sortKey\030\003 \001(\0162&.d" - "atacatalog.PaginationOptions.SortKey\022;\n\t" - "sortOrder\030\004 \001(\0162(.datacatalog.Pagination" - "Options.SortOrder\"*\n\tSortOrder\022\016\n\nDESCEN" - "DING\020\000\022\r\n\tASCENDING\020\001\"\034\n\007SortKey\022\021\n\rCREA" - "TION_TIME\020\0002\321\004\n\013DataCatalog\022V\n\rCreateDat" - "aset\022!.datacatalog.CreateDatasetRequest\032" - "\".datacatalog.CreateDatasetResponse\022M\n\nG" - "etDataset\022\036.datacatalog.GetDatasetReques" - "t\032\037.datacatalog.GetDatasetResponse\022Y\n\016Cr" - "eateArtifact\022\".datacatalog.CreateArtifac" - "tRequest\032#.datacatalog.CreateArtifactRes" - "ponse\022P\n\013GetArtifact\022\037.datacatalog.GetAr" - "tifactRequest\032 .datacatalog.GetArtifactR" - "esponse\022A\n\006AddTag\022\032.datacatalog.AddTagRe" - "quest\032\033.datacatalog.AddTagResponse\022V\n\rLi" - "stArtifacts\022!.datacatalog.ListArtifactsR" - "equest\032\".datacatalog.ListArtifactsRespon" - "se\022S\n\014ListDatasets\022 .datacatalog.ListDat" - "asetsRequest\032!.datacatalog.ListDatasetsR" - "esponseb\006proto3" + "ken\030\002 \001(\t\"\212\001\n\033GetOrReserveArtifactReques" + "t\022*\n\ndataset_id\030\001 \001(\0132\026.datacatalog.Data" + "setID\022\020\n\010tag_name\030\002 \001(\t\022-\n\texpire_at\030\003 \001" + "(\0132\032.google.protobuf.Timestamp\"\203\001\n\034GetOr" + "ReserveArtifactResponse\022\'\n\010artifact\030\001 \001(" + "\0132\025.datacatalog.Artifact\022:\n\022reservation_" + "status\030\002 \001(\0162\036.datacatalog.ReservationSt" + "atus\"m\n\007Dataset\022\"\n\002id\030\001 \001(\0132\026.datacatalo" + "g.DatasetID\022\'\n\010metadata\030\002 \001(\0132\025.datacata" + "log.Metadata\022\025\n\rpartitionKeys\030\003 \003(\t\"\'\n\tP" + "artition\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t\"Y\n\t" + "DatasetID\022\017\n\007project\030\001 \001(\t\022\014\n\004name\030\002 \001(\t" + "\022\016\n\006domain\030\003 \001(\t\022\017\n\007version\030\004 \001(\t\022\014\n\004UUI" + "D\030\005 \001(\t\"\215\002\n\010Artifact\022\n\n\002id\030\001 \001(\t\022\'\n\007data" + "set\030\002 \001(\0132\026.datacatalog.DatasetID\022\'\n\004dat" + "a\030\003 \003(\0132\031.datacatalog.ArtifactData\022\'\n\010me" + "tadata\030\004 \001(\0132\025.datacatalog.Metadata\022*\n\np" + "artitions\030\005 \003(\0132\026.datacatalog.Partition\022" + "\036\n\004tags\030\006 \003(\0132\020.datacatalog.Tag\022.\n\ncreat" + "ed_at\030\007 \001(\0132\032.google.protobuf.Timestamp\"" + "C\n\014ArtifactData\022\014\n\004name\030\001 \001(\t\022%\n\005value\030\002" + " \001(\0132\026.flyteidl.core.Literal\"Q\n\003Tag\022\014\n\004n" + "ame\030\001 \001(\t\022\023\n\013artifact_id\030\002 \001(\t\022\'\n\007datase" + "t\030\003 \001(\0132\026.datacatalog.DatasetID\"m\n\010Metad" + "ata\0222\n\007key_map\030\001 \003(\0132!.datacatalog.Metad" + "ata.KeyMapEntry\032-\n\013KeyMapEntry\022\013\n\003key\030\001 " + "\001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"F\n\020FilterExpressi" + "on\0222\n\007filters\030\001 \003(\0132!.datacatalog.Single" + "PropertyFilter\"\211\003\n\024SinglePropertyFilter\022" + "4\n\ntag_filter\030\001 \001(\0132\036.datacatalog.TagPro" + "pertyFilterH\000\022@\n\020partition_filter\030\002 \001(\0132" + "$.datacatalog.PartitionPropertyFilterH\000\022" + ">\n\017artifact_filter\030\003 \001(\0132#.datacatalog.A" + "rtifactPropertyFilterH\000\022<\n\016dataset_filte" + "r\030\004 \001(\0132\".datacatalog.DatasetPropertyFil" + "terH\000\022F\n\010operator\030\n \001(\01624.datacatalog.Si" + "nglePropertyFilter.ComparisonOperator\" \n" + "\022ComparisonOperator\022\n\n\006EQUALS\020\000B\021\n\017prope" + "rty_filter\";\n\026ArtifactPropertyFilter\022\025\n\013" + "artifact_id\030\001 \001(\tH\000B\n\n\010property\"3\n\021TagPr" + "opertyFilter\022\022\n\010tag_name\030\001 \001(\tH\000B\n\n\010prop" + "erty\"S\n\027PartitionPropertyFilter\022,\n\007key_v" + "al\030\001 \001(\0132\031.datacatalog.KeyValuePairH\000B\n\n" + "\010property\"*\n\014KeyValuePair\022\013\n\003key\030\001 \001(\t\022\r" + "\n\005value\030\002 \001(\t\"k\n\025DatasetPropertyFilter\022\021" + "\n\007project\030\001 \001(\tH\000\022\016\n\004name\030\002 \001(\tH\000\022\020\n\006dom" + "ain\030\003 \001(\tH\000\022\021\n\007version\030\004 \001(\tH\000B\n\n\010proper" + "ty\"\361\001\n\021PaginationOptions\022\r\n\005limit\030\001 \001(\r\022" + "\r\n\005token\030\002 \001(\t\0227\n\007sortKey\030\003 \001(\0162&.dataca" + "talog.PaginationOptions.SortKey\022;\n\tsortO" + "rder\030\004 \001(\0162(.datacatalog.PaginationOptio" + "ns.SortOrder\"*\n\tSortOrder\022\016\n\nDESCENDING\020" + "\000\022\r\n\tASCENDING\020\001\"\034\n\007SortKey\022\021\n\rCREATION_" + "TIME\020\000*,\n\021ReservationStatus\022\013\n\007SUCCESS\020\000" + "\022\n\n\006FAILED\020\0012\276\005\n\013DataCatalog\022V\n\rCreateDa" + "taset\022!.datacatalog.CreateDatasetRequest" + "\032\".datacatalog.CreateDatasetResponse\022M\n\n" + "GetDataset\022\036.datacatalog.GetDatasetReque" + "st\032\037.datacatalog.GetDatasetResponse\022Y\n\016C" + "reateArtifact\022\".datacatalog.CreateArtifa" + "ctRequest\032#.datacatalog.CreateArtifactRe" + "sponse\022P\n\013GetArtifact\022\037.datacatalog.GetA" + "rtifactRequest\032 .datacatalog.GetArtifact" + "Response\022A\n\006AddTag\022\032.datacatalog.AddTagR" + "equest\032\033.datacatalog.AddTagResponse\022V\n\rL" + "istArtifacts\022!.datacatalog.ListArtifacts" + "Request\032\".datacatalog.ListArtifactsRespo" + "nse\022S\n\014ListDatasets\022 .datacatalog.ListDa" + "tasetsRequest\032!.datacatalog.ListDatasets" + "Response\022k\n\024GetOrReserveArtifact\022(.datac" + "atalog.GetOrReserveArtifactRequest\032).dat" + "acatalog.GetOrReserveArtifactResponseb\006p" + "roto3" ; ::google::protobuf::internal::DescriptorTable descriptor_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto = { false, InitDefaults_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, descriptor_table_protodef_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, - "flyteidl/datacatalog/datacatalog.proto", &assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, 3575, + "flyteidl/datacatalog/datacatalog.proto", &assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto, 4005, }; void AddDescriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto() { @@ -1119,6 +1190,20 @@ const PaginationOptions_SortKey PaginationOptions::SortKey_MIN; const PaginationOptions_SortKey PaginationOptions::SortKey_MAX; const int PaginationOptions::SortKey_ARRAYSIZE; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 +const ::google::protobuf::EnumDescriptor* ReservationStatus_descriptor() { + ::google::protobuf::internal::AssignDescriptors(&assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto); + return file_level_enum_descriptors_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[3]; +} +bool ReservationStatus_IsValid(int value) { + switch (value) { + case 0: + case 1: + return true; + default: + return false; + } +} + // =================================================================== @@ -4934,52 +5019,834 @@ void ListDatasetsRequest::SerializeWithCachedSizes( // .datacatalog.FilterExpression filter = 1; if (this->has_filter()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 1, HasBitSetters::filter(this), output); + 1, HasBitSetters::filter(this), output); + } + + // .datacatalog.PaginationOptions pagination = 2; + if (this->has_pagination()) { + ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( + 2, HasBitSetters::pagination(this), output); + } + + if (_internal_metadata_.have_unknown_fields()) { + ::google::protobuf::internal::WireFormat::SerializeUnknownFields( + _internal_metadata_.unknown_fields(), output); + } + // @@protoc_insertion_point(serialize_end:datacatalog.ListDatasetsRequest) +} + +::google::protobuf::uint8* ListDatasetsRequest::InternalSerializeWithCachedSizesToArray( + ::google::protobuf::uint8* target) const { + // @@protoc_insertion_point(serialize_to_array_start:datacatalog.ListDatasetsRequest) + ::google::protobuf::uint32 cached_has_bits = 0; + (void) cached_has_bits; + + // .datacatalog.FilterExpression filter = 1; + if (this->has_filter()) { + target = ::google::protobuf::internal::WireFormatLite:: + InternalWriteMessageToArray( + 1, HasBitSetters::filter(this), target); + } + + // .datacatalog.PaginationOptions pagination = 2; + if (this->has_pagination()) { + target = ::google::protobuf::internal::WireFormatLite:: + InternalWriteMessageToArray( + 2, HasBitSetters::pagination(this), target); + } + + if (_internal_metadata_.have_unknown_fields()) { + target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields(), target); + } + // @@protoc_insertion_point(serialize_to_array_end:datacatalog.ListDatasetsRequest) + return target; +} + +size_t ListDatasetsRequest::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:datacatalog.ListDatasetsRequest) + size_t total_size = 0; + + if (_internal_metadata_.have_unknown_fields()) { + total_size += + ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( + _internal_metadata_.unknown_fields()); + } + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + // .datacatalog.FilterExpression filter = 1; + if (this->has_filter()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSize( + *filter_); + } + + // .datacatalog.PaginationOptions pagination = 2; + if (this->has_pagination()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSize( + *pagination_); + } + + int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); + SetCachedSize(cached_size); + return total_size; +} + +void ListDatasetsRequest::MergeFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_merge_from_start:datacatalog.ListDatasetsRequest) + GOOGLE_DCHECK_NE(&from, this); + const ListDatasetsRequest* source = + ::google::protobuf::DynamicCastToGenerated( + &from); + if (source == nullptr) { + // @@protoc_insertion_point(generalized_merge_from_cast_fail:datacatalog.ListDatasetsRequest) + ::google::protobuf::internal::ReflectionOps::Merge(from, this); + } else { + // @@protoc_insertion_point(generalized_merge_from_cast_success:datacatalog.ListDatasetsRequest) + MergeFrom(*source); + } +} + +void ListDatasetsRequest::MergeFrom(const ListDatasetsRequest& from) { +// @@protoc_insertion_point(class_specific_merge_from_start:datacatalog.ListDatasetsRequest) + GOOGLE_DCHECK_NE(&from, this); + _internal_metadata_.MergeFrom(from._internal_metadata_); + ::google::protobuf::uint32 cached_has_bits = 0; + (void) cached_has_bits; + + if (from.has_filter()) { + mutable_filter()->::datacatalog::FilterExpression::MergeFrom(from.filter()); + } + if (from.has_pagination()) { + mutable_pagination()->::datacatalog::PaginationOptions::MergeFrom(from.pagination()); + } +} + +void ListDatasetsRequest::CopyFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_copy_from_start:datacatalog.ListDatasetsRequest) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +void ListDatasetsRequest::CopyFrom(const ListDatasetsRequest& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:datacatalog.ListDatasetsRequest) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ListDatasetsRequest::IsInitialized() const { + return true; +} + +void ListDatasetsRequest::Swap(ListDatasetsRequest* other) { + if (other == this) return; + InternalSwap(other); +} +void ListDatasetsRequest::InternalSwap(ListDatasetsRequest* other) { + using std::swap; + _internal_metadata_.Swap(&other->_internal_metadata_); + swap(filter_, other->filter_); + swap(pagination_, other->pagination_); +} + +::google::protobuf::Metadata ListDatasetsRequest::GetMetadata() const { + ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto); + return ::file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[kIndexInFileMessages]; +} + + +// =================================================================== + +void ListDatasetsResponse::InitAsDefaultInstance() { +} +class ListDatasetsResponse::HasBitSetters { + public: +}; + +#if !defined(_MSC_VER) || _MSC_VER >= 1900 +const int ListDatasetsResponse::kDatasetsFieldNumber; +const int ListDatasetsResponse::kNextTokenFieldNumber; +#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 + +ListDatasetsResponse::ListDatasetsResponse() + : ::google::protobuf::Message(), _internal_metadata_(nullptr) { + SharedCtor(); + // @@protoc_insertion_point(constructor:datacatalog.ListDatasetsResponse) +} +ListDatasetsResponse::ListDatasetsResponse(const ListDatasetsResponse& from) + : ::google::protobuf::Message(), + _internal_metadata_(nullptr), + datasets_(from.datasets_) { + _internal_metadata_.MergeFrom(from._internal_metadata_); + next_token_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + if (from.next_token().size() > 0) { + next_token_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.next_token_); + } + // @@protoc_insertion_point(copy_constructor:datacatalog.ListDatasetsResponse) +} + +void ListDatasetsResponse::SharedCtor() { + ::google::protobuf::internal::InitSCC( + &scc_info_ListDatasetsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + next_token_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); +} + +ListDatasetsResponse::~ListDatasetsResponse() { + // @@protoc_insertion_point(destructor:datacatalog.ListDatasetsResponse) + SharedDtor(); +} + +void ListDatasetsResponse::SharedDtor() { + next_token_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); +} + +void ListDatasetsResponse::SetCachedSize(int size) const { + _cached_size_.Set(size); +} +const ListDatasetsResponse& ListDatasetsResponse::default_instance() { + ::google::protobuf::internal::InitSCC(&::scc_info_ListDatasetsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + return *internal_default_instance(); +} + + +void ListDatasetsResponse::Clear() { +// @@protoc_insertion_point(message_clear_start:datacatalog.ListDatasetsResponse) + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + datasets_.Clear(); + next_token_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + _internal_metadata_.Clear(); +} + +#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER +const char* ListDatasetsResponse::_InternalParse(const char* begin, const char* end, void* object, + ::google::protobuf::internal::ParseContext* ctx) { + auto msg = static_cast(object); + ::google::protobuf::int32 size; (void)size; + int depth; (void)depth; + ::google::protobuf::uint32 tag; + ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end; + auto ptr = begin; + while (ptr < end) { + ptr = ::google::protobuf::io::Parse32(ptr, &tag); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + switch (tag >> 3) { + // repeated .datacatalog.Dataset datasets = 1; + case 1: { + if (static_cast<::google::protobuf::uint8>(tag) != 10) goto handle_unusual; + do { + ptr = ::google::protobuf::io::ReadSize(ptr, &size); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + parser_till_end = ::datacatalog::Dataset::_InternalParse; + object = msg->add_datasets(); + if (size > end - ptr) goto len_delim_till_end; + ptr += size; + GOOGLE_PROTOBUF_PARSER_ASSERT(ctx->ParseExactRange( + {parser_till_end, object}, ptr - size, ptr)); + if (ptr >= end) break; + } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 10 && (ptr += 1)); + break; + } + // string next_token = 2; + case 2: { + if (static_cast<::google::protobuf::uint8>(tag) != 18) goto handle_unusual; + ptr = ::google::protobuf::io::ReadSize(ptr, &size); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + ctx->extra_parse_data().SetFieldName("datacatalog.ListDatasetsResponse.next_token"); + object = msg->mutable_next_token(); + if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) { + parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8; + goto string_till_end; + } + GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx)); + ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx); + ptr += size; + break; + } + default: { + handle_unusual: + if ((tag & 7) == 4 || tag == 0) { + ctx->EndGroup(tag); + return ptr; + } + auto res = UnknownFieldParse(tag, {_InternalParse, msg}, + ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx); + ptr = res.first; + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr); + if (res.second) return ptr; + } + } // switch + } // while + return ptr; +string_till_end: + static_cast<::std::string*>(object)->clear(); + static_cast<::std::string*>(object)->reserve(size); + goto len_delim_till_end; +len_delim_till_end: + return ctx->StoreAndTailCall(ptr, end, {_InternalParse, msg}, + {parser_till_end, object}, size); +} +#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER +bool ListDatasetsResponse::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + // @@protoc_insertion_point(parse_start:datacatalog.ListDatasetsResponse) + for (;;) { + ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // repeated .datacatalog.Dataset datasets = 1; + case 1: { + if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) { + DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( + input, add_datasets())); + } else { + goto handle_unusual; + } + break; + } + + // string next_token = 2; + case 2: { + if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) { + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_next_token())); + DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( + this->next_token().data(), static_cast(this->next_token().length()), + ::google::protobuf::internal::WireFormatLite::PARSE, + "datacatalog.ListDatasetsResponse.next_token")); + } else { + goto handle_unusual; + } + break; + } + + default: { + handle_unusual: + if (tag == 0) { + goto success; + } + DO_(::google::protobuf::internal::WireFormat::SkipField( + input, tag, _internal_metadata_.mutable_unknown_fields())); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:datacatalog.ListDatasetsResponse) + return true; +failure: + // @@protoc_insertion_point(parse_failure:datacatalog.ListDatasetsResponse) + return false; +#undef DO_ +} +#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER + +void ListDatasetsResponse::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:datacatalog.ListDatasetsResponse) + ::google::protobuf::uint32 cached_has_bits = 0; + (void) cached_has_bits; + + // repeated .datacatalog.Dataset datasets = 1; + for (unsigned int i = 0, + n = static_cast(this->datasets_size()); i < n; i++) { + ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( + 1, + this->datasets(static_cast(i)), + output); + } + + // string next_token = 2; + if (this->next_token().size() > 0) { + ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( + this->next_token().data(), static_cast(this->next_token().length()), + ::google::protobuf::internal::WireFormatLite::SERIALIZE, + "datacatalog.ListDatasetsResponse.next_token"); + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 2, this->next_token(), output); + } + + if (_internal_metadata_.have_unknown_fields()) { + ::google::protobuf::internal::WireFormat::SerializeUnknownFields( + _internal_metadata_.unknown_fields(), output); + } + // @@protoc_insertion_point(serialize_end:datacatalog.ListDatasetsResponse) +} + +::google::protobuf::uint8* ListDatasetsResponse::InternalSerializeWithCachedSizesToArray( + ::google::protobuf::uint8* target) const { + // @@protoc_insertion_point(serialize_to_array_start:datacatalog.ListDatasetsResponse) + ::google::protobuf::uint32 cached_has_bits = 0; + (void) cached_has_bits; + + // repeated .datacatalog.Dataset datasets = 1; + for (unsigned int i = 0, + n = static_cast(this->datasets_size()); i < n; i++) { + target = ::google::protobuf::internal::WireFormatLite:: + InternalWriteMessageToArray( + 1, this->datasets(static_cast(i)), target); + } + + // string next_token = 2; + if (this->next_token().size() > 0) { + ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( + this->next_token().data(), static_cast(this->next_token().length()), + ::google::protobuf::internal::WireFormatLite::SERIALIZE, + "datacatalog.ListDatasetsResponse.next_token"); + target = + ::google::protobuf::internal::WireFormatLite::WriteStringToArray( + 2, this->next_token(), target); + } + + if (_internal_metadata_.have_unknown_fields()) { + target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields(), target); + } + // @@protoc_insertion_point(serialize_to_array_end:datacatalog.ListDatasetsResponse) + return target; +} + +size_t ListDatasetsResponse::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:datacatalog.ListDatasetsResponse) + size_t total_size = 0; + + if (_internal_metadata_.have_unknown_fields()) { + total_size += + ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( + _internal_metadata_.unknown_fields()); + } + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + // repeated .datacatalog.Dataset datasets = 1; + { + unsigned int count = static_cast(this->datasets_size()); + total_size += 1UL * count; + for (unsigned int i = 0; i < count; i++) { + total_size += + ::google::protobuf::internal::WireFormatLite::MessageSize( + this->datasets(static_cast(i))); + } + } + + // string next_token = 2; + if (this->next_token().size() > 0) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->next_token()); + } + + int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); + SetCachedSize(cached_size); + return total_size; +} + +void ListDatasetsResponse::MergeFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_merge_from_start:datacatalog.ListDatasetsResponse) + GOOGLE_DCHECK_NE(&from, this); + const ListDatasetsResponse* source = + ::google::protobuf::DynamicCastToGenerated( + &from); + if (source == nullptr) { + // @@protoc_insertion_point(generalized_merge_from_cast_fail:datacatalog.ListDatasetsResponse) + ::google::protobuf::internal::ReflectionOps::Merge(from, this); + } else { + // @@protoc_insertion_point(generalized_merge_from_cast_success:datacatalog.ListDatasetsResponse) + MergeFrom(*source); + } +} + +void ListDatasetsResponse::MergeFrom(const ListDatasetsResponse& from) { +// @@protoc_insertion_point(class_specific_merge_from_start:datacatalog.ListDatasetsResponse) + GOOGLE_DCHECK_NE(&from, this); + _internal_metadata_.MergeFrom(from._internal_metadata_); + ::google::protobuf::uint32 cached_has_bits = 0; + (void) cached_has_bits; + + datasets_.MergeFrom(from.datasets_); + if (from.next_token().size() > 0) { + + next_token_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.next_token_); + } +} + +void ListDatasetsResponse::CopyFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_copy_from_start:datacatalog.ListDatasetsResponse) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +void ListDatasetsResponse::CopyFrom(const ListDatasetsResponse& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:datacatalog.ListDatasetsResponse) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ListDatasetsResponse::IsInitialized() const { + return true; +} + +void ListDatasetsResponse::Swap(ListDatasetsResponse* other) { + if (other == this) return; + InternalSwap(other); +} +void ListDatasetsResponse::InternalSwap(ListDatasetsResponse* other) { + using std::swap; + _internal_metadata_.Swap(&other->_internal_metadata_); + CastToBase(&datasets_)->InternalSwap(CastToBase(&other->datasets_)); + next_token_.Swap(&other->next_token_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), + GetArenaNoVirtual()); +} + +::google::protobuf::Metadata ListDatasetsResponse::GetMetadata() const { + ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto); + return ::file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[kIndexInFileMessages]; +} + + +// =================================================================== + +void GetOrReserveArtifactRequest::InitAsDefaultInstance() { + ::datacatalog::_GetOrReserveArtifactRequest_default_instance_._instance.get_mutable()->dataset_id_ = const_cast< ::datacatalog::DatasetID*>( + ::datacatalog::DatasetID::internal_default_instance()); + ::datacatalog::_GetOrReserveArtifactRequest_default_instance_._instance.get_mutable()->expire_at_ = const_cast< ::google::protobuf::Timestamp*>( + ::google::protobuf::Timestamp::internal_default_instance()); +} +class GetOrReserveArtifactRequest::HasBitSetters { + public: + static const ::datacatalog::DatasetID& dataset_id(const GetOrReserveArtifactRequest* msg); + static const ::google::protobuf::Timestamp& expire_at(const GetOrReserveArtifactRequest* msg); +}; + +const ::datacatalog::DatasetID& +GetOrReserveArtifactRequest::HasBitSetters::dataset_id(const GetOrReserveArtifactRequest* msg) { + return *msg->dataset_id_; +} +const ::google::protobuf::Timestamp& +GetOrReserveArtifactRequest::HasBitSetters::expire_at(const GetOrReserveArtifactRequest* msg) { + return *msg->expire_at_; +} +void GetOrReserveArtifactRequest::clear_expire_at() { + if (GetArenaNoVirtual() == nullptr && expire_at_ != nullptr) { + delete expire_at_; + } + expire_at_ = nullptr; +} +#if !defined(_MSC_VER) || _MSC_VER >= 1900 +const int GetOrReserveArtifactRequest::kDatasetIdFieldNumber; +const int GetOrReserveArtifactRequest::kTagNameFieldNumber; +const int GetOrReserveArtifactRequest::kExpireAtFieldNumber; +#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 + +GetOrReserveArtifactRequest::GetOrReserveArtifactRequest() + : ::google::protobuf::Message(), _internal_metadata_(nullptr) { + SharedCtor(); + // @@protoc_insertion_point(constructor:datacatalog.GetOrReserveArtifactRequest) +} +GetOrReserveArtifactRequest::GetOrReserveArtifactRequest(const GetOrReserveArtifactRequest& from) + : ::google::protobuf::Message(), + _internal_metadata_(nullptr) { + _internal_metadata_.MergeFrom(from._internal_metadata_); + tag_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + if (from.tag_name().size() > 0) { + tag_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.tag_name_); + } + if (from.has_dataset_id()) { + dataset_id_ = new ::datacatalog::DatasetID(*from.dataset_id_); + } else { + dataset_id_ = nullptr; + } + if (from.has_expire_at()) { + expire_at_ = new ::google::protobuf::Timestamp(*from.expire_at_); + } else { + expire_at_ = nullptr; + } + // @@protoc_insertion_point(copy_constructor:datacatalog.GetOrReserveArtifactRequest) +} + +void GetOrReserveArtifactRequest::SharedCtor() { + ::google::protobuf::internal::InitSCC( + &scc_info_GetOrReserveArtifactRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + tag_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + ::memset(&dataset_id_, 0, static_cast( + reinterpret_cast(&expire_at_) - + reinterpret_cast(&dataset_id_)) + sizeof(expire_at_)); +} + +GetOrReserveArtifactRequest::~GetOrReserveArtifactRequest() { + // @@protoc_insertion_point(destructor:datacatalog.GetOrReserveArtifactRequest) + SharedDtor(); +} + +void GetOrReserveArtifactRequest::SharedDtor() { + tag_name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + if (this != internal_default_instance()) delete dataset_id_; + if (this != internal_default_instance()) delete expire_at_; +} + +void GetOrReserveArtifactRequest::SetCachedSize(int size) const { + _cached_size_.Set(size); +} +const GetOrReserveArtifactRequest& GetOrReserveArtifactRequest::default_instance() { + ::google::protobuf::internal::InitSCC(&::scc_info_GetOrReserveArtifactRequest_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + return *internal_default_instance(); +} + + +void GetOrReserveArtifactRequest::Clear() { +// @@protoc_insertion_point(message_clear_start:datacatalog.GetOrReserveArtifactRequest) + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + tag_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + if (GetArenaNoVirtual() == nullptr && dataset_id_ != nullptr) { + delete dataset_id_; + } + dataset_id_ = nullptr; + if (GetArenaNoVirtual() == nullptr && expire_at_ != nullptr) { + delete expire_at_; + } + expire_at_ = nullptr; + _internal_metadata_.Clear(); +} + +#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER +const char* GetOrReserveArtifactRequest::_InternalParse(const char* begin, const char* end, void* object, + ::google::protobuf::internal::ParseContext* ctx) { + auto msg = static_cast(object); + ::google::protobuf::int32 size; (void)size; + int depth; (void)depth; + ::google::protobuf::uint32 tag; + ::google::protobuf::internal::ParseFunc parser_till_end; (void)parser_till_end; + auto ptr = begin; + while (ptr < end) { + ptr = ::google::protobuf::io::Parse32(ptr, &tag); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + switch (tag >> 3) { + // .datacatalog.DatasetID dataset_id = 1; + case 1: { + if (static_cast<::google::protobuf::uint8>(tag) != 10) goto handle_unusual; + ptr = ::google::protobuf::io::ReadSize(ptr, &size); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + parser_till_end = ::datacatalog::DatasetID::_InternalParse; + object = msg->mutable_dataset_id(); + if (size > end - ptr) goto len_delim_till_end; + ptr += size; + GOOGLE_PROTOBUF_PARSER_ASSERT(ctx->ParseExactRange( + {parser_till_end, object}, ptr - size, ptr)); + break; + } + // string tag_name = 2; + case 2: { + if (static_cast<::google::protobuf::uint8>(tag) != 18) goto handle_unusual; + ptr = ::google::protobuf::io::ReadSize(ptr, &size); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + ctx->extra_parse_data().SetFieldName("datacatalog.GetOrReserveArtifactRequest.tag_name"); + object = msg->mutable_tag_name(); + if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) { + parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8; + goto string_till_end; + } + GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx)); + ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx); + ptr += size; + break; + } + // .google.protobuf.Timestamp expire_at = 3; + case 3: { + if (static_cast<::google::protobuf::uint8>(tag) != 26) goto handle_unusual; + ptr = ::google::protobuf::io::ReadSize(ptr, &size); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + parser_till_end = ::google::protobuf::Timestamp::_InternalParse; + object = msg->mutable_expire_at(); + if (size > end - ptr) goto len_delim_till_end; + ptr += size; + GOOGLE_PROTOBUF_PARSER_ASSERT(ctx->ParseExactRange( + {parser_till_end, object}, ptr - size, ptr)); + break; + } + default: { + handle_unusual: + if ((tag & 7) == 4 || tag == 0) { + ctx->EndGroup(tag); + return ptr; + } + auto res = UnknownFieldParse(tag, {_InternalParse, msg}, + ptr, end, msg->_internal_metadata_.mutable_unknown_fields(), ctx); + ptr = res.first; + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr != nullptr); + if (res.second) return ptr; + } + } // switch + } // while + return ptr; +string_till_end: + static_cast<::std::string*>(object)->clear(); + static_cast<::std::string*>(object)->reserve(size); + goto len_delim_till_end; +len_delim_till_end: + return ctx->StoreAndTailCall(ptr, end, {_InternalParse, msg}, + {parser_till_end, object}, size); +} +#else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER +bool GetOrReserveArtifactRequest::MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) { +#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure + ::google::protobuf::uint32 tag; + // @@protoc_insertion_point(parse_start:datacatalog.GetOrReserveArtifactRequest) + for (;;) { + ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); + tag = p.first; + if (!p.second) goto handle_unusual; + switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { + // .datacatalog.DatasetID dataset_id = 1; + case 1: { + if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) { + DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( + input, mutable_dataset_id())); + } else { + goto handle_unusual; + } + break; + } + + // string tag_name = 2; + case 2: { + if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) { + DO_(::google::protobuf::internal::WireFormatLite::ReadString( + input, this->mutable_tag_name())); + DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( + this->tag_name().data(), static_cast(this->tag_name().length()), + ::google::protobuf::internal::WireFormatLite::PARSE, + "datacatalog.GetOrReserveArtifactRequest.tag_name")); + } else { + goto handle_unusual; + } + break; + } + + // .google.protobuf.Timestamp expire_at = 3; + case 3: { + if (static_cast< ::google::protobuf::uint8>(tag) == (26 & 0xFF)) { + DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( + input, mutable_expire_at())); + } else { + goto handle_unusual; + } + break; + } + + default: { + handle_unusual: + if (tag == 0) { + goto success; + } + DO_(::google::protobuf::internal::WireFormat::SkipField( + input, tag, _internal_metadata_.mutable_unknown_fields())); + break; + } + } + } +success: + // @@protoc_insertion_point(parse_success:datacatalog.GetOrReserveArtifactRequest) + return true; +failure: + // @@protoc_insertion_point(parse_failure:datacatalog.GetOrReserveArtifactRequest) + return false; +#undef DO_ +} +#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER + +void GetOrReserveArtifactRequest::SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const { + // @@protoc_insertion_point(serialize_start:datacatalog.GetOrReserveArtifactRequest) + ::google::protobuf::uint32 cached_has_bits = 0; + (void) cached_has_bits; + + // .datacatalog.DatasetID dataset_id = 1; + if (this->has_dataset_id()) { + ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( + 1, HasBitSetters::dataset_id(this), output); } - // .datacatalog.PaginationOptions pagination = 2; - if (this->has_pagination()) { + // string tag_name = 2; + if (this->tag_name().size() > 0) { + ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( + this->tag_name().data(), static_cast(this->tag_name().length()), + ::google::protobuf::internal::WireFormatLite::SERIALIZE, + "datacatalog.GetOrReserveArtifactRequest.tag_name"); + ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( + 2, this->tag_name(), output); + } + + // .google.protobuf.Timestamp expire_at = 3; + if (this->has_expire_at()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 2, HasBitSetters::pagination(this), output); + 3, HasBitSetters::expire_at(this), output); } if (_internal_metadata_.have_unknown_fields()) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( _internal_metadata_.unknown_fields(), output); } - // @@protoc_insertion_point(serialize_end:datacatalog.ListDatasetsRequest) + // @@protoc_insertion_point(serialize_end:datacatalog.GetOrReserveArtifactRequest) } -::google::protobuf::uint8* ListDatasetsRequest::InternalSerializeWithCachedSizesToArray( +::google::protobuf::uint8* GetOrReserveArtifactRequest::InternalSerializeWithCachedSizesToArray( ::google::protobuf::uint8* target) const { - // @@protoc_insertion_point(serialize_to_array_start:datacatalog.ListDatasetsRequest) + // @@protoc_insertion_point(serialize_to_array_start:datacatalog.GetOrReserveArtifactRequest) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; - // .datacatalog.FilterExpression filter = 1; - if (this->has_filter()) { + // .datacatalog.DatasetID dataset_id = 1; + if (this->has_dataset_id()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( - 1, HasBitSetters::filter(this), target); + 1, HasBitSetters::dataset_id(this), target); } - // .datacatalog.PaginationOptions pagination = 2; - if (this->has_pagination()) { + // string tag_name = 2; + if (this->tag_name().size() > 0) { + ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( + this->tag_name().data(), static_cast(this->tag_name().length()), + ::google::protobuf::internal::WireFormatLite::SERIALIZE, + "datacatalog.GetOrReserveArtifactRequest.tag_name"); + target = + ::google::protobuf::internal::WireFormatLite::WriteStringToArray( + 2, this->tag_name(), target); + } + + // .google.protobuf.Timestamp expire_at = 3; + if (this->has_expire_at()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( - 2, HasBitSetters::pagination(this), target); + 3, HasBitSetters::expire_at(this), target); } if (_internal_metadata_.have_unknown_fields()) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields(), target); } - // @@protoc_insertion_point(serialize_to_array_end:datacatalog.ListDatasetsRequest) + // @@protoc_insertion_point(serialize_to_array_end:datacatalog.GetOrReserveArtifactRequest) return target; } -size_t ListDatasetsRequest::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:datacatalog.ListDatasetsRequest) +size_t GetOrReserveArtifactRequest::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:datacatalog.GetOrReserveArtifactRequest) size_t total_size = 0; if (_internal_metadata_.have_unknown_fields()) { @@ -4991,18 +5858,25 @@ size_t ListDatasetsRequest::ByteSizeLong() const { // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; - // .datacatalog.FilterExpression filter = 1; - if (this->has_filter()) { + // string tag_name = 2; + if (this->tag_name().size() > 0) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::StringSize( + this->tag_name()); + } + + // .datacatalog.DatasetID dataset_id = 1; + if (this->has_dataset_id()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( - *filter_); + *dataset_id_); } - // .datacatalog.PaginationOptions pagination = 2; - if (this->has_pagination()) { + // .google.protobuf.Timestamp expire_at = 3; + if (this->has_expire_at()) { total_size += 1 + ::google::protobuf::internal::WireFormatLite::MessageSize( - *pagination_); + *expire_at_); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); @@ -5010,66 +5884,72 @@ size_t ListDatasetsRequest::ByteSizeLong() const { return total_size; } -void ListDatasetsRequest::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:datacatalog.ListDatasetsRequest) +void GetOrReserveArtifactRequest::MergeFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_merge_from_start:datacatalog.GetOrReserveArtifactRequest) GOOGLE_DCHECK_NE(&from, this); - const ListDatasetsRequest* source = - ::google::protobuf::DynamicCastToGenerated( + const GetOrReserveArtifactRequest* source = + ::google::protobuf::DynamicCastToGenerated( &from); if (source == nullptr) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:datacatalog.ListDatasetsRequest) + // @@protoc_insertion_point(generalized_merge_from_cast_fail:datacatalog.GetOrReserveArtifactRequest) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:datacatalog.ListDatasetsRequest) + // @@protoc_insertion_point(generalized_merge_from_cast_success:datacatalog.GetOrReserveArtifactRequest) MergeFrom(*source); } } -void ListDatasetsRequest::MergeFrom(const ListDatasetsRequest& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:datacatalog.ListDatasetsRequest) +void GetOrReserveArtifactRequest::MergeFrom(const GetOrReserveArtifactRequest& from) { +// @@protoc_insertion_point(class_specific_merge_from_start:datacatalog.GetOrReserveArtifactRequest) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; - if (from.has_filter()) { - mutable_filter()->::datacatalog::FilterExpression::MergeFrom(from.filter()); + if (from.tag_name().size() > 0) { + + tag_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.tag_name_); } - if (from.has_pagination()) { - mutable_pagination()->::datacatalog::PaginationOptions::MergeFrom(from.pagination()); + if (from.has_dataset_id()) { + mutable_dataset_id()->::datacatalog::DatasetID::MergeFrom(from.dataset_id()); + } + if (from.has_expire_at()) { + mutable_expire_at()->::google::protobuf::Timestamp::MergeFrom(from.expire_at()); } } -void ListDatasetsRequest::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:datacatalog.ListDatasetsRequest) +void GetOrReserveArtifactRequest::CopyFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_copy_from_start:datacatalog.GetOrReserveArtifactRequest) if (&from == this) return; Clear(); MergeFrom(from); } -void ListDatasetsRequest::CopyFrom(const ListDatasetsRequest& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:datacatalog.ListDatasetsRequest) +void GetOrReserveArtifactRequest::CopyFrom(const GetOrReserveArtifactRequest& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:datacatalog.GetOrReserveArtifactRequest) if (&from == this) return; Clear(); MergeFrom(from); } -bool ListDatasetsRequest::IsInitialized() const { +bool GetOrReserveArtifactRequest::IsInitialized() const { return true; } -void ListDatasetsRequest::Swap(ListDatasetsRequest* other) { +void GetOrReserveArtifactRequest::Swap(GetOrReserveArtifactRequest* other) { if (other == this) return; InternalSwap(other); } -void ListDatasetsRequest::InternalSwap(ListDatasetsRequest* other) { +void GetOrReserveArtifactRequest::InternalSwap(GetOrReserveArtifactRequest* other) { using std::swap; _internal_metadata_.Swap(&other->_internal_metadata_); - swap(filter_, other->filter_); - swap(pagination_, other->pagination_); + tag_name_.Swap(&other->tag_name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), + GetArenaNoVirtual()); + swap(dataset_id_, other->dataset_id_); + swap(expire_at_, other->expire_at_); } -::google::protobuf::Metadata ListDatasetsRequest::GetMetadata() const { +::google::protobuf::Metadata GetOrReserveArtifactRequest::GetMetadata() const { ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto); return ::file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[kIndexInFileMessages]; } @@ -5077,73 +5957,86 @@ ::google::protobuf::Metadata ListDatasetsRequest::GetMetadata() const { // =================================================================== -void ListDatasetsResponse::InitAsDefaultInstance() { +void GetOrReserveArtifactResponse::InitAsDefaultInstance() { + ::datacatalog::_GetOrReserveArtifactResponse_default_instance_._instance.get_mutable()->artifact_ = const_cast< ::datacatalog::Artifact*>( + ::datacatalog::Artifact::internal_default_instance()); } -class ListDatasetsResponse::HasBitSetters { +class GetOrReserveArtifactResponse::HasBitSetters { public: + static const ::datacatalog::Artifact& artifact(const GetOrReserveArtifactResponse* msg); }; +const ::datacatalog::Artifact& +GetOrReserveArtifactResponse::HasBitSetters::artifact(const GetOrReserveArtifactResponse* msg) { + return *msg->artifact_; +} #if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int ListDatasetsResponse::kDatasetsFieldNumber; -const int ListDatasetsResponse::kNextTokenFieldNumber; +const int GetOrReserveArtifactResponse::kArtifactFieldNumber; +const int GetOrReserveArtifactResponse::kReservationStatusFieldNumber; #endif // !defined(_MSC_VER) || _MSC_VER >= 1900 -ListDatasetsResponse::ListDatasetsResponse() +GetOrReserveArtifactResponse::GetOrReserveArtifactResponse() : ::google::protobuf::Message(), _internal_metadata_(nullptr) { SharedCtor(); - // @@protoc_insertion_point(constructor:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(constructor:datacatalog.GetOrReserveArtifactResponse) } -ListDatasetsResponse::ListDatasetsResponse(const ListDatasetsResponse& from) +GetOrReserveArtifactResponse::GetOrReserveArtifactResponse(const GetOrReserveArtifactResponse& from) : ::google::protobuf::Message(), - _internal_metadata_(nullptr), - datasets_(from.datasets_) { + _internal_metadata_(nullptr) { _internal_metadata_.MergeFrom(from._internal_metadata_); - next_token_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (from.next_token().size() > 0) { - next_token_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.next_token_); + if (from.has_artifact()) { + artifact_ = new ::datacatalog::Artifact(*from.artifact_); + } else { + artifact_ = nullptr; } - // @@protoc_insertion_point(copy_constructor:datacatalog.ListDatasetsResponse) + reservation_status_ = from.reservation_status_; + // @@protoc_insertion_point(copy_constructor:datacatalog.GetOrReserveArtifactResponse) } -void ListDatasetsResponse::SharedCtor() { +void GetOrReserveArtifactResponse::SharedCtor() { ::google::protobuf::internal::InitSCC( - &scc_info_ListDatasetsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); - next_token_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + &scc_info_GetOrReserveArtifactResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); + ::memset(&artifact_, 0, static_cast( + reinterpret_cast(&reservation_status_) - + reinterpret_cast(&artifact_)) + sizeof(reservation_status_)); } -ListDatasetsResponse::~ListDatasetsResponse() { - // @@protoc_insertion_point(destructor:datacatalog.ListDatasetsResponse) +GetOrReserveArtifactResponse::~GetOrReserveArtifactResponse() { + // @@protoc_insertion_point(destructor:datacatalog.GetOrReserveArtifactResponse) SharedDtor(); } -void ListDatasetsResponse::SharedDtor() { - next_token_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); +void GetOrReserveArtifactResponse::SharedDtor() { + if (this != internal_default_instance()) delete artifact_; } -void ListDatasetsResponse::SetCachedSize(int size) const { +void GetOrReserveArtifactResponse::SetCachedSize(int size) const { _cached_size_.Set(size); } -const ListDatasetsResponse& ListDatasetsResponse::default_instance() { - ::google::protobuf::internal::InitSCC(&::scc_info_ListDatasetsResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); +const GetOrReserveArtifactResponse& GetOrReserveArtifactResponse::default_instance() { + ::google::protobuf::internal::InitSCC(&::scc_info_GetOrReserveArtifactResponse_flyteidl_2fdatacatalog_2fdatacatalog_2eproto.base); return *internal_default_instance(); } -void ListDatasetsResponse::Clear() { -// @@protoc_insertion_point(message_clear_start:datacatalog.ListDatasetsResponse) +void GetOrReserveArtifactResponse::Clear() { +// @@protoc_insertion_point(message_clear_start:datacatalog.GetOrReserveArtifactResponse) ::google::protobuf::uint32 cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; - datasets_.Clear(); - next_token_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + if (GetArenaNoVirtual() == nullptr && artifact_ != nullptr) { + delete artifact_; + } + artifact_ = nullptr; + reservation_status_ = 0; _internal_metadata_.Clear(); } #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -const char* ListDatasetsResponse::_InternalParse(const char* begin, const char* end, void* object, +const char* GetOrReserveArtifactResponse::_InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx) { - auto msg = static_cast(object); + auto msg = static_cast(object); ::google::protobuf::int32 size; (void)size; int depth; (void)depth; ::google::protobuf::uint32 tag; @@ -5153,36 +6046,25 @@ const char* ListDatasetsResponse::_InternalParse(const char* begin, const char* ptr = ::google::protobuf::io::Parse32(ptr, &tag); GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); switch (tag >> 3) { - // repeated .datacatalog.Dataset datasets = 1; + // .datacatalog.Artifact artifact = 1; case 1: { if (static_cast<::google::protobuf::uint8>(tag) != 10) goto handle_unusual; - do { - ptr = ::google::protobuf::io::ReadSize(ptr, &size); - GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); - parser_till_end = ::datacatalog::Dataset::_InternalParse; - object = msg->add_datasets(); - if (size > end - ptr) goto len_delim_till_end; - ptr += size; - GOOGLE_PROTOBUF_PARSER_ASSERT(ctx->ParseExactRange( - {parser_till_end, object}, ptr - size, ptr)); - if (ptr >= end) break; - } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 10 && (ptr += 1)); + ptr = ::google::protobuf::io::ReadSize(ptr, &size); + GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); + parser_till_end = ::datacatalog::Artifact::_InternalParse; + object = msg->mutable_artifact(); + if (size > end - ptr) goto len_delim_till_end; + ptr += size; + GOOGLE_PROTOBUF_PARSER_ASSERT(ctx->ParseExactRange( + {parser_till_end, object}, ptr - size, ptr)); break; } - // string next_token = 2; + // .datacatalog.ReservationStatus reservation_status = 2; case 2: { - if (static_cast<::google::protobuf::uint8>(tag) != 18) goto handle_unusual; - ptr = ::google::protobuf::io::ReadSize(ptr, &size); + if (static_cast<::google::protobuf::uint8>(tag) != 16) goto handle_unusual; + ::google::protobuf::uint64 val = ::google::protobuf::internal::ReadVarint(&ptr); + msg->set_reservation_status(static_cast<::datacatalog::ReservationStatus>(val)); GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); - ctx->extra_parse_data().SetFieldName("datacatalog.ListDatasetsResponse.next_token"); - object = msg->mutable_next_token(); - if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) { - parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8; - goto string_till_end; - } - GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx)); - ::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx); - ptr += size; break; } default: { @@ -5200,45 +6082,40 @@ const char* ListDatasetsResponse::_InternalParse(const char* begin, const char* } // switch } // while return ptr; -string_till_end: - static_cast<::std::string*>(object)->clear(); - static_cast<::std::string*>(object)->reserve(size); - goto len_delim_till_end; len_delim_till_end: return ctx->StoreAndTailCall(ptr, end, {_InternalParse, msg}, {parser_till_end, object}, size); } #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -bool ListDatasetsResponse::MergePartialFromCodedStream( +bool GetOrReserveArtifactResponse::MergePartialFromCodedStream( ::google::protobuf::io::CodedInputStream* input) { #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure ::google::protobuf::uint32 tag; - // @@protoc_insertion_point(parse_start:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(parse_start:datacatalog.GetOrReserveArtifactResponse) for (;;) { ::std::pair<::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); tag = p.first; if (!p.second) goto handle_unusual; switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) { - // repeated .datacatalog.Dataset datasets = 1; + // .datacatalog.Artifact artifact = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( - input, add_datasets())); + input, mutable_artifact())); } else { goto handle_unusual; } break; } - // string next_token = 2; + // .datacatalog.ReservationStatus reservation_status = 2; case 2: { - if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) { - DO_(::google::protobuf::internal::WireFormatLite::ReadString( - input, this->mutable_next_token())); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->next_token().data(), static_cast(this->next_token().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "datacatalog.ListDatasetsResponse.next_token")); + if (static_cast< ::google::protobuf::uint8>(tag) == (16 & 0xFF)) { + int value = 0; + DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< + int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( + input, &value))); + set_reservation_status(static_cast< ::datacatalog::ReservationStatus >(value)); } else { goto handle_unusual; } @@ -5257,82 +6134,69 @@ bool ListDatasetsResponse::MergePartialFromCodedStream( } } success: - // @@protoc_insertion_point(parse_success:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(parse_success:datacatalog.GetOrReserveArtifactResponse) return true; failure: - // @@protoc_insertion_point(parse_failure:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(parse_failure:datacatalog.GetOrReserveArtifactResponse) return false; #undef DO_ } #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -void ListDatasetsResponse::SerializeWithCachedSizes( +void GetOrReserveArtifactResponse::SerializeWithCachedSizes( ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(serialize_start:datacatalog.GetOrReserveArtifactResponse) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; - // repeated .datacatalog.Dataset datasets = 1; - for (unsigned int i = 0, - n = static_cast(this->datasets_size()); i < n; i++) { + // .datacatalog.Artifact artifact = 1; + if (this->has_artifact()) { ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 1, - this->datasets(static_cast(i)), - output); + 1, HasBitSetters::artifact(this), output); } - // string next_token = 2; - if (this->next_token().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->next_token().data(), static_cast(this->next_token().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "datacatalog.ListDatasetsResponse.next_token"); - ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( - 2, this->next_token(), output); + // .datacatalog.ReservationStatus reservation_status = 2; + if (this->reservation_status() != 0) { + ::google::protobuf::internal::WireFormatLite::WriteEnum( + 2, this->reservation_status(), output); } if (_internal_metadata_.have_unknown_fields()) { ::google::protobuf::internal::WireFormat::SerializeUnknownFields( _internal_metadata_.unknown_fields(), output); } - // @@protoc_insertion_point(serialize_end:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(serialize_end:datacatalog.GetOrReserveArtifactResponse) } -::google::protobuf::uint8* ListDatasetsResponse::InternalSerializeWithCachedSizesToArray( +::google::protobuf::uint8* GetOrReserveArtifactResponse::InternalSerializeWithCachedSizesToArray( ::google::protobuf::uint8* target) const { - // @@protoc_insertion_point(serialize_to_array_start:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(serialize_to_array_start:datacatalog.GetOrReserveArtifactResponse) ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; - // repeated .datacatalog.Dataset datasets = 1; - for (unsigned int i = 0, - n = static_cast(this->datasets_size()); i < n; i++) { + // .datacatalog.Artifact artifact = 1; + if (this->has_artifact()) { target = ::google::protobuf::internal::WireFormatLite:: InternalWriteMessageToArray( - 1, this->datasets(static_cast(i)), target); + 1, HasBitSetters::artifact(this), target); } - // string next_token = 2; - if (this->next_token().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->next_token().data(), static_cast(this->next_token().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "datacatalog.ListDatasetsResponse.next_token"); - target = - ::google::protobuf::internal::WireFormatLite::WriteStringToArray( - 2, this->next_token(), target); + // .datacatalog.ReservationStatus reservation_status = 2; + if (this->reservation_status() != 0) { + target = ::google::protobuf::internal::WireFormatLite::WriteEnumToArray( + 2, this->reservation_status(), target); } if (_internal_metadata_.have_unknown_fields()) { target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields(), target); } - // @@protoc_insertion_point(serialize_to_array_end:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(serialize_to_array_end:datacatalog.GetOrReserveArtifactResponse) return target; } -size_t ListDatasetsResponse::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:datacatalog.ListDatasetsResponse) +size_t GetOrReserveArtifactResponse::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:datacatalog.GetOrReserveArtifactResponse) size_t total_size = 0; if (_internal_metadata_.have_unknown_fields()) { @@ -5344,22 +6208,17 @@ size_t ListDatasetsResponse::ByteSizeLong() const { // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; - // repeated .datacatalog.Dataset datasets = 1; - { - unsigned int count = static_cast(this->datasets_size()); - total_size += 1UL * count; - for (unsigned int i = 0; i < count; i++) { - total_size += - ::google::protobuf::internal::WireFormatLite::MessageSize( - this->datasets(static_cast(i))); - } + // .datacatalog.Artifact artifact = 1; + if (this->has_artifact()) { + total_size += 1 + + ::google::protobuf::internal::WireFormatLite::MessageSize( + *artifact_); } - // string next_token = 2; - if (this->next_token().size() > 0) { + // .datacatalog.ReservationStatus reservation_status = 2; + if (this->reservation_status() != 0) { total_size += 1 + - ::google::protobuf::internal::WireFormatLite::StringSize( - this->next_token()); + ::google::protobuf::internal::WireFormatLite::EnumSize(this->reservation_status()); } int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); @@ -5367,66 +6226,66 @@ size_t ListDatasetsResponse::ByteSizeLong() const { return total_size; } -void ListDatasetsResponse::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:datacatalog.ListDatasetsResponse) +void GetOrReserveArtifactResponse::MergeFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_merge_from_start:datacatalog.GetOrReserveArtifactResponse) GOOGLE_DCHECK_NE(&from, this); - const ListDatasetsResponse* source = - ::google::protobuf::DynamicCastToGenerated( + const GetOrReserveArtifactResponse* source = + ::google::protobuf::DynamicCastToGenerated( &from); if (source == nullptr) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(generalized_merge_from_cast_fail:datacatalog.GetOrReserveArtifactResponse) ::google::protobuf::internal::ReflectionOps::Merge(from, this); } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(generalized_merge_from_cast_success:datacatalog.GetOrReserveArtifactResponse) MergeFrom(*source); } } -void ListDatasetsResponse::MergeFrom(const ListDatasetsResponse& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:datacatalog.ListDatasetsResponse) +void GetOrReserveArtifactResponse::MergeFrom(const GetOrReserveArtifactResponse& from) { +// @@protoc_insertion_point(class_specific_merge_from_start:datacatalog.GetOrReserveArtifactResponse) GOOGLE_DCHECK_NE(&from, this); _internal_metadata_.MergeFrom(from._internal_metadata_); ::google::protobuf::uint32 cached_has_bits = 0; (void) cached_has_bits; - datasets_.MergeFrom(from.datasets_); - if (from.next_token().size() > 0) { - - next_token_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.next_token_); + if (from.has_artifact()) { + mutable_artifact()->::datacatalog::Artifact::MergeFrom(from.artifact()); + } + if (from.reservation_status() != 0) { + set_reservation_status(from.reservation_status()); } } -void ListDatasetsResponse::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:datacatalog.ListDatasetsResponse) +void GetOrReserveArtifactResponse::CopyFrom(const ::google::protobuf::Message& from) { +// @@protoc_insertion_point(generalized_copy_from_start:datacatalog.GetOrReserveArtifactResponse) if (&from == this) return; Clear(); MergeFrom(from); } -void ListDatasetsResponse::CopyFrom(const ListDatasetsResponse& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:datacatalog.ListDatasetsResponse) +void GetOrReserveArtifactResponse::CopyFrom(const GetOrReserveArtifactResponse& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:datacatalog.GetOrReserveArtifactResponse) if (&from == this) return; Clear(); MergeFrom(from); } -bool ListDatasetsResponse::IsInitialized() const { +bool GetOrReserveArtifactResponse::IsInitialized() const { return true; } -void ListDatasetsResponse::Swap(ListDatasetsResponse* other) { +void GetOrReserveArtifactResponse::Swap(GetOrReserveArtifactResponse* other) { if (other == this) return; InternalSwap(other); } -void ListDatasetsResponse::InternalSwap(ListDatasetsResponse* other) { +void GetOrReserveArtifactResponse::InternalSwap(GetOrReserveArtifactResponse* other) { using std::swap; _internal_metadata_.Swap(&other->_internal_metadata_); - CastToBase(&datasets_)->InternalSwap(CastToBase(&other->datasets_)); - next_token_.Swap(&other->next_token_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); + swap(artifact_, other->artifact_); + swap(reservation_status_, other->reservation_status_); } -::google::protobuf::Metadata ListDatasetsResponse::GetMetadata() const { +::google::protobuf::Metadata GetOrReserveArtifactResponse::GetMetadata() const { ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto); return ::file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[kIndexInFileMessages]; } @@ -8319,7 +9178,7 @@ void Metadata_KeyMapEntry_DoNotUse::MergeFrom(const Metadata_KeyMapEntry_DoNotUs } ::google::protobuf::Metadata Metadata_KeyMapEntry_DoNotUse::GetMetadata() const { ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fdatacatalog_2fdatacatalog_2eproto); - return ::file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[20]; + return ::file_level_metadata_flyteidl_2fdatacatalog_2fdatacatalog_2eproto[22]; } void Metadata_KeyMapEntry_DoNotUse::MergeFrom( const ::google::protobuf::Message& other) { @@ -12030,6 +12889,12 @@ template<> PROTOBUF_NOINLINE ::datacatalog::ListDatasetsRequest* Arena::CreateMa template<> PROTOBUF_NOINLINE ::datacatalog::ListDatasetsResponse* Arena::CreateMaybeMessage< ::datacatalog::ListDatasetsResponse >(Arena* arena) { return Arena::CreateInternal< ::datacatalog::ListDatasetsResponse >(arena); } +template<> PROTOBUF_NOINLINE ::datacatalog::GetOrReserveArtifactRequest* Arena::CreateMaybeMessage< ::datacatalog::GetOrReserveArtifactRequest >(Arena* arena) { + return Arena::CreateInternal< ::datacatalog::GetOrReserveArtifactRequest >(arena); +} +template<> PROTOBUF_NOINLINE ::datacatalog::GetOrReserveArtifactResponse* Arena::CreateMaybeMessage< ::datacatalog::GetOrReserveArtifactResponse >(Arena* arena) { + return Arena::CreateInternal< ::datacatalog::GetOrReserveArtifactResponse >(arena); +} template<> PROTOBUF_NOINLINE ::datacatalog::Dataset* Arena::CreateMaybeMessage< ::datacatalog::Dataset >(Arena* arena) { return Arena::CreateInternal< ::datacatalog::Dataset >(arena); } diff --git a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.h b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.h index f711269ab..1cfa391e7 100644 --- a/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.h +++ b/gen/pb-cpp/flyteidl/datacatalog/datacatalog.pb.h @@ -47,7 +47,7 @@ struct TableStruct_flyteidl_2fdatacatalog_2fdatacatalog_2eproto { PROTOBUF_SECTION_VARIABLE(protodesc_cold); static const ::google::protobuf::internal::AuxillaryParseTableField aux[] PROTOBUF_SECTION_VARIABLE(protodesc_cold); - static const ::google::protobuf::internal::ParseTable schema[30] + static const ::google::protobuf::internal::ParseTable schema[32] PROTOBUF_SECTION_VARIABLE(protodesc_cold); static const ::google::protobuf::internal::FieldMetadata field_metadata[]; static const ::google::protobuf::internal::SerializationTable serialization_table[]; @@ -106,6 +106,12 @@ extern GetDatasetRequestDefaultTypeInternal _GetDatasetRequest_default_instance_ class GetDatasetResponse; class GetDatasetResponseDefaultTypeInternal; extern GetDatasetResponseDefaultTypeInternal _GetDatasetResponse_default_instance_; +class GetOrReserveArtifactRequest; +class GetOrReserveArtifactRequestDefaultTypeInternal; +extern GetOrReserveArtifactRequestDefaultTypeInternal _GetOrReserveArtifactRequest_default_instance_; +class GetOrReserveArtifactResponse; +class GetOrReserveArtifactResponseDefaultTypeInternal; +extern GetOrReserveArtifactResponseDefaultTypeInternal _GetOrReserveArtifactResponse_default_instance_; class KeyValuePair; class KeyValuePairDefaultTypeInternal; extern KeyValuePairDefaultTypeInternal _KeyValuePair_default_instance_; @@ -165,6 +171,8 @@ template<> ::datacatalog::GetArtifactRequest* Arena::CreateMaybeMessage<::dataca template<> ::datacatalog::GetArtifactResponse* Arena::CreateMaybeMessage<::datacatalog::GetArtifactResponse>(Arena*); template<> ::datacatalog::GetDatasetRequest* Arena::CreateMaybeMessage<::datacatalog::GetDatasetRequest>(Arena*); template<> ::datacatalog::GetDatasetResponse* Arena::CreateMaybeMessage<::datacatalog::GetDatasetResponse>(Arena*); +template<> ::datacatalog::GetOrReserveArtifactRequest* Arena::CreateMaybeMessage<::datacatalog::GetOrReserveArtifactRequest>(Arena*); +template<> ::datacatalog::GetOrReserveArtifactResponse* Arena::CreateMaybeMessage<::datacatalog::GetOrReserveArtifactResponse>(Arena*); template<> ::datacatalog::KeyValuePair* Arena::CreateMaybeMessage<::datacatalog::KeyValuePair>(Arena*); template<> ::datacatalog::ListArtifactsRequest* Arena::CreateMaybeMessage<::datacatalog::ListArtifactsRequest>(Arena*); template<> ::datacatalog::ListArtifactsResponse* Arena::CreateMaybeMessage<::datacatalog::ListArtifactsResponse>(Arena*); @@ -243,6 +251,27 @@ inline bool PaginationOptions_SortKey_Parse( return ::google::protobuf::internal::ParseNamedEnum( PaginationOptions_SortKey_descriptor(), name, value); } +enum ReservationStatus { + SUCCESS = 0, + FAILED = 1, + ReservationStatus_INT_MIN_SENTINEL_DO_NOT_USE_ = std::numeric_limits<::google::protobuf::int32>::min(), + ReservationStatus_INT_MAX_SENTINEL_DO_NOT_USE_ = std::numeric_limits<::google::protobuf::int32>::max() +}; +bool ReservationStatus_IsValid(int value); +const ReservationStatus ReservationStatus_MIN = SUCCESS; +const ReservationStatus ReservationStatus_MAX = FAILED; +const int ReservationStatus_ARRAYSIZE = ReservationStatus_MAX + 1; + +const ::google::protobuf::EnumDescriptor* ReservationStatus_descriptor(); +inline const ::std::string& ReservationStatus_Name(ReservationStatus value) { + return ::google::protobuf::internal::NameOfEnum( + ReservationStatus_descriptor(), value); +} +inline bool ReservationStatus_Parse( + const ::std::string& name, ReservationStatus* value) { + return ::google::protobuf::internal::ParseNamedEnum( + ReservationStatus_descriptor(), name, value); +} // =================================================================== class CreateDatasetRequest final : @@ -1945,6 +1974,268 @@ class ListDatasetsResponse final : }; // ------------------------------------------------------------------- +class GetOrReserveArtifactRequest final : + public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:datacatalog.GetOrReserveArtifactRequest) */ { + public: + GetOrReserveArtifactRequest(); + virtual ~GetOrReserveArtifactRequest(); + + GetOrReserveArtifactRequest(const GetOrReserveArtifactRequest& from); + + inline GetOrReserveArtifactRequest& operator=(const GetOrReserveArtifactRequest& from) { + CopyFrom(from); + return *this; + } + #if LANG_CXX11 + GetOrReserveArtifactRequest(GetOrReserveArtifactRequest&& from) noexcept + : GetOrReserveArtifactRequest() { + *this = ::std::move(from); + } + + inline GetOrReserveArtifactRequest& operator=(GetOrReserveArtifactRequest&& from) noexcept { + if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { + if (this != &from) InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + #endif + static const ::google::protobuf::Descriptor* descriptor() { + return default_instance().GetDescriptor(); + } + static const GetOrReserveArtifactRequest& default_instance(); + + static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY + static inline const GetOrReserveArtifactRequest* internal_default_instance() { + return reinterpret_cast( + &_GetOrReserveArtifactRequest_default_instance_); + } + static constexpr int kIndexInFileMessages = + 14; + + void Swap(GetOrReserveArtifactRequest* other); + friend void swap(GetOrReserveArtifactRequest& a, GetOrReserveArtifactRequest& b) { + a.Swap(&b); + } + + // implements Message ---------------------------------------------- + + inline GetOrReserveArtifactRequest* New() const final { + return CreateMaybeMessage(nullptr); + } + + GetOrReserveArtifactRequest* New(::google::protobuf::Arena* arena) const final { + return CreateMaybeMessage(arena); + } + void CopyFrom(const ::google::protobuf::Message& from) final; + void MergeFrom(const ::google::protobuf::Message& from) final; + void CopyFrom(const GetOrReserveArtifactRequest& from); + void MergeFrom(const GetOrReserveArtifactRequest& from); + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER + static const char* _InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx); + ::google::protobuf::internal::ParseFunc _ParseFunc() const final { return _InternalParse; } + #else + bool MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) final; + #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER + void SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const final; + ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( + ::google::protobuf::uint8* target) const final; + int GetCachedSize() const final { return _cached_size_.Get(); } + + private: + void SharedCtor(); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(GetOrReserveArtifactRequest* other); + private: + inline ::google::protobuf::Arena* GetArenaNoVirtual() const { + return nullptr; + } + inline void* MaybeArenaPtr() const { + return nullptr; + } + public: + + ::google::protobuf::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + // string tag_name = 2; + void clear_tag_name(); + static const int kTagNameFieldNumber = 2; + const ::std::string& tag_name() const; + void set_tag_name(const ::std::string& value); + #if LANG_CXX11 + void set_tag_name(::std::string&& value); + #endif + void set_tag_name(const char* value); + void set_tag_name(const char* value, size_t size); + ::std::string* mutable_tag_name(); + ::std::string* release_tag_name(); + void set_allocated_tag_name(::std::string* tag_name); + + // .datacatalog.DatasetID dataset_id = 1; + bool has_dataset_id() const; + void clear_dataset_id(); + static const int kDatasetIdFieldNumber = 1; + const ::datacatalog::DatasetID& dataset_id() const; + ::datacatalog::DatasetID* release_dataset_id(); + ::datacatalog::DatasetID* mutable_dataset_id(); + void set_allocated_dataset_id(::datacatalog::DatasetID* dataset_id); + + // .google.protobuf.Timestamp expire_at = 3; + bool has_expire_at() const; + void clear_expire_at(); + static const int kExpireAtFieldNumber = 3; + const ::google::protobuf::Timestamp& expire_at() const; + ::google::protobuf::Timestamp* release_expire_at(); + ::google::protobuf::Timestamp* mutable_expire_at(); + void set_allocated_expire_at(::google::protobuf::Timestamp* expire_at); + + // @@protoc_insertion_point(class_scope:datacatalog.GetOrReserveArtifactRequest) + private: + class HasBitSetters; + + ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; + ::google::protobuf::internal::ArenaStringPtr tag_name_; + ::datacatalog::DatasetID* dataset_id_; + ::google::protobuf::Timestamp* expire_at_; + mutable ::google::protobuf::internal::CachedSize _cached_size_; + friend struct ::TableStruct_flyteidl_2fdatacatalog_2fdatacatalog_2eproto; +}; +// ------------------------------------------------------------------- + +class GetOrReserveArtifactResponse final : + public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:datacatalog.GetOrReserveArtifactResponse) */ { + public: + GetOrReserveArtifactResponse(); + virtual ~GetOrReserveArtifactResponse(); + + GetOrReserveArtifactResponse(const GetOrReserveArtifactResponse& from); + + inline GetOrReserveArtifactResponse& operator=(const GetOrReserveArtifactResponse& from) { + CopyFrom(from); + return *this; + } + #if LANG_CXX11 + GetOrReserveArtifactResponse(GetOrReserveArtifactResponse&& from) noexcept + : GetOrReserveArtifactResponse() { + *this = ::std::move(from); + } + + inline GetOrReserveArtifactResponse& operator=(GetOrReserveArtifactResponse&& from) noexcept { + if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) { + if (this != &from) InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + #endif + static const ::google::protobuf::Descriptor* descriptor() { + return default_instance().GetDescriptor(); + } + static const GetOrReserveArtifactResponse& default_instance(); + + static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY + static inline const GetOrReserveArtifactResponse* internal_default_instance() { + return reinterpret_cast( + &_GetOrReserveArtifactResponse_default_instance_); + } + static constexpr int kIndexInFileMessages = + 15; + + void Swap(GetOrReserveArtifactResponse* other); + friend void swap(GetOrReserveArtifactResponse& a, GetOrReserveArtifactResponse& b) { + a.Swap(&b); + } + + // implements Message ---------------------------------------------- + + inline GetOrReserveArtifactResponse* New() const final { + return CreateMaybeMessage(nullptr); + } + + GetOrReserveArtifactResponse* New(::google::protobuf::Arena* arena) const final { + return CreateMaybeMessage(arena); + } + void CopyFrom(const ::google::protobuf::Message& from) final; + void MergeFrom(const ::google::protobuf::Message& from) final; + void CopyFrom(const GetOrReserveArtifactResponse& from); + void MergeFrom(const GetOrReserveArtifactResponse& from); + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER + static const char* _InternalParse(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx); + ::google::protobuf::internal::ParseFunc _ParseFunc() const final { return _InternalParse; } + #else + bool MergePartialFromCodedStream( + ::google::protobuf::io::CodedInputStream* input) final; + #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER + void SerializeWithCachedSizes( + ::google::protobuf::io::CodedOutputStream* output) const final; + ::google::protobuf::uint8* InternalSerializeWithCachedSizesToArray( + ::google::protobuf::uint8* target) const final; + int GetCachedSize() const final { return _cached_size_.Get(); } + + private: + void SharedCtor(); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(GetOrReserveArtifactResponse* other); + private: + inline ::google::protobuf::Arena* GetArenaNoVirtual() const { + return nullptr; + } + inline void* MaybeArenaPtr() const { + return nullptr; + } + public: + + ::google::protobuf::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + // accessors ------------------------------------------------------- + + // .datacatalog.Artifact artifact = 1; + bool has_artifact() const; + void clear_artifact(); + static const int kArtifactFieldNumber = 1; + const ::datacatalog::Artifact& artifact() const; + ::datacatalog::Artifact* release_artifact(); + ::datacatalog::Artifact* mutable_artifact(); + void set_allocated_artifact(::datacatalog::Artifact* artifact); + + // .datacatalog.ReservationStatus reservation_status = 2; + void clear_reservation_status(); + static const int kReservationStatusFieldNumber = 2; + ::datacatalog::ReservationStatus reservation_status() const; + void set_reservation_status(::datacatalog::ReservationStatus value); + + // @@protoc_insertion_point(class_scope:datacatalog.GetOrReserveArtifactResponse) + private: + class HasBitSetters; + + ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; + ::datacatalog::Artifact* artifact_; + int reservation_status_; + mutable ::google::protobuf::internal::CachedSize _cached_size_; + friend struct ::TableStruct_flyteidl_2fdatacatalog_2fdatacatalog_2eproto; +}; +// ------------------------------------------------------------------- + class Dataset final : public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:datacatalog.Dataset) */ { public: @@ -1983,7 +2274,7 @@ class Dataset final : &_Dataset_default_instance_); } static constexpr int kIndexInFileMessages = - 14; + 16; void Swap(Dataset* other); friend void swap(Dataset& a, Dataset& b) { @@ -2131,7 +2422,7 @@ class Partition final : &_Partition_default_instance_); } static constexpr int kIndexInFileMessages = - 15; + 17; void Swap(Partition* other); friend void swap(Partition& a, Partition& b) { @@ -2266,7 +2557,7 @@ class DatasetID final : &_DatasetID_default_instance_); } static constexpr int kIndexInFileMessages = - 16; + 18; void Swap(DatasetID* other); friend void swap(DatasetID& a, DatasetID& b) { @@ -2446,7 +2737,7 @@ class Artifact final : &_Artifact_default_instance_); } static constexpr int kIndexInFileMessages = - 17; + 19; void Swap(Artifact* other); friend void swap(Artifact& a, Artifact& b) { @@ -2635,7 +2926,7 @@ class ArtifactData final : &_ArtifactData_default_instance_); } static constexpr int kIndexInFileMessages = - 18; + 20; void Swap(ArtifactData* other); friend void swap(ArtifactData& a, ArtifactData& b) { @@ -2765,7 +3056,7 @@ class Tag final : &_Tag_default_instance_); } static constexpr int kIndexInFileMessages = - 19; + 21; void Swap(Tag* other); friend void swap(Tag& a, Tag& b) { @@ -2934,7 +3225,7 @@ class Metadata final : &_Metadata_default_instance_); } static constexpr int kIndexInFileMessages = - 21; + 23; void Swap(Metadata* other); friend void swap(Metadata& a, Metadata& b) { @@ -3055,7 +3346,7 @@ class FilterExpression final : &_FilterExpression_default_instance_); } static constexpr int kIndexInFileMessages = - 22; + 24; void Swap(FilterExpression* other); friend void swap(FilterExpression& a, FilterExpression& b) { @@ -3181,7 +3472,7 @@ class SinglePropertyFilter final : &_SinglePropertyFilter_default_instance_); } static constexpr int kIndexInFileMessages = - 23; + 25; void Swap(SinglePropertyFilter* other); friend void swap(SinglePropertyFilter& a, SinglePropertyFilter& b) { @@ -3376,7 +3667,7 @@ class ArtifactPropertyFilter final : &_ArtifactPropertyFilter_default_instance_); } static constexpr int kIndexInFileMessages = - 24; + 26; void Swap(ArtifactPropertyFilter* other); friend void swap(ArtifactPropertyFilter& a, ArtifactPropertyFilter& b) { @@ -3515,7 +3806,7 @@ class TagPropertyFilter final : &_TagPropertyFilter_default_instance_); } static constexpr int kIndexInFileMessages = - 25; + 27; void Swap(TagPropertyFilter* other); friend void swap(TagPropertyFilter& a, TagPropertyFilter& b) { @@ -3654,7 +3945,7 @@ class PartitionPropertyFilter final : &_PartitionPropertyFilter_default_instance_); } static constexpr int kIndexInFileMessages = - 26; + 28; void Swap(PartitionPropertyFilter* other); friend void swap(PartitionPropertyFilter& a, PartitionPropertyFilter& b) { @@ -3780,7 +4071,7 @@ class KeyValuePair final : &_KeyValuePair_default_instance_); } static constexpr int kIndexInFileMessages = - 27; + 29; void Swap(KeyValuePair* other); friend void swap(KeyValuePair& a, KeyValuePair& b) { @@ -3923,7 +4214,7 @@ class DatasetPropertyFilter final : &_DatasetPropertyFilter_default_instance_); } static constexpr int kIndexInFileMessages = - 28; + 30; void Swap(DatasetPropertyFilter* other); friend void swap(DatasetPropertyFilter& a, DatasetPropertyFilter& b) { @@ -4114,7 +4405,7 @@ class PaginationOptions final : &_PaginationOptions_default_instance_); } static constexpr int kIndexInFileMessages = - 29; + 31; void Swap(PaginationOptions* other); friend void swap(PaginationOptions& a, PaginationOptions& b) { @@ -5301,6 +5592,229 @@ inline void ListDatasetsResponse::set_allocated_next_token(::std::string* next_t // ------------------------------------------------------------------- +// GetOrReserveArtifactRequest + +// .datacatalog.DatasetID dataset_id = 1; +inline bool GetOrReserveArtifactRequest::has_dataset_id() const { + return this != internal_default_instance() && dataset_id_ != nullptr; +} +inline void GetOrReserveArtifactRequest::clear_dataset_id() { + if (GetArenaNoVirtual() == nullptr && dataset_id_ != nullptr) { + delete dataset_id_; + } + dataset_id_ = nullptr; +} +inline const ::datacatalog::DatasetID& GetOrReserveArtifactRequest::dataset_id() const { + const ::datacatalog::DatasetID* p = dataset_id_; + // @@protoc_insertion_point(field_get:datacatalog.GetOrReserveArtifactRequest.dataset_id) + return p != nullptr ? *p : *reinterpret_cast( + &::datacatalog::_DatasetID_default_instance_); +} +inline ::datacatalog::DatasetID* GetOrReserveArtifactRequest::release_dataset_id() { + // @@protoc_insertion_point(field_release:datacatalog.GetOrReserveArtifactRequest.dataset_id) + + ::datacatalog::DatasetID* temp = dataset_id_; + dataset_id_ = nullptr; + return temp; +} +inline ::datacatalog::DatasetID* GetOrReserveArtifactRequest::mutable_dataset_id() { + + if (dataset_id_ == nullptr) { + auto* p = CreateMaybeMessage<::datacatalog::DatasetID>(GetArenaNoVirtual()); + dataset_id_ = p; + } + // @@protoc_insertion_point(field_mutable:datacatalog.GetOrReserveArtifactRequest.dataset_id) + return dataset_id_; +} +inline void GetOrReserveArtifactRequest::set_allocated_dataset_id(::datacatalog::DatasetID* dataset_id) { + ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); + if (message_arena == nullptr) { + delete dataset_id_; + } + if (dataset_id) { + ::google::protobuf::Arena* submessage_arena = nullptr; + if (message_arena != submessage_arena) { + dataset_id = ::google::protobuf::internal::GetOwnedMessage( + message_arena, dataset_id, submessage_arena); + } + + } else { + + } + dataset_id_ = dataset_id; + // @@protoc_insertion_point(field_set_allocated:datacatalog.GetOrReserveArtifactRequest.dataset_id) +} + +// string tag_name = 2; +inline void GetOrReserveArtifactRequest::clear_tag_name() { + tag_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); +} +inline const ::std::string& GetOrReserveArtifactRequest::tag_name() const { + // @@protoc_insertion_point(field_get:datacatalog.GetOrReserveArtifactRequest.tag_name) + return tag_name_.GetNoArena(); +} +inline void GetOrReserveArtifactRequest::set_tag_name(const ::std::string& value) { + + tag_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value); + // @@protoc_insertion_point(field_set:datacatalog.GetOrReserveArtifactRequest.tag_name) +} +#if LANG_CXX11 +inline void GetOrReserveArtifactRequest::set_tag_name(::std::string&& value) { + + tag_name_.SetNoArena( + &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value)); + // @@protoc_insertion_point(field_set_rvalue:datacatalog.GetOrReserveArtifactRequest.tag_name) +} +#endif +inline void GetOrReserveArtifactRequest::set_tag_name(const char* value) { + GOOGLE_DCHECK(value != nullptr); + + tag_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value)); + // @@protoc_insertion_point(field_set_char:datacatalog.GetOrReserveArtifactRequest.tag_name) +} +inline void GetOrReserveArtifactRequest::set_tag_name(const char* value, size_t size) { + + tag_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), + ::std::string(reinterpret_cast(value), size)); + // @@protoc_insertion_point(field_set_pointer:datacatalog.GetOrReserveArtifactRequest.tag_name) +} +inline ::std::string* GetOrReserveArtifactRequest::mutable_tag_name() { + + // @@protoc_insertion_point(field_mutable:datacatalog.GetOrReserveArtifactRequest.tag_name) + return tag_name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); +} +inline ::std::string* GetOrReserveArtifactRequest::release_tag_name() { + // @@protoc_insertion_point(field_release:datacatalog.GetOrReserveArtifactRequest.tag_name) + + return tag_name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); +} +inline void GetOrReserveArtifactRequest::set_allocated_tag_name(::std::string* tag_name) { + if (tag_name != nullptr) { + + } else { + + } + tag_name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), tag_name); + // @@protoc_insertion_point(field_set_allocated:datacatalog.GetOrReserveArtifactRequest.tag_name) +} + +// .google.protobuf.Timestamp expire_at = 3; +inline bool GetOrReserveArtifactRequest::has_expire_at() const { + return this != internal_default_instance() && expire_at_ != nullptr; +} +inline const ::google::protobuf::Timestamp& GetOrReserveArtifactRequest::expire_at() const { + const ::google::protobuf::Timestamp* p = expire_at_; + // @@protoc_insertion_point(field_get:datacatalog.GetOrReserveArtifactRequest.expire_at) + return p != nullptr ? *p : *reinterpret_cast( + &::google::protobuf::_Timestamp_default_instance_); +} +inline ::google::protobuf::Timestamp* GetOrReserveArtifactRequest::release_expire_at() { + // @@protoc_insertion_point(field_release:datacatalog.GetOrReserveArtifactRequest.expire_at) + + ::google::protobuf::Timestamp* temp = expire_at_; + expire_at_ = nullptr; + return temp; +} +inline ::google::protobuf::Timestamp* GetOrReserveArtifactRequest::mutable_expire_at() { + + if (expire_at_ == nullptr) { + auto* p = CreateMaybeMessage<::google::protobuf::Timestamp>(GetArenaNoVirtual()); + expire_at_ = p; + } + // @@protoc_insertion_point(field_mutable:datacatalog.GetOrReserveArtifactRequest.expire_at) + return expire_at_; +} +inline void GetOrReserveArtifactRequest::set_allocated_expire_at(::google::protobuf::Timestamp* expire_at) { + ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); + if (message_arena == nullptr) { + delete reinterpret_cast< ::google::protobuf::MessageLite*>(expire_at_); + } + if (expire_at) { + ::google::protobuf::Arena* submessage_arena = + reinterpret_cast<::google::protobuf::MessageLite*>(expire_at)->GetArena(); + if (message_arena != submessage_arena) { + expire_at = ::google::protobuf::internal::GetOwnedMessage( + message_arena, expire_at, submessage_arena); + } + + } else { + + } + expire_at_ = expire_at; + // @@protoc_insertion_point(field_set_allocated:datacatalog.GetOrReserveArtifactRequest.expire_at) +} + +// ------------------------------------------------------------------- + +// GetOrReserveArtifactResponse + +// .datacatalog.Artifact artifact = 1; +inline bool GetOrReserveArtifactResponse::has_artifact() const { + return this != internal_default_instance() && artifact_ != nullptr; +} +inline void GetOrReserveArtifactResponse::clear_artifact() { + if (GetArenaNoVirtual() == nullptr && artifact_ != nullptr) { + delete artifact_; + } + artifact_ = nullptr; +} +inline const ::datacatalog::Artifact& GetOrReserveArtifactResponse::artifact() const { + const ::datacatalog::Artifact* p = artifact_; + // @@protoc_insertion_point(field_get:datacatalog.GetOrReserveArtifactResponse.artifact) + return p != nullptr ? *p : *reinterpret_cast( + &::datacatalog::_Artifact_default_instance_); +} +inline ::datacatalog::Artifact* GetOrReserveArtifactResponse::release_artifact() { + // @@protoc_insertion_point(field_release:datacatalog.GetOrReserveArtifactResponse.artifact) + + ::datacatalog::Artifact* temp = artifact_; + artifact_ = nullptr; + return temp; +} +inline ::datacatalog::Artifact* GetOrReserveArtifactResponse::mutable_artifact() { + + if (artifact_ == nullptr) { + auto* p = CreateMaybeMessage<::datacatalog::Artifact>(GetArenaNoVirtual()); + artifact_ = p; + } + // @@protoc_insertion_point(field_mutable:datacatalog.GetOrReserveArtifactResponse.artifact) + return artifact_; +} +inline void GetOrReserveArtifactResponse::set_allocated_artifact(::datacatalog::Artifact* artifact) { + ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); + if (message_arena == nullptr) { + delete artifact_; + } + if (artifact) { + ::google::protobuf::Arena* submessage_arena = nullptr; + if (message_arena != submessage_arena) { + artifact = ::google::protobuf::internal::GetOwnedMessage( + message_arena, artifact, submessage_arena); + } + + } else { + + } + artifact_ = artifact; + // @@protoc_insertion_point(field_set_allocated:datacatalog.GetOrReserveArtifactResponse.artifact) +} + +// .datacatalog.ReservationStatus reservation_status = 2; +inline void GetOrReserveArtifactResponse::clear_reservation_status() { + reservation_status_ = 0; +} +inline ::datacatalog::ReservationStatus GetOrReserveArtifactResponse::reservation_status() const { + // @@protoc_insertion_point(field_get:datacatalog.GetOrReserveArtifactResponse.reservation_status) + return static_cast< ::datacatalog::ReservationStatus >(reservation_status_); +} +inline void GetOrReserveArtifactResponse::set_reservation_status(::datacatalog::ReservationStatus value) { + + reservation_status_ = value; + // @@protoc_insertion_point(field_set:datacatalog.GetOrReserveArtifactResponse.reservation_status) +} + +// ------------------------------------------------------------------- + // Dataset // .datacatalog.DatasetID id = 1; @@ -7575,6 +8089,10 @@ inline void PaginationOptions::set_sortorder(::datacatalog::PaginationOptions_So // ------------------------------------------------------------------- +// ------------------------------------------------------------------- + +// ------------------------------------------------------------------- + // @@protoc_insertion_point(namespace_scope) @@ -7598,6 +8116,11 @@ template <> inline const EnumDescriptor* GetEnumDescriptor< ::datacatalog::PaginationOptions_SortKey>() { return ::datacatalog::PaginationOptions_SortKey_descriptor(); } +template <> struct is_proto_enum< ::datacatalog::ReservationStatus> : ::std::true_type {}; +template <> +inline const EnumDescriptor* GetEnumDescriptor< ::datacatalog::ReservationStatus>() { + return ::datacatalog::ReservationStatus_descriptor(); +} } // namespace protobuf } // namespace google diff --git a/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.go b/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.go index 47e4fa072..14ee31479 100644 --- a/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.go +++ b/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.go @@ -26,6 +26,31 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package +type ReservationStatus int32 + +const ( + ReservationStatus_SUCCESS ReservationStatus = 0 + ReservationStatus_FAILED ReservationStatus = 1 +) + +var ReservationStatus_name = map[int32]string{ + 0: "SUCCESS", + 1: "FAILED", +} + +var ReservationStatus_value = map[string]int32{ + "SUCCESS": 0, + "FAILED": 1, +} + +func (x ReservationStatus) String() string { + return proto.EnumName(ReservationStatus_name, int32(x)) +} + +func (ReservationStatus) EnumDescriptor() ([]byte, []int) { + return fileDescriptor_275951237ff4368a, []int{0} +} + // as use-cases come up we can add more operators, ex: gte, like, not eq etc. type SinglePropertyFilter_ComparisonOperator int32 @@ -46,7 +71,7 @@ func (x SinglePropertyFilter_ComparisonOperator) String() string { } func (SinglePropertyFilter_ComparisonOperator) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{22, 0} + return fileDescriptor_275951237ff4368a, []int{24, 0} } type PaginationOptions_SortOrder int32 @@ -71,7 +96,7 @@ func (x PaginationOptions_SortOrder) String() string { } func (PaginationOptions_SortOrder) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{28, 0} + return fileDescriptor_275951237ff4368a, []int{30, 0} } type PaginationOptions_SortKey int32 @@ -93,7 +118,7 @@ func (x PaginationOptions_SortKey) String() string { } func (PaginationOptions_SortKey) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{28, 1} + return fileDescriptor_275951237ff4368a, []int{30, 1} } // @@ -745,6 +770,108 @@ func (m *ListDatasetsResponse) GetNextToken() string { return "" } +type GetOrReserveArtifactRequest struct { + DatasetId *DatasetID `protobuf:"bytes,1,opt,name=dataset_id,json=datasetId,proto3" json:"dataset_id,omitempty"` + TagName string `protobuf:"bytes,2,opt,name=tag_name,json=tagName,proto3" json:"tag_name,omitempty"` + ExpireAt *timestamp.Timestamp `protobuf:"bytes,3,opt,name=expire_at,json=expireAt,proto3" json:"expire_at,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetOrReserveArtifactRequest) Reset() { *m = GetOrReserveArtifactRequest{} } +func (m *GetOrReserveArtifactRequest) String() string { return proto.CompactTextString(m) } +func (*GetOrReserveArtifactRequest) ProtoMessage() {} +func (*GetOrReserveArtifactRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_275951237ff4368a, []int{14} +} + +func (m *GetOrReserveArtifactRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetOrReserveArtifactRequest.Unmarshal(m, b) +} +func (m *GetOrReserveArtifactRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetOrReserveArtifactRequest.Marshal(b, m, deterministic) +} +func (m *GetOrReserveArtifactRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetOrReserveArtifactRequest.Merge(m, src) +} +func (m *GetOrReserveArtifactRequest) XXX_Size() int { + return xxx_messageInfo_GetOrReserveArtifactRequest.Size(m) +} +func (m *GetOrReserveArtifactRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetOrReserveArtifactRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetOrReserveArtifactRequest proto.InternalMessageInfo + +func (m *GetOrReserveArtifactRequest) GetDatasetId() *DatasetID { + if m != nil { + return m.DatasetId + } + return nil +} + +func (m *GetOrReserveArtifactRequest) GetTagName() string { + if m != nil { + return m.TagName + } + return "" +} + +func (m *GetOrReserveArtifactRequest) GetExpireAt() *timestamp.Timestamp { + if m != nil { + return m.ExpireAt + } + return nil +} + +type GetOrReserveArtifactResponse struct { + Artifact *Artifact `protobuf:"bytes,1,opt,name=artifact,proto3" json:"artifact,omitempty"` + ReservationStatus ReservationStatus `protobuf:"varint,2,opt,name=reservation_status,json=reservationStatus,proto3,enum=datacatalog.ReservationStatus" json:"reservation_status,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *GetOrReserveArtifactResponse) Reset() { *m = GetOrReserveArtifactResponse{} } +func (m *GetOrReserveArtifactResponse) String() string { return proto.CompactTextString(m) } +func (*GetOrReserveArtifactResponse) ProtoMessage() {} +func (*GetOrReserveArtifactResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_275951237ff4368a, []int{15} +} + +func (m *GetOrReserveArtifactResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_GetOrReserveArtifactResponse.Unmarshal(m, b) +} +func (m *GetOrReserveArtifactResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_GetOrReserveArtifactResponse.Marshal(b, m, deterministic) +} +func (m *GetOrReserveArtifactResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetOrReserveArtifactResponse.Merge(m, src) +} +func (m *GetOrReserveArtifactResponse) XXX_Size() int { + return xxx_messageInfo_GetOrReserveArtifactResponse.Size(m) +} +func (m *GetOrReserveArtifactResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetOrReserveArtifactResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetOrReserveArtifactResponse proto.InternalMessageInfo + +func (m *GetOrReserveArtifactResponse) GetArtifact() *Artifact { + if m != nil { + return m.Artifact + } + return nil +} + +func (m *GetOrReserveArtifactResponse) GetReservationStatus() ReservationStatus { + if m != nil { + return m.ReservationStatus + } + return ReservationStatus_SUCCESS +} + // // Dataset message. It is uniquely identified by DatasetID. type Dataset struct { @@ -760,7 +887,7 @@ func (m *Dataset) Reset() { *m = Dataset{} } func (m *Dataset) String() string { return proto.CompactTextString(m) } func (*Dataset) ProtoMessage() {} func (*Dataset) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{14} + return fileDescriptor_275951237ff4368a, []int{16} } func (m *Dataset) XXX_Unmarshal(b []byte) error { @@ -816,7 +943,7 @@ func (m *Partition) Reset() { *m = Partition{} } func (m *Partition) String() string { return proto.CompactTextString(m) } func (*Partition) ProtoMessage() {} func (*Partition) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{15} + return fileDescriptor_275951237ff4368a, []int{17} } func (m *Partition) XXX_Unmarshal(b []byte) error { @@ -868,7 +995,7 @@ func (m *DatasetID) Reset() { *m = DatasetID{} } func (m *DatasetID) String() string { return proto.CompactTextString(m) } func (*DatasetID) ProtoMessage() {} func (*DatasetID) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{16} + return fileDescriptor_275951237ff4368a, []int{18} } func (m *DatasetID) XXX_Unmarshal(b []byte) error { @@ -943,7 +1070,7 @@ func (m *Artifact) Reset() { *m = Artifact{} } func (m *Artifact) String() string { return proto.CompactTextString(m) } func (*Artifact) ProtoMessage() {} func (*Artifact) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{17} + return fileDescriptor_275951237ff4368a, []int{19} } func (m *Artifact) XXX_Unmarshal(b []byte) error { @@ -1027,7 +1154,7 @@ func (m *ArtifactData) Reset() { *m = ArtifactData{} } func (m *ArtifactData) String() string { return proto.CompactTextString(m) } func (*ArtifactData) ProtoMessage() {} func (*ArtifactData) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{18} + return fileDescriptor_275951237ff4368a, []int{20} } func (m *ArtifactData) XXX_Unmarshal(b []byte) error { @@ -1078,7 +1205,7 @@ func (m *Tag) Reset() { *m = Tag{} } func (m *Tag) String() string { return proto.CompactTextString(m) } func (*Tag) ProtoMessage() {} func (*Tag) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{19} + return fileDescriptor_275951237ff4368a, []int{21} } func (m *Tag) XXX_Unmarshal(b []byte) error { @@ -1133,7 +1260,7 @@ func (m *Metadata) Reset() { *m = Metadata{} } func (m *Metadata) String() string { return proto.CompactTextString(m) } func (*Metadata) ProtoMessage() {} func (*Metadata) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{20} + return fileDescriptor_275951237ff4368a, []int{22} } func (m *Metadata) XXX_Unmarshal(b []byte) error { @@ -1173,7 +1300,7 @@ func (m *FilterExpression) Reset() { *m = FilterExpression{} } func (m *FilterExpression) String() string { return proto.CompactTextString(m) } func (*FilterExpression) ProtoMessage() {} func (*FilterExpression) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{21} + return fileDescriptor_275951237ff4368a, []int{23} } func (m *FilterExpression) XXX_Unmarshal(b []byte) error { @@ -1219,7 +1346,7 @@ func (m *SinglePropertyFilter) Reset() { *m = SinglePropertyFilter{} } func (m *SinglePropertyFilter) String() string { return proto.CompactTextString(m) } func (*SinglePropertyFilter) ProtoMessage() {} func (*SinglePropertyFilter) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{22} + return fileDescriptor_275951237ff4368a, []int{24} } func (m *SinglePropertyFilter) XXX_Unmarshal(b []byte) error { @@ -1336,7 +1463,7 @@ func (m *ArtifactPropertyFilter) Reset() { *m = ArtifactPropertyFilter{} func (m *ArtifactPropertyFilter) String() string { return proto.CompactTextString(m) } func (*ArtifactPropertyFilter) ProtoMessage() {} func (*ArtifactPropertyFilter) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{23} + return fileDescriptor_275951237ff4368a, []int{25} } func (m *ArtifactPropertyFilter) XXX_Unmarshal(b []byte) error { @@ -1402,7 +1529,7 @@ func (m *TagPropertyFilter) Reset() { *m = TagPropertyFilter{} } func (m *TagPropertyFilter) String() string { return proto.CompactTextString(m) } func (*TagPropertyFilter) ProtoMessage() {} func (*TagPropertyFilter) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{24} + return fileDescriptor_275951237ff4368a, []int{26} } func (m *TagPropertyFilter) XXX_Unmarshal(b []byte) error { @@ -1468,7 +1595,7 @@ func (m *PartitionPropertyFilter) Reset() { *m = PartitionPropertyFilter func (m *PartitionPropertyFilter) String() string { return proto.CompactTextString(m) } func (*PartitionPropertyFilter) ProtoMessage() {} func (*PartitionPropertyFilter) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{25} + return fileDescriptor_275951237ff4368a, []int{27} } func (m *PartitionPropertyFilter) XXX_Unmarshal(b []byte) error { @@ -1532,7 +1659,7 @@ func (m *KeyValuePair) Reset() { *m = KeyValuePair{} } func (m *KeyValuePair) String() string { return proto.CompactTextString(m) } func (*KeyValuePair) ProtoMessage() {} func (*KeyValuePair) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{26} + return fileDescriptor_275951237ff4368a, []int{28} } func (m *KeyValuePair) XXX_Unmarshal(b []byte) error { @@ -1584,7 +1711,7 @@ func (m *DatasetPropertyFilter) Reset() { *m = DatasetPropertyFilter{} } func (m *DatasetPropertyFilter) String() string { return proto.CompactTextString(m) } func (*DatasetPropertyFilter) ProtoMessage() {} func (*DatasetPropertyFilter) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{27} + return fileDescriptor_275951237ff4368a, []int{29} } func (m *DatasetPropertyFilter) XXX_Unmarshal(b []byte) error { @@ -1697,7 +1824,7 @@ func (m *PaginationOptions) Reset() { *m = PaginationOptions{} } func (m *PaginationOptions) String() string { return proto.CompactTextString(m) } func (*PaginationOptions) ProtoMessage() {} func (*PaginationOptions) Descriptor() ([]byte, []int) { - return fileDescriptor_275951237ff4368a, []int{28} + return fileDescriptor_275951237ff4368a, []int{30} } func (m *PaginationOptions) XXX_Unmarshal(b []byte) error { @@ -1747,6 +1874,7 @@ func (m *PaginationOptions) GetSortOrder() PaginationOptions_SortOrder { } func init() { + proto.RegisterEnum("datacatalog.ReservationStatus", ReservationStatus_name, ReservationStatus_value) proto.RegisterEnum("datacatalog.SinglePropertyFilter_ComparisonOperator", SinglePropertyFilter_ComparisonOperator_name, SinglePropertyFilter_ComparisonOperator_value) proto.RegisterEnum("datacatalog.PaginationOptions_SortOrder", PaginationOptions_SortOrder_name, PaginationOptions_SortOrder_value) proto.RegisterEnum("datacatalog.PaginationOptions_SortKey", PaginationOptions_SortKey_name, PaginationOptions_SortKey_value) @@ -1764,6 +1892,8 @@ func init() { proto.RegisterType((*ListArtifactsResponse)(nil), "datacatalog.ListArtifactsResponse") proto.RegisterType((*ListDatasetsRequest)(nil), "datacatalog.ListDatasetsRequest") proto.RegisterType((*ListDatasetsResponse)(nil), "datacatalog.ListDatasetsResponse") + proto.RegisterType((*GetOrReserveArtifactRequest)(nil), "datacatalog.GetOrReserveArtifactRequest") + proto.RegisterType((*GetOrReserveArtifactResponse)(nil), "datacatalog.GetOrReserveArtifactResponse") proto.RegisterType((*Dataset)(nil), "datacatalog.Dataset") proto.RegisterType((*Partition)(nil), "datacatalog.Partition") proto.RegisterType((*DatasetID)(nil), "datacatalog.DatasetID") @@ -1787,92 +1917,100 @@ func init() { } var fileDescriptor_275951237ff4368a = []byte{ - // 1347 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x57, 0x5f, 0x6f, 0xdb, 0xb6, - 0x17, 0xb5, 0x6c, 0xd7, 0xb6, 0xae, 0x63, 0xd7, 0x61, 0x9d, 0x54, 0x3f, 0xf5, 0x9f, 0xab, 0x16, - 0x45, 0xf0, 0xc3, 0xe6, 0x74, 0x4e, 0x57, 0xac, 0xdd, 0xb0, 0xcd, 0x8d, 0xdd, 0xc6, 0x4b, 0x93, - 0xb8, 0x8a, 0x1b, 0x60, 0xd8, 0x83, 0xc1, 0x46, 0x8c, 0xa6, 0x45, 0xb6, 0x54, 0x89, 0x29, 0xea, - 0xa7, 0x61, 0xaf, 0xdb, 0xde, 0x06, 0xec, 0xeb, 0xec, 0x71, 0x6f, 0x03, 0xf6, 0x8d, 0x06, 0x8a, - 0x94, 0x2c, 0xc9, 0x4a, 0xea, 0xe6, 0xc5, 0x10, 0xc9, 0x73, 0x8f, 0xef, 0xe5, 0xb9, 0xe4, 0xbd, - 0x84, 0x07, 0x27, 0xf6, 0x8c, 0x12, 0xcb, 0xb0, 0x37, 0x0d, 0x4c, 0xf1, 0x31, 0xa6, 0xd8, 0x76, - 0xcc, 0xf8, 0x77, 0xdb, 0xf5, 0x1c, 0xea, 0xa0, 0x6a, 0x6c, 0x4a, 0xbd, 0x19, 0x19, 0x1d, 0x3b, - 0x1e, 0xd9, 0xb4, 0x2d, 0x4a, 0x3c, 0x6c, 0xfb, 0x1c, 0xaa, 0xde, 0x31, 0x1d, 0xc7, 0xb4, 0xc9, - 0x66, 0x30, 0x7a, 0x73, 0x76, 0xb2, 0x49, 0xad, 0x09, 0xf1, 0x29, 0x9e, 0xb8, 0x1c, 0xa0, 0x3d, - 0x87, 0xe6, 0xb6, 0x47, 0x30, 0x25, 0x3d, 0x4c, 0xb1, 0x4f, 0xa8, 0x4e, 0xde, 0x9e, 0x11, 0x9f, - 0xa2, 0x36, 0x94, 0x0d, 0x3e, 0xa3, 0x48, 0x2d, 0x69, 0xa3, 0xda, 0x69, 0xb6, 0xe3, 0x8e, 0x84, - 0xe8, 0x10, 0xa4, 0x5d, 0x87, 0xb5, 0x14, 0x8f, 0xef, 0x3a, 0x53, 0x9f, 0x68, 0x7d, 0x58, 0x7d, - 0x41, 0x68, 0x8a, 0xfd, 0x61, 0x9a, 0x7d, 0x3d, 0x8b, 0x7d, 0xd0, 0x9b, 0xf3, 0xf7, 0x00, 0xc5, - 0x69, 0x38, 0xf9, 0x47, 0x7b, 0xf9, 0xa7, 0x14, 0xd0, 0x74, 0x3d, 0x6a, 0x9d, 0xe0, 0xe3, 0xcb, - 0xbb, 0x83, 0xee, 0x42, 0x15, 0x0b, 0x92, 0xb1, 0x65, 0x28, 0xf9, 0x96, 0xb4, 0x21, 0xef, 0xe4, - 0x74, 0x08, 0x27, 0x07, 0x06, 0xba, 0x01, 0x15, 0x8a, 0xcd, 0xf1, 0x14, 0x4f, 0x88, 0x52, 0x10, - 0xeb, 0x65, 0x8a, 0xcd, 0x7d, 0x3c, 0x21, 0xcf, 0xea, 0xb0, 0xf2, 0xf6, 0x8c, 0x78, 0xb3, 0xf1, - 0x8f, 0x78, 0x6a, 0xd8, 0x44, 0xdb, 0x81, 0x6b, 0x09, 0xbf, 0x44, 0x7c, 0x9f, 0x41, 0x25, 0x64, - 0x14, 0x9e, 0xad, 0x25, 0x3c, 0x8b, 0x0c, 0x22, 0x98, 0xf6, 0x5d, 0x28, 0x44, 0x3a, 0xc8, 0x4b, - 0x70, 0x29, 0xb0, 0x9e, 0xe6, 0x12, 0xaa, 0x6e, 0x41, 0xad, 0x6b, 0x18, 0x23, 0x6c, 0x86, 0xec, - 0x1a, 0x14, 0x28, 0x36, 0x05, 0x71, 0x23, 0x41, 0xcc, 0x50, 0x6c, 0x51, 0x6b, 0x40, 0x3d, 0x34, - 0x12, 0x34, 0x7f, 0x49, 0xd0, 0x7c, 0x69, 0xf9, 0x51, 0xe0, 0xfe, 0xe5, 0x15, 0xf9, 0x1c, 0x4a, - 0x27, 0x96, 0x4d, 0x89, 0x17, 0x88, 0x51, 0xed, 0xdc, 0x4a, 0x18, 0x3c, 0x0f, 0x96, 0xfa, 0xef, - 0x5d, 0x8f, 0xf8, 0xbe, 0xe5, 0x4c, 0x75, 0x01, 0x46, 0x5f, 0x03, 0xb8, 0xd8, 0xb4, 0xa6, 0x98, - 0x5a, 0xce, 0x34, 0xd0, 0xa9, 0xda, 0xb9, 0x9d, 0x30, 0x1d, 0x46, 0xcb, 0x07, 0x2e, 0xfb, 0xf5, - 0xf5, 0x98, 0x85, 0x76, 0x0a, 0x6b, 0xa9, 0x00, 0x84, 0x74, 0x5b, 0x20, 0x87, 0xfb, 0xe8, 0x2b, - 0x52, 0xab, 0x70, 0xfe, 0x7e, 0xcf, 0x71, 0xe8, 0x16, 0xc0, 0x94, 0xbc, 0xa7, 0x63, 0xea, 0x9c, - 0x92, 0x29, 0xcf, 0x2a, 0x5d, 0x66, 0x33, 0x23, 0x36, 0xa1, 0xfd, 0x2e, 0xc1, 0x35, 0xf6, 0x6f, - 0x22, 0xfc, 0x68, 0xb7, 0xe6, 0xb1, 0x4b, 0x97, 0x8f, 0x3d, 0xff, 0xd1, 0xb1, 0x9b, 0x5c, 0xbc, - 0xb9, 0x37, 0x22, 0xf4, 0x87, 0x50, 0x11, 0xaa, 0x84, 0x91, 0x67, 0x1f, 0xcb, 0x08, 0xf5, 0xa1, - 0xb8, 0x7f, 0x95, 0xa0, 0x2c, 0x8c, 0xd0, 0x03, 0xc8, 0x5b, 0xc6, 0x07, 0x92, 0x22, 0x6f, 0x19, - 0x2c, 0xdd, 0x27, 0x84, 0x62, 0x06, 0x10, 0xa1, 0x25, 0xb7, 0x7f, 0x4f, 0x2c, 0xea, 0x11, 0x0c, - 0xdd, 0x87, 0x9a, 0xcb, 0xb4, 0x60, 0xc1, 0xed, 0x92, 0x99, 0xaf, 0x14, 0x5a, 0x85, 0x0d, 0x59, - 0x4f, 0x4e, 0x6a, 0x5b, 0x20, 0x0f, 0xc3, 0x09, 0xd4, 0x80, 0xc2, 0x29, 0x99, 0x05, 0xee, 0xc8, - 0x3a, 0xfb, 0x44, 0x4d, 0xb8, 0xf2, 0x0e, 0xdb, 0x67, 0x44, 0x44, 0xc1, 0x07, 0xda, 0xcf, 0x20, - 0x47, 0xee, 0x21, 0x05, 0xca, 0xae, 0xe7, 0xfc, 0x44, 0xc4, 0x41, 0x94, 0xf5, 0x70, 0x88, 0x10, - 0x14, 0x83, 0xfb, 0x82, 0xdb, 0x06, 0xdf, 0x68, 0x1d, 0x4a, 0x86, 0x33, 0xc1, 0x16, 0xcf, 0x4e, - 0x59, 0x17, 0x23, 0xc6, 0xf2, 0x8e, 0x78, 0x4c, 0x50, 0xa5, 0xc8, 0x59, 0xc4, 0x90, 0xb1, 0xbc, - 0x7e, 0x3d, 0xe8, 0x29, 0x57, 0x38, 0x0b, 0xfb, 0xd6, 0xfe, 0xce, 0x43, 0x25, 0xcc, 0x38, 0x54, - 0x8f, 0xf6, 0x50, 0x0e, 0xf6, 0x2a, 0x76, 0xda, 0xf2, 0xcb, 0x9d, 0xb6, 0x4f, 0xa1, 0x18, 0xec, - 0x6c, 0x21, 0x90, 0xf7, 0x7f, 0x99, 0x89, 0xcd, 0xcc, 0xf4, 0x00, 0x96, 0x10, 0xa3, 0xb8, 0x9c, - 0x18, 0x8f, 0x59, 0x72, 0x8a, 0x6d, 0xf6, 0x95, 0x2b, 0xc1, 0xff, 0xac, 0xa7, 0x92, 0x53, 0x2c, - 0xeb, 0x31, 0x24, 0xba, 0x0f, 0x45, 0x8a, 0x4d, 0x5f, 0x29, 0x05, 0x16, 0x8b, 0x37, 0x51, 0xb0, - 0x8a, 0x9e, 0x00, 0x1c, 0x07, 0x37, 0x9b, 0x31, 0xc6, 0x54, 0x29, 0x07, 0x2e, 0xa9, 0x6d, 0x5e, - 0x2c, 0xdb, 0x61, 0xb1, 0x6c, 0x8f, 0xc2, 0x62, 0xa9, 0xcb, 0x02, 0xdd, 0xa5, 0xda, 0x10, 0x56, - 0xe2, 0x11, 0x46, 0x9a, 0x49, 0x31, 0xcd, 0x3e, 0x89, 0x27, 0x01, 0xf3, 0x3b, 0x2c, 0xd2, 0x6d, - 0x56, 0xa4, 0xdb, 0x2f, 0x79, 0x91, 0x0e, 0x93, 0xc3, 0x86, 0xc2, 0x08, 0x9b, 0x99, 0x44, 0x77, - 0x32, 0xea, 0x4c, 0xa2, 0xca, 0xc4, 0xa4, 0x2b, 0x2c, 0x57, 0x49, 0x7f, 0x91, 0xa0, 0x12, 0xee, - 0x37, 0x7a, 0x0a, 0xe5, 0x53, 0x32, 0x1b, 0x4f, 0xb0, 0x2b, 0x4e, 0xea, 0xdd, 0x4c, 0x5d, 0xda, - 0xbb, 0x64, 0xb6, 0x87, 0xdd, 0xfe, 0x94, 0x7a, 0x33, 0xbd, 0x74, 0x1a, 0x0c, 0xd4, 0x27, 0x50, - 0x8d, 0x4d, 0x2f, 0x7b, 0x14, 0x9e, 0xe6, 0xbf, 0x90, 0xb4, 0x03, 0x68, 0xa4, 0x6f, 0x25, 0xf4, - 0x25, 0x94, 0xf9, 0xbd, 0xe4, 0x67, 0xba, 0x72, 0x68, 0x4d, 0x4d, 0x9b, 0x0c, 0x3d, 0xc7, 0x25, - 0x1e, 0x9d, 0x71, 0x6b, 0x3d, 0xb4, 0xd0, 0xfe, 0x29, 0x40, 0x33, 0x0b, 0x81, 0xbe, 0x01, 0x60, - 0x55, 0x38, 0x71, 0x3d, 0xde, 0x4e, 0x27, 0x45, 0xd2, 0x66, 0x27, 0xa7, 0xcb, 0x14, 0x9b, 0x82, - 0xe0, 0x15, 0x34, 0xa2, 0xec, 0x1a, 0x27, 0x2a, 0xcc, 0xfd, 0xec, 0x6c, 0x5c, 0x20, 0xbb, 0x1a, - 0xd9, 0x0b, 0xca, 0x7d, 0xb8, 0x1a, 0x89, 0x2a, 0x18, 0xb9, 0x76, 0xf7, 0x32, 0xcf, 0xd1, 0x02, - 0x61, 0x3d, 0xb4, 0x16, 0x7c, 0xbb, 0x50, 0x17, 0xe2, 0x86, 0x74, 0xfc, 0x8c, 0x69, 0x59, 0xa9, - 0xb0, 0xc0, 0x56, 0x13, 0xb6, 0x82, 0x6c, 0x08, 0x15, 0x06, 0xc0, 0xd4, 0xf1, 0x14, 0x68, 0x49, - 0x1b, 0xf5, 0xce, 0xa3, 0x0f, 0xea, 0xd0, 0xde, 0x76, 0x26, 0x2e, 0xf6, 0x2c, 0x9f, 0xd5, 0x09, - 0x6e, 0xab, 0x47, 0x2c, 0x5a, 0x0b, 0xd0, 0xe2, 0x3a, 0x02, 0x28, 0xf5, 0x5f, 0xbd, 0xee, 0xbe, - 0x3c, 0x6c, 0xe4, 0x9e, 0xad, 0xc2, 0x55, 0x57, 0x10, 0x8a, 0x08, 0xb4, 0x17, 0xb0, 0x9e, 0x1d, - 0x7f, 0xba, 0xf5, 0x92, 0x16, 0x5b, 0xaf, 0x67, 0x00, 0x95, 0x90, 0x4f, 0xfb, 0x0a, 0x56, 0x17, - 0x14, 0x4e, 0xf4, 0x66, 0x52, 0xba, 0x37, 0x8b, 0x5b, 0xff, 0x00, 0xd7, 0xcf, 0x11, 0x16, 0x3d, - 0xe2, 0x47, 0xe7, 0x1d, 0xb6, 0x45, 0x5a, 0x25, 0x6f, 0xc1, 0x5d, 0x32, 0x3b, 0x62, 0xf9, 0x3e, - 0xc4, 0x16, 0xdb, 0x65, 0x76, 0x68, 0x8e, 0xb0, 0x9d, 0x20, 0x7f, 0x0c, 0x2b, 0x71, 0xd4, 0xd2, - 0xc5, 0xe4, 0x37, 0x09, 0xd6, 0x32, 0xd5, 0x44, 0x6a, 0xaa, 0xb2, 0xb0, 0xb0, 0xc2, 0xda, 0xd2, - 0x8c, 0xd7, 0x96, 0x9d, 0x9c, 0xb8, 0x60, 0x94, 0x64, 0x75, 0x61, 0x9e, 0x8a, 0xfa, 0xa2, 0xa6, - 0xea, 0x0b, 0xe3, 0x12, 0x13, 0x89, 0x28, 0xfe, 0xc8, 0xc3, 0xea, 0x42, 0x9f, 0xc0, 0x3c, 0xb7, - 0xad, 0x89, 0xc5, 0xfd, 0xa8, 0xe9, 0x7c, 0xc0, 0x66, 0xe3, 0x25, 0x9e, 0x0f, 0xd0, 0xb7, 0x50, - 0xf6, 0x1d, 0x8f, 0xee, 0x92, 0x59, 0xe0, 0x44, 0xbd, 0xf3, 0xe0, 0xe2, 0x26, 0xa4, 0x7d, 0xc8, - 0xd1, 0x7a, 0x68, 0x86, 0x9e, 0x83, 0xcc, 0x3e, 0x0f, 0x3c, 0x43, 0x24, 0x7f, 0xbd, 0xb3, 0xb1, - 0x04, 0x47, 0x80, 0xd7, 0xe7, 0xa6, 0xda, 0xff, 0x41, 0x8e, 0xe6, 0x51, 0x1d, 0xa0, 0xd7, 0x3f, - 0xdc, 0xee, 0xef, 0xf7, 0x06, 0xfb, 0x2f, 0x1a, 0x39, 0x54, 0x03, 0xb9, 0x1b, 0x0d, 0x25, 0xed, - 0x26, 0x94, 0x85, 0x1f, 0x68, 0x15, 0x6a, 0xdb, 0x7a, 0xbf, 0x3b, 0x1a, 0x1c, 0xec, 0x8f, 0x47, - 0x83, 0xbd, 0x7e, 0x23, 0xd7, 0xf9, 0xb7, 0x08, 0x55, 0xa6, 0xd1, 0x36, 0x77, 0x00, 0x1d, 0x41, - 0x2d, 0xf1, 0x3e, 0x42, 0xc9, 0xdb, 0x2d, 0xeb, 0x0d, 0xa6, 0x6a, 0x17, 0x41, 0x44, 0xaf, 0xb5, - 0x07, 0x30, 0x7f, 0x17, 0xa1, 0xe4, 0xcd, 0xb6, 0xf0, 0xee, 0x52, 0xef, 0x9c, 0xbb, 0x2e, 0xe8, - 0xbe, 0x87, 0x7a, 0xb2, 0xe3, 0x47, 0x59, 0x4e, 0xa4, 0x9e, 0x16, 0xea, 0xbd, 0x0b, 0x31, 0x82, - 0x7a, 0x08, 0xd5, 0xd8, 0x13, 0x07, 0x2d, 0xb8, 0x92, 0x26, 0x6d, 0x9d, 0x0f, 0x10, 0x8c, 0x5d, - 0x28, 0xf1, 0xf7, 0x04, 0x52, 0x93, 0x17, 0x67, 0xfc, 0x65, 0xa2, 0xde, 0xc8, 0x5c, 0x13, 0x14, - 0x47, 0x50, 0x4b, 0xb4, 0xef, 0x29, 0x59, 0xb2, 0xde, 0x26, 0x29, 0x59, 0xb2, 0xbb, 0xff, 0x43, - 0x58, 0x89, 0xb7, 0xc6, 0xa8, 0xb5, 0x60, 0x93, 0xea, 0xe1, 0xd5, 0xbb, 0x17, 0x20, 0x38, 0xe9, - 0x9b, 0x52, 0xd0, 0x98, 0x6c, 0xfd, 0x17, 0x00, 0x00, 0xff, 0xff, 0x93, 0xd2, 0x4d, 0xdb, 0x28, - 0x10, 0x00, 0x00, + // 1480 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x57, 0x4b, 0x73, 0x1a, 0xc7, + 0x13, 0x67, 0x41, 0x02, 0xb6, 0x11, 0x18, 0xc6, 0x48, 0xc6, 0xf8, 0x85, 0xd7, 0x2e, 0x97, 0xfe, + 0x2e, 0xff, 0x91, 0x23, 0xd9, 0x4e, 0xec, 0xa4, 0x92, 0x60, 0x40, 0x12, 0xd1, 0x0b, 0x2f, 0x92, + 0xaa, 0x52, 0x39, 0x50, 0x63, 0x31, 0x22, 0x1b, 0x2d, 0xec, 0x7a, 0x77, 0xa4, 0x12, 0xa7, 0x54, + 0xae, 0x49, 0x6e, 0xa9, 0xca, 0x39, 0xc7, 0x7c, 0x8a, 0xe4, 0x98, 0x5b, 0x3e, 0x53, 0x6a, 0x76, + 0x66, 0x97, 0x7d, 0x49, 0xc2, 0xba, 0x50, 0xcc, 0xcc, 0xaf, 0x7f, 0xdb, 0x3d, 0xfd, 0x98, 0x6e, + 0x78, 0x72, 0xac, 0x4f, 0x28, 0xd1, 0x06, 0xfa, 0xca, 0x00, 0x53, 0x7c, 0x84, 0x29, 0xd6, 0x8d, + 0xa1, 0xff, 0x7f, 0xdd, 0xb4, 0x0c, 0x6a, 0xa0, 0x9c, 0x6f, 0xab, 0x7a, 0xd7, 0x13, 0x3a, 0x32, + 0x2c, 0xb2, 0xa2, 0x6b, 0x94, 0x58, 0x58, 0xb7, 0x39, 0xb4, 0xfa, 0x60, 0x68, 0x18, 0x43, 0x9d, + 0xac, 0x38, 0xab, 0xf7, 0xa7, 0xc7, 0x2b, 0x54, 0x1b, 0x11, 0x9b, 0xe2, 0x91, 0xc9, 0x01, 0xca, + 0x3a, 0x94, 0x9b, 0x16, 0xc1, 0x94, 0xb4, 0x30, 0xc5, 0x36, 0xa1, 0x2a, 0xf9, 0x70, 0x4a, 0x6c, + 0x8a, 0xea, 0x90, 0x19, 0xf0, 0x9d, 0x8a, 0x54, 0x93, 0x96, 0x73, 0xab, 0xe5, 0xba, 0x5f, 0x11, + 0x17, 0xed, 0x82, 0x94, 0x5b, 0xb0, 0x18, 0xe2, 0xb1, 0x4d, 0x63, 0x6c, 0x13, 0xa5, 0x0d, 0xa5, + 0x0d, 0x42, 0x43, 0xec, 0xcf, 0xc3, 0xec, 0x4b, 0x71, 0xec, 0x9d, 0xd6, 0x94, 0xbf, 0x05, 0xc8, + 0x4f, 0xc3, 0xc9, 0x3f, 0x5a, 0xcb, 0xdf, 0x25, 0x87, 0xa6, 0x61, 0x51, 0xed, 0x18, 0x1f, 0x5d, + 0x5f, 0x1d, 0xf4, 0x10, 0x72, 0x58, 0x90, 0xf4, 0xb5, 0x41, 0x25, 0x59, 0x93, 0x96, 0xe5, 0xcd, + 0x84, 0x0a, 0xee, 0x66, 0x67, 0x80, 0xee, 0x40, 0x96, 0xe2, 0x61, 0x7f, 0x8c, 0x47, 0xa4, 0x92, + 0x12, 0xe7, 0x19, 0x8a, 0x87, 0xbb, 0x78, 0x44, 0xde, 0x16, 0x60, 0xe1, 0xc3, 0x29, 0xb1, 0x26, + 0xfd, 0xef, 0xf1, 0x78, 0xa0, 0x13, 0x65, 0x13, 0x6e, 0x06, 0xf4, 0x12, 0xf6, 0x7d, 0x02, 0x59, + 0x97, 0x51, 0x68, 0xb6, 0x18, 0xd0, 0xcc, 0x13, 0xf0, 0x60, 0xca, 0x37, 0xae, 0x23, 0xc2, 0x46, + 0x5e, 0x83, 0xab, 0x02, 0x4b, 0x61, 0x2e, 0xe1, 0xd5, 0x35, 0xc8, 0x37, 0x06, 0x83, 0x7d, 0x3c, + 0x74, 0xd9, 0x15, 0x48, 0x51, 0x3c, 0x14, 0xc4, 0xc5, 0x00, 0x31, 0x43, 0xb1, 0x43, 0xa5, 0x08, + 0x05, 0x57, 0x48, 0xd0, 0xfc, 0x2d, 0x41, 0x79, 0x5b, 0xb3, 0x3d, 0xc3, 0xed, 0xeb, 0x7b, 0xe4, + 0x25, 0xa4, 0x8f, 0x35, 0x9d, 0x12, 0xcb, 0x71, 0x46, 0x6e, 0xf5, 0x5e, 0x40, 0x60, 0xdd, 0x39, + 0x6a, 0x9f, 0x9b, 0x16, 0xb1, 0x6d, 0xcd, 0x18, 0xab, 0x02, 0x8c, 0xbe, 0x04, 0x30, 0xf1, 0x50, + 0x1b, 0x63, 0xaa, 0x19, 0x63, 0xc7, 0x4f, 0xb9, 0xd5, 0xfb, 0x01, 0xd1, 0xae, 0x77, 0xbc, 0x67, + 0xb2, 0x5f, 0x5b, 0xf5, 0x49, 0x28, 0x27, 0xb0, 0x18, 0x32, 0x40, 0xb8, 0x6e, 0x0d, 0x64, 0xf7, + 0x1e, 0xed, 0x8a, 0x54, 0x4b, 0x5d, 0x7c, 0xdf, 0x53, 0x1c, 0xba, 0x07, 0x30, 0x26, 0xe7, 0xb4, + 0x4f, 0x8d, 0x13, 0x32, 0xe6, 0x51, 0xa5, 0xca, 0x6c, 0x67, 0x9f, 0x6d, 0x28, 0xbf, 0x4a, 0x70, + 0x93, 0x7d, 0x4d, 0x98, 0xef, 0xdd, 0xd6, 0xd4, 0x76, 0xe9, 0xfa, 0xb6, 0x27, 0x3f, 0xda, 0xf6, + 0x21, 0x77, 0xde, 0x54, 0x1b, 0x61, 0xfa, 0x73, 0xc8, 0x0a, 0xaf, 0xb8, 0x96, 0xc7, 0xa7, 0xa5, + 0x87, 0xba, 0xca, 0xee, 0x3f, 0x25, 0xb8, 0xb3, 0x41, 0xe8, 0x9e, 0xa5, 0x12, 0x9b, 0x58, 0x67, + 0x91, 0xd0, 0x7e, 0x09, 0x20, 0xa8, 0x58, 0x32, 0x5e, 0x1e, 0x30, 0xb2, 0x40, 0x76, 0x06, 0xe8, + 0xb6, 0x2f, 0x43, 0xf9, 0x37, 0xdd, 0xfc, 0x44, 0x9f, 0x82, 0x4c, 0xce, 0x4d, 0xcd, 0x22, 0x7d, + 0x4c, 0x45, 0x54, 0x54, 0xeb, 0xbc, 0x96, 0xd6, 0xdd, 0x5a, 0x5a, 0xdf, 0x77, 0x6b, 0xa9, 0x9a, + 0xe5, 0xe0, 0x06, 0x55, 0xfe, 0x90, 0xe0, 0x6e, 0xbc, 0xaa, 0xd7, 0x4e, 0x69, 0xb4, 0x03, 0xc8, + 0x72, 0xd8, 0x9c, 0x6b, 0xef, 0xdb, 0x14, 0xd3, 0x53, 0xdb, 0xd1, 0xb8, 0x10, 0xf2, 0x97, 0x3a, + 0x85, 0xf5, 0x1c, 0x94, 0x5a, 0xb2, 0xc2, 0x5b, 0xca, 0xcf, 0x12, 0x64, 0xc4, 0x7d, 0xa0, 0x27, + 0x90, 0xbc, 0xf2, 0xc6, 0x92, 0xda, 0x80, 0x69, 0x3d, 0x22, 0x14, 0x33, 0x80, 0x08, 0x94, 0xa0, + 0xd6, 0x3b, 0xe2, 0x50, 0xf5, 0x60, 0xe8, 0x31, 0xe4, 0x4d, 0x66, 0x02, 0xfb, 0xf2, 0x16, 0x99, + 0xd8, 0x95, 0x54, 0x2d, 0xb5, 0x2c, 0xab, 0xc1, 0x4d, 0x65, 0x0d, 0xe4, 0xae, 0xbb, 0x81, 0x8a, + 0x90, 0x3a, 0x21, 0x13, 0x47, 0x1d, 0x59, 0x65, 0x7f, 0x51, 0x19, 0xe6, 0xcf, 0xb0, 0x7e, 0xea, + 0xfa, 0x87, 0x2f, 0x94, 0x1f, 0x41, 0xf6, 0xd4, 0x43, 0x15, 0xc8, 0x98, 0x96, 0xf1, 0x03, 0x11, + 0xf7, 0x29, 0xab, 0xee, 0x12, 0x21, 0x98, 0xf3, 0xf9, 0xd6, 0xf9, 0x8f, 0x96, 0x20, 0x3d, 0x30, + 0x46, 0x58, 0xe3, 0xb9, 0x2e, 0xab, 0x62, 0xc5, 0x58, 0xce, 0x88, 0xc5, 0xd2, 0xa3, 0x32, 0xc7, + 0x59, 0xc4, 0x92, 0xb1, 0x1c, 0x1c, 0x74, 0x5a, 0x95, 0x79, 0xce, 0xc2, 0xfe, 0x2b, 0xff, 0x24, + 0x21, 0xeb, 0x3a, 0x0a, 0x15, 0xbc, 0x3b, 0x94, 0x9d, 0xbb, 0xf2, 0xd5, 0xae, 0xe4, 0x6c, 0xb5, + 0xeb, 0xff, 0x30, 0xe7, 0xdc, 0x6c, 0xca, 0x49, 0x96, 0xdb, 0xb1, 0xf1, 0xc0, 0xc4, 0x54, 0x07, + 0x16, 0x70, 0xc6, 0xdc, 0x6c, 0xce, 0x78, 0xc5, 0x52, 0x5d, 0x5c, 0xb3, 0x5d, 0x99, 0x77, 0xbe, + 0xb3, 0x14, 0x4a, 0x75, 0x71, 0xac, 0xfa, 0x90, 0xe8, 0x31, 0xcc, 0x51, 0x3c, 0xb4, 0x2b, 0x69, + 0x47, 0x22, 0x5a, 0xd7, 0x9d, 0x53, 0xf4, 0x1a, 0xe0, 0xc8, 0x79, 0x27, 0x06, 0x2c, 0x5d, 0x32, + 0x57, 0xa6, 0x8b, 0x2c, 0xd0, 0x0d, 0xaa, 0x74, 0x61, 0xc1, 0x6f, 0xa1, 0xe7, 0x33, 0xc9, 0xe7, + 0xb3, 0x67, 0xfe, 0x20, 0x60, 0x7a, 0xbb, 0x2d, 0x4f, 0x9d, 0xb5, 0x3c, 0xf5, 0x6d, 0xde, 0xf2, + 0xb8, 0xc1, 0xa1, 0x43, 0x6a, 0x1f, 0x0f, 0x63, 0x89, 0x1e, 0xc4, 0xbc, 0xda, 0x81, 0x37, 0xdb, + 0xe7, 0xba, 0xd4, 0x6c, 0x7d, 0xc9, 0x4f, 0x12, 0x64, 0xdd, 0xfb, 0x46, 0x6f, 0x20, 0x73, 0x42, + 0x26, 0xfd, 0x11, 0x36, 0x45, 0xdd, 0x7b, 0x18, 0xeb, 0x97, 0xfa, 0x16, 0x99, 0xec, 0x60, 0xb3, + 0x3d, 0xa6, 0xd6, 0x44, 0x4d, 0x9f, 0x38, 0x8b, 0xea, 0x6b, 0xc8, 0xf9, 0xb6, 0x67, 0x4d, 0x85, + 0x37, 0xc9, 0xcf, 0x24, 0x65, 0x0f, 0x8a, 0xe1, 0x1a, 0x8f, 0x3e, 0x87, 0x0c, 0xaf, 0xf2, 0x76, + 0xac, 0x2a, 0x3d, 0x6d, 0x3c, 0xd4, 0x49, 0xd7, 0x32, 0x4c, 0x62, 0xd1, 0x09, 0x97, 0x56, 0x5d, + 0x09, 0xe5, 0xdf, 0x14, 0x94, 0xe3, 0x10, 0xe8, 0x2b, 0x00, 0x56, 0x31, 0x03, 0x8f, 0xcd, 0xfd, + 0x70, 0x50, 0x04, 0x65, 0x36, 0x13, 0xaa, 0x4c, 0xf1, 0x50, 0x10, 0xbc, 0x83, 0xa2, 0x17, 0x5d, + 0xfd, 0xc0, 0x7b, 0xfd, 0x38, 0x3e, 0x1a, 0x23, 0x64, 0x37, 0x3c, 0x79, 0x41, 0xb9, 0x0b, 0x37, + 0x3c, 0xa7, 0x0a, 0x46, 0xee, 0xbb, 0x47, 0xb1, 0x79, 0x14, 0x21, 0x2c, 0xb8, 0xd2, 0x82, 0x6f, + 0x0b, 0x0a, 0xee, 0x63, 0x22, 0xe8, 0x78, 0x8e, 0x29, 0x71, 0xa1, 0x10, 0x61, 0xcb, 0x0b, 0x59, + 0x41, 0xd6, 0x85, 0x2c, 0x03, 0x60, 0x6a, 0x58, 0x15, 0x70, 0x0a, 0xf6, 0x8b, 0x2b, 0xfd, 0x50, + 0x6f, 0x1a, 0x23, 0x13, 0x5b, 0x9a, 0xcd, 0x5e, 0x5d, 0x2e, 0xab, 0x7a, 0x2c, 0x4a, 0x0d, 0x50, + 0xf4, 0x1c, 0x01, 0xa4, 0xdb, 0xef, 0x0e, 0x1a, 0xdb, 0xbd, 0x62, 0xe2, 0x6d, 0x09, 0x6e, 0x98, + 0x82, 0x50, 0x58, 0xa0, 0x6c, 0xc0, 0x52, 0xbc, 0xfd, 0xe1, 0x46, 0x56, 0x8a, 0x36, 0xb2, 0x6f, + 0x01, 0xb2, 0x2e, 0x9f, 0xf2, 0x05, 0x94, 0x22, 0x1e, 0x0e, 0x74, 0xba, 0x52, 0xb8, 0xd3, 0xf5, + 0x4b, 0x7f, 0x07, 0xb7, 0x2e, 0x70, 0x2c, 0x7a, 0xc1, 0x53, 0xe7, 0x0c, 0xeb, 0x22, 0xac, 0x82, + 0x55, 0x70, 0x8b, 0x4c, 0x0e, 0x59, 0xbc, 0x77, 0xb1, 0xc6, 0x6e, 0x99, 0x25, 0xcd, 0x21, 0xd6, + 0x03, 0xe4, 0xaf, 0x60, 0xc1, 0x8f, 0x9a, 0xf9, 0x31, 0xf9, 0x45, 0x82, 0xc5, 0x58, 0x6f, 0xa2, + 0x6a, 0xe8, 0x65, 0x61, 0x66, 0xb9, 0x6f, 0x4b, 0xd9, 0xff, 0xb6, 0x6c, 0x26, 0x44, 0x81, 0xa9, + 0x04, 0x5f, 0x17, 0xa6, 0xa9, 0x78, 0x5f, 0xaa, 0xa1, 0xf7, 0x85, 0x71, 0x89, 0x8d, 0x80, 0x15, + 0xbf, 0x25, 0xa1, 0x14, 0xe9, 0xba, 0x98, 0xe6, 0xba, 0x36, 0xd2, 0xb8, 0x1e, 0x79, 0x95, 0x2f, + 0xd8, 0xae, 0xbf, 0x61, 0xe2, 0x0b, 0xf4, 0x35, 0x64, 0x6c, 0xc3, 0xa2, 0x5b, 0x64, 0xe2, 0x28, + 0x51, 0x58, 0x7d, 0x72, 0x79, 0x4b, 0x57, 0xef, 0x71, 0xb4, 0xea, 0x8a, 0xa1, 0x75, 0x90, 0xd9, + 0xdf, 0x3d, 0x6b, 0x20, 0x82, 0xbf, 0xb0, 0xba, 0x3c, 0x03, 0x87, 0x83, 0x57, 0xa7, 0xa2, 0xca, + 0x53, 0x90, 0xbd, 0x7d, 0x54, 0x00, 0x68, 0xb5, 0x7b, 0xcd, 0xf6, 0x6e, 0xab, 0xb3, 0xbb, 0x51, + 0x4c, 0xa0, 0x3c, 0xc8, 0x0d, 0x6f, 0x29, 0x29, 0x77, 0x21, 0x23, 0xf4, 0x40, 0x25, 0xc8, 0x37, + 0xd5, 0x76, 0x63, 0xbf, 0xb3, 0xb7, 0xdb, 0xdf, 0xef, 0xec, 0xb4, 0x8b, 0x89, 0xa7, 0xcf, 0xa0, + 0x14, 0x69, 0x6d, 0x50, 0x0e, 0x32, 0xbd, 0x83, 0x66, 0xb3, 0xdd, 0xeb, 0x15, 0x13, 0x2c, 0x01, + 0xd6, 0x1b, 0x9d, 0xed, 0x76, 0xab, 0x28, 0xad, 0xfe, 0x35, 0x0f, 0x39, 0xe6, 0xd1, 0x26, 0x57, + 0x17, 0x1d, 0x42, 0x3e, 0x30, 0x9b, 0xa2, 0x60, 0x2d, 0x8c, 0x9b, 0x7f, 0xab, 0xca, 0x65, 0x10, + 0xd1, 0xca, 0xed, 0x00, 0x4c, 0x67, 0x52, 0x14, 0xac, 0x83, 0x91, 0x99, 0xb7, 0xfa, 0xe0, 0xc2, + 0x73, 0x41, 0xf7, 0x2d, 0x14, 0x82, 0xd3, 0x16, 0x8a, 0x53, 0x22, 0xd4, 0xfb, 0x56, 0x1f, 0x5d, + 0x8a, 0x11, 0xd4, 0x5d, 0xc8, 0xf9, 0xc6, 0x4b, 0x14, 0x51, 0x25, 0x4c, 0x5a, 0xbb, 0x18, 0x20, + 0x18, 0x1b, 0x90, 0xe6, 0xb3, 0x1c, 0xaa, 0x06, 0xcb, 0xac, 0x7f, 0x2a, 0xac, 0xde, 0x89, 0x3d, + 0x13, 0x14, 0x87, 0x90, 0x0f, 0x8c, 0x4e, 0x21, 0xb7, 0xc4, 0xcd, 0x85, 0x21, 0xb7, 0xc4, 0x4f, + 0x5e, 0x3d, 0x58, 0xf0, 0x8f, 0x25, 0xa8, 0x16, 0x91, 0x09, 0xcd, 0x4f, 0xd5, 0x87, 0x97, 0x20, + 0x04, 0xe9, 0x09, 0x94, 0xe3, 0xda, 0x7a, 0xb4, 0x1c, 0xbe, 0xa9, 0x8b, 0x86, 0x94, 0xea, 0xff, + 0x66, 0x40, 0xf2, 0x8f, 0xbd, 0x4f, 0x3b, 0x3d, 0xd3, 0xda, 0x7f, 0x01, 0x00, 0x00, 0xff, 0xff, + 0xc1, 0x90, 0x48, 0xc7, 0x11, 0x12, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1903,6 +2041,12 @@ type DataCatalogClient interface { ListArtifacts(ctx context.Context, in *ListArtifactsRequest, opts ...grpc.CallOption) (*ListArtifactsResponse, error) // Return a paginated list of datasets ListDatasets(ctx context.Context, in *ListDatasetsRequest, opts ...grpc.CallOption) (*ListDatasetsResponse, error) + // Get an artifact and the corresponding data. If the artifact does not exist, + // try to reserve a spot for populating the artifact. We may have multiple + // concurrent tasks with the same signature and the same input that try to populate + // the same artifact at the same time. Thus with reservation, only one task + // can run at a time. + GetOrReserveArtifact(ctx context.Context, in *GetOrReserveArtifactRequest, opts ...grpc.CallOption) (*GetOrReserveArtifactResponse, error) } type dataCatalogClient struct { @@ -1976,6 +2120,15 @@ func (c *dataCatalogClient) ListDatasets(ctx context.Context, in *ListDatasetsRe return out, nil } +func (c *dataCatalogClient) GetOrReserveArtifact(ctx context.Context, in *GetOrReserveArtifactRequest, opts ...grpc.CallOption) (*GetOrReserveArtifactResponse, error) { + out := new(GetOrReserveArtifactResponse) + err := c.cc.Invoke(ctx, "/datacatalog.DataCatalog/GetOrReserveArtifact", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // DataCatalogServer is the server API for DataCatalog service. type DataCatalogServer interface { // Create a new Dataset. Datasets are unique based on the DatasetID. Datasets are logical groupings of artifacts. @@ -1994,6 +2147,12 @@ type DataCatalogServer interface { ListArtifacts(context.Context, *ListArtifactsRequest) (*ListArtifactsResponse, error) // Return a paginated list of datasets ListDatasets(context.Context, *ListDatasetsRequest) (*ListDatasetsResponse, error) + // Get an artifact and the corresponding data. If the artifact does not exist, + // try to reserve a spot for populating the artifact. We may have multiple + // concurrent tasks with the same signature and the same input that try to populate + // the same artifact at the same time. Thus with reservation, only one task + // can run at a time. + GetOrReserveArtifact(context.Context, *GetOrReserveArtifactRequest) (*GetOrReserveArtifactResponse, error) } // UnimplementedDataCatalogServer can be embedded to have forward compatible implementations. @@ -2021,6 +2180,9 @@ func (*UnimplementedDataCatalogServer) ListArtifacts(ctx context.Context, req *L func (*UnimplementedDataCatalogServer) ListDatasets(ctx context.Context, req *ListDatasetsRequest) (*ListDatasetsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ListDatasets not implemented") } +func (*UnimplementedDataCatalogServer) GetOrReserveArtifact(ctx context.Context, req *GetOrReserveArtifactRequest) (*GetOrReserveArtifactResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetOrReserveArtifact not implemented") +} func RegisterDataCatalogServer(s *grpc.Server, srv DataCatalogServer) { s.RegisterService(&_DataCatalog_serviceDesc, srv) @@ -2152,6 +2314,24 @@ func _DataCatalog_ListDatasets_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } +func _DataCatalog_GetOrReserveArtifact_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetOrReserveArtifactRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(DataCatalogServer).GetOrReserveArtifact(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/datacatalog.DataCatalog/GetOrReserveArtifact", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(DataCatalogServer).GetOrReserveArtifact(ctx, req.(*GetOrReserveArtifactRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _DataCatalog_serviceDesc = grpc.ServiceDesc{ ServiceName: "datacatalog.DataCatalog", HandlerType: (*DataCatalogServer)(nil), @@ -2184,6 +2364,10 @@ var _DataCatalog_serviceDesc = grpc.ServiceDesc{ MethodName: "ListDatasets", Handler: _DataCatalog_ListDatasets_Handler, }, + { + MethodName: "GetOrReserveArtifact", + Handler: _DataCatalog_GetOrReserveArtifact_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "flyteidl/datacatalog/datacatalog.proto", diff --git a/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.validate.go b/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.validate.go index 431015a91..c7efddefb 100644 --- a/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.validate.go +++ b/gen/pb-go/flyteidl/datacatalog/datacatalog.pb.validate.go @@ -1134,6 +1134,176 @@ var _ interface { ErrorName() string } = ListDatasetsResponseValidationError{} +// Validate checks the field values on GetOrReserveArtifactRequest with the +// rules defined in the proto definition for this message. If any rules are +// violated, an error is returned. +func (m *GetOrReserveArtifactRequest) Validate() error { + if m == nil { + return nil + } + + if v, ok := interface{}(m.GetDatasetId()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return GetOrReserveArtifactRequestValidationError{ + field: "DatasetId", + reason: "embedded message failed validation", + cause: err, + } + } + } + + // no validation rules for TagName + + if v, ok := interface{}(m.GetExpireAt()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return GetOrReserveArtifactRequestValidationError{ + field: "ExpireAt", + reason: "embedded message failed validation", + cause: err, + } + } + } + + return nil +} + +// GetOrReserveArtifactRequestValidationError is the validation error returned +// by GetOrReserveArtifactRequest.Validate if the designated constraints +// aren't met. +type GetOrReserveArtifactRequestValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e GetOrReserveArtifactRequestValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e GetOrReserveArtifactRequestValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e GetOrReserveArtifactRequestValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e GetOrReserveArtifactRequestValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e GetOrReserveArtifactRequestValidationError) ErrorName() string { + return "GetOrReserveArtifactRequestValidationError" +} + +// Error satisfies the builtin error interface +func (e GetOrReserveArtifactRequestValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sGetOrReserveArtifactRequest.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = GetOrReserveArtifactRequestValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = GetOrReserveArtifactRequestValidationError{} + +// Validate checks the field values on GetOrReserveArtifactResponse with the +// rules defined in the proto definition for this message. If any rules are +// violated, an error is returned. +func (m *GetOrReserveArtifactResponse) Validate() error { + if m == nil { + return nil + } + + if v, ok := interface{}(m.GetArtifact()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return GetOrReserveArtifactResponseValidationError{ + field: "Artifact", + reason: "embedded message failed validation", + cause: err, + } + } + } + + // no validation rules for ReservationStatus + + return nil +} + +// GetOrReserveArtifactResponseValidationError is the validation error returned +// by GetOrReserveArtifactResponse.Validate if the designated constraints +// aren't met. +type GetOrReserveArtifactResponseValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e GetOrReserveArtifactResponseValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e GetOrReserveArtifactResponseValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e GetOrReserveArtifactResponseValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e GetOrReserveArtifactResponseValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e GetOrReserveArtifactResponseValidationError) ErrorName() string { + return "GetOrReserveArtifactResponseValidationError" +} + +// Error satisfies the builtin error interface +func (e GetOrReserveArtifactResponseValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sGetOrReserveArtifactResponse.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = GetOrReserveArtifactResponseValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = GetOrReserveArtifactResponseValidationError{} + // Validate checks the field values on Dataset with the rules defined in the // proto definition for this message. If any rules are violated, an error is returned. func (m *Dataset) Validate() error { diff --git a/gen/pb-java/datacatalog/Datacatalog.java b/gen/pb-java/datacatalog/Datacatalog.java index 7950642e9..64ba492ca 100644 --- a/gen/pb-java/datacatalog/Datacatalog.java +++ b/gen/pb-java/datacatalog/Datacatalog.java @@ -14,6 +14,104 @@ public static void registerAllExtensions( registerAllExtensions( (com.google.protobuf.ExtensionRegistryLite) registry); } + /** + * Protobuf enum {@code datacatalog.ReservationStatus} + */ + public enum ReservationStatus + implements com.google.protobuf.ProtocolMessageEnum { + /** + * SUCCESS = 0; + */ + SUCCESS(0), + /** + * FAILED = 1; + */ + FAILED(1), + UNRECOGNIZED(-1), + ; + + /** + * SUCCESS = 0; + */ + public static final int SUCCESS_VALUE = 0; + /** + * FAILED = 1; + */ + public static final int FAILED_VALUE = 1; + + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ReservationStatus valueOf(int value) { + return forNumber(value); + } + + public static ReservationStatus forNumber(int value) { + switch (value) { + case 0: return SUCCESS; + case 1: return FAILED; + default: return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap + internalGetValueMap() { + return internalValueMap; + } + private static final com.google.protobuf.Internal.EnumLiteMap< + ReservationStatus> internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public ReservationStatus findValueByNumber(int number) { + return ReservationStatus.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor + getValueDescriptor() { + return getDescriptor().getValues().get(ordinal()); + } + public final com.google.protobuf.Descriptors.EnumDescriptor + getDescriptorForType() { + return getDescriptor(); + } + public static final com.google.protobuf.Descriptors.EnumDescriptor + getDescriptor() { + return datacatalog.Datacatalog.getDescriptor().getEnumTypes().get(0); + } + + private static final ReservationStatus[] VALUES = values(); + + public static ReservationStatus valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException( + "EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private ReservationStatus(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:datacatalog.ReservationStatus) + } + public interface CreateDatasetRequestOrBuilder extends // @@protoc_insertion_point(interface_extends:datacatalog.CreateDatasetRequest) com.google.protobuf.MessageOrBuilder { @@ -9988,201 +10086,1838 @@ public Builder clearDatasets() { bitField0_ = (bitField0_ & ~0x00000001); onChanged(); } else { - datasetsBuilder_.clear(); + datasetsBuilder_.clear(); + } + return this; + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public Builder removeDatasets(int index) { + if (datasetsBuilder_ == null) { + ensureDatasetsIsMutable(); + datasets_.remove(index); + onChanged(); + } else { + datasetsBuilder_.remove(index); + } + return this; + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public datacatalog.Datacatalog.Dataset.Builder getDatasetsBuilder( + int index) { + return getDatasetsFieldBuilder().getBuilder(index); + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public datacatalog.Datacatalog.DatasetOrBuilder getDatasetsOrBuilder( + int index) { + if (datasetsBuilder_ == null) { + return datasets_.get(index); } else { + return datasetsBuilder_.getMessageOrBuilder(index); + } + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public java.util.List + getDatasetsOrBuilderList() { + if (datasetsBuilder_ != null) { + return datasetsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(datasets_); + } + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public datacatalog.Datacatalog.Dataset.Builder addDatasetsBuilder() { + return getDatasetsFieldBuilder().addBuilder( + datacatalog.Datacatalog.Dataset.getDefaultInstance()); + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public datacatalog.Datacatalog.Dataset.Builder addDatasetsBuilder( + int index) { + return getDatasetsFieldBuilder().addBuilder( + index, datacatalog.Datacatalog.Dataset.getDefaultInstance()); + } + /** + *
+       * The list of datasets
+       * 
+ * + * repeated .datacatalog.Dataset datasets = 1; + */ + public java.util.List + getDatasetsBuilderList() { + return getDatasetsFieldBuilder().getBuilderList(); + } + private com.google.protobuf.RepeatedFieldBuilderV3< + datacatalog.Datacatalog.Dataset, datacatalog.Datacatalog.Dataset.Builder, datacatalog.Datacatalog.DatasetOrBuilder> + getDatasetsFieldBuilder() { + if (datasetsBuilder_ == null) { + datasetsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< + datacatalog.Datacatalog.Dataset, datacatalog.Datacatalog.Dataset.Builder, datacatalog.Datacatalog.DatasetOrBuilder>( + datasets_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + datasets_ = null; + } + return datasetsBuilder_; + } + + private java.lang.Object nextToken_ = ""; + /** + *
+       * Token to use to request the next page, pass this into the next requests PaginationOptions
+       * 
+ * + * string next_token = 2; + */ + public java.lang.String getNextToken() { + java.lang.Object ref = nextToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + *
+       * Token to use to request the next page, pass this into the next requests PaginationOptions
+       * 
+ * + * string next_token = 2; + */ + public com.google.protobuf.ByteString + getNextTokenBytes() { + java.lang.Object ref = nextToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + nextToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + *
+       * Token to use to request the next page, pass this into the next requests PaginationOptions
+       * 
+ * + * string next_token = 2; + */ + public Builder setNextToken( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextToken_ = value; + onChanged(); + return this; + } + /** + *
+       * Token to use to request the next page, pass this into the next requests PaginationOptions
+       * 
+ * + * string next_token = 2; + */ + public Builder clearNextToken() { + + nextToken_ = getDefaultInstance().getNextToken(); + onChanged(); + return this; + } + /** + *
+       * Token to use to request the next page, pass this into the next requests PaginationOptions
+       * 
+ * + * string next_token = 2; + */ + public Builder setNextTokenBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextToken_ = 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:datacatalog.ListDatasetsResponse) + } + + // @@protoc_insertion_point(class_scope:datacatalog.ListDatasetsResponse) + private static final datacatalog.Datacatalog.ListDatasetsResponse DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new datacatalog.Datacatalog.ListDatasetsResponse(); + } + + public static datacatalog.Datacatalog.ListDatasetsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListDatasetsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListDatasetsResponse(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 datacatalog.Datacatalog.ListDatasetsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + + } + + public interface GetOrReserveArtifactRequestOrBuilder extends + // @@protoc_insertion_point(interface_extends:datacatalog.GetOrReserveArtifactRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + boolean hasDatasetId(); + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + datacatalog.Datacatalog.DatasetID getDatasetId(); + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + datacatalog.Datacatalog.DatasetIDOrBuilder getDatasetIdOrBuilder(); + + /** + * string tag_name = 2; + */ + java.lang.String getTagName(); + /** + * string tag_name = 2; + */ + com.google.protobuf.ByteString + getTagNameBytes(); + + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + boolean hasExpireAt(); + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + com.google.protobuf.Timestamp getExpireAt(); + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + com.google.protobuf.TimestampOrBuilder getExpireAtOrBuilder(); + } + /** + * Protobuf type {@code datacatalog.GetOrReserveArtifactRequest} + */ + public static final class GetOrReserveArtifactRequest extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:datacatalog.GetOrReserveArtifactRequest) + GetOrReserveArtifactRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetOrReserveArtifactRequest.newBuilder() to construct. + private GetOrReserveArtifactRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private GetOrReserveArtifactRequest() { + tagName_ = ""; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private GetOrReserveArtifactRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + 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: { + datacatalog.Datacatalog.DatasetID.Builder subBuilder = null; + if (datasetId_ != null) { + subBuilder = datasetId_.toBuilder(); + } + datasetId_ = input.readMessage(datacatalog.Datacatalog.DatasetID.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(datasetId_); + datasetId_ = subBuilder.buildPartial(); + } + + break; + } + case 18: { + java.lang.String s = input.readStringRequireUtf8(); + + tagName_ = s; + break; + } + case 26: { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (expireAt_ != null) { + subBuilder = expireAt_.toBuilder(); + } + expireAt_ = input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(expireAt_); + expireAt_ = subBuilder.buildPartial(); + } + + break; + } + default: { + if (!parseUnknownField( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.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 datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + datacatalog.Datacatalog.GetOrReserveArtifactRequest.class, datacatalog.Datacatalog.GetOrReserveArtifactRequest.Builder.class); + } + + public static final int DATASET_ID_FIELD_NUMBER = 1; + private datacatalog.Datacatalog.DatasetID datasetId_; + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public boolean hasDatasetId() { + return datasetId_ != null; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public datacatalog.Datacatalog.DatasetID getDatasetId() { + return datasetId_ == null ? datacatalog.Datacatalog.DatasetID.getDefaultInstance() : datasetId_; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public datacatalog.Datacatalog.DatasetIDOrBuilder getDatasetIdOrBuilder() { + return getDatasetId(); + } + + public static final int TAG_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object tagName_; + /** + * string tag_name = 2; + */ + public java.lang.String getTagName() { + java.lang.Object ref = tagName_; + 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(); + tagName_ = s; + return s; + } + } + /** + * string tag_name = 2; + */ + public com.google.protobuf.ByteString + getTagNameBytes() { + java.lang.Object ref = tagName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + tagName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int EXPIRE_AT_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp expireAt_; + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public boolean hasExpireAt() { + return expireAt_ != null; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public com.google.protobuf.Timestamp getExpireAt() { + return expireAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireAt_; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public com.google.protobuf.TimestampOrBuilder getExpireAtOrBuilder() { + return getExpireAt(); + } + + 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 (datasetId_ != null) { + output.writeMessage(1, getDatasetId()); + } + if (!getTagNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, tagName_); + } + if (expireAt_ != null) { + output.writeMessage(3, getExpireAt()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (datasetId_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getDatasetId()); + } + if (!getTagNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, tagName_); + } + if (expireAt_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(3, getExpireAt()); + } + 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 datacatalog.Datacatalog.GetOrReserveArtifactRequest)) { + return super.equals(obj); + } + datacatalog.Datacatalog.GetOrReserveArtifactRequest other = (datacatalog.Datacatalog.GetOrReserveArtifactRequest) obj; + + if (hasDatasetId() != other.hasDatasetId()) return false; + if (hasDatasetId()) { + if (!getDatasetId() + .equals(other.getDatasetId())) return false; + } + if (!getTagName() + .equals(other.getTagName())) return false; + if (hasExpireAt() != other.hasExpireAt()) return false; + if (hasExpireAt()) { + if (!getExpireAt() + .equals(other.getExpireAt())) 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 (hasDatasetId()) { + hash = (37 * hash) + DATASET_ID_FIELD_NUMBER; + hash = (53 * hash) + getDatasetId().hashCode(); + } + hash = (37 * hash) + TAG_NAME_FIELD_NUMBER; + hash = (53 * hash) + getTagName().hashCode(); + if (hasExpireAt()) { + hash = (37 * hash) + EXPIRE_AT_FIELD_NUMBER; + hash = (53 * hash) + getExpireAt().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom( + java.nio.ByteBuffer data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest 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 datacatalog.Datacatalog.GetOrReserveArtifactRequest parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest 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 datacatalog.Datacatalog.GetOrReserveArtifactRequest parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest 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(datacatalog.Datacatalog.GetOrReserveArtifactRequest 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 datacatalog.GetOrReserveArtifactRequest} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:datacatalog.GetOrReserveArtifactRequest) + datacatalog.Datacatalog.GetOrReserveArtifactRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + datacatalog.Datacatalog.GetOrReserveArtifactRequest.class, datacatalog.Datacatalog.GetOrReserveArtifactRequest.Builder.class); + } + + // Construct using datacatalog.Datacatalog.GetOrReserveArtifactRequest.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 (datasetIdBuilder_ == null) { + datasetId_ = null; + } else { + datasetId_ = null; + datasetIdBuilder_ = null; + } + tagName_ = ""; + + if (expireAtBuilder_ == null) { + expireAt_ = null; + } else { + expireAt_ = null; + expireAtBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactRequest_descriptor; + } + + @java.lang.Override + public datacatalog.Datacatalog.GetOrReserveArtifactRequest getDefaultInstanceForType() { + return datacatalog.Datacatalog.GetOrReserveArtifactRequest.getDefaultInstance(); + } + + @java.lang.Override + public datacatalog.Datacatalog.GetOrReserveArtifactRequest build() { + datacatalog.Datacatalog.GetOrReserveArtifactRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public datacatalog.Datacatalog.GetOrReserveArtifactRequest buildPartial() { + datacatalog.Datacatalog.GetOrReserveArtifactRequest result = new datacatalog.Datacatalog.GetOrReserveArtifactRequest(this); + if (datasetIdBuilder_ == null) { + result.datasetId_ = datasetId_; + } else { + result.datasetId_ = datasetIdBuilder_.build(); + } + result.tagName_ = tagName_; + if (expireAtBuilder_ == null) { + result.expireAt_ = expireAt_; + } else { + result.expireAt_ = expireAtBuilder_.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 datacatalog.Datacatalog.GetOrReserveArtifactRequest) { + return mergeFrom((datacatalog.Datacatalog.GetOrReserveArtifactRequest)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(datacatalog.Datacatalog.GetOrReserveArtifactRequest other) { + if (other == datacatalog.Datacatalog.GetOrReserveArtifactRequest.getDefaultInstance()) return this; + if (other.hasDatasetId()) { + mergeDatasetId(other.getDatasetId()); + } + if (!other.getTagName().isEmpty()) { + tagName_ = other.tagName_; + onChanged(); + } + if (other.hasExpireAt()) { + mergeExpireAt(other.getExpireAt()); + } + 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 { + datacatalog.Datacatalog.GetOrReserveArtifactRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (datacatalog.Datacatalog.GetOrReserveArtifactRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private datacatalog.Datacatalog.DatasetID datasetId_; + private com.google.protobuf.SingleFieldBuilderV3< + datacatalog.Datacatalog.DatasetID, datacatalog.Datacatalog.DatasetID.Builder, datacatalog.Datacatalog.DatasetIDOrBuilder> datasetIdBuilder_; + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public boolean hasDatasetId() { + return datasetIdBuilder_ != null || datasetId_ != null; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public datacatalog.Datacatalog.DatasetID getDatasetId() { + if (datasetIdBuilder_ == null) { + return datasetId_ == null ? datacatalog.Datacatalog.DatasetID.getDefaultInstance() : datasetId_; + } else { + return datasetIdBuilder_.getMessage(); + } + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public Builder setDatasetId(datacatalog.Datacatalog.DatasetID value) { + if (datasetIdBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + datasetId_ = value; + onChanged(); + } else { + datasetIdBuilder_.setMessage(value); + } + + return this; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public Builder setDatasetId( + datacatalog.Datacatalog.DatasetID.Builder builderForValue) { + if (datasetIdBuilder_ == null) { + datasetId_ = builderForValue.build(); + onChanged(); + } else { + datasetIdBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public Builder mergeDatasetId(datacatalog.Datacatalog.DatasetID value) { + if (datasetIdBuilder_ == null) { + if (datasetId_ != null) { + datasetId_ = + datacatalog.Datacatalog.DatasetID.newBuilder(datasetId_).mergeFrom(value).buildPartial(); + } else { + datasetId_ = value; + } + onChanged(); + } else { + datasetIdBuilder_.mergeFrom(value); + } + + return this; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public Builder clearDatasetId() { + if (datasetIdBuilder_ == null) { + datasetId_ = null; + onChanged(); + } else { + datasetId_ = null; + datasetIdBuilder_ = null; + } + + return this; + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public datacatalog.Datacatalog.DatasetID.Builder getDatasetIdBuilder() { + + onChanged(); + return getDatasetIdFieldBuilder().getBuilder(); + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + public datacatalog.Datacatalog.DatasetIDOrBuilder getDatasetIdOrBuilder() { + if (datasetIdBuilder_ != null) { + return datasetIdBuilder_.getMessageOrBuilder(); + } else { + return datasetId_ == null ? + datacatalog.Datacatalog.DatasetID.getDefaultInstance() : datasetId_; + } + } + /** + * .datacatalog.DatasetID dataset_id = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + datacatalog.Datacatalog.DatasetID, datacatalog.Datacatalog.DatasetID.Builder, datacatalog.Datacatalog.DatasetIDOrBuilder> + getDatasetIdFieldBuilder() { + if (datasetIdBuilder_ == null) { + datasetIdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + datacatalog.Datacatalog.DatasetID, datacatalog.Datacatalog.DatasetID.Builder, datacatalog.Datacatalog.DatasetIDOrBuilder>( + getDatasetId(), + getParentForChildren(), + isClean()); + datasetId_ = null; + } + return datasetIdBuilder_; + } + + private java.lang.Object tagName_ = ""; + /** + * string tag_name = 2; + */ + public java.lang.String getTagName() { + java.lang.Object ref = tagName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = + (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + tagName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * string tag_name = 2; + */ + public com.google.protobuf.ByteString + getTagNameBytes() { + java.lang.Object ref = tagName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8( + (java.lang.String) ref); + tagName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * string tag_name = 2; + */ + public Builder setTagName( + java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + tagName_ = value; + onChanged(); + return this; + } + /** + * string tag_name = 2; + */ + public Builder clearTagName() { + + tagName_ = getDefaultInstance().getTagName(); + onChanged(); + return this; + } + /** + * string tag_name = 2; + */ + public Builder setTagNameBytes( + com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + tagName_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp expireAt_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> expireAtBuilder_; + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public boolean hasExpireAt() { + return expireAtBuilder_ != null || expireAt_ != null; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public com.google.protobuf.Timestamp getExpireAt() { + if (expireAtBuilder_ == null) { + return expireAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : expireAt_; + } else { + return expireAtBuilder_.getMessage(); + } + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public Builder setExpireAt(com.google.protobuf.Timestamp value) { + if (expireAtBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + expireAt_ = value; + onChanged(); + } else { + expireAtBuilder_.setMessage(value); + } + + return this; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public Builder setExpireAt( + com.google.protobuf.Timestamp.Builder builderForValue) { + if (expireAtBuilder_ == null) { + expireAt_ = builderForValue.build(); + onChanged(); + } else { + expireAtBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public Builder mergeExpireAt(com.google.protobuf.Timestamp value) { + if (expireAtBuilder_ == null) { + if (expireAt_ != null) { + expireAt_ = + com.google.protobuf.Timestamp.newBuilder(expireAt_).mergeFrom(value).buildPartial(); + } else { + expireAt_ = value; + } + onChanged(); + } else { + expireAtBuilder_.mergeFrom(value); + } + + return this; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public Builder clearExpireAt() { + if (expireAtBuilder_ == null) { + expireAt_ = null; + onChanged(); + } else { + expireAt_ = null; + expireAtBuilder_ = null; + } + + return this; + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public com.google.protobuf.Timestamp.Builder getExpireAtBuilder() { + + onChanged(); + return getExpireAtFieldBuilder().getBuilder(); + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + public com.google.protobuf.TimestampOrBuilder getExpireAtOrBuilder() { + if (expireAtBuilder_ != null) { + return expireAtBuilder_.getMessageOrBuilder(); + } else { + return expireAt_ == null ? + com.google.protobuf.Timestamp.getDefaultInstance() : expireAt_; + } + } + /** + * .google.protobuf.Timestamp expire_at = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + getExpireAtFieldBuilder() { + if (expireAtBuilder_ == null) { + expireAtBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( + getExpireAt(), + getParentForChildren(), + isClean()); + expireAt_ = null; + } + return expireAtBuilder_; + } + @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:datacatalog.GetOrReserveArtifactRequest) + } + + // @@protoc_insertion_point(class_scope:datacatalog.GetOrReserveArtifactRequest) + private static final datacatalog.Datacatalog.GetOrReserveArtifactRequest DEFAULT_INSTANCE; + static { + DEFAULT_INSTANCE = new datacatalog.Datacatalog.GetOrReserveArtifactRequest(); + } + + public static datacatalog.Datacatalog.GetOrReserveArtifactRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetOrReserveArtifactRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new GetOrReserveArtifactRequest(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 datacatalog.Datacatalog.GetOrReserveArtifactRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + + } + + public interface GetOrReserveArtifactResponseOrBuilder extends + // @@protoc_insertion_point(interface_extends:datacatalog.GetOrReserveArtifactResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * .datacatalog.Artifact artifact = 1; + */ + boolean hasArtifact(); + /** + * .datacatalog.Artifact artifact = 1; + */ + datacatalog.Datacatalog.Artifact getArtifact(); + /** + * .datacatalog.Artifact artifact = 1; + */ + datacatalog.Datacatalog.ArtifactOrBuilder getArtifactOrBuilder(); + + /** + * .datacatalog.ReservationStatus reservation_status = 2; + */ + int getReservationStatusValue(); + /** + * .datacatalog.ReservationStatus reservation_status = 2; + */ + datacatalog.Datacatalog.ReservationStatus getReservationStatus(); + } + /** + * Protobuf type {@code datacatalog.GetOrReserveArtifactResponse} + */ + public static final class GetOrReserveArtifactResponse extends + com.google.protobuf.GeneratedMessageV3 implements + // @@protoc_insertion_point(message_implements:datacatalog.GetOrReserveArtifactResponse) + GetOrReserveArtifactResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetOrReserveArtifactResponse.newBuilder() to construct. + private GetOrReserveArtifactResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + private GetOrReserveArtifactResponse() { + reservationStatus_ = 0; + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private GetOrReserveArtifactResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + 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: { + datacatalog.Datacatalog.Artifact.Builder subBuilder = null; + if (artifact_ != null) { + subBuilder = artifact_.toBuilder(); + } + artifact_ = input.readMessage(datacatalog.Datacatalog.Artifact.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(artifact_); + artifact_ = subBuilder.buildPartial(); + } + + break; + } + case 16: { + int rawValue = input.readEnum(); + + reservationStatus_ = rawValue; + break; + } + default: { + if (!parseUnknownField( + input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.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 datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + datacatalog.Datacatalog.GetOrReserveArtifactResponse.class, datacatalog.Datacatalog.GetOrReserveArtifactResponse.Builder.class); + } + + public static final int ARTIFACT_FIELD_NUMBER = 1; + private datacatalog.Datacatalog.Artifact artifact_; + /** + * .datacatalog.Artifact artifact = 1; + */ + public boolean hasArtifact() { + return artifact_ != null; + } + /** + * .datacatalog.Artifact artifact = 1; + */ + public datacatalog.Datacatalog.Artifact getArtifact() { + return artifact_ == null ? datacatalog.Datacatalog.Artifact.getDefaultInstance() : artifact_; + } + /** + * .datacatalog.Artifact artifact = 1; + */ + public datacatalog.Datacatalog.ArtifactOrBuilder getArtifactOrBuilder() { + return getArtifact(); + } + + public static final int RESERVATION_STATUS_FIELD_NUMBER = 2; + private int reservationStatus_; + /** + * .datacatalog.ReservationStatus reservation_status = 2; + */ + public int getReservationStatusValue() { + return reservationStatus_; + } + /** + * .datacatalog.ReservationStatus reservation_status = 2; + */ + public datacatalog.Datacatalog.ReservationStatus getReservationStatus() { + @SuppressWarnings("deprecation") + datacatalog.Datacatalog.ReservationStatus result = datacatalog.Datacatalog.ReservationStatus.valueOf(reservationStatus_); + return result == null ? datacatalog.Datacatalog.ReservationStatus.UNRECOGNIZED : result; + } + + 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 (artifact_ != null) { + output.writeMessage(1, getArtifact()); + } + if (reservationStatus_ != datacatalog.Datacatalog.ReservationStatus.SUCCESS.getNumber()) { + output.writeEnum(2, reservationStatus_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (artifact_ != null) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, getArtifact()); + } + if (reservationStatus_ != datacatalog.Datacatalog.ReservationStatus.SUCCESS.getNumber()) { + size += com.google.protobuf.CodedOutputStream + .computeEnumSize(2, reservationStatus_); + } + 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 datacatalog.Datacatalog.GetOrReserveArtifactResponse)) { + return super.equals(obj); + } + datacatalog.Datacatalog.GetOrReserveArtifactResponse other = (datacatalog.Datacatalog.GetOrReserveArtifactResponse) obj; + + if (hasArtifact() != other.hasArtifact()) return false; + if (hasArtifact()) { + if (!getArtifact() + .equals(other.getArtifact())) return false; + } + if (reservationStatus_ != other.reservationStatus_) 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 (hasArtifact()) { + hash = (37 * hash) + ARTIFACT_FIELD_NUMBER; + hash = (53 * hash) + getArtifact().hashCode(); + } + hash = (37 * hash) + RESERVATION_STATUS_FIELD_NUMBER; + hash = (53 * hash) + reservationStatus_; + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom( + java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom( + java.nio.ByteBuffer data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse 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 datacatalog.Datacatalog.GetOrReserveArtifactResponse parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseDelimitedWithIOException(PARSER, input); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse 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 datacatalog.Datacatalog.GetOrReserveArtifactResponse parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3 + .parseWithIOException(PARSER, input); + } + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse 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(datacatalog.Datacatalog.GetOrReserveArtifactResponse 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 datacatalog.GetOrReserveArtifactResponse} + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessageV3.Builder implements + // @@protoc_insertion_point(builder_implements:datacatalog.GetOrReserveArtifactResponse) + datacatalog.Datacatalog.GetOrReserveArtifactResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + datacatalog.Datacatalog.GetOrReserveArtifactResponse.class, datacatalog.Datacatalog.GetOrReserveArtifactResponse.Builder.class); + } + + // Construct using datacatalog.Datacatalog.GetOrReserveArtifactResponse.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 (artifactBuilder_ == null) { + artifact_ = null; + } else { + artifact_ = null; + artifactBuilder_ = null; + } + reservationStatus_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return datacatalog.Datacatalog.internal_static_datacatalog_GetOrReserveArtifactResponse_descriptor; + } + + @java.lang.Override + public datacatalog.Datacatalog.GetOrReserveArtifactResponse getDefaultInstanceForType() { + return datacatalog.Datacatalog.GetOrReserveArtifactResponse.getDefaultInstance(); + } + + @java.lang.Override + public datacatalog.Datacatalog.GetOrReserveArtifactResponse build() { + datacatalog.Datacatalog.GetOrReserveArtifactResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public datacatalog.Datacatalog.GetOrReserveArtifactResponse buildPartial() { + datacatalog.Datacatalog.GetOrReserveArtifactResponse result = new datacatalog.Datacatalog.GetOrReserveArtifactResponse(this); + if (artifactBuilder_ == null) { + result.artifact_ = artifact_; + } else { + result.artifact_ = artifactBuilder_.build(); + } + result.reservationStatus_ = reservationStatus_; + 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 datacatalog.Datacatalog.GetOrReserveArtifactResponse) { + return mergeFrom((datacatalog.Datacatalog.GetOrReserveArtifactResponse)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(datacatalog.Datacatalog.GetOrReserveArtifactResponse other) { + if (other == datacatalog.Datacatalog.GetOrReserveArtifactResponse.getDefaultInstance()) return this; + if (other.hasArtifact()) { + mergeArtifact(other.getArtifact()); + } + if (other.reservationStatus_ != 0) { + setReservationStatusValue(other.getReservationStatusValue()); + } + 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 { + datacatalog.Datacatalog.GetOrReserveArtifactResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (datacatalog.Datacatalog.GetOrReserveArtifactResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private datacatalog.Datacatalog.Artifact artifact_; + private com.google.protobuf.SingleFieldBuilderV3< + datacatalog.Datacatalog.Artifact, datacatalog.Datacatalog.Artifact.Builder, datacatalog.Datacatalog.ArtifactOrBuilder> artifactBuilder_; + /** + * .datacatalog.Artifact artifact = 1; + */ + public boolean hasArtifact() { + return artifactBuilder_ != null || artifact_ != null; + } + /** + * .datacatalog.Artifact artifact = 1; + */ + public datacatalog.Datacatalog.Artifact getArtifact() { + if (artifactBuilder_ == null) { + return artifact_ == null ? datacatalog.Datacatalog.Artifact.getDefaultInstance() : artifact_; + } else { + return artifactBuilder_.getMessage(); + } + } + /** + * .datacatalog.Artifact artifact = 1; + */ + public Builder setArtifact(datacatalog.Datacatalog.Artifact value) { + if (artifactBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + artifact_ = value; + onChanged(); + } else { + artifactBuilder_.setMessage(value); } + return this; } /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; + * .datacatalog.Artifact artifact = 1; */ - public Builder removeDatasets(int index) { - if (datasetsBuilder_ == null) { - ensureDatasetsIsMutable(); - datasets_.remove(index); + public Builder setArtifact( + datacatalog.Datacatalog.Artifact.Builder builderForValue) { + if (artifactBuilder_ == null) { + artifact_ = builderForValue.build(); onChanged(); } else { - datasetsBuilder_.remove(index); + artifactBuilder_.setMessage(builderForValue.build()); } + return this; } /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; - */ - public datacatalog.Datacatalog.Dataset.Builder getDatasetsBuilder( - int index) { - return getDatasetsFieldBuilder().getBuilder(index); - } - /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; + * .datacatalog.Artifact artifact = 1; */ - public datacatalog.Datacatalog.DatasetOrBuilder getDatasetsOrBuilder( - int index) { - if (datasetsBuilder_ == null) { - return datasets_.get(index); } else { - return datasetsBuilder_.getMessageOrBuilder(index); + public Builder mergeArtifact(datacatalog.Datacatalog.Artifact value) { + if (artifactBuilder_ == null) { + if (artifact_ != null) { + artifact_ = + datacatalog.Datacatalog.Artifact.newBuilder(artifact_).mergeFrom(value).buildPartial(); + } else { + artifact_ = value; + } + onChanged(); + } else { + artifactBuilder_.mergeFrom(value); } + + return this; } /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; + * .datacatalog.Artifact artifact = 1; */ - public java.util.List - getDatasetsOrBuilderList() { - if (datasetsBuilder_ != null) { - return datasetsBuilder_.getMessageOrBuilderList(); + public Builder clearArtifact() { + if (artifactBuilder_ == null) { + artifact_ = null; + onChanged(); } else { - return java.util.Collections.unmodifiableList(datasets_); + artifact_ = null; + artifactBuilder_ = null; } + + return this; } /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; + * .datacatalog.Artifact artifact = 1; */ - public datacatalog.Datacatalog.Dataset.Builder addDatasetsBuilder() { - return getDatasetsFieldBuilder().addBuilder( - datacatalog.Datacatalog.Dataset.getDefaultInstance()); + public datacatalog.Datacatalog.Artifact.Builder getArtifactBuilder() { + + onChanged(); + return getArtifactFieldBuilder().getBuilder(); } /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; + * .datacatalog.Artifact artifact = 1; */ - public datacatalog.Datacatalog.Dataset.Builder addDatasetsBuilder( - int index) { - return getDatasetsFieldBuilder().addBuilder( - index, datacatalog.Datacatalog.Dataset.getDefaultInstance()); + public datacatalog.Datacatalog.ArtifactOrBuilder getArtifactOrBuilder() { + if (artifactBuilder_ != null) { + return artifactBuilder_.getMessageOrBuilder(); + } else { + return artifact_ == null ? + datacatalog.Datacatalog.Artifact.getDefaultInstance() : artifact_; + } } /** - *
-       * The list of datasets
-       * 
- * - * repeated .datacatalog.Dataset datasets = 1; + * .datacatalog.Artifact artifact = 1; */ - public java.util.List - getDatasetsBuilderList() { - return getDatasetsFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilderV3< - datacatalog.Datacatalog.Dataset, datacatalog.Datacatalog.Dataset.Builder, datacatalog.Datacatalog.DatasetOrBuilder> - getDatasetsFieldBuilder() { - if (datasetsBuilder_ == null) { - datasetsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - datacatalog.Datacatalog.Dataset, datacatalog.Datacatalog.Dataset.Builder, datacatalog.Datacatalog.DatasetOrBuilder>( - datasets_, - ((bitField0_ & 0x00000001) != 0), + private com.google.protobuf.SingleFieldBuilderV3< + datacatalog.Datacatalog.Artifact, datacatalog.Datacatalog.Artifact.Builder, datacatalog.Datacatalog.ArtifactOrBuilder> + getArtifactFieldBuilder() { + if (artifactBuilder_ == null) { + artifactBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< + datacatalog.Datacatalog.Artifact, datacatalog.Datacatalog.Artifact.Builder, datacatalog.Datacatalog.ArtifactOrBuilder>( + getArtifact(), getParentForChildren(), isClean()); - datasets_ = null; + artifact_ = null; } - return datasetsBuilder_; + return artifactBuilder_; } - private java.lang.Object nextToken_ = ""; + private int reservationStatus_ = 0; /** - *
-       * Token to use to request the next page, pass this into the next requests PaginationOptions
-       * 
- * - * string next_token = 2; + * .datacatalog.ReservationStatus reservation_status = 2; */ - public java.lang.String getNextToken() { - java.lang.Object ref = nextToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } + public int getReservationStatusValue() { + return reservationStatus_; } /** - *
-       * Token to use to request the next page, pass this into the next requests PaginationOptions
-       * 
- * - * string next_token = 2; + * .datacatalog.ReservationStatus reservation_status = 2; */ - public com.google.protobuf.ByteString - getNextTokenBytes() { - java.lang.Object ref = nextToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - nextToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } + public Builder setReservationStatusValue(int value) { + reservationStatus_ = value; + onChanged(); + return this; } /** - *
-       * Token to use to request the next page, pass this into the next requests PaginationOptions
-       * 
- * - * string next_token = 2; + * .datacatalog.ReservationStatus reservation_status = 2; */ - public Builder setNextToken( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextToken_ = value; - onChanged(); - return this; + public datacatalog.Datacatalog.ReservationStatus getReservationStatus() { + @SuppressWarnings("deprecation") + datacatalog.Datacatalog.ReservationStatus result = datacatalog.Datacatalog.ReservationStatus.valueOf(reservationStatus_); + return result == null ? datacatalog.Datacatalog.ReservationStatus.UNRECOGNIZED : result; } /** - *
-       * Token to use to request the next page, pass this into the next requests PaginationOptions
-       * 
- * - * string next_token = 2; + * .datacatalog.ReservationStatus reservation_status = 2; */ - public Builder clearNextToken() { + public Builder setReservationStatus(datacatalog.Datacatalog.ReservationStatus value) { + if (value == null) { + throw new NullPointerException(); + } - nextToken_ = getDefaultInstance().getNextToken(); + reservationStatus_ = value.getNumber(); onChanged(); return this; } /** - *
-       * Token to use to request the next page, pass this into the next requests PaginationOptions
-       * 
- * - * string next_token = 2; + * .datacatalog.ReservationStatus reservation_status = 2; */ - public Builder setNextTokenBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + public Builder clearReservationStatus() { - nextToken_ = value; + reservationStatus_ = 0; onChanged(); return this; } @@ -10199,41 +11934,41 @@ public final Builder mergeUnknownFields( } - // @@protoc_insertion_point(builder_scope:datacatalog.ListDatasetsResponse) + // @@protoc_insertion_point(builder_scope:datacatalog.GetOrReserveArtifactResponse) } - // @@protoc_insertion_point(class_scope:datacatalog.ListDatasetsResponse) - private static final datacatalog.Datacatalog.ListDatasetsResponse DEFAULT_INSTANCE; + // @@protoc_insertion_point(class_scope:datacatalog.GetOrReserveArtifactResponse) + private static final datacatalog.Datacatalog.GetOrReserveArtifactResponse DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new datacatalog.Datacatalog.ListDatasetsResponse(); + DEFAULT_INSTANCE = new datacatalog.Datacatalog.GetOrReserveArtifactResponse(); } - public static datacatalog.Datacatalog.ListDatasetsResponse getDefaultInstance() { + public static datacatalog.Datacatalog.GetOrReserveArtifactResponse getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { + private static final com.google.protobuf.Parser + PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override - public ListDatasetsResponse parsePartialFrom( + public GetOrReserveArtifactResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListDatasetsResponse(input, extensionRegistry); + return new GetOrReserveArtifactResponse(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override - public datacatalog.Datacatalog.ListDatasetsResponse getDefaultInstanceForType() { + public datacatalog.Datacatalog.GetOrReserveArtifactResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } @@ -25758,6 +27493,16 @@ public datacatalog.Datacatalog.PaginationOptions getDefaultInstanceForType() { private static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_datacatalog_ListDatasetsResponse_fieldAccessorTable; + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_datacatalog_GetOrReserveArtifactRequest_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_datacatalog_GetOrReserveArtifactRequest_fieldAccessorTable; + private static final com.google.protobuf.Descriptors.Descriptor + internal_static_datacatalog_GetOrReserveArtifactResponse_descriptor; + private static final + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_datacatalog_GetOrReserveArtifactResponse_fieldAccessorTable; private static final com.google.protobuf.Descriptors.Descriptor internal_static_datacatalog_Dataset_descriptor; private static final @@ -25875,68 +27620,79 @@ public datacatalog.Datacatalog.PaginationOptions getDefaultInstanceForType() { "ination\030\002 \001(\0132\036.datacatalog.PaginationOp" + "tions\"R\n\024ListDatasetsResponse\022&\n\010dataset" + "s\030\001 \003(\0132\024.datacatalog.Dataset\022\022\n\nnext_to" + - "ken\030\002 \001(\t\"m\n\007Dataset\022\"\n\002id\030\001 \001(\0132\026.datac" + - "atalog.DatasetID\022\'\n\010metadata\030\002 \001(\0132\025.dat" + - "acatalog.Metadata\022\025\n\rpartitionKeys\030\003 \003(\t" + - "\"\'\n\tPartition\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" + - "\t\"Y\n\tDatasetID\022\017\n\007project\030\001 \001(\t\022\014\n\004name\030" + - "\002 \001(\t\022\016\n\006domain\030\003 \001(\t\022\017\n\007version\030\004 \001(\t\022\014" + - "\n\004UUID\030\005 \001(\t\"\215\002\n\010Artifact\022\n\n\002id\030\001 \001(\t\022\'\n" + - "\007dataset\030\002 \001(\0132\026.datacatalog.DatasetID\022\'" + - "\n\004data\030\003 \003(\0132\031.datacatalog.ArtifactData\022" + - "\'\n\010metadata\030\004 \001(\0132\025.datacatalog.Metadata" + - "\022*\n\npartitions\030\005 \003(\0132\026.datacatalog.Parti" + - "tion\022\036\n\004tags\030\006 \003(\0132\020.datacatalog.Tag\022.\n\n" + - "created_at\030\007 \001(\0132\032.google.protobuf.Times" + - "tamp\"C\n\014ArtifactData\022\014\n\004name\030\001 \001(\t\022%\n\005va" + - "lue\030\002 \001(\0132\026.flyteidl.core.Literal\"Q\n\003Tag" + - "\022\014\n\004name\030\001 \001(\t\022\023\n\013artifact_id\030\002 \001(\t\022\'\n\007d" + - "ataset\030\003 \001(\0132\026.datacatalog.DatasetID\"m\n\010" + - "Metadata\0222\n\007key_map\030\001 \003(\0132!.datacatalog." + - "Metadata.KeyMapEntry\032-\n\013KeyMapEntry\022\013\n\003k" + - "ey\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"F\n\020FilterExp" + - "ression\0222\n\007filters\030\001 \003(\0132!.datacatalog.S" + - "inglePropertyFilter\"\211\003\n\024SinglePropertyFi" + - "lter\0224\n\ntag_filter\030\001 \001(\0132\036.datacatalog.T" + - "agPropertyFilterH\000\022@\n\020partition_filter\030\002" + - " \001(\0132$.datacatalog.PartitionPropertyFilt" + - "erH\000\022>\n\017artifact_filter\030\003 \001(\0132#.datacata" + - "log.ArtifactPropertyFilterH\000\022<\n\016dataset_" + - "filter\030\004 \001(\0132\".datacatalog.DatasetProper" + - "tyFilterH\000\022F\n\010operator\030\n \001(\01624.datacatal" + - "og.SinglePropertyFilter.ComparisonOperat" + - "or\" \n\022ComparisonOperator\022\n\n\006EQUALS\020\000B\021\n\017" + - "property_filter\";\n\026ArtifactPropertyFilte" + - "r\022\025\n\013artifact_id\030\001 \001(\tH\000B\n\n\010property\"3\n\021" + - "TagPropertyFilter\022\022\n\010tag_name\030\001 \001(\tH\000B\n\n" + - "\010property\"S\n\027PartitionPropertyFilter\022,\n\007" + - "key_val\030\001 \001(\0132\031.datacatalog.KeyValuePair" + - "H\000B\n\n\010property\"*\n\014KeyValuePair\022\013\n\003key\030\001 " + - "\001(\t\022\r\n\005value\030\002 \001(\t\"k\n\025DatasetPropertyFil" + - "ter\022\021\n\007project\030\001 \001(\tH\000\022\016\n\004name\030\002 \001(\tH\000\022\020" + - "\n\006domain\030\003 \001(\tH\000\022\021\n\007version\030\004 \001(\tH\000B\n\n\010p" + - "roperty\"\361\001\n\021PaginationOptions\022\r\n\005limit\030\001" + - " \001(\r\022\r\n\005token\030\002 \001(\t\0227\n\007sortKey\030\003 \001(\0162&.d" + - "atacatalog.PaginationOptions.SortKey\022;\n\t" + - "sortOrder\030\004 \001(\0162(.datacatalog.Pagination" + - "Options.SortOrder\"*\n\tSortOrder\022\016\n\nDESCEN" + - "DING\020\000\022\r\n\tASCENDING\020\001\"\034\n\007SortKey\022\021\n\rCREA" + - "TION_TIME\020\0002\321\004\n\013DataCatalog\022V\n\rCreateDat" + - "aset\022!.datacatalog.CreateDatasetRequest\032" + - "\".datacatalog.CreateDatasetResponse\022M\n\nG" + - "etDataset\022\036.datacatalog.GetDatasetReques" + - "t\032\037.datacatalog.GetDatasetResponse\022Y\n\016Cr" + - "eateArtifact\022\".datacatalog.CreateArtifac" + - "tRequest\032#.datacatalog.CreateArtifactRes" + - "ponse\022P\n\013GetArtifact\022\037.datacatalog.GetAr" + - "tifactRequest\032 .datacatalog.GetArtifactR" + - "esponse\022A\n\006AddTag\022\032.datacatalog.AddTagRe" + - "quest\032\033.datacatalog.AddTagResponse\022V\n\rLi" + - "stArtifacts\022!.datacatalog.ListArtifactsR" + - "equest\032\".datacatalog.ListArtifactsRespon" + - "se\022S\n\014ListDatasets\022 .datacatalog.ListDat" + - "asetsRequest\032!.datacatalog.ListDatasetsR" + - "esponseb\006proto3" + "ken\030\002 \001(\t\"\212\001\n\033GetOrReserveArtifactReques" + + "t\022*\n\ndataset_id\030\001 \001(\0132\026.datacatalog.Data" + + "setID\022\020\n\010tag_name\030\002 \001(\t\022-\n\texpire_at\030\003 \001" + + "(\0132\032.google.protobuf.Timestamp\"\203\001\n\034GetOr" + + "ReserveArtifactResponse\022\'\n\010artifact\030\001 \001(" + + "\0132\025.datacatalog.Artifact\022:\n\022reservation_" + + "status\030\002 \001(\0162\036.datacatalog.ReservationSt" + + "atus\"m\n\007Dataset\022\"\n\002id\030\001 \001(\0132\026.datacatalo" + + "g.DatasetID\022\'\n\010metadata\030\002 \001(\0132\025.datacata" + + "log.Metadata\022\025\n\rpartitionKeys\030\003 \003(\t\"\'\n\tP" + + "artition\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t\"Y\n\t" + + "DatasetID\022\017\n\007project\030\001 \001(\t\022\014\n\004name\030\002 \001(\t" + + "\022\016\n\006domain\030\003 \001(\t\022\017\n\007version\030\004 \001(\t\022\014\n\004UUI" + + "D\030\005 \001(\t\"\215\002\n\010Artifact\022\n\n\002id\030\001 \001(\t\022\'\n\007data" + + "set\030\002 \001(\0132\026.datacatalog.DatasetID\022\'\n\004dat" + + "a\030\003 \003(\0132\031.datacatalog.ArtifactData\022\'\n\010me" + + "tadata\030\004 \001(\0132\025.datacatalog.Metadata\022*\n\np" + + "artitions\030\005 \003(\0132\026.datacatalog.Partition\022" + + "\036\n\004tags\030\006 \003(\0132\020.datacatalog.Tag\022.\n\ncreat" + + "ed_at\030\007 \001(\0132\032.google.protobuf.Timestamp\"" + + "C\n\014ArtifactData\022\014\n\004name\030\001 \001(\t\022%\n\005value\030\002" + + " \001(\0132\026.flyteidl.core.Literal\"Q\n\003Tag\022\014\n\004n" + + "ame\030\001 \001(\t\022\023\n\013artifact_id\030\002 \001(\t\022\'\n\007datase" + + "t\030\003 \001(\0132\026.datacatalog.DatasetID\"m\n\010Metad" + + "ata\0222\n\007key_map\030\001 \003(\0132!.datacatalog.Metad" + + "ata.KeyMapEntry\032-\n\013KeyMapEntry\022\013\n\003key\030\001 " + + "\001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"F\n\020FilterExpressi" + + "on\0222\n\007filters\030\001 \003(\0132!.datacatalog.Single" + + "PropertyFilter\"\211\003\n\024SinglePropertyFilter\022" + + "4\n\ntag_filter\030\001 \001(\0132\036.datacatalog.TagPro" + + "pertyFilterH\000\022@\n\020partition_filter\030\002 \001(\0132" + + "$.datacatalog.PartitionPropertyFilterH\000\022" + + ">\n\017artifact_filter\030\003 \001(\0132#.datacatalog.A" + + "rtifactPropertyFilterH\000\022<\n\016dataset_filte" + + "r\030\004 \001(\0132\".datacatalog.DatasetPropertyFil" + + "terH\000\022F\n\010operator\030\n \001(\01624.datacatalog.Si" + + "nglePropertyFilter.ComparisonOperator\" \n" + + "\022ComparisonOperator\022\n\n\006EQUALS\020\000B\021\n\017prope" + + "rty_filter\";\n\026ArtifactPropertyFilter\022\025\n\013" + + "artifact_id\030\001 \001(\tH\000B\n\n\010property\"3\n\021TagPr" + + "opertyFilter\022\022\n\010tag_name\030\001 \001(\tH\000B\n\n\010prop" + + "erty\"S\n\027PartitionPropertyFilter\022,\n\007key_v" + + "al\030\001 \001(\0132\031.datacatalog.KeyValuePairH\000B\n\n" + + "\010property\"*\n\014KeyValuePair\022\013\n\003key\030\001 \001(\t\022\r" + + "\n\005value\030\002 \001(\t\"k\n\025DatasetPropertyFilter\022\021" + + "\n\007project\030\001 \001(\tH\000\022\016\n\004name\030\002 \001(\tH\000\022\020\n\006dom" + + "ain\030\003 \001(\tH\000\022\021\n\007version\030\004 \001(\tH\000B\n\n\010proper" + + "ty\"\361\001\n\021PaginationOptions\022\r\n\005limit\030\001 \001(\r\022" + + "\r\n\005token\030\002 \001(\t\0227\n\007sortKey\030\003 \001(\0162&.dataca" + + "talog.PaginationOptions.SortKey\022;\n\tsortO" + + "rder\030\004 \001(\0162(.datacatalog.PaginationOptio" + + "ns.SortOrder\"*\n\tSortOrder\022\016\n\nDESCENDING\020" + + "\000\022\r\n\tASCENDING\020\001\"\034\n\007SortKey\022\021\n\rCREATION_" + + "TIME\020\000*,\n\021ReservationStatus\022\013\n\007SUCCESS\020\000" + + "\022\n\n\006FAILED\020\0012\276\005\n\013DataCatalog\022V\n\rCreateDa" + + "taset\022!.datacatalog.CreateDatasetRequest" + + "\032\".datacatalog.CreateDatasetResponse\022M\n\n" + + "GetDataset\022\036.datacatalog.GetDatasetReque" + + "st\032\037.datacatalog.GetDatasetResponse\022Y\n\016C" + + "reateArtifact\022\".datacatalog.CreateArtifa" + + "ctRequest\032#.datacatalog.CreateArtifactRe" + + "sponse\022P\n\013GetArtifact\022\037.datacatalog.GetA" + + "rtifactRequest\032 .datacatalog.GetArtifact" + + "Response\022A\n\006AddTag\022\032.datacatalog.AddTagR" + + "equest\032\033.datacatalog.AddTagResponse\022V\n\rL" + + "istArtifacts\022!.datacatalog.ListArtifacts" + + "Request\032\".datacatalog.ListArtifactsRespo" + + "nse\022S\n\014ListDatasets\022 .datacatalog.ListDa" + + "tasetsRequest\032!.datacatalog.ListDatasets" + + "Response\022k\n\024GetOrReserveArtifact\022(.datac" + + "atalog.GetOrReserveArtifactRequest\032).dat" + + "acatalog.GetOrReserveArtifactResponseb\006p" + + "roto3" }; com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { @@ -26036,44 +27792,56 @@ public com.google.protobuf.ExtensionRegistry assignDescriptors( com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_ListDatasetsResponse_descriptor, new java.lang.String[] { "Datasets", "NextToken", }); - internal_static_datacatalog_Dataset_descriptor = + internal_static_datacatalog_GetOrReserveArtifactRequest_descriptor = getDescriptor().getMessageTypes().get(14); + internal_static_datacatalog_GetOrReserveArtifactRequest_fieldAccessorTable = new + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_datacatalog_GetOrReserveArtifactRequest_descriptor, + new java.lang.String[] { "DatasetId", "TagName", "ExpireAt", }); + internal_static_datacatalog_GetOrReserveArtifactResponse_descriptor = + getDescriptor().getMessageTypes().get(15); + internal_static_datacatalog_GetOrReserveArtifactResponse_fieldAccessorTable = new + com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_datacatalog_GetOrReserveArtifactResponse_descriptor, + new java.lang.String[] { "Artifact", "ReservationStatus", }); + internal_static_datacatalog_Dataset_descriptor = + getDescriptor().getMessageTypes().get(16); internal_static_datacatalog_Dataset_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_Dataset_descriptor, new java.lang.String[] { "Id", "Metadata", "PartitionKeys", }); internal_static_datacatalog_Partition_descriptor = - getDescriptor().getMessageTypes().get(15); + getDescriptor().getMessageTypes().get(17); internal_static_datacatalog_Partition_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_Partition_descriptor, new java.lang.String[] { "Key", "Value", }); internal_static_datacatalog_DatasetID_descriptor = - getDescriptor().getMessageTypes().get(16); + getDescriptor().getMessageTypes().get(18); internal_static_datacatalog_DatasetID_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_DatasetID_descriptor, new java.lang.String[] { "Project", "Name", "Domain", "Version", "UUID", }); internal_static_datacatalog_Artifact_descriptor = - getDescriptor().getMessageTypes().get(17); + getDescriptor().getMessageTypes().get(19); internal_static_datacatalog_Artifact_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_Artifact_descriptor, new java.lang.String[] { "Id", "Dataset", "Data", "Metadata", "Partitions", "Tags", "CreatedAt", }); internal_static_datacatalog_ArtifactData_descriptor = - getDescriptor().getMessageTypes().get(18); + getDescriptor().getMessageTypes().get(20); internal_static_datacatalog_ArtifactData_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_ArtifactData_descriptor, new java.lang.String[] { "Name", "Value", }); internal_static_datacatalog_Tag_descriptor = - getDescriptor().getMessageTypes().get(19); + getDescriptor().getMessageTypes().get(21); internal_static_datacatalog_Tag_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_Tag_descriptor, new java.lang.String[] { "Name", "ArtifactId", "Dataset", }); internal_static_datacatalog_Metadata_descriptor = - getDescriptor().getMessageTypes().get(20); + getDescriptor().getMessageTypes().get(22); internal_static_datacatalog_Metadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_Metadata_descriptor, @@ -26085,49 +27853,49 @@ public com.google.protobuf.ExtensionRegistry assignDescriptors( internal_static_datacatalog_Metadata_KeyMapEntry_descriptor, new java.lang.String[] { "Key", "Value", }); internal_static_datacatalog_FilterExpression_descriptor = - getDescriptor().getMessageTypes().get(21); + getDescriptor().getMessageTypes().get(23); internal_static_datacatalog_FilterExpression_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_FilterExpression_descriptor, new java.lang.String[] { "Filters", }); internal_static_datacatalog_SinglePropertyFilter_descriptor = - getDescriptor().getMessageTypes().get(22); + getDescriptor().getMessageTypes().get(24); internal_static_datacatalog_SinglePropertyFilter_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_SinglePropertyFilter_descriptor, new java.lang.String[] { "TagFilter", "PartitionFilter", "ArtifactFilter", "DatasetFilter", "Operator", "PropertyFilter", }); internal_static_datacatalog_ArtifactPropertyFilter_descriptor = - getDescriptor().getMessageTypes().get(23); + getDescriptor().getMessageTypes().get(25); internal_static_datacatalog_ArtifactPropertyFilter_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_ArtifactPropertyFilter_descriptor, new java.lang.String[] { "ArtifactId", "Property", }); internal_static_datacatalog_TagPropertyFilter_descriptor = - getDescriptor().getMessageTypes().get(24); + getDescriptor().getMessageTypes().get(26); internal_static_datacatalog_TagPropertyFilter_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_TagPropertyFilter_descriptor, new java.lang.String[] { "TagName", "Property", }); internal_static_datacatalog_PartitionPropertyFilter_descriptor = - getDescriptor().getMessageTypes().get(25); + getDescriptor().getMessageTypes().get(27); internal_static_datacatalog_PartitionPropertyFilter_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_PartitionPropertyFilter_descriptor, new java.lang.String[] { "KeyVal", "Property", }); internal_static_datacatalog_KeyValuePair_descriptor = - getDescriptor().getMessageTypes().get(26); + getDescriptor().getMessageTypes().get(28); internal_static_datacatalog_KeyValuePair_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_KeyValuePair_descriptor, new java.lang.String[] { "Key", "Value", }); internal_static_datacatalog_DatasetPropertyFilter_descriptor = - getDescriptor().getMessageTypes().get(27); + getDescriptor().getMessageTypes().get(29); internal_static_datacatalog_DatasetPropertyFilter_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_DatasetPropertyFilter_descriptor, new java.lang.String[] { "Project", "Name", "Domain", "Version", "Property", }); internal_static_datacatalog_PaginationOptions_descriptor = - getDescriptor().getMessageTypes().get(28); + getDescriptor().getMessageTypes().get(30); internal_static_datacatalog_PaginationOptions_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_datacatalog_PaginationOptions_descriptor, diff --git a/gen/pb-protodoc/flyteidl/datacatalog/datacatalog.proto.rst b/gen/pb-protodoc/flyteidl/datacatalog/datacatalog.proto.rst index a7ade52df..89c6d9874 100644 --- a/gen/pb-protodoc/flyteidl/datacatalog/datacatalog.proto.rst +++ b/gen/pb-protodoc/flyteidl/datacatalog/datacatalog.proto.rst @@ -8,7 +8,7 @@ datacatalog.proto datacatalog.CreateDatasetRequest -------------------------------- -`[datacatalog.CreateDatasetRequest proto] `_ +`[datacatalog.CreateDatasetRequest proto] `_ Request message for creating a Dataset. @@ -31,7 +31,7 @@ dataset datacatalog.CreateDatasetResponse --------------------------------- -`[datacatalog.CreateDatasetResponse proto] `_ +`[datacatalog.CreateDatasetResponse proto] `_ Response message for creating a Dataset @@ -48,7 +48,7 @@ Response message for creating a Dataset datacatalog.GetDatasetRequest ----------------------------- -`[datacatalog.GetDatasetRequest proto] `_ +`[datacatalog.GetDatasetRequest proto] `_ Request message for retrieving a Dataset. The Dataset is retrieved by it's unique identifier @@ -72,7 +72,7 @@ dataset datacatalog.GetDatasetResponse ------------------------------ -`[datacatalog.GetDatasetResponse proto] `_ +`[datacatalog.GetDatasetResponse proto] `_ Response message for retrieving a Dataset. The response will include the metadata for the @@ -96,7 +96,7 @@ dataset datacatalog.GetArtifactRequest ------------------------------ -`[datacatalog.GetArtifactRequest proto] `_ +`[datacatalog.GetArtifactRequest proto] `_ Request message for retrieving an Artifact. Retrieve an artifact based on a query handle that @@ -139,7 +139,7 @@ tag_name datacatalog.GetArtifactResponse ------------------------------- -`[datacatalog.GetArtifactResponse proto] `_ +`[datacatalog.GetArtifactResponse proto] `_ Response message for retrieving an Artifact. The result returned will include the artifact data @@ -163,7 +163,7 @@ artifact datacatalog.CreateArtifactRequest --------------------------------- -`[datacatalog.CreateArtifactRequest proto] `_ +`[datacatalog.CreateArtifactRequest proto] `_ Request message for creating an Artifact and its associated artifact Data. @@ -186,7 +186,7 @@ artifact datacatalog.CreateArtifactResponse ---------------------------------- -`[datacatalog.CreateArtifactResponse proto] `_ +`[datacatalog.CreateArtifactResponse proto] `_ Response message for creating an Artifact. @@ -203,7 +203,7 @@ Response message for creating an Artifact. datacatalog.AddTagRequest ------------------------- -`[datacatalog.AddTagRequest proto] `_ +`[datacatalog.AddTagRequest proto] `_ Request message for tagging an Artifact. @@ -226,7 +226,7 @@ tag datacatalog.AddTagResponse -------------------------- -`[datacatalog.AddTagResponse proto] `_ +`[datacatalog.AddTagResponse proto] `_ Response message for tagging an Artifact. @@ -243,7 +243,7 @@ Response message for tagging an Artifact. datacatalog.ListArtifactsRequest -------------------------------- -`[datacatalog.ListArtifactsRequest proto] `_ +`[datacatalog.ListArtifactsRequest proto] `_ List the artifacts that belong to the Dataset, optionally filtered using filtered expression. @@ -280,7 +280,7 @@ pagination datacatalog.ListArtifactsResponse --------------------------------- -`[datacatalog.ListArtifactsResponse proto] `_ +`[datacatalog.ListArtifactsResponse proto] `_ Response to list artifacts @@ -310,7 +310,7 @@ next_token datacatalog.ListDatasetsRequest ------------------------------- -`[datacatalog.ListDatasetsRequest proto] `_ +`[datacatalog.ListDatasetsRequest proto] `_ List the datasets for the given query @@ -340,7 +340,7 @@ pagination datacatalog.ListDatasetsResponse -------------------------------- -`[datacatalog.ListDatasetsResponse proto] `_ +`[datacatalog.ListDatasetsResponse proto] `_ List the datasets response with token for next pagination @@ -365,12 +365,72 @@ next_token +.. _api_msg_datacatalog.GetOrReserveArtifactRequest: + +datacatalog.GetOrReserveArtifactRequest +--------------------------------------- + +`[datacatalog.GetOrReserveArtifactRequest proto] `_ + + +.. code-block:: json + + { + "dataset_id": "{...}", + "tag_name": "...", + "expire_at": "{...}" + } + +.. _api_field_datacatalog.GetOrReserveArtifactRequest.dataset_id: + +dataset_id + (:ref:`datacatalog.DatasetID `) + +.. _api_field_datacatalog.GetOrReserveArtifactRequest.tag_name: + +tag_name + (`string `_) + +.. _api_field_datacatalog.GetOrReserveArtifactRequest.expire_at: + +expire_at + (:ref:`google.protobuf.Timestamp `) + + + +.. _api_msg_datacatalog.GetOrReserveArtifactResponse: + +datacatalog.GetOrReserveArtifactResponse +---------------------------------------- + +`[datacatalog.GetOrReserveArtifactResponse proto] `_ + + +.. code-block:: json + + { + "artifact": "{...}", + "reservation_status": "..." + } + +.. _api_field_datacatalog.GetOrReserveArtifactResponse.artifact: + +artifact + (:ref:`datacatalog.Artifact `) + +.. _api_field_datacatalog.GetOrReserveArtifactResponse.reservation_status: + +reservation_status + (:ref:`datacatalog.ReservationStatus `) + + + .. _api_msg_datacatalog.Dataset: datacatalog.Dataset ------------------- -`[datacatalog.Dataset proto] `_ +`[datacatalog.Dataset proto] `_ Dataset message. It is uniquely identified by DatasetID. @@ -405,7 +465,7 @@ partitionKeys datacatalog.Partition --------------------- -`[datacatalog.Partition proto] `_ +`[datacatalog.Partition proto] `_ An artifact could have multiple partitions and each partition can have an arbitrary string key/value pair @@ -434,7 +494,7 @@ value datacatalog.DatasetID --------------------- -`[datacatalog.DatasetID proto] `_ +`[datacatalog.DatasetID proto] `_ DatasetID message that is composed of several string fields. @@ -481,7 +541,7 @@ UUID datacatalog.Artifact -------------------- -`[datacatalog.Artifact proto] `_ +`[datacatalog.Artifact proto] `_ Artifact message. It is composed of several string fields. @@ -540,7 +600,7 @@ created_at datacatalog.ArtifactData ------------------------ -`[datacatalog.ArtifactData proto] `_ +`[datacatalog.ArtifactData proto] `_ ArtifactData that belongs to an artifact @@ -569,7 +629,7 @@ value datacatalog.Tag --------------- -`[datacatalog.Tag proto] `_ +`[datacatalog.Tag proto] `_ Tag message that is unique to a Dataset. It is associated to a single artifact and @@ -605,7 +665,7 @@ dataset datacatalog.Metadata -------------------- -`[datacatalog.Metadata proto] `_ +`[datacatalog.Metadata proto] `_ Metadata representation for artifacts and datasets @@ -628,7 +688,7 @@ key_map datacatalog.FilterExpression ---------------------------- -`[datacatalog.FilterExpression proto] `_ +`[datacatalog.FilterExpression proto] `_ Filter expression that is composed of a combination of single filters @@ -650,7 +710,7 @@ filters datacatalog.SinglePropertyFilter -------------------------------- -`[datacatalog.SinglePropertyFilter proto] `_ +`[datacatalog.SinglePropertyFilter proto] `_ A single property to filter on. @@ -707,7 +767,7 @@ operator Enum datacatalog.SinglePropertyFilter.ComparisonOperator -------------------------------------------------------- -`[datacatalog.SinglePropertyFilter.ComparisonOperator proto] `_ +`[datacatalog.SinglePropertyFilter.ComparisonOperator proto] `_ as use-cases come up we can add more operators, ex: gte, like, not eq etc. @@ -722,7 +782,7 @@ EQUALS datacatalog.ArtifactPropertyFilter ---------------------------------- -`[datacatalog.ArtifactPropertyFilter proto] `_ +`[datacatalog.ArtifactPropertyFilter proto] `_ Artifact properties we can filter by @@ -746,7 +806,7 @@ artifact_id datacatalog.TagPropertyFilter ----------------------------- -`[datacatalog.TagPropertyFilter proto] `_ +`[datacatalog.TagPropertyFilter proto] `_ Tag properties we can filter by @@ -769,7 +829,7 @@ tag_name datacatalog.PartitionPropertyFilter ----------------------------------- -`[datacatalog.PartitionPropertyFilter proto] `_ +`[datacatalog.PartitionPropertyFilter proto] `_ Partition properties we can filter by @@ -792,7 +852,7 @@ key_val datacatalog.KeyValuePair ------------------------ -`[datacatalog.KeyValuePair proto] `_ +`[datacatalog.KeyValuePair proto] `_ .. code-block:: json @@ -819,7 +879,7 @@ value datacatalog.DatasetPropertyFilter --------------------------------- -`[datacatalog.DatasetPropertyFilter proto] `_ +`[datacatalog.DatasetPropertyFilter proto] `_ Dataset properties we can filter by @@ -871,7 +931,7 @@ version datacatalog.PaginationOptions ----------------------------- -`[datacatalog.PaginationOptions proto] `_ +`[datacatalog.PaginationOptions proto] `_ Pagination options for making list requests @@ -914,7 +974,7 @@ sortOrder Enum datacatalog.PaginationOptions.SortOrder -------------------------------------------- -`[datacatalog.PaginationOptions.SortOrder proto] `_ +`[datacatalog.PaginationOptions.SortOrder proto] `_ .. _api_enum_value_datacatalog.PaginationOptions.SortOrder.DESCENDING: @@ -933,7 +993,7 @@ ASCENDING Enum datacatalog.PaginationOptions.SortKey ------------------------------------------ -`[datacatalog.PaginationOptions.SortKey proto] `_ +`[datacatalog.PaginationOptions.SortKey proto] `_ .. _api_enum_value_datacatalog.PaginationOptions.SortKey.CREATION_TIME: @@ -941,3 +1001,21 @@ Enum datacatalog.PaginationOptions.SortKey CREATION_TIME *(DEFAULT)* ⁣ +.. _api_enum_datacatalog.ReservationStatus: + +Enum datacatalog.ReservationStatus +---------------------------------- + +`[datacatalog.ReservationStatus proto] `_ + + +.. _api_enum_value_datacatalog.ReservationStatus.SUCCESS: + +SUCCESS + *(DEFAULT)* ⁣ + +.. _api_enum_value_datacatalog.ReservationStatus.FAILED: + +FAILED + ⁣ + diff --git a/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2.py b/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2.py index 6d50252f2..1b7653fb2 100644 --- a/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2.py +++ b/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2.py @@ -4,6 +4,7 @@ import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) +from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection @@ -22,10 +23,35 @@ package='datacatalog', syntax='proto3', serialized_options=None, - serialized_pb=_b('\n&flyteidl/datacatalog/datacatalog.proto\x12\x0b\x64\x61tacatalog\x1a\x1c\x66lyteidl/core/literals.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"=\n\x14\x43reateDatasetRequest\x12%\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x14.datacatalog.Dataset\"\x17\n\x15\x43reateDatasetResponse\"<\n\x11GetDatasetRequest\x12\'\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\";\n\x12GetDatasetResponse\x12%\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x14.datacatalog.Dataset\"x\n\x12GetArtifactRequest\x12\'\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\x15\n\x0b\x61rtifact_id\x18\x02 \x01(\tH\x00\x12\x12\n\x08tag_name\x18\x03 \x01(\tH\x00\x42\x0e\n\x0cquery_handle\">\n\x13GetArtifactResponse\x12\'\n\x08\x61rtifact\x18\x01 \x01(\x0b\x32\x15.datacatalog.Artifact\"@\n\x15\x43reateArtifactRequest\x12\'\n\x08\x61rtifact\x18\x01 \x01(\x0b\x32\x15.datacatalog.Artifact\"\x18\n\x16\x43reateArtifactResponse\".\n\rAddTagRequest\x12\x1d\n\x03tag\x18\x01 \x01(\x0b\x32\x10.datacatalog.Tag\"\x10\n\x0e\x41\x64\x64TagResponse\"\xa2\x01\n\x14ListArtifactsRequest\x12\'\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12-\n\x06\x66ilter\x18\x02 \x01(\x0b\x32\x1d.datacatalog.FilterExpression\x12\x32\n\npagination\x18\x03 \x01(\x0b\x32\x1e.datacatalog.PaginationOptions\"U\n\x15ListArtifactsResponse\x12(\n\tartifacts\x18\x01 \x03(\x0b\x32\x15.datacatalog.Artifact\x12\x12\n\nnext_token\x18\x02 \x01(\t\"x\n\x13ListDatasetsRequest\x12-\n\x06\x66ilter\x18\x01 \x01(\x0b\x32\x1d.datacatalog.FilterExpression\x12\x32\n\npagination\x18\x02 \x01(\x0b\x32\x1e.datacatalog.PaginationOptions\"R\n\x14ListDatasetsResponse\x12&\n\x08\x64\x61tasets\x18\x01 \x03(\x0b\x32\x14.datacatalog.Dataset\x12\x12\n\nnext_token\x18\x02 \x01(\t\"m\n\x07\x44\x61taset\x12\"\n\x02id\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\'\n\x08metadata\x18\x02 \x01(\x0b\x32\x15.datacatalog.Metadata\x12\x15\n\rpartitionKeys\x18\x03 \x03(\t\"\'\n\tPartition\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"Y\n\tDatasetID\x12\x0f\n\x07project\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0e\n\x06\x64omain\x18\x03 \x01(\t\x12\x0f\n\x07version\x18\x04 \x01(\t\x12\x0c\n\x04UUID\x18\x05 \x01(\t\"\x8d\x02\n\x08\x41rtifact\x12\n\n\x02id\x18\x01 \x01(\t\x12\'\n\x07\x64\x61taset\x18\x02 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\'\n\x04\x64\x61ta\x18\x03 \x03(\x0b\x32\x19.datacatalog.ArtifactData\x12\'\n\x08metadata\x18\x04 \x01(\x0b\x32\x15.datacatalog.Metadata\x12*\n\npartitions\x18\x05 \x03(\x0b\x32\x16.datacatalog.Partition\x12\x1e\n\x04tags\x18\x06 \x03(\x0b\x32\x10.datacatalog.Tag\x12.\n\ncreated_at\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"C\n\x0c\x41rtifactData\x12\x0c\n\x04name\x18\x01 \x01(\t\x12%\n\x05value\x18\x02 \x01(\x0b\x32\x16.flyteidl.core.Literal\"Q\n\x03Tag\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x13\n\x0b\x61rtifact_id\x18\x02 \x01(\t\x12\'\n\x07\x64\x61taset\x18\x03 \x01(\x0b\x32\x16.datacatalog.DatasetID\"m\n\x08Metadata\x12\x32\n\x07key_map\x18\x01 \x03(\x0b\x32!.datacatalog.Metadata.KeyMapEntry\x1a-\n\x0bKeyMapEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"F\n\x10\x46ilterExpression\x12\x32\n\x07\x66ilters\x18\x01 \x03(\x0b\x32!.datacatalog.SinglePropertyFilter\"\x89\x03\n\x14SinglePropertyFilter\x12\x34\n\ntag_filter\x18\x01 \x01(\x0b\x32\x1e.datacatalog.TagPropertyFilterH\x00\x12@\n\x10partition_filter\x18\x02 \x01(\x0b\x32$.datacatalog.PartitionPropertyFilterH\x00\x12>\n\x0f\x61rtifact_filter\x18\x03 \x01(\x0b\x32#.datacatalog.ArtifactPropertyFilterH\x00\x12<\n\x0e\x64\x61taset_filter\x18\x04 \x01(\x0b\x32\".datacatalog.DatasetPropertyFilterH\x00\x12\x46\n\x08operator\x18\n \x01(\x0e\x32\x34.datacatalog.SinglePropertyFilter.ComparisonOperator\" \n\x12\x43omparisonOperator\x12\n\n\x06\x45QUALS\x10\x00\x42\x11\n\x0fproperty_filter\";\n\x16\x41rtifactPropertyFilter\x12\x15\n\x0b\x61rtifact_id\x18\x01 \x01(\tH\x00\x42\n\n\x08property\"3\n\x11TagPropertyFilter\x12\x12\n\x08tag_name\x18\x01 \x01(\tH\x00\x42\n\n\x08property\"S\n\x17PartitionPropertyFilter\x12,\n\x07key_val\x18\x01 \x01(\x0b\x32\x19.datacatalog.KeyValuePairH\x00\x42\n\n\x08property\"*\n\x0cKeyValuePair\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"k\n\x15\x44\x61tasetPropertyFilter\x12\x11\n\x07project\x18\x01 \x01(\tH\x00\x12\x0e\n\x04name\x18\x02 \x01(\tH\x00\x12\x10\n\x06\x64omain\x18\x03 \x01(\tH\x00\x12\x11\n\x07version\x18\x04 \x01(\tH\x00\x42\n\n\x08property\"\xf1\x01\n\x11PaginationOptions\x12\r\n\x05limit\x18\x01 \x01(\r\x12\r\n\x05token\x18\x02 \x01(\t\x12\x37\n\x07sortKey\x18\x03 \x01(\x0e\x32&.datacatalog.PaginationOptions.SortKey\x12;\n\tsortOrder\x18\x04 \x01(\x0e\x32(.datacatalog.PaginationOptions.SortOrder\"*\n\tSortOrder\x12\x0e\n\nDESCENDING\x10\x00\x12\r\n\tASCENDING\x10\x01\"\x1c\n\x07SortKey\x12\x11\n\rCREATION_TIME\x10\x00\x32\xd1\x04\n\x0b\x44\x61taCatalog\x12V\n\rCreateDataset\x12!.datacatalog.CreateDatasetRequest\x1a\".datacatalog.CreateDatasetResponse\x12M\n\nGetDataset\x12\x1e.datacatalog.GetDatasetRequest\x1a\x1f.datacatalog.GetDatasetResponse\x12Y\n\x0e\x43reateArtifact\x12\".datacatalog.CreateArtifactRequest\x1a#.datacatalog.CreateArtifactResponse\x12P\n\x0bGetArtifact\x12\x1f.datacatalog.GetArtifactRequest\x1a .datacatalog.GetArtifactResponse\x12\x41\n\x06\x41\x64\x64Tag\x12\x1a.datacatalog.AddTagRequest\x1a\x1b.datacatalog.AddTagResponse\x12V\n\rListArtifacts\x12!.datacatalog.ListArtifactsRequest\x1a\".datacatalog.ListArtifactsResponse\x12S\n\x0cListDatasets\x12 .datacatalog.ListDatasetsRequest\x1a!.datacatalog.ListDatasetsResponseb\x06proto3') + serialized_pb=_b('\n&flyteidl/datacatalog/datacatalog.proto\x12\x0b\x64\x61tacatalog\x1a\x1c\x66lyteidl/core/literals.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"=\n\x14\x43reateDatasetRequest\x12%\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x14.datacatalog.Dataset\"\x17\n\x15\x43reateDatasetResponse\"<\n\x11GetDatasetRequest\x12\'\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\";\n\x12GetDatasetResponse\x12%\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x14.datacatalog.Dataset\"x\n\x12GetArtifactRequest\x12\'\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\x15\n\x0b\x61rtifact_id\x18\x02 \x01(\tH\x00\x12\x12\n\x08tag_name\x18\x03 \x01(\tH\x00\x42\x0e\n\x0cquery_handle\">\n\x13GetArtifactResponse\x12\'\n\x08\x61rtifact\x18\x01 \x01(\x0b\x32\x15.datacatalog.Artifact\"@\n\x15\x43reateArtifactRequest\x12\'\n\x08\x61rtifact\x18\x01 \x01(\x0b\x32\x15.datacatalog.Artifact\"\x18\n\x16\x43reateArtifactResponse\".\n\rAddTagRequest\x12\x1d\n\x03tag\x18\x01 \x01(\x0b\x32\x10.datacatalog.Tag\"\x10\n\x0e\x41\x64\x64TagResponse\"\xa2\x01\n\x14ListArtifactsRequest\x12\'\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12-\n\x06\x66ilter\x18\x02 \x01(\x0b\x32\x1d.datacatalog.FilterExpression\x12\x32\n\npagination\x18\x03 \x01(\x0b\x32\x1e.datacatalog.PaginationOptions\"U\n\x15ListArtifactsResponse\x12(\n\tartifacts\x18\x01 \x03(\x0b\x32\x15.datacatalog.Artifact\x12\x12\n\nnext_token\x18\x02 \x01(\t\"x\n\x13ListDatasetsRequest\x12-\n\x06\x66ilter\x18\x01 \x01(\x0b\x32\x1d.datacatalog.FilterExpression\x12\x32\n\npagination\x18\x02 \x01(\x0b\x32\x1e.datacatalog.PaginationOptions\"R\n\x14ListDatasetsResponse\x12&\n\x08\x64\x61tasets\x18\x01 \x03(\x0b\x32\x14.datacatalog.Dataset\x12\x12\n\nnext_token\x18\x02 \x01(\t\"\x8a\x01\n\x1bGetOrReserveArtifactRequest\x12*\n\ndataset_id\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\x10\n\x08tag_name\x18\x02 \x01(\t\x12-\n\texpire_at\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"\x83\x01\n\x1cGetOrReserveArtifactResponse\x12\'\n\x08\x61rtifact\x18\x01 \x01(\x0b\x32\x15.datacatalog.Artifact\x12:\n\x12reservation_status\x18\x02 \x01(\x0e\x32\x1e.datacatalog.ReservationStatus\"m\n\x07\x44\x61taset\x12\"\n\x02id\x18\x01 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\'\n\x08metadata\x18\x02 \x01(\x0b\x32\x15.datacatalog.Metadata\x12\x15\n\rpartitionKeys\x18\x03 \x03(\t\"\'\n\tPartition\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"Y\n\tDatasetID\x12\x0f\n\x07project\x18\x01 \x01(\t\x12\x0c\n\x04name\x18\x02 \x01(\t\x12\x0e\n\x06\x64omain\x18\x03 \x01(\t\x12\x0f\n\x07version\x18\x04 \x01(\t\x12\x0c\n\x04UUID\x18\x05 \x01(\t\"\x8d\x02\n\x08\x41rtifact\x12\n\n\x02id\x18\x01 \x01(\t\x12\'\n\x07\x64\x61taset\x18\x02 \x01(\x0b\x32\x16.datacatalog.DatasetID\x12\'\n\x04\x64\x61ta\x18\x03 \x03(\x0b\x32\x19.datacatalog.ArtifactData\x12\'\n\x08metadata\x18\x04 \x01(\x0b\x32\x15.datacatalog.Metadata\x12*\n\npartitions\x18\x05 \x03(\x0b\x32\x16.datacatalog.Partition\x12\x1e\n\x04tags\x18\x06 \x03(\x0b\x32\x10.datacatalog.Tag\x12.\n\ncreated_at\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\"C\n\x0c\x41rtifactData\x12\x0c\n\x04name\x18\x01 \x01(\t\x12%\n\x05value\x18\x02 \x01(\x0b\x32\x16.flyteidl.core.Literal\"Q\n\x03Tag\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x13\n\x0b\x61rtifact_id\x18\x02 \x01(\t\x12\'\n\x07\x64\x61taset\x18\x03 \x01(\x0b\x32\x16.datacatalog.DatasetID\"m\n\x08Metadata\x12\x32\n\x07key_map\x18\x01 \x03(\x0b\x32!.datacatalog.Metadata.KeyMapEntry\x1a-\n\x0bKeyMapEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"F\n\x10\x46ilterExpression\x12\x32\n\x07\x66ilters\x18\x01 \x03(\x0b\x32!.datacatalog.SinglePropertyFilter\"\x89\x03\n\x14SinglePropertyFilter\x12\x34\n\ntag_filter\x18\x01 \x01(\x0b\x32\x1e.datacatalog.TagPropertyFilterH\x00\x12@\n\x10partition_filter\x18\x02 \x01(\x0b\x32$.datacatalog.PartitionPropertyFilterH\x00\x12>\n\x0f\x61rtifact_filter\x18\x03 \x01(\x0b\x32#.datacatalog.ArtifactPropertyFilterH\x00\x12<\n\x0e\x64\x61taset_filter\x18\x04 \x01(\x0b\x32\".datacatalog.DatasetPropertyFilterH\x00\x12\x46\n\x08operator\x18\n \x01(\x0e\x32\x34.datacatalog.SinglePropertyFilter.ComparisonOperator\" \n\x12\x43omparisonOperator\x12\n\n\x06\x45QUALS\x10\x00\x42\x11\n\x0fproperty_filter\";\n\x16\x41rtifactPropertyFilter\x12\x15\n\x0b\x61rtifact_id\x18\x01 \x01(\tH\x00\x42\n\n\x08property\"3\n\x11TagPropertyFilter\x12\x12\n\x08tag_name\x18\x01 \x01(\tH\x00\x42\n\n\x08property\"S\n\x17PartitionPropertyFilter\x12,\n\x07key_val\x18\x01 \x01(\x0b\x32\x19.datacatalog.KeyValuePairH\x00\x42\n\n\x08property\"*\n\x0cKeyValuePair\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t\"k\n\x15\x44\x61tasetPropertyFilter\x12\x11\n\x07project\x18\x01 \x01(\tH\x00\x12\x0e\n\x04name\x18\x02 \x01(\tH\x00\x12\x10\n\x06\x64omain\x18\x03 \x01(\tH\x00\x12\x11\n\x07version\x18\x04 \x01(\tH\x00\x42\n\n\x08property\"\xf1\x01\n\x11PaginationOptions\x12\r\n\x05limit\x18\x01 \x01(\r\x12\r\n\x05token\x18\x02 \x01(\t\x12\x37\n\x07sortKey\x18\x03 \x01(\x0e\x32&.datacatalog.PaginationOptions.SortKey\x12;\n\tsortOrder\x18\x04 \x01(\x0e\x32(.datacatalog.PaginationOptions.SortOrder\"*\n\tSortOrder\x12\x0e\n\nDESCENDING\x10\x00\x12\r\n\tASCENDING\x10\x01\"\x1c\n\x07SortKey\x12\x11\n\rCREATION_TIME\x10\x00*,\n\x11ReservationStatus\x12\x0b\n\x07SUCCESS\x10\x00\x12\n\n\x06\x46\x41ILED\x10\x01\x32\xbe\x05\n\x0b\x44\x61taCatalog\x12V\n\rCreateDataset\x12!.datacatalog.CreateDatasetRequest\x1a\".datacatalog.CreateDatasetResponse\x12M\n\nGetDataset\x12\x1e.datacatalog.GetDatasetRequest\x1a\x1f.datacatalog.GetDatasetResponse\x12Y\n\x0e\x43reateArtifact\x12\".datacatalog.CreateArtifactRequest\x1a#.datacatalog.CreateArtifactResponse\x12P\n\x0bGetArtifact\x12\x1f.datacatalog.GetArtifactRequest\x1a .datacatalog.GetArtifactResponse\x12\x41\n\x06\x41\x64\x64Tag\x12\x1a.datacatalog.AddTagRequest\x1a\x1b.datacatalog.AddTagResponse\x12V\n\rListArtifacts\x12!.datacatalog.ListArtifactsRequest\x1a\".datacatalog.ListArtifactsResponse\x12S\n\x0cListDatasets\x12 .datacatalog.ListDatasetsRequest\x1a!.datacatalog.ListDatasetsResponse\x12k\n\x14GetOrReserveArtifact\x12(.datacatalog.GetOrReserveArtifactRequest\x1a).datacatalog.GetOrReserveArtifactResponseb\x06proto3') , dependencies=[flyteidl_dot_core_dot_literals__pb2.DESCRIPTOR,google_dot_protobuf_dot_timestamp__pb2.DESCRIPTOR,]) +_RESERVATIONSTATUS = _descriptor.EnumDescriptor( + name='ReservationStatus', + full_name='datacatalog.ReservationStatus', + filename=None, + file=DESCRIPTOR, + values=[ + _descriptor.EnumValueDescriptor( + name='SUCCESS', index=0, number=0, + serialized_options=None, + type=None), + _descriptor.EnumValueDescriptor( + name='FAILED', index=1, number=1, + serialized_options=None, + type=None), + ], + containing_type=None, + serialized_options=None, + serialized_start=3248, + serialized_end=3292, +) +_sym_db.RegisterEnumDescriptor(_RESERVATIONSTATUS) + +ReservationStatus = enum_type_wrapper.EnumTypeWrapper(_RESERVATIONSTATUS) +SUCCESS = 0 +FAILED = 1 _SINGLEPROPERTYFILTER_COMPARISONOPERATOR = _descriptor.EnumDescriptor( @@ -41,8 +67,8 @@ ], containing_type=None, serialized_options=None, - serialized_start=2324, - serialized_end=2356, + serialized_start=2599, + serialized_end=2631, ) _sym_db.RegisterEnumDescriptor(_SINGLEPROPERTYFILTER_COMPARISONOPERATOR) @@ -63,8 +89,8 @@ ], containing_type=None, serialized_options=None, - serialized_start=2899, - serialized_end=2941, + serialized_start=3174, + serialized_end=3216, ) _sym_db.RegisterEnumDescriptor(_PAGINATIONOPTIONS_SORTORDER) @@ -81,8 +107,8 @@ ], containing_type=None, serialized_options=None, - serialized_start=2943, - serialized_end=2971, + serialized_start=3218, + serialized_end=3246, ) _sym_db.RegisterEnumDescriptor(_PAGINATIONOPTIONS_SORTKEY) @@ -552,6 +578,89 @@ ) +_GETORRESERVEARTIFACTREQUEST = _descriptor.Descriptor( + name='GetOrReserveArtifactRequest', + full_name='datacatalog.GetOrReserveArtifactRequest', + filename=None, + file=DESCRIPTOR, + containing_type=None, + fields=[ + _descriptor.FieldDescriptor( + name='dataset_id', full_name='datacatalog.GetOrReserveArtifactRequest.dataset_id', index=0, + number=1, type=11, cpp_type=10, label=1, + has_default_value=False, default_value=None, + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + _descriptor.FieldDescriptor( + name='tag_name', full_name='datacatalog.GetOrReserveArtifactRequest.tag_name', index=1, + number=2, type=9, cpp_type=9, label=1, + has_default_value=False, default_value=_b("").decode('utf-8'), + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + _descriptor.FieldDescriptor( + name='expire_at', full_name='datacatalog.GetOrReserveArtifactRequest.expire_at', index=2, + number=3, type=11, cpp_type=10, label=1, + has_default_value=False, default_value=None, + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + ], + extensions=[ + ], + nested_types=[], + enum_types=[ + ], + serialized_options=None, + is_extendable=False, + syntax='proto3', + extension_ranges=[], + oneofs=[ + ], + serialized_start=1132, + serialized_end=1270, +) + + +_GETORRESERVEARTIFACTRESPONSE = _descriptor.Descriptor( + name='GetOrReserveArtifactResponse', + full_name='datacatalog.GetOrReserveArtifactResponse', + filename=None, + file=DESCRIPTOR, + containing_type=None, + fields=[ + _descriptor.FieldDescriptor( + name='artifact', full_name='datacatalog.GetOrReserveArtifactResponse.artifact', index=0, + number=1, type=11, cpp_type=10, label=1, + has_default_value=False, default_value=None, + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + _descriptor.FieldDescriptor( + name='reservation_status', full_name='datacatalog.GetOrReserveArtifactResponse.reservation_status', index=1, + number=2, type=14, cpp_type=8, label=1, + has_default_value=False, default_value=0, + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + ], + extensions=[ + ], + nested_types=[], + enum_types=[ + ], + serialized_options=None, + is_extendable=False, + syntax='proto3', + extension_ranges=[], + oneofs=[ + ], + serialized_start=1273, + serialized_end=1404, +) + + _DATASET = _descriptor.Descriptor( name='Dataset', full_name='datacatalog.Dataset', @@ -592,8 +701,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1131, - serialized_end=1240, + serialized_start=1406, + serialized_end=1515, ) @@ -630,8 +739,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1242, - serialized_end=1281, + serialized_start=1517, + serialized_end=1556, ) @@ -689,8 +798,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1283, - serialized_end=1372, + serialized_start=1558, + serialized_end=1647, ) @@ -762,8 +871,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1375, - serialized_end=1644, + serialized_start=1650, + serialized_end=1919, ) @@ -800,8 +909,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1646, - serialized_end=1713, + serialized_start=1921, + serialized_end=1988, ) @@ -845,8 +954,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1715, - serialized_end=1796, + serialized_start=1990, + serialized_end=2071, ) @@ -883,8 +992,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1862, - serialized_end=1907, + serialized_start=2137, + serialized_end=2182, ) _METADATA = _descriptor.Descriptor( @@ -913,8 +1022,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1798, - serialized_end=1907, + serialized_start=2073, + serialized_end=2182, ) @@ -944,8 +1053,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=1909, - serialized_end=1979, + serialized_start=2184, + serialized_end=2254, ) @@ -1007,8 +1116,8 @@ name='property_filter', full_name='datacatalog.SinglePropertyFilter.property_filter', index=0, containing_type=None, fields=[]), ], - serialized_start=1982, - serialized_end=2375, + serialized_start=2257, + serialized_end=2650, ) @@ -1041,8 +1150,8 @@ name='property', full_name='datacatalog.ArtifactPropertyFilter.property', index=0, containing_type=None, fields=[]), ], - serialized_start=2377, - serialized_end=2436, + serialized_start=2652, + serialized_end=2711, ) @@ -1075,8 +1184,8 @@ name='property', full_name='datacatalog.TagPropertyFilter.property', index=0, containing_type=None, fields=[]), ], - serialized_start=2438, - serialized_end=2489, + serialized_start=2713, + serialized_end=2764, ) @@ -1109,8 +1218,8 @@ name='property', full_name='datacatalog.PartitionPropertyFilter.property', index=0, containing_type=None, fields=[]), ], - serialized_start=2491, - serialized_end=2574, + serialized_start=2766, + serialized_end=2849, ) @@ -1147,8 +1256,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=2576, - serialized_end=2618, + serialized_start=2851, + serialized_end=2893, ) @@ -1202,8 +1311,8 @@ name='property', full_name='datacatalog.DatasetPropertyFilter.property', index=0, containing_type=None, fields=[]), ], - serialized_start=2620, - serialized_end=2727, + serialized_start=2895, + serialized_end=3002, ) @@ -1256,8 +1365,8 @@ extension_ranges=[], oneofs=[ ], - serialized_start=2730, - serialized_end=2971, + serialized_start=3005, + serialized_end=3246, ) _CREATEDATASETREQUEST.fields_by_name['dataset'].message_type = _DATASET @@ -1280,6 +1389,10 @@ _LISTDATASETSREQUEST.fields_by_name['filter'].message_type = _FILTEREXPRESSION _LISTDATASETSREQUEST.fields_by_name['pagination'].message_type = _PAGINATIONOPTIONS _LISTDATASETSRESPONSE.fields_by_name['datasets'].message_type = _DATASET +_GETORRESERVEARTIFACTREQUEST.fields_by_name['dataset_id'].message_type = _DATASETID +_GETORRESERVEARTIFACTREQUEST.fields_by_name['expire_at'].message_type = google_dot_protobuf_dot_timestamp__pb2._TIMESTAMP +_GETORRESERVEARTIFACTRESPONSE.fields_by_name['artifact'].message_type = _ARTIFACT +_GETORRESERVEARTIFACTRESPONSE.fields_by_name['reservation_status'].enum_type = _RESERVATIONSTATUS _DATASET.fields_by_name['id'].message_type = _DATASETID _DATASET.fields_by_name['metadata'].message_type = _METADATA _ARTIFACT.fields_by_name['dataset'].message_type = _DATASETID @@ -1351,6 +1464,8 @@ DESCRIPTOR.message_types_by_name['ListArtifactsResponse'] = _LISTARTIFACTSRESPONSE DESCRIPTOR.message_types_by_name['ListDatasetsRequest'] = _LISTDATASETSREQUEST DESCRIPTOR.message_types_by_name['ListDatasetsResponse'] = _LISTDATASETSRESPONSE +DESCRIPTOR.message_types_by_name['GetOrReserveArtifactRequest'] = _GETORRESERVEARTIFACTREQUEST +DESCRIPTOR.message_types_by_name['GetOrReserveArtifactResponse'] = _GETORRESERVEARTIFACTRESPONSE DESCRIPTOR.message_types_by_name['Dataset'] = _DATASET DESCRIPTOR.message_types_by_name['Partition'] = _PARTITION DESCRIPTOR.message_types_by_name['DatasetID'] = _DATASETID @@ -1366,6 +1481,7 @@ DESCRIPTOR.message_types_by_name['KeyValuePair'] = _KEYVALUEPAIR DESCRIPTOR.message_types_by_name['DatasetPropertyFilter'] = _DATASETPROPERTYFILTER DESCRIPTOR.message_types_by_name['PaginationOptions'] = _PAGINATIONOPTIONS +DESCRIPTOR.enum_types_by_name['ReservationStatus'] = _RESERVATIONSTATUS _sym_db.RegisterFileDescriptor(DESCRIPTOR) CreateDatasetRequest = _reflection.GeneratedProtocolMessageType('CreateDatasetRequest', (_message.Message,), dict( @@ -1466,6 +1582,20 @@ )) _sym_db.RegisterMessage(ListDatasetsResponse) +GetOrReserveArtifactRequest = _reflection.GeneratedProtocolMessageType('GetOrReserveArtifactRequest', (_message.Message,), dict( + DESCRIPTOR = _GETORRESERVEARTIFACTREQUEST, + __module__ = 'flyteidl.datacatalog.datacatalog_pb2' + # @@protoc_insertion_point(class_scope:datacatalog.GetOrReserveArtifactRequest) + )) +_sym_db.RegisterMessage(GetOrReserveArtifactRequest) + +GetOrReserveArtifactResponse = _reflection.GeneratedProtocolMessageType('GetOrReserveArtifactResponse', (_message.Message,), dict( + DESCRIPTOR = _GETORRESERVEARTIFACTRESPONSE, + __module__ = 'flyteidl.datacatalog.datacatalog_pb2' + # @@protoc_insertion_point(class_scope:datacatalog.GetOrReserveArtifactResponse) + )) +_sym_db.RegisterMessage(GetOrReserveArtifactResponse) + Dataset = _reflection.GeneratedProtocolMessageType('Dataset', (_message.Message,), dict( DESCRIPTOR = _DATASET, __module__ = 'flyteidl.datacatalog.datacatalog_pb2' @@ -1588,8 +1718,8 @@ file=DESCRIPTOR, index=0, serialized_options=None, - serialized_start=2974, - serialized_end=3567, + serialized_start=3295, + serialized_end=3997, methods=[ _descriptor.MethodDescriptor( name='CreateDataset', @@ -1654,6 +1784,15 @@ output_type=_LISTDATASETSRESPONSE, serialized_options=None, ), + _descriptor.MethodDescriptor( + name='GetOrReserveArtifact', + full_name='datacatalog.DataCatalog.GetOrReserveArtifact', + index=7, + containing_service=None, + input_type=_GETORRESERVEARTIFACTREQUEST, + output_type=_GETORRESERVEARTIFACTRESPONSE, + serialized_options=None, + ), ]) _sym_db.RegisterServiceDescriptor(_DATACATALOG) diff --git a/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2_grpc.py b/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2_grpc.py index d6a2ea509..3cac51685 100644 --- a/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2_grpc.py +++ b/gen/pb_python/flyteidl/datacatalog/datacatalog_pb2_grpc.py @@ -52,6 +52,11 @@ def __init__(self, channel): request_serializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.ListDatasetsRequest.SerializeToString, response_deserializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.ListDatasetsResponse.FromString, ) + self.GetOrReserveArtifact = channel.unary_unary( + '/datacatalog.DataCatalog/GetOrReserveArtifact', + request_serializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.GetOrReserveArtifactRequest.SerializeToString, + response_deserializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.GetOrReserveArtifactResponse.FromString, + ) class DataCatalogServicer(object): @@ -112,6 +117,17 @@ def ListDatasets(self, request, context): context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') + def GetOrReserveArtifact(self, request, context): + """Get an artifact and the corresponding data. If the artifact does not exist, + try to reserve a spot for populating the artifact. We may have multiple + concurrent tasks with the same signature and the same input that try to populate + the same artifact at the same time. Thus with reservation, only one task + can run at a time. + """ + context.set_code(grpc.StatusCode.UNIMPLEMENTED) + context.set_details('Method not implemented!') + raise NotImplementedError('Method not implemented!') + def add_DataCatalogServicer_to_server(servicer, server): rpc_method_handlers = { @@ -150,6 +166,11 @@ def add_DataCatalogServicer_to_server(servicer, server): request_deserializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.ListDatasetsRequest.FromString, response_serializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.ListDatasetsResponse.SerializeToString, ), + 'GetOrReserveArtifact': grpc.unary_unary_rpc_method_handler( + servicer.GetOrReserveArtifact, + request_deserializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.GetOrReserveArtifactRequest.FromString, + response_serializer=flyteidl_dot_datacatalog_dot_datacatalog__pb2.GetOrReserveArtifactResponse.SerializeToString, + ), } generic_handler = grpc.method_handlers_generic_handler( 'datacatalog.DataCatalog', rpc_method_handlers)