diff --git a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.grpc.pb.cc b/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.grpc.pb.cc deleted file mode 100644 index e5995eed01d..00000000000 --- a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.grpc.pb.cc +++ /dev/null @@ -1,24 +0,0 @@ -// Generated by the gRPC C++ plugin. -// If you make any local change, they will be lost. -// source: flyteidl/plugins/sidecar.proto - -#include "flyteidl/plugins/sidecar.pb.h" -#include "flyteidl/plugins/sidecar.grpc.pb.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -namespace flyteidl { -namespace plugins { - -} // namespace flyteidl -} // namespace plugins - diff --git a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.grpc.pb.h b/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.grpc.pb.h deleted file mode 100644 index 4ceccaa1223..00000000000 --- a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.grpc.pb.h +++ /dev/null @@ -1,47 +0,0 @@ -// Generated by the gRPC C++ plugin. -// If you make any local change, they will be lost. -// source: flyteidl/plugins/sidecar.proto -#ifndef GRPC_flyteidl_2fplugins_2fsidecar_2eproto__INCLUDED -#define GRPC_flyteidl_2fplugins_2fsidecar_2eproto__INCLUDED - -#include "flyteidl/plugins/sidecar.pb.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -namespace grpc_impl { -class Channel; -class CompletionQueue; -class ServerCompletionQueue; -} // namespace grpc_impl - -namespace grpc { -namespace experimental { -template -class MessageAllocator; -} // namespace experimental -} // namespace grpc_impl - -namespace grpc { -class ServerContext; -} // namespace grpc - -namespace flyteidl { -namespace plugins { - -} // namespace plugins -} // namespace flyteidl - - -#endif // GRPC_flyteidl_2fplugins_2fsidecar_2eproto__INCLUDED diff --git a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.pb.cc b/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.pb.cc deleted file mode 100644 index 1f33c24d42e..00000000000 --- a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.pb.cc +++ /dev/null @@ -1,965 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: flyteidl/plugins/sidecar.proto - -#include "flyteidl/plugins/sidecar.pb.h" - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -// @@protoc_insertion_point(includes) -#include - -extern PROTOBUF_INTERNAL_EXPORT_flyteidl_2fplugins_2fsidecar_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_SidecarJob_AnnotationsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto; -extern PROTOBUF_INTERNAL_EXPORT_flyteidl_2fplugins_2fsidecar_2eproto ::google::protobuf::internal::SCCInfo<0> scc_info_SidecarJob_LabelsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto; -extern PROTOBUF_INTERNAL_EXPORT_k8s_2eio_2fapi_2fcore_2fv1_2fgenerated_2eproto ::google::protobuf::internal::SCCInfo<10> scc_info_PodSpec_k8s_2eio_2fapi_2fcore_2fv1_2fgenerated_2eproto; -namespace flyteidl { -namespace plugins { -class SidecarJob_AnnotationsEntry_DoNotUseDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed _instance; -} _SidecarJob_AnnotationsEntry_DoNotUse_default_instance_; -class SidecarJob_LabelsEntry_DoNotUseDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed _instance; -} _SidecarJob_LabelsEntry_DoNotUse_default_instance_; -class SidecarJobDefaultTypeInternal { - public: - ::google::protobuf::internal::ExplicitlyConstructed _instance; -} _SidecarJob_default_instance_; -} // namespace plugins -} // namespace flyteidl -static void InitDefaultsSidecarJob_AnnotationsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto() { - GOOGLE_PROTOBUF_VERIFY_VERSION; - - { - void* ptr = &::flyteidl::plugins::_SidecarJob_AnnotationsEntry_DoNotUse_default_instance_; - new (ptr) ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse(); - } - ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse::InitAsDefaultInstance(); -} - -::google::protobuf::internal::SCCInfo<0> scc_info_SidecarJob_AnnotationsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto = - {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsSidecarJob_AnnotationsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto}, {}}; - -static void InitDefaultsSidecarJob_LabelsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto() { - GOOGLE_PROTOBUF_VERIFY_VERSION; - - { - void* ptr = &::flyteidl::plugins::_SidecarJob_LabelsEntry_DoNotUse_default_instance_; - new (ptr) ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse(); - } - ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse::InitAsDefaultInstance(); -} - -::google::protobuf::internal::SCCInfo<0> scc_info_SidecarJob_LabelsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto = - {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsSidecarJob_LabelsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto}, {}}; - -static void InitDefaultsSidecarJob_flyteidl_2fplugins_2fsidecar_2eproto() { - GOOGLE_PROTOBUF_VERIFY_VERSION; - - { - void* ptr = &::flyteidl::plugins::_SidecarJob_default_instance_; - new (ptr) ::flyteidl::plugins::SidecarJob(); - ::google::protobuf::internal::OnShutdownDestroyMessage(ptr); - } - ::flyteidl::plugins::SidecarJob::InitAsDefaultInstance(); -} - -::google::protobuf::internal::SCCInfo<3> scc_info_SidecarJob_flyteidl_2fplugins_2fsidecar_2eproto = - {{ATOMIC_VAR_INIT(::google::protobuf::internal::SCCInfoBase::kUninitialized), 3, InitDefaultsSidecarJob_flyteidl_2fplugins_2fsidecar_2eproto}, { - &scc_info_PodSpec_k8s_2eio_2fapi_2fcore_2fv1_2fgenerated_2eproto.base, - &scc_info_SidecarJob_AnnotationsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto.base, - &scc_info_SidecarJob_LabelsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto.base,}}; - -void InitDefaults_flyteidl_2fplugins_2fsidecar_2eproto() { - ::google::protobuf::internal::InitSCC(&scc_info_SidecarJob_AnnotationsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto.base); - ::google::protobuf::internal::InitSCC(&scc_info_SidecarJob_LabelsEntry_DoNotUse_flyteidl_2fplugins_2fsidecar_2eproto.base); - ::google::protobuf::internal::InitSCC(&scc_info_SidecarJob_flyteidl_2fplugins_2fsidecar_2eproto.base); -} - -::google::protobuf::Metadata file_level_metadata_flyteidl_2fplugins_2fsidecar_2eproto[3]; -constexpr ::google::protobuf::EnumDescriptor const** file_level_enum_descriptors_flyteidl_2fplugins_2fsidecar_2eproto = nullptr; -constexpr ::google::protobuf::ServiceDescriptor const** file_level_service_descriptors_flyteidl_2fplugins_2fsidecar_2eproto = nullptr; - -const ::google::protobuf::uint32 TableStruct_flyteidl_2fplugins_2fsidecar_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse, _has_bits_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse, key_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse, value_), - 0, - 1, - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse, _has_bits_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse, key_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse, value_), - 0, - 1, - ~0u, // no _has_bits_ - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob, _internal_metadata_), - ~0u, // no _extensions_ - ~0u, // no _oneof_case_ - ~0u, // no _weak_field_map_ - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob, pod_spec_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob, primary_container_name_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob, annotations_), - PROTOBUF_FIELD_OFFSET(::flyteidl::plugins::SidecarJob, labels_), -}; -static const ::google::protobuf::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { - { 0, 7, sizeof(::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse)}, - { 9, 16, sizeof(::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse)}, - { 18, -1, sizeof(::flyteidl::plugins::SidecarJob)}, -}; - -static ::google::protobuf::Message const * const file_default_instances[] = { - reinterpret_cast(&::flyteidl::plugins::_SidecarJob_AnnotationsEntry_DoNotUse_default_instance_), - reinterpret_cast(&::flyteidl::plugins::_SidecarJob_LabelsEntry_DoNotUse_default_instance_), - reinterpret_cast(&::flyteidl::plugins::_SidecarJob_default_instance_), -}; - -::google::protobuf::internal::AssignDescriptorsTable assign_descriptors_table_flyteidl_2fplugins_2fsidecar_2eproto = { - {}, AddDescriptors_flyteidl_2fplugins_2fsidecar_2eproto, "flyteidl/plugins/sidecar.proto", schemas, - file_default_instances, TableStruct_flyteidl_2fplugins_2fsidecar_2eproto::offsets, - file_level_metadata_flyteidl_2fplugins_2fsidecar_2eproto, 3, file_level_enum_descriptors_flyteidl_2fplugins_2fsidecar_2eproto, file_level_service_descriptors_flyteidl_2fplugins_2fsidecar_2eproto, -}; - -const char descriptor_table_protodef_flyteidl_2fplugins_2fsidecar_2eproto[] = - "\n\036flyteidl/plugins/sidecar.proto\022\020flytei" - "dl.plugins\032\"k8s.io/api/core/v1/generated" - ".proto\"\274\002\n\nSidecarJob\022-\n\010pod_spec\030\001 \001(\0132" - "\033.k8s.io.api.core.v1.PodSpec\022\036\n\026primary_" - "container_name\030\002 \001(\t\022B\n\013annotations\030\003 \003(" - "\0132-.flyteidl.plugins.SidecarJob.Annotati" - "onsEntry\0228\n\006labels\030\004 \003(\0132(.flyteidl.plug" - "ins.SidecarJob.LabelsEntry\0322\n\020Annotation" - "sEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\032-" - "\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" - "\t:\0028\001B9Z7github.com/flyteorg/flyteidl/ge" - "n/pb-go/flyteidl/pluginsb\006proto3" - ; -::google::protobuf::internal::DescriptorTable descriptor_table_flyteidl_2fplugins_2fsidecar_2eproto = { - false, InitDefaults_flyteidl_2fplugins_2fsidecar_2eproto, - descriptor_table_protodef_flyteidl_2fplugins_2fsidecar_2eproto, - "flyteidl/plugins/sidecar.proto", &assign_descriptors_table_flyteidl_2fplugins_2fsidecar_2eproto, 472, -}; - -void AddDescriptors_flyteidl_2fplugins_2fsidecar_2eproto() { - static constexpr ::google::protobuf::internal::InitFunc deps[1] = - { - ::AddDescriptors_k8s_2eio_2fapi_2fcore_2fv1_2fgenerated_2eproto, - }; - ::google::protobuf::internal::AddDescriptors(&descriptor_table_flyteidl_2fplugins_2fsidecar_2eproto, deps, 1); -} - -// Force running AddDescriptors() at dynamic initialization time. -static bool dynamic_init_dummy_flyteidl_2fplugins_2fsidecar_2eproto = []() { AddDescriptors_flyteidl_2fplugins_2fsidecar_2eproto(); return true; }(); -namespace flyteidl { -namespace plugins { - -// =================================================================== - -SidecarJob_AnnotationsEntry_DoNotUse::SidecarJob_AnnotationsEntry_DoNotUse() {} -SidecarJob_AnnotationsEntry_DoNotUse::SidecarJob_AnnotationsEntry_DoNotUse(::google::protobuf::Arena* arena) - : SuperType(arena) {} -void SidecarJob_AnnotationsEntry_DoNotUse::MergeFrom(const SidecarJob_AnnotationsEntry_DoNotUse& other) { - MergeFromInternal(other); -} -::google::protobuf::Metadata SidecarJob_AnnotationsEntry_DoNotUse::GetMetadata() const { - ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fplugins_2fsidecar_2eproto); - return ::file_level_metadata_flyteidl_2fplugins_2fsidecar_2eproto[0]; -} -void SidecarJob_AnnotationsEntry_DoNotUse::MergeFrom( - const ::google::protobuf::Message& other) { - ::google::protobuf::Message::MergeFrom(other); -} - -#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -bool SidecarJob_AnnotationsEntry_DoNotUse::_ParseMap(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx) { - using MF = ::google::protobuf::internal::MapField< - SidecarJob_AnnotationsEntry_DoNotUse, EntryKeyType, EntryValueType, - kEntryKeyFieldType, kEntryValueFieldType, - kEntryDefaultEnumValue>; - auto mf = static_cast(object); - Parser> parser(mf); -#define DO_(x) if (!(x)) return false - DO_(parser.ParseMap(begin, end)); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.key().data(), static_cast(parser.key().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.key")); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.value().data(), static_cast(parser.value().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.value")); -#undef DO_ - return true; -} -#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER - - -// =================================================================== - -SidecarJob_LabelsEntry_DoNotUse::SidecarJob_LabelsEntry_DoNotUse() {} -SidecarJob_LabelsEntry_DoNotUse::SidecarJob_LabelsEntry_DoNotUse(::google::protobuf::Arena* arena) - : SuperType(arena) {} -void SidecarJob_LabelsEntry_DoNotUse::MergeFrom(const SidecarJob_LabelsEntry_DoNotUse& other) { - MergeFromInternal(other); -} -::google::protobuf::Metadata SidecarJob_LabelsEntry_DoNotUse::GetMetadata() const { - ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fplugins_2fsidecar_2eproto); - return ::file_level_metadata_flyteidl_2fplugins_2fsidecar_2eproto[1]; -} -void SidecarJob_LabelsEntry_DoNotUse::MergeFrom( - const ::google::protobuf::Message& other) { - ::google::protobuf::Message::MergeFrom(other); -} - -#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -bool SidecarJob_LabelsEntry_DoNotUse::_ParseMap(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx) { - using MF = ::google::protobuf::internal::MapField< - SidecarJob_LabelsEntry_DoNotUse, EntryKeyType, EntryValueType, - kEntryKeyFieldType, kEntryValueFieldType, - kEntryDefaultEnumValue>; - auto mf = static_cast(object); - Parser> parser(mf); -#define DO_(x) if (!(x)) return false - DO_(parser.ParseMap(begin, end)); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.key().data(), static_cast(parser.key().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.LabelsEntry.key")); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.value().data(), static_cast(parser.value().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.LabelsEntry.value")); -#undef DO_ - return true; -} -#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER - - -// =================================================================== - -void SidecarJob::InitAsDefaultInstance() { - ::flyteidl::plugins::_SidecarJob_default_instance_._instance.get_mutable()->pod_spec_ = const_cast< ::k8s::io::api::core::v1::PodSpec*>( - ::k8s::io::api::core::v1::PodSpec::internal_default_instance()); -} -class SidecarJob::HasBitSetters { - public: - static const ::k8s::io::api::core::v1::PodSpec& pod_spec(const SidecarJob* msg); -}; - -const ::k8s::io::api::core::v1::PodSpec& -SidecarJob::HasBitSetters::pod_spec(const SidecarJob* msg) { - return *msg->pod_spec_; -} -void SidecarJob::clear_pod_spec() { - if (GetArenaNoVirtual() == nullptr && pod_spec_ != nullptr) { - delete pod_spec_; - } - pod_spec_ = nullptr; -} -#if !defined(_MSC_VER) || _MSC_VER >= 1900 -const int SidecarJob::kPodSpecFieldNumber; -const int SidecarJob::kPrimaryContainerNameFieldNumber; -const int SidecarJob::kAnnotationsFieldNumber; -const int SidecarJob::kLabelsFieldNumber; -#endif // !defined(_MSC_VER) || _MSC_VER >= 1900 - -SidecarJob::SidecarJob() - : ::google::protobuf::Message(), _internal_metadata_(nullptr) { - SharedCtor(); - // @@protoc_insertion_point(constructor:flyteidl.plugins.SidecarJob) -} -SidecarJob::SidecarJob(const SidecarJob& from) - : ::google::protobuf::Message(), - _internal_metadata_(nullptr) { - _internal_metadata_.MergeFrom(from._internal_metadata_); - annotations_.MergeFrom(from.annotations_); - labels_.MergeFrom(from.labels_); - primary_container_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (from.primary_container_name().size() > 0) { - primary_container_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.primary_container_name_); - } - if (from.has_pod_spec()) { - pod_spec_ = new ::k8s::io::api::core::v1::PodSpec(*from.pod_spec_); - } else { - pod_spec_ = nullptr; - } - // @@protoc_insertion_point(copy_constructor:flyteidl.plugins.SidecarJob) -} - -void SidecarJob::SharedCtor() { - ::google::protobuf::internal::InitSCC( - &scc_info_SidecarJob_flyteidl_2fplugins_2fsidecar_2eproto.base); - primary_container_name_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - pod_spec_ = nullptr; -} - -SidecarJob::~SidecarJob() { - // @@protoc_insertion_point(destructor:flyteidl.plugins.SidecarJob) - SharedDtor(); -} - -void SidecarJob::SharedDtor() { - primary_container_name_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (this != internal_default_instance()) delete pod_spec_; -} - -void SidecarJob::SetCachedSize(int size) const { - _cached_size_.Set(size); -} -const SidecarJob& SidecarJob::default_instance() { - ::google::protobuf::internal::InitSCC(&::scc_info_SidecarJob_flyteidl_2fplugins_2fsidecar_2eproto.base); - return *internal_default_instance(); -} - - -void SidecarJob::Clear() { -// @@protoc_insertion_point(message_clear_start:flyteidl.plugins.SidecarJob) - ::google::protobuf::uint32 cached_has_bits = 0; - // Prevent compiler warnings about cached_has_bits being unused - (void) cached_has_bits; - - annotations_.Clear(); - labels_.Clear(); - primary_container_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); - if (GetArenaNoVirtual() == nullptr && pod_spec_ != nullptr) { - delete pod_spec_; - } - pod_spec_ = nullptr; - _internal_metadata_.Clear(); -} - -#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -const char* SidecarJob::_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) { - // .k8s.io.api.core.v1.PodSpec pod_spec = 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 = ::k8s::io::api::core::v1::PodSpec::_InternalParse; - object = msg->mutable_pod_spec(); - 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 primary_container_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("flyteidl.plugins.SidecarJob.primary_container_name"); - object = msg->mutable_primary_container_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; - } - // map annotations = 3; - case 3: { - if (static_cast<::google::protobuf::uint8>(tag) != 26) goto handle_unusual; - do { - ptr = ::google::protobuf::io::ReadSize(ptr, &size); - GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); - parser_till_end = ::google::protobuf::internal::SlowMapEntryParser; - auto parse_map = ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse::_ParseMap; - ctx->extra_parse_data().payload.clear(); - ctx->extra_parse_data().parse_map = parse_map; - object = &msg->annotations_; - if (size > end - ptr) goto len_delim_till_end; - auto newend = ptr + size; - GOOGLE_PROTOBUF_PARSER_ASSERT(parse_map(ptr, newend, object, ctx)); - ptr = newend; - if (ptr >= end) break; - } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 26 && (ptr += 1)); - break; - } - // map labels = 4; - case 4: { - if (static_cast<::google::protobuf::uint8>(tag) != 34) goto handle_unusual; - do { - ptr = ::google::protobuf::io::ReadSize(ptr, &size); - GOOGLE_PROTOBUF_PARSER_ASSERT(ptr); - parser_till_end = ::google::protobuf::internal::SlowMapEntryParser; - auto parse_map = ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse::_ParseMap; - ctx->extra_parse_data().payload.clear(); - ctx->extra_parse_data().parse_map = parse_map; - object = &msg->labels_; - if (size > end - ptr) goto len_delim_till_end; - auto newend = ptr + size; - GOOGLE_PROTOBUF_PARSER_ASSERT(parse_map(ptr, newend, object, ctx)); - ptr = newend; - if (ptr >= end) break; - } while ((::google::protobuf::io::UnalignedLoad<::google::protobuf::uint64>(ptr) & 255) == 34 && (ptr += 1)); - 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 SidecarJob::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:flyteidl.plugins.SidecarJob) - 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)) { - // .k8s.io.api.core.v1.PodSpec pod_spec = 1; - case 1: { - if (static_cast< ::google::protobuf::uint8>(tag) == (10 & 0xFF)) { - DO_(::google::protobuf::internal::WireFormatLite::ReadMessage( - input, mutable_pod_spec())); - } else { - goto handle_unusual; - } - break; - } - - // string primary_container_name = 2; - case 2: { - if (static_cast< ::google::protobuf::uint8>(tag) == (18 & 0xFF)) { - DO_(::google::protobuf::internal::WireFormatLite::ReadString( - input, this->mutable_primary_container_name())); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->primary_container_name().data(), static_cast(this->primary_container_name().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.primary_container_name")); - } else { - goto handle_unusual; - } - break; - } - - // map annotations = 3; - case 3: { - if (static_cast< ::google::protobuf::uint8>(tag) == (26 & 0xFF)) { - SidecarJob_AnnotationsEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField< - SidecarJob_AnnotationsEntry_DoNotUse, - ::std::string, ::std::string, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - 0 >, - ::google::protobuf::Map< ::std::string, ::std::string > > parser(&annotations_); - DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( - input, &parser)); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.key().data(), static_cast(parser.key().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.key")); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.value().data(), static_cast(parser.value().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.value")); - } else { - goto handle_unusual; - } - break; - } - - // map labels = 4; - case 4: { - if (static_cast< ::google::protobuf::uint8>(tag) == (34 & 0xFF)) { - SidecarJob_LabelsEntry_DoNotUse::Parser< ::google::protobuf::internal::MapField< - SidecarJob_LabelsEntry_DoNotUse, - ::std::string, ::std::string, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - 0 >, - ::google::protobuf::Map< ::std::string, ::std::string > > parser(&labels_); - DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( - input, &parser)); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.key().data(), static_cast(parser.key().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.LabelsEntry.key")); - DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - parser.value().data(), static_cast(parser.value().length()), - ::google::protobuf::internal::WireFormatLite::PARSE, - "flyteidl.plugins.SidecarJob.LabelsEntry.value")); - } 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:flyteidl.plugins.SidecarJob) - return true; -failure: - // @@protoc_insertion_point(parse_failure:flyteidl.plugins.SidecarJob) - return false; -#undef DO_ -} -#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER - -void SidecarJob::SerializeWithCachedSizes( - ::google::protobuf::io::CodedOutputStream* output) const { - // @@protoc_insertion_point(serialize_start:flyteidl.plugins.SidecarJob) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // .k8s.io.api.core.v1.PodSpec pod_spec = 1; - if (this->has_pod_spec()) { - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray( - 1, HasBitSetters::pod_spec(this), output); - } - - // string primary_container_name = 2; - if (this->primary_container_name().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->primary_container_name().data(), static_cast(this->primary_container_name().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.primary_container_name"); - ::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased( - 2, this->primary_container_name(), output); - } - - // map annotations = 3; - if (!this->annotations().empty()) { - typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer - ConstPtr; - typedef ConstPtr SortItem; - typedef ::google::protobuf::internal::CompareByDerefFirst Less; - struct Utf8Check { - static void Check(ConstPtr p) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->first.data(), static_cast(p->first.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.key"); - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->second.data(), static_cast(p->second.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.value"); - } - }; - - if (output->IsSerializationDeterministic() && - this->annotations().size() > 1) { - ::std::unique_ptr items( - new SortItem[this->annotations().size()]); - typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type; - size_type n = 0; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->annotations().begin(); - it != this->annotations().end(); ++it, ++n) { - items[static_cast(n)] = SortItem(&*it); - } - ::std::sort(&items[0], &items[static_cast(n)], Less()); - ::std::unique_ptr entry; - for (size_type i = 0; i < n; i++) { - entry.reset(annotations_.NewEntryWrapper(items[static_cast(i)]->first, items[static_cast(i)]->second)); - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(3, *entry, output); - Utf8Check::Check(&(*items[static_cast(i)])); - } - } else { - ::std::unique_ptr entry; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->annotations().begin(); - it != this->annotations().end(); ++it) { - entry.reset(annotations_.NewEntryWrapper(it->first, it->second)); - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(3, *entry, output); - Utf8Check::Check(&(*it)); - } - } - } - - // map labels = 4; - if (!this->labels().empty()) { - typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer - ConstPtr; - typedef ConstPtr SortItem; - typedef ::google::protobuf::internal::CompareByDerefFirst Less; - struct Utf8Check { - static void Check(ConstPtr p) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->first.data(), static_cast(p->first.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.LabelsEntry.key"); - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->second.data(), static_cast(p->second.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.LabelsEntry.value"); - } - }; - - if (output->IsSerializationDeterministic() && - this->labels().size() > 1) { - ::std::unique_ptr items( - new SortItem[this->labels().size()]); - typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type; - size_type n = 0; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->labels().begin(); - it != this->labels().end(); ++it, ++n) { - items[static_cast(n)] = SortItem(&*it); - } - ::std::sort(&items[0], &items[static_cast(n)], Less()); - ::std::unique_ptr entry; - for (size_type i = 0; i < n; i++) { - entry.reset(labels_.NewEntryWrapper(items[static_cast(i)]->first, items[static_cast(i)]->second)); - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(4, *entry, output); - Utf8Check::Check(&(*items[static_cast(i)])); - } - } else { - ::std::unique_ptr entry; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->labels().begin(); - it != this->labels().end(); ++it) { - entry.reset(labels_.NewEntryWrapper(it->first, it->second)); - ::google::protobuf::internal::WireFormatLite::WriteMessageMaybeToArray(4, *entry, output); - Utf8Check::Check(&(*it)); - } - } - } - - if (_internal_metadata_.have_unknown_fields()) { - ::google::protobuf::internal::WireFormat::SerializeUnknownFields( - _internal_metadata_.unknown_fields(), output); - } - // @@protoc_insertion_point(serialize_end:flyteidl.plugins.SidecarJob) -} - -::google::protobuf::uint8* SidecarJob::InternalSerializeWithCachedSizesToArray( - ::google::protobuf::uint8* target) const { - // @@protoc_insertion_point(serialize_to_array_start:flyteidl.plugins.SidecarJob) - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - // .k8s.io.api.core.v1.PodSpec pod_spec = 1; - if (this->has_pod_spec()) { - target = ::google::protobuf::internal::WireFormatLite:: - InternalWriteMessageToArray( - 1, HasBitSetters::pod_spec(this), target); - } - - // string primary_container_name = 2; - if (this->primary_container_name().size() > 0) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - this->primary_container_name().data(), static_cast(this->primary_container_name().length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.primary_container_name"); - target = - ::google::protobuf::internal::WireFormatLite::WriteStringToArray( - 2, this->primary_container_name(), target); - } - - // map annotations = 3; - if (!this->annotations().empty()) { - typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer - ConstPtr; - typedef ConstPtr SortItem; - typedef ::google::protobuf::internal::CompareByDerefFirst Less; - struct Utf8Check { - static void Check(ConstPtr p) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->first.data(), static_cast(p->first.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.key"); - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->second.data(), static_cast(p->second.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.AnnotationsEntry.value"); - } - }; - - if (false && - this->annotations().size() > 1) { - ::std::unique_ptr items( - new SortItem[this->annotations().size()]); - typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type; - size_type n = 0; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->annotations().begin(); - it != this->annotations().end(); ++it, ++n) { - items[static_cast(n)] = SortItem(&*it); - } - ::std::sort(&items[0], &items[static_cast(n)], Less()); - ::std::unique_ptr entry; - for (size_type i = 0; i < n; i++) { - entry.reset(annotations_.NewEntryWrapper(items[static_cast(i)]->first, items[static_cast(i)]->second)); - target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessageNoVirtualToArray(3, *entry, target); - Utf8Check::Check(&(*items[static_cast(i)])); - } - } else { - ::std::unique_ptr entry; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->annotations().begin(); - it != this->annotations().end(); ++it) { - entry.reset(annotations_.NewEntryWrapper(it->first, it->second)); - target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessageNoVirtualToArray(3, *entry, target); - Utf8Check::Check(&(*it)); - } - } - } - - // map labels = 4; - if (!this->labels().empty()) { - typedef ::google::protobuf::Map< ::std::string, ::std::string >::const_pointer - ConstPtr; - typedef ConstPtr SortItem; - typedef ::google::protobuf::internal::CompareByDerefFirst Less; - struct Utf8Check { - static void Check(ConstPtr p) { - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->first.data(), static_cast(p->first.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.LabelsEntry.key"); - ::google::protobuf::internal::WireFormatLite::VerifyUtf8String( - p->second.data(), static_cast(p->second.length()), - ::google::protobuf::internal::WireFormatLite::SERIALIZE, - "flyteidl.plugins.SidecarJob.LabelsEntry.value"); - } - }; - - if (false && - this->labels().size() > 1) { - ::std::unique_ptr items( - new SortItem[this->labels().size()]); - typedef ::google::protobuf::Map< ::std::string, ::std::string >::size_type size_type; - size_type n = 0; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->labels().begin(); - it != this->labels().end(); ++it, ++n) { - items[static_cast(n)] = SortItem(&*it); - } - ::std::sort(&items[0], &items[static_cast(n)], Less()); - ::std::unique_ptr entry; - for (size_type i = 0; i < n; i++) { - entry.reset(labels_.NewEntryWrapper(items[static_cast(i)]->first, items[static_cast(i)]->second)); - target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessageNoVirtualToArray(4, *entry, target); - Utf8Check::Check(&(*items[static_cast(i)])); - } - } else { - ::std::unique_ptr entry; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->labels().begin(); - it != this->labels().end(); ++it) { - entry.reset(labels_.NewEntryWrapper(it->first, it->second)); - target = ::google::protobuf::internal::WireFormatLite::InternalWriteMessageNoVirtualToArray(4, *entry, target); - Utf8Check::Check(&(*it)); - } - } - } - - if (_internal_metadata_.have_unknown_fields()) { - target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( - _internal_metadata_.unknown_fields(), target); - } - // @@protoc_insertion_point(serialize_to_array_end:flyteidl.plugins.SidecarJob) - return target; -} - -size_t SidecarJob::ByteSizeLong() const { -// @@protoc_insertion_point(message_byte_size_start:flyteidl.plugins.SidecarJob) - 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; - - // map annotations = 3; - total_size += 1 * - ::google::protobuf::internal::FromIntSize(this->annotations_size()); - { - ::std::unique_ptr entry; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->annotations().begin(); - it != this->annotations().end(); ++it) { - entry.reset(annotations_.NewEntryWrapper(it->first, it->second)); - total_size += ::google::protobuf::internal::WireFormatLite:: - MessageSizeNoVirtual(*entry); - } - } - - // map labels = 4; - total_size += 1 * - ::google::protobuf::internal::FromIntSize(this->labels_size()); - { - ::std::unique_ptr entry; - for (::google::protobuf::Map< ::std::string, ::std::string >::const_iterator - it = this->labels().begin(); - it != this->labels().end(); ++it) { - entry.reset(labels_.NewEntryWrapper(it->first, it->second)); - total_size += ::google::protobuf::internal::WireFormatLite:: - MessageSizeNoVirtual(*entry); - } - } - - // string primary_container_name = 2; - if (this->primary_container_name().size() > 0) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::StringSize( - this->primary_container_name()); - } - - // .k8s.io.api.core.v1.PodSpec pod_spec = 1; - if (this->has_pod_spec()) { - total_size += 1 + - ::google::protobuf::internal::WireFormatLite::MessageSize( - *pod_spec_); - } - - int cached_size = ::google::protobuf::internal::ToCachedSize(total_size); - SetCachedSize(cached_size); - return total_size; -} - -void SidecarJob::MergeFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_merge_from_start:flyteidl.plugins.SidecarJob) - GOOGLE_DCHECK_NE(&from, this); - const SidecarJob* source = - ::google::protobuf::DynamicCastToGenerated( - &from); - if (source == nullptr) { - // @@protoc_insertion_point(generalized_merge_from_cast_fail:flyteidl.plugins.SidecarJob) - ::google::protobuf::internal::ReflectionOps::Merge(from, this); - } else { - // @@protoc_insertion_point(generalized_merge_from_cast_success:flyteidl.plugins.SidecarJob) - MergeFrom(*source); - } -} - -void SidecarJob::MergeFrom(const SidecarJob& from) { -// @@protoc_insertion_point(class_specific_merge_from_start:flyteidl.plugins.SidecarJob) - GOOGLE_DCHECK_NE(&from, this); - _internal_metadata_.MergeFrom(from._internal_metadata_); - ::google::protobuf::uint32 cached_has_bits = 0; - (void) cached_has_bits; - - annotations_.MergeFrom(from.annotations_); - labels_.MergeFrom(from.labels_); - if (from.primary_container_name().size() > 0) { - - primary_container_name_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.primary_container_name_); - } - if (from.has_pod_spec()) { - mutable_pod_spec()->::k8s::io::api::core::v1::PodSpec::MergeFrom(from.pod_spec()); - } -} - -void SidecarJob::CopyFrom(const ::google::protobuf::Message& from) { -// @@protoc_insertion_point(generalized_copy_from_start:flyteidl.plugins.SidecarJob) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -void SidecarJob::CopyFrom(const SidecarJob& from) { -// @@protoc_insertion_point(class_specific_copy_from_start:flyteidl.plugins.SidecarJob) - if (&from == this) return; - Clear(); - MergeFrom(from); -} - -bool SidecarJob::IsInitialized() const { - return true; -} - -void SidecarJob::Swap(SidecarJob* other) { - if (other == this) return; - InternalSwap(other); -} -void SidecarJob::InternalSwap(SidecarJob* other) { - using std::swap; - _internal_metadata_.Swap(&other->_internal_metadata_); - annotations_.Swap(&other->annotations_); - labels_.Swap(&other->labels_); - primary_container_name_.Swap(&other->primary_container_name_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(), - GetArenaNoVirtual()); - swap(pod_spec_, other->pod_spec_); -} - -::google::protobuf::Metadata SidecarJob::GetMetadata() const { - ::google::protobuf::internal::AssignDescriptors(&::assign_descriptors_table_flyteidl_2fplugins_2fsidecar_2eproto); - return ::file_level_metadata_flyteidl_2fplugins_2fsidecar_2eproto[kIndexInFileMessages]; -} - - -// @@protoc_insertion_point(namespace_scope) -} // namespace plugins -} // namespace flyteidl -namespace google { -namespace protobuf { -template<> PROTOBUF_NOINLINE ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse* Arena::CreateMaybeMessage< ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse >(Arena* arena) { - return Arena::CreateInternal< ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse >(arena); -} -template<> PROTOBUF_NOINLINE ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse* Arena::CreateMaybeMessage< ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse >(Arena* arena) { - return Arena::CreateInternal< ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse >(arena); -} -template<> PROTOBUF_NOINLINE ::flyteidl::plugins::SidecarJob* Arena::CreateMaybeMessage< ::flyteidl::plugins::SidecarJob >(Arena* arena) { - return Arena::CreateInternal< ::flyteidl::plugins::SidecarJob >(arena); -} -} // namespace protobuf -} // namespace google - -// @@protoc_insertion_point(global_scope) -#include diff --git a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.pb.h b/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.pb.h deleted file mode 100644 index 582e48e76fd..00000000000 --- a/flyteidl/gen/pb-cpp/flyteidl/plugins/sidecar.pb.h +++ /dev/null @@ -1,452 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: flyteidl/plugins/sidecar.proto - -#ifndef PROTOBUF_INCLUDED_flyteidl_2fplugins_2fsidecar_2eproto -#define PROTOBUF_INCLUDED_flyteidl_2fplugins_2fsidecar_2eproto - -#include -#include - -#include -#if PROTOBUF_VERSION < 3007000 -#error This file was generated by a newer version of protoc which is -#error incompatible with your Protocol Buffer headers. Please update -#error your headers. -#endif -#if 3007000 < PROTOBUF_MIN_PROTOC_VERSION -#error This file was generated by an older version of protoc which is -#error incompatible with your Protocol Buffer headers. Please -#error regenerate this file with a newer version of protoc. -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include // IWYU pragma: export -#include // IWYU pragma: export -#include // IWYU pragma: export -#include -#include -#include -#include "k8s.io/api/core/v1/generated.pb.h" -// @@protoc_insertion_point(includes) -#include -#define PROTOBUF_INTERNAL_EXPORT_flyteidl_2fplugins_2fsidecar_2eproto - -// Internal implementation detail -- do not use these members. -struct TableStruct_flyteidl_2fplugins_2fsidecar_2eproto { - static const ::google::protobuf::internal::ParseTableField entries[] - PROTOBUF_SECTION_VARIABLE(protodesc_cold); - static const ::google::protobuf::internal::AuxillaryParseTableField aux[] - PROTOBUF_SECTION_VARIABLE(protodesc_cold); - static const ::google::protobuf::internal::ParseTable schema[3] - PROTOBUF_SECTION_VARIABLE(protodesc_cold); - static const ::google::protobuf::internal::FieldMetadata field_metadata[]; - static const ::google::protobuf::internal::SerializationTable serialization_table[]; - static const ::google::protobuf::uint32 offsets[]; -}; -void AddDescriptors_flyteidl_2fplugins_2fsidecar_2eproto(); -namespace flyteidl { -namespace plugins { -class SidecarJob; -class SidecarJobDefaultTypeInternal; -extern SidecarJobDefaultTypeInternal _SidecarJob_default_instance_; -class SidecarJob_AnnotationsEntry_DoNotUse; -class SidecarJob_AnnotationsEntry_DoNotUseDefaultTypeInternal; -extern SidecarJob_AnnotationsEntry_DoNotUseDefaultTypeInternal _SidecarJob_AnnotationsEntry_DoNotUse_default_instance_; -class SidecarJob_LabelsEntry_DoNotUse; -class SidecarJob_LabelsEntry_DoNotUseDefaultTypeInternal; -extern SidecarJob_LabelsEntry_DoNotUseDefaultTypeInternal _SidecarJob_LabelsEntry_DoNotUse_default_instance_; -} // namespace plugins -} // namespace flyteidl -namespace google { -namespace protobuf { -template<> ::flyteidl::plugins::SidecarJob* Arena::CreateMaybeMessage<::flyteidl::plugins::SidecarJob>(Arena*); -template<> ::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse* Arena::CreateMaybeMessage<::flyteidl::plugins::SidecarJob_AnnotationsEntry_DoNotUse>(Arena*); -template<> ::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse* Arena::CreateMaybeMessage<::flyteidl::plugins::SidecarJob_LabelsEntry_DoNotUse>(Arena*); -} // namespace protobuf -} // namespace google -namespace flyteidl { -namespace plugins { - -// =================================================================== - -class SidecarJob_AnnotationsEntry_DoNotUse : public ::google::protobuf::internal::MapEntry { -public: -#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -static bool _ParseMap(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx); -#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER - typedef ::google::protobuf::internal::MapEntry SuperType; - SidecarJob_AnnotationsEntry_DoNotUse(); - SidecarJob_AnnotationsEntry_DoNotUse(::google::protobuf::Arena* arena); - void MergeFrom(const SidecarJob_AnnotationsEntry_DoNotUse& other); - static const SidecarJob_AnnotationsEntry_DoNotUse* internal_default_instance() { return reinterpret_cast(&_SidecarJob_AnnotationsEntry_DoNotUse_default_instance_); } - void MergeFrom(const ::google::protobuf::Message& other) final; - ::google::protobuf::Metadata GetMetadata() const; -}; - -// ------------------------------------------------------------------- - -class SidecarJob_LabelsEntry_DoNotUse : public ::google::protobuf::internal::MapEntry { -public: -#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER -static bool _ParseMap(const char* begin, const char* end, void* object, ::google::protobuf::internal::ParseContext* ctx); -#endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER - typedef ::google::protobuf::internal::MapEntry SuperType; - SidecarJob_LabelsEntry_DoNotUse(); - SidecarJob_LabelsEntry_DoNotUse(::google::protobuf::Arena* arena); - void MergeFrom(const SidecarJob_LabelsEntry_DoNotUse& other); - static const SidecarJob_LabelsEntry_DoNotUse* internal_default_instance() { return reinterpret_cast(&_SidecarJob_LabelsEntry_DoNotUse_default_instance_); } - void MergeFrom(const ::google::protobuf::Message& other) final; - ::google::protobuf::Metadata GetMetadata() const; -}; - -// ------------------------------------------------------------------- - -class SidecarJob final : - public ::google::protobuf::Message /* @@protoc_insertion_point(class_definition:flyteidl.plugins.SidecarJob) */ { - public: - SidecarJob(); - virtual ~SidecarJob(); - - SidecarJob(const SidecarJob& from); - - inline SidecarJob& operator=(const SidecarJob& from) { - CopyFrom(from); - return *this; - } - #if LANG_CXX11 - SidecarJob(SidecarJob&& from) noexcept - : SidecarJob() { - *this = ::std::move(from); - } - - inline SidecarJob& operator=(SidecarJob&& 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 SidecarJob& default_instance(); - - static void InitAsDefaultInstance(); // FOR INTERNAL USE ONLY - static inline const SidecarJob* internal_default_instance() { - return reinterpret_cast( - &_SidecarJob_default_instance_); - } - static constexpr int kIndexInFileMessages = - 2; - - void Swap(SidecarJob* other); - friend void swap(SidecarJob& a, SidecarJob& b) { - a.Swap(&b); - } - - // implements Message ---------------------------------------------- - - inline SidecarJob* New() const final { - return CreateMaybeMessage(nullptr); - } - - SidecarJob* 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 SidecarJob& from); - void MergeFrom(const SidecarJob& 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(SidecarJob* 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 ------------------------------------------------------- - - // map annotations = 3; - int annotations_size() const; - void clear_annotations(); - static const int kAnnotationsFieldNumber = 3; - const ::google::protobuf::Map< ::std::string, ::std::string >& - annotations() const; - ::google::protobuf::Map< ::std::string, ::std::string >* - mutable_annotations(); - - // map labels = 4; - int labels_size() const; - void clear_labels(); - static const int kLabelsFieldNumber = 4; - const ::google::protobuf::Map< ::std::string, ::std::string >& - labels() const; - ::google::protobuf::Map< ::std::string, ::std::string >* - mutable_labels(); - - // string primary_container_name = 2; - void clear_primary_container_name(); - static const int kPrimaryContainerNameFieldNumber = 2; - const ::std::string& primary_container_name() const; - void set_primary_container_name(const ::std::string& value); - #if LANG_CXX11 - void set_primary_container_name(::std::string&& value); - #endif - void set_primary_container_name(const char* value); - void set_primary_container_name(const char* value, size_t size); - ::std::string* mutable_primary_container_name(); - ::std::string* release_primary_container_name(); - void set_allocated_primary_container_name(::std::string* primary_container_name); - - // .k8s.io.api.core.v1.PodSpec pod_spec = 1; - bool has_pod_spec() const; - void clear_pod_spec(); - static const int kPodSpecFieldNumber = 1; - const ::k8s::io::api::core::v1::PodSpec& pod_spec() const; - ::k8s::io::api::core::v1::PodSpec* release_pod_spec(); - ::k8s::io::api::core::v1::PodSpec* mutable_pod_spec(); - void set_allocated_pod_spec(::k8s::io::api::core::v1::PodSpec* pod_spec); - - // @@protoc_insertion_point(class_scope:flyteidl.plugins.SidecarJob) - private: - class HasBitSetters; - - ::google::protobuf::internal::InternalMetadataWithArena _internal_metadata_; - ::google::protobuf::internal::MapField< - SidecarJob_AnnotationsEntry_DoNotUse, - ::std::string, ::std::string, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - 0 > annotations_; - ::google::protobuf::internal::MapField< - SidecarJob_LabelsEntry_DoNotUse, - ::std::string, ::std::string, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - ::google::protobuf::internal::WireFormatLite::TYPE_STRING, - 0 > labels_; - ::google::protobuf::internal::ArenaStringPtr primary_container_name_; - ::k8s::io::api::core::v1::PodSpec* pod_spec_; - mutable ::google::protobuf::internal::CachedSize _cached_size_; - friend struct ::TableStruct_flyteidl_2fplugins_2fsidecar_2eproto; -}; -// =================================================================== - - -// =================================================================== - -#ifdef __GNUC__ - #pragma GCC diagnostic push - #pragma GCC diagnostic ignored "-Wstrict-aliasing" -#endif // __GNUC__ -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - -// SidecarJob - -// .k8s.io.api.core.v1.PodSpec pod_spec = 1; -inline bool SidecarJob::has_pod_spec() const { - return this != internal_default_instance() && pod_spec_ != nullptr; -} -inline const ::k8s::io::api::core::v1::PodSpec& SidecarJob::pod_spec() const { - const ::k8s::io::api::core::v1::PodSpec* p = pod_spec_; - // @@protoc_insertion_point(field_get:flyteidl.plugins.SidecarJob.pod_spec) - return p != nullptr ? *p : *reinterpret_cast( - &::k8s::io::api::core::v1::_PodSpec_default_instance_); -} -inline ::k8s::io::api::core::v1::PodSpec* SidecarJob::release_pod_spec() { - // @@protoc_insertion_point(field_release:flyteidl.plugins.SidecarJob.pod_spec) - - ::k8s::io::api::core::v1::PodSpec* temp = pod_spec_; - pod_spec_ = nullptr; - return temp; -} -inline ::k8s::io::api::core::v1::PodSpec* SidecarJob::mutable_pod_spec() { - - if (pod_spec_ == nullptr) { - auto* p = CreateMaybeMessage<::k8s::io::api::core::v1::PodSpec>(GetArenaNoVirtual()); - pod_spec_ = p; - } - // @@protoc_insertion_point(field_mutable:flyteidl.plugins.SidecarJob.pod_spec) - return pod_spec_; -} -inline void SidecarJob::set_allocated_pod_spec(::k8s::io::api::core::v1::PodSpec* pod_spec) { - ::google::protobuf::Arena* message_arena = GetArenaNoVirtual(); - if (message_arena == nullptr) { - delete reinterpret_cast< ::google::protobuf::MessageLite*>(pod_spec_); - } - if (pod_spec) { - ::google::protobuf::Arena* submessage_arena = nullptr; - if (message_arena != submessage_arena) { - pod_spec = ::google::protobuf::internal::GetOwnedMessage( - message_arena, pod_spec, submessage_arena); - } - - } else { - - } - pod_spec_ = pod_spec; - // @@protoc_insertion_point(field_set_allocated:flyteidl.plugins.SidecarJob.pod_spec) -} - -// string primary_container_name = 2; -inline void SidecarJob::clear_primary_container_name() { - primary_container_name_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline const ::std::string& SidecarJob::primary_container_name() const { - // @@protoc_insertion_point(field_get:flyteidl.plugins.SidecarJob.primary_container_name) - return primary_container_name_.GetNoArena(); -} -inline void SidecarJob::set_primary_container_name(const ::std::string& value) { - - primary_container_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value); - // @@protoc_insertion_point(field_set:flyteidl.plugins.SidecarJob.primary_container_name) -} -#if LANG_CXX11 -inline void SidecarJob::set_primary_container_name(::std::string&& value) { - - primary_container_name_.SetNoArena( - &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value)); - // @@protoc_insertion_point(field_set_rvalue:flyteidl.plugins.SidecarJob.primary_container_name) -} -#endif -inline void SidecarJob::set_primary_container_name(const char* value) { - GOOGLE_DCHECK(value != nullptr); - - primary_container_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value)); - // @@protoc_insertion_point(field_set_char:flyteidl.plugins.SidecarJob.primary_container_name) -} -inline void SidecarJob::set_primary_container_name(const char* value, size_t size) { - - primary_container_name_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), - ::std::string(reinterpret_cast(value), size)); - // @@protoc_insertion_point(field_set_pointer:flyteidl.plugins.SidecarJob.primary_container_name) -} -inline ::std::string* SidecarJob::mutable_primary_container_name() { - - // @@protoc_insertion_point(field_mutable:flyteidl.plugins.SidecarJob.primary_container_name) - return primary_container_name_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline ::std::string* SidecarJob::release_primary_container_name() { - // @@protoc_insertion_point(field_release:flyteidl.plugins.SidecarJob.primary_container_name) - - return primary_container_name_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); -} -inline void SidecarJob::set_allocated_primary_container_name(::std::string* primary_container_name) { - if (primary_container_name != nullptr) { - - } else { - - } - primary_container_name_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), primary_container_name); - // @@protoc_insertion_point(field_set_allocated:flyteidl.plugins.SidecarJob.primary_container_name) -} - -// map annotations = 3; -inline int SidecarJob::annotations_size() const { - return annotations_.size(); -} -inline void SidecarJob::clear_annotations() { - annotations_.Clear(); -} -inline const ::google::protobuf::Map< ::std::string, ::std::string >& -SidecarJob::annotations() const { - // @@protoc_insertion_point(field_map:flyteidl.plugins.SidecarJob.annotations) - return annotations_.GetMap(); -} -inline ::google::protobuf::Map< ::std::string, ::std::string >* -SidecarJob::mutable_annotations() { - // @@protoc_insertion_point(field_mutable_map:flyteidl.plugins.SidecarJob.annotations) - return annotations_.MutableMap(); -} - -// map labels = 4; -inline int SidecarJob::labels_size() const { - return labels_.size(); -} -inline void SidecarJob::clear_labels() { - labels_.Clear(); -} -inline const ::google::protobuf::Map< ::std::string, ::std::string >& -SidecarJob::labels() const { - // @@protoc_insertion_point(field_map:flyteidl.plugins.SidecarJob.labels) - return labels_.GetMap(); -} -inline ::google::protobuf::Map< ::std::string, ::std::string >* -SidecarJob::mutable_labels() { - // @@protoc_insertion_point(field_mutable_map:flyteidl.plugins.SidecarJob.labels) - return labels_.MutableMap(); -} - -#ifdef __GNUC__ - #pragma GCC diagnostic pop -#endif // __GNUC__ -// ------------------------------------------------------------------- - -// ------------------------------------------------------------------- - - -// @@protoc_insertion_point(namespace_scope) - -} // namespace plugins -} // namespace flyteidl - -// @@protoc_insertion_point(global_scope) - -#include -#endif // PROTOBUF_INCLUDED_flyteidl_2fplugins_2fsidecar_2eproto diff --git a/flyteidl/gen/pb-go/flyteidl/plugins/sidecar.pb.go b/flyteidl/gen/pb-go/flyteidl/plugins/sidecar.pb.go deleted file mode 100644 index e0181dfef2a..00000000000 --- a/flyteidl/gen/pb-go/flyteidl/plugins/sidecar.pb.go +++ /dev/null @@ -1,123 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// source: flyteidl/plugins/sidecar.proto - -package plugins - -import ( - fmt "fmt" - proto "github.com/golang/protobuf/proto" - v1 "k8s.io/api/core/v1" - math "math" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package - -// A sidecar job brings up the desired pod_spec. -// The plugin executor is responsible for keeping the pod alive until the primary container terminates -// or the task itself times out. -type SidecarJob struct { - PodSpec *v1.PodSpec `protobuf:"bytes,1,opt,name=pod_spec,json=podSpec,proto3" json:"pod_spec,omitempty"` - PrimaryContainerName string `protobuf:"bytes,2,opt,name=primary_container_name,json=primaryContainerName,proto3" json:"primary_container_name,omitempty"` - // Pod annotations - Annotations map[string]string `protobuf:"bytes,3,rep,name=annotations,proto3" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` - // Pod labels - Labels map[string]string `protobuf:"bytes,4,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` -} - -func (m *SidecarJob) Reset() { *m = SidecarJob{} } -func (m *SidecarJob) String() string { return proto.CompactTextString(m) } -func (*SidecarJob) ProtoMessage() {} -func (*SidecarJob) Descriptor() ([]byte, []int) { - return fileDescriptor_b34ccf0cecf5c059, []int{0} -} - -func (m *SidecarJob) XXX_Unmarshal(b []byte) error { - return xxx_messageInfo_SidecarJob.Unmarshal(m, b) -} -func (m *SidecarJob) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - return xxx_messageInfo_SidecarJob.Marshal(b, m, deterministic) -} -func (m *SidecarJob) XXX_Merge(src proto.Message) { - xxx_messageInfo_SidecarJob.Merge(m, src) -} -func (m *SidecarJob) XXX_Size() int { - return xxx_messageInfo_SidecarJob.Size(m) -} -func (m *SidecarJob) XXX_DiscardUnknown() { - xxx_messageInfo_SidecarJob.DiscardUnknown(m) -} - -var xxx_messageInfo_SidecarJob proto.InternalMessageInfo - -func (m *SidecarJob) GetPodSpec() *v1.PodSpec { - if m != nil { - return m.PodSpec - } - return nil -} - -func (m *SidecarJob) GetPrimaryContainerName() string { - if m != nil { - return m.PrimaryContainerName - } - return "" -} - -func (m *SidecarJob) GetAnnotations() map[string]string { - if m != nil { - return m.Annotations - } - return nil -} - -func (m *SidecarJob) GetLabels() map[string]string { - if m != nil { - return m.Labels - } - return nil -} - -func init() { - proto.RegisterType((*SidecarJob)(nil), "flyteidl.plugins.SidecarJob") - proto.RegisterMapType((map[string]string)(nil), "flyteidl.plugins.SidecarJob.AnnotationsEntry") - proto.RegisterMapType((map[string]string)(nil), "flyteidl.plugins.SidecarJob.LabelsEntry") -} - -func init() { proto.RegisterFile("flyteidl/plugins/sidecar.proto", fileDescriptor_b34ccf0cecf5c059) } - -var fileDescriptor_b34ccf0cecf5c059 = []byte{ - // 330 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x92, 0x4f, 0x4b, 0xf3, 0x40, - 0x10, 0xc6, 0x49, 0xf3, 0xbe, 0xd5, 0x6e, 0x2e, 0x65, 0x29, 0x12, 0x2a, 0x48, 0xe9, 0x29, 0x97, - 0xee, 0xd2, 0x2a, 0xda, 0x7a, 0x10, 0xff, 0xe0, 0x45, 0x44, 0x25, 0xbd, 0x79, 0x29, 0x9b, 0x64, - 0x8c, 0x4b, 0x93, 0x9d, 0x65, 0xb3, 0x2d, 0xe4, 0x1b, 0xf8, 0xb1, 0xa5, 0x49, 0x6b, 0x4b, 0x0e, - 0x82, 0xb7, 0x59, 0x9e, 0x79, 0x7e, 0x3b, 0xb3, 0xcf, 0x92, 0xb3, 0x8f, 0xac, 0xb4, 0x20, 0x93, - 0x8c, 0xeb, 0x6c, 0x95, 0x4a, 0x55, 0xf0, 0x42, 0x26, 0x10, 0x0b, 0xc3, 0xb4, 0x41, 0x8b, 0xb4, - 0xbb, 0xd3, 0xd9, 0x56, 0xef, 0x0f, 0x97, 0xd3, 0x82, 0x49, 0xe4, 0x42, 0x4b, 0x1e, 0xa3, 0x01, - 0xbe, 0x1e, 0xf3, 0x14, 0x14, 0x18, 0x61, 0x21, 0xa9, 0x5d, 0xc3, 0x2f, 0x97, 0x90, 0x79, 0xcd, - 0x79, 0xc2, 0x88, 0x5e, 0x92, 0x63, 0x8d, 0xc9, 0xa2, 0xd0, 0x10, 0xfb, 0xce, 0xc0, 0x09, 0xbc, - 0xc9, 0x29, 0xab, 0x29, 0x4c, 0x68, 0xc9, 0x36, 0x14, 0xb6, 0x1e, 0xb3, 0x37, 0x4c, 0xe6, 0x1a, - 0xe2, 0xf0, 0x48, 0xd7, 0x05, 0xbd, 0x20, 0x27, 0xda, 0xc8, 0x5c, 0x98, 0x72, 0x11, 0xa3, 0xb2, - 0x42, 0x2a, 0x30, 0x0b, 0x25, 0x72, 0xf0, 0x5b, 0x03, 0x27, 0xe8, 0x84, 0xbd, 0xad, 0xfa, 0xb0, - 0x13, 0x5f, 0x44, 0x0e, 0xf4, 0x95, 0x78, 0x42, 0x29, 0xb4, 0xc2, 0x4a, 0x54, 0x85, 0xef, 0x0e, - 0xdc, 0xc0, 0x9b, 0x8c, 0x58, 0x73, 0x11, 0xb6, 0x1f, 0x90, 0xdd, 0xed, 0xfb, 0x1f, 0x95, 0x35, - 0x65, 0x78, 0x48, 0xa0, 0xb7, 0xa4, 0x9d, 0x89, 0x08, 0xb2, 0xc2, 0xff, 0x57, 0xb1, 0x82, 0x5f, - 0x59, 0xcf, 0x55, 0x6b, 0x8d, 0xd9, 0xfa, 0xfa, 0x37, 0xa4, 0xdb, 0xbc, 0x82, 0x76, 0x89, 0xbb, - 0x84, 0xb2, 0x7a, 0x8f, 0x4e, 0xb8, 0x29, 0x69, 0x8f, 0xfc, 0x5f, 0x8b, 0x6c, 0xb5, 0xdb, 0xae, - 0x3e, 0x5c, 0xb7, 0xa6, 0x4e, 0x7f, 0x46, 0xbc, 0x03, 0xec, 0x5f, 0xac, 0xf7, 0xb3, 0xf7, 0xab, - 0x54, 0xda, 0xcf, 0x55, 0xc4, 0x62, 0xcc, 0x79, 0x35, 0x38, 0x9a, 0x94, 0xff, 0xc4, 0x9e, 0x82, - 0xe2, 0x3a, 0x1a, 0xa5, 0xc8, 0x9b, 0x3f, 0x21, 0x6a, 0x57, 0x61, 0x9e, 0x7f, 0x07, 0x00, 0x00, - 0xff, 0xff, 0xcc, 0x9c, 0x7d, 0x1f, 0x24, 0x02, 0x00, 0x00, -} diff --git a/flyteidl/gen/pb-go/flyteidl/plugins/sidecar.pb.validate.go b/flyteidl/gen/pb-go/flyteidl/plugins/sidecar.pb.validate.go deleted file mode 100644 index d41f896e594..00000000000 --- a/flyteidl/gen/pb-go/flyteidl/plugins/sidecar.pb.validate.go +++ /dev/null @@ -1,117 +0,0 @@ -// Code generated by protoc-gen-validate. DO NOT EDIT. -// source: flyteidl/plugins/sidecar.proto - -package plugins - -import ( - "bytes" - "errors" - "fmt" - "net" - "net/mail" - "net/url" - "regexp" - "strings" - "time" - "unicode/utf8" - - "github.com/golang/protobuf/ptypes" -) - -// ensure the imports are used -var ( - _ = bytes.MinRead - _ = errors.New("") - _ = fmt.Print - _ = utf8.UTFMax - _ = (*regexp.Regexp)(nil) - _ = (*strings.Reader)(nil) - _ = net.IPv4len - _ = time.Duration(0) - _ = (*url.URL)(nil) - _ = (*mail.Address)(nil) - _ = ptypes.DynamicAny{} -) - -// define the regex for a UUID once up-front -var _sidecar_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$") - -// Validate checks the field values on SidecarJob with the rules defined in the -// proto definition for this message. If any rules are violated, an error is returned. -func (m *SidecarJob) Validate() error { - if m == nil { - return nil - } - - if v, ok := interface{}(m.GetPodSpec()).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return SidecarJobValidationError{ - field: "PodSpec", - reason: "embedded message failed validation", - cause: err, - } - } - } - - // no validation rules for PrimaryContainerName - - // no validation rules for Annotations - - // no validation rules for Labels - - return nil -} - -// SidecarJobValidationError is the validation error returned by -// SidecarJob.Validate if the designated constraints aren't met. -type SidecarJobValidationError struct { - field string - reason string - cause error - key bool -} - -// Field function returns field value. -func (e SidecarJobValidationError) Field() string { return e.field } - -// Reason function returns reason value. -func (e SidecarJobValidationError) Reason() string { return e.reason } - -// Cause function returns cause value. -func (e SidecarJobValidationError) Cause() error { return e.cause } - -// Key function returns key value. -func (e SidecarJobValidationError) Key() bool { return e.key } - -// ErrorName returns error name. -func (e SidecarJobValidationError) ErrorName() string { return "SidecarJobValidationError" } - -// Error satisfies the builtin error interface -func (e SidecarJobValidationError) 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 %sSidecarJob.%s: %s%s", - key, - e.field, - e.reason, - cause) -} - -var _ error = SidecarJobValidationError{} - -var _ interface { - Field() string - Reason() string - Key() bool - Cause() error - ErrorName() string -} = SidecarJobValidationError{} diff --git a/flyteidl/gen/pb-java/flyteidl/plugins/Sidecar.java b/flyteidl/gen/pb-java/flyteidl/plugins/Sidecar.java deleted file mode 100644 index 74bec59bef4..00000000000 --- a/flyteidl/gen/pb-java/flyteidl/plugins/Sidecar.java +++ /dev/null @@ -1,1563 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: flyteidl/plugins/sidecar.proto - -package flyteidl.plugins; - -public final class Sidecar { - private Sidecar() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); - } - public interface SidecarJobOrBuilder extends - // @@protoc_insertion_point(interface_extends:flyteidl.plugins.SidecarJob) - com.google.protobuf.MessageOrBuilder { - - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - boolean hasPodSpec(); - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - k8s.io.api.core.v1.Generated.PodSpec getPodSpec(); - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - k8s.io.api.core.v1.Generated.PodSpecOrBuilder getPodSpecOrBuilder(); - - /** - * string primary_container_name = 2; - */ - java.lang.String getPrimaryContainerName(); - /** - * string primary_container_name = 2; - */ - com.google.protobuf.ByteString - getPrimaryContainerNameBytes(); - - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - int getAnnotationsCount(); - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - boolean containsAnnotations( - java.lang.String key); - /** - * Use {@link #getAnnotationsMap()} instead. - */ - @java.lang.Deprecated - java.util.Map - getAnnotations(); - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - java.util.Map - getAnnotationsMap(); - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - - java.lang.String getAnnotationsOrDefault( - java.lang.String key, - java.lang.String defaultValue); - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - - java.lang.String getAnnotationsOrThrow( - java.lang.String key); - - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - int getLabelsCount(); - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - boolean containsLabels( - java.lang.String key); - /** - * Use {@link #getLabelsMap()} instead. - */ - @java.lang.Deprecated - java.util.Map - getLabels(); - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - java.util.Map - getLabelsMap(); - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - - java.lang.String getLabelsOrDefault( - java.lang.String key, - java.lang.String defaultValue); - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - - java.lang.String getLabelsOrThrow( - java.lang.String key); - } - /** - *
-   * A sidecar job brings up the desired pod_spec.
-   * The plugin executor is responsible for keeping the pod alive until the primary container terminates
-   * or the task itself times out.
-   * 
- * - * Protobuf type {@code flyteidl.plugins.SidecarJob} - */ - public static final class SidecarJob extends - com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:flyteidl.plugins.SidecarJob) - SidecarJobOrBuilder { - private static final long serialVersionUID = 0L; - // Use SidecarJob.newBuilder() to construct. - private SidecarJob(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - private SidecarJob() { - primaryContainerName_ = ""; - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private SidecarJob( - 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: { - k8s.io.api.core.v1.Generated.PodSpec.Builder subBuilder = null; - if (podSpec_ != null) { - subBuilder = podSpec_.toBuilder(); - } - podSpec_ = input.readMessage(k8s.io.api.core.v1.Generated.PodSpec.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(podSpec_); - podSpec_ = subBuilder.buildPartial(); - } - - break; - } - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - - primaryContainerName_ = s; - break; - } - case 26: { - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - annotations_ = com.google.protobuf.MapField.newMapField( - AnnotationsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000004; - } - com.google.protobuf.MapEntry - annotations__ = input.readMessage( - AnnotationsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - annotations_.getMutableMap().put( - annotations__.getKey(), annotations__.getValue()); - break; - } - case 34: { - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - labels_ = com.google.protobuf.MapField.newMapField( - LabelsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000008; - } - com.google.protobuf.MapEntry - labels__ = input.readMessage( - LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - labels_.getMutableMap().put( - labels__.getKey(), labels__.getValue()); - 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 flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField( - int number) { - switch (number) { - case 3: - return internalGetAnnotations(); - case 4: - return internalGetLabels(); - default: - throw new RuntimeException( - "Invalid map field number: " + number); - } - } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_fieldAccessorTable - .ensureFieldAccessorsInitialized( - flyteidl.plugins.Sidecar.SidecarJob.class, flyteidl.plugins.Sidecar.SidecarJob.Builder.class); - } - - private int bitField0_; - public static final int POD_SPEC_FIELD_NUMBER = 1; - private k8s.io.api.core.v1.Generated.PodSpec podSpec_; - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public boolean hasPodSpec() { - return podSpec_ != null; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public k8s.io.api.core.v1.Generated.PodSpec getPodSpec() { - return podSpec_ == null ? k8s.io.api.core.v1.Generated.PodSpec.getDefaultInstance() : podSpec_; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public k8s.io.api.core.v1.Generated.PodSpecOrBuilder getPodSpecOrBuilder() { - return getPodSpec(); - } - - public static final int PRIMARY_CONTAINER_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object primaryContainerName_; - /** - * string primary_container_name = 2; - */ - public java.lang.String getPrimaryContainerName() { - java.lang.Object ref = primaryContainerName_; - 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(); - primaryContainerName_ = s; - return s; - } - } - /** - * string primary_container_name = 2; - */ - public com.google.protobuf.ByteString - getPrimaryContainerNameBytes() { - java.lang.Object ref = primaryContainerName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - primaryContainerName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ANNOTATIONS_FIELD_NUMBER = 3; - private static final class AnnotationsDefaultEntryHolder { - static final com.google.protobuf.MapEntry< - java.lang.String, java.lang.String> defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_AnnotationsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> annotations_; - private com.google.protobuf.MapField - internalGetAnnotations() { - if (annotations_ == null) { - return com.google.protobuf.MapField.emptyMapField( - AnnotationsDefaultEntryHolder.defaultEntry); - } - return annotations_; - } - - public int getAnnotationsCount() { - return internalGetAnnotations().getMap().size(); - } - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - - public boolean containsAnnotations( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - return internalGetAnnotations().getMap().containsKey(key); - } - /** - * Use {@link #getAnnotationsMap()} instead. - */ - @java.lang.Deprecated - public java.util.Map getAnnotations() { - return getAnnotationsMap(); - } - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - - public java.util.Map getAnnotationsMap() { - return internalGetAnnotations().getMap(); - } - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - - public java.lang.String getAnnotationsOrDefault( - java.lang.String key, - java.lang.String defaultValue) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetAnnotations().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - *
-     * Pod annotations
-     * 
- * - * map<string, string> annotations = 3; - */ - - public java.lang.String getAnnotationsOrThrow( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetAnnotations().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int LABELS_FIELD_NUMBER = 4; - private static final class LabelsDefaultEntryHolder { - static final com.google.protobuf.MapEntry< - java.lang.String, java.lang.String> defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_LabelsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> labels_; - private com.google.protobuf.MapField - internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField( - LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - - public boolean containsLabels( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - return internalGetLabels().getMap().containsKey(key); - } - /** - * Use {@link #getLabelsMap()} instead. - */ - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - - public java.lang.String getLabelsOrDefault( - java.lang.String key, - java.lang.String defaultValue) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - *
-     * Pod labels
-     * 
- * - * map<string, string> labels = 4; - */ - - public java.lang.String getLabelsOrThrow( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - 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 (podSpec_ != null) { - output.writeMessage(1, getPodSpec()); - } - if (!getPrimaryContainerNameBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, primaryContainerName_); - } - com.google.protobuf.GeneratedMessageV3 - .serializeStringMapTo( - output, - internalGetAnnotations(), - AnnotationsDefaultEntryHolder.defaultEntry, - 3); - com.google.protobuf.GeneratedMessageV3 - .serializeStringMapTo( - output, - internalGetLabels(), - LabelsDefaultEntryHolder.defaultEntry, - 4); - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (podSpec_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getPodSpec()); - } - if (!getPrimaryContainerNameBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, primaryContainerName_); - } - for (java.util.Map.Entry entry - : internalGetAnnotations().getMap().entrySet()) { - com.google.protobuf.MapEntry - annotations__ = AnnotationsDefaultEntryHolder.defaultEntry.newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, annotations__); - } - for (java.util.Map.Entry entry - : internalGetLabels().getMap().entrySet()) { - com.google.protobuf.MapEntry - labels__ = LabelsDefaultEntryHolder.defaultEntry.newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, labels__); - } - 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 flyteidl.plugins.Sidecar.SidecarJob)) { - return super.equals(obj); - } - flyteidl.plugins.Sidecar.SidecarJob other = (flyteidl.plugins.Sidecar.SidecarJob) obj; - - if (hasPodSpec() != other.hasPodSpec()) return false; - if (hasPodSpec()) { - if (!getPodSpec() - .equals(other.getPodSpec())) return false; - } - if (!getPrimaryContainerName() - .equals(other.getPrimaryContainerName())) return false; - if (!internalGetAnnotations().equals( - other.internalGetAnnotations())) return false; - if (!internalGetLabels().equals( - other.internalGetLabels())) 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 (hasPodSpec()) { - hash = (37 * hash) + POD_SPEC_FIELD_NUMBER; - hash = (53 * hash) + getPodSpec().hashCode(); - } - hash = (37 * hash) + PRIMARY_CONTAINER_NAME_FIELD_NUMBER; - hash = (53 * hash) + getPrimaryContainerName().hashCode(); - if (!internalGetAnnotations().getMap().isEmpty()) { - hash = (37 * hash) + ANNOTATIONS_FIELD_NUMBER; - hash = (53 * hash) + internalGetAnnotations().hashCode(); - } - if (!internalGetLabels().getMap().isEmpty()) { - hash = (37 * hash) + LABELS_FIELD_NUMBER; - hash = (53 * hash) + internalGetLabels().hashCode(); - } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static flyteidl.plugins.Sidecar.SidecarJob parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static flyteidl.plugins.Sidecar.SidecarJob 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 flyteidl.plugins.Sidecar.SidecarJob parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); - } - public static flyteidl.plugins.Sidecar.SidecarJob 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 flyteidl.plugins.Sidecar.SidecarJob parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); - } - public static flyteidl.plugins.Sidecar.SidecarJob 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(flyteidl.plugins.Sidecar.SidecarJob 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; - } - /** - *
-     * A sidecar job brings up the desired pod_spec.
-     * The plugin executor is responsible for keeping the pod alive until the primary container terminates
-     * or the task itself times out.
-     * 
- * - * Protobuf type {@code flyteidl.plugins.SidecarJob} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:flyteidl.plugins.SidecarJob) - flyteidl.plugins.Sidecar.SidecarJobOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField( - int number) { - switch (number) { - case 3: - return internalGetAnnotations(); - case 4: - return internalGetLabels(); - default: - throw new RuntimeException( - "Invalid map field number: " + number); - } - } - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField( - int number) { - switch (number) { - case 3: - return internalGetMutableAnnotations(); - case 4: - return internalGetMutableLabels(); - default: - throw new RuntimeException( - "Invalid map field number: " + number); - } - } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_fieldAccessorTable - .ensureFieldAccessorsInitialized( - flyteidl.plugins.Sidecar.SidecarJob.class, flyteidl.plugins.Sidecar.SidecarJob.Builder.class); - } - - // Construct using flyteidl.plugins.Sidecar.SidecarJob.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 (podSpecBuilder_ == null) { - podSpec_ = null; - } else { - podSpec_ = null; - podSpecBuilder_ = null; - } - primaryContainerName_ = ""; - - internalGetMutableAnnotations().clear(); - internalGetMutableLabels().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return flyteidl.plugins.Sidecar.internal_static_flyteidl_plugins_SidecarJob_descriptor; - } - - @java.lang.Override - public flyteidl.plugins.Sidecar.SidecarJob getDefaultInstanceForType() { - return flyteidl.plugins.Sidecar.SidecarJob.getDefaultInstance(); - } - - @java.lang.Override - public flyteidl.plugins.Sidecar.SidecarJob build() { - flyteidl.plugins.Sidecar.SidecarJob result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public flyteidl.plugins.Sidecar.SidecarJob buildPartial() { - flyteidl.plugins.Sidecar.SidecarJob result = new flyteidl.plugins.Sidecar.SidecarJob(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (podSpecBuilder_ == null) { - result.podSpec_ = podSpec_; - } else { - result.podSpec_ = podSpecBuilder_.build(); - } - result.primaryContainerName_ = primaryContainerName_; - result.annotations_ = internalGetAnnotations(); - result.annotations_.makeImmutable(); - result.labels_ = internalGetLabels(); - result.labels_.makeImmutable(); - result.bitField0_ = to_bitField0_; - 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 flyteidl.plugins.Sidecar.SidecarJob) { - return mergeFrom((flyteidl.plugins.Sidecar.SidecarJob)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(flyteidl.plugins.Sidecar.SidecarJob other) { - if (other == flyteidl.plugins.Sidecar.SidecarJob.getDefaultInstance()) return this; - if (other.hasPodSpec()) { - mergePodSpec(other.getPodSpec()); - } - if (!other.getPrimaryContainerName().isEmpty()) { - primaryContainerName_ = other.primaryContainerName_; - onChanged(); - } - internalGetMutableAnnotations().mergeFrom( - other.internalGetAnnotations()); - internalGetMutableLabels().mergeFrom( - other.internalGetLabels()); - 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 { - flyteidl.plugins.Sidecar.SidecarJob parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (flyteidl.plugins.Sidecar.SidecarJob) e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - private k8s.io.api.core.v1.Generated.PodSpec podSpec_; - private com.google.protobuf.SingleFieldBuilderV3< - k8s.io.api.core.v1.Generated.PodSpec, k8s.io.api.core.v1.Generated.PodSpec.Builder, k8s.io.api.core.v1.Generated.PodSpecOrBuilder> podSpecBuilder_; - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public boolean hasPodSpec() { - return podSpecBuilder_ != null || podSpec_ != null; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public k8s.io.api.core.v1.Generated.PodSpec getPodSpec() { - if (podSpecBuilder_ == null) { - return podSpec_ == null ? k8s.io.api.core.v1.Generated.PodSpec.getDefaultInstance() : podSpec_; - } else { - return podSpecBuilder_.getMessage(); - } - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public Builder setPodSpec(k8s.io.api.core.v1.Generated.PodSpec value) { - if (podSpecBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - podSpec_ = value; - onChanged(); - } else { - podSpecBuilder_.setMessage(value); - } - - return this; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public Builder setPodSpec( - k8s.io.api.core.v1.Generated.PodSpec.Builder builderForValue) { - if (podSpecBuilder_ == null) { - podSpec_ = builderForValue.build(); - onChanged(); - } else { - podSpecBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public Builder mergePodSpec(k8s.io.api.core.v1.Generated.PodSpec value) { - if (podSpecBuilder_ == null) { - if (podSpec_ != null) { - podSpec_ = - k8s.io.api.core.v1.Generated.PodSpec.newBuilder(podSpec_).mergeFrom(value).buildPartial(); - } else { - podSpec_ = value; - } - onChanged(); - } else { - podSpecBuilder_.mergeFrom(value); - } - - return this; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public Builder clearPodSpec() { - if (podSpecBuilder_ == null) { - podSpec_ = null; - onChanged(); - } else { - podSpec_ = null; - podSpecBuilder_ = null; - } - - return this; - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public k8s.io.api.core.v1.Generated.PodSpec.Builder getPodSpecBuilder() { - - onChanged(); - return getPodSpecFieldBuilder().getBuilder(); - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - public k8s.io.api.core.v1.Generated.PodSpecOrBuilder getPodSpecOrBuilder() { - if (podSpecBuilder_ != null) { - return podSpecBuilder_.getMessageOrBuilder(); - } else { - return podSpec_ == null ? - k8s.io.api.core.v1.Generated.PodSpec.getDefaultInstance() : podSpec_; - } - } - /** - * .k8s.io.api.core.v1.PodSpec pod_spec = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - k8s.io.api.core.v1.Generated.PodSpec, k8s.io.api.core.v1.Generated.PodSpec.Builder, k8s.io.api.core.v1.Generated.PodSpecOrBuilder> - getPodSpecFieldBuilder() { - if (podSpecBuilder_ == null) { - podSpecBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - k8s.io.api.core.v1.Generated.PodSpec, k8s.io.api.core.v1.Generated.PodSpec.Builder, k8s.io.api.core.v1.Generated.PodSpecOrBuilder>( - getPodSpec(), - getParentForChildren(), - isClean()); - podSpec_ = null; - } - return podSpecBuilder_; - } - - private java.lang.Object primaryContainerName_ = ""; - /** - * string primary_container_name = 2; - */ - public java.lang.String getPrimaryContainerName() { - java.lang.Object ref = primaryContainerName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - primaryContainerName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * string primary_container_name = 2; - */ - public com.google.protobuf.ByteString - getPrimaryContainerNameBytes() { - java.lang.Object ref = primaryContainerName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - primaryContainerName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * string primary_container_name = 2; - */ - public Builder setPrimaryContainerName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - primaryContainerName_ = value; - onChanged(); - return this; - } - /** - * string primary_container_name = 2; - */ - public Builder clearPrimaryContainerName() { - - primaryContainerName_ = getDefaultInstance().getPrimaryContainerName(); - onChanged(); - return this; - } - /** - * string primary_container_name = 2; - */ - public Builder setPrimaryContainerNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - primaryContainerName_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> annotations_; - private com.google.protobuf.MapField - internalGetAnnotations() { - if (annotations_ == null) { - return com.google.protobuf.MapField.emptyMapField( - AnnotationsDefaultEntryHolder.defaultEntry); - } - return annotations_; - } - private com.google.protobuf.MapField - internalGetMutableAnnotations() { - onChanged();; - if (annotations_ == null) { - annotations_ = com.google.protobuf.MapField.newMapField( - AnnotationsDefaultEntryHolder.defaultEntry); - } - if (!annotations_.isMutable()) { - annotations_ = annotations_.copy(); - } - return annotations_; - } - - public int getAnnotationsCount() { - return internalGetAnnotations().getMap().size(); - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - - public boolean containsAnnotations( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - return internalGetAnnotations().getMap().containsKey(key); - } - /** - * Use {@link #getAnnotationsMap()} instead. - */ - @java.lang.Deprecated - public java.util.Map getAnnotations() { - return getAnnotationsMap(); - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - - public java.util.Map getAnnotationsMap() { - return internalGetAnnotations().getMap(); - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - - public java.lang.String getAnnotationsOrDefault( - java.lang.String key, - java.lang.String defaultValue) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetAnnotations().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - - public java.lang.String getAnnotationsOrThrow( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetAnnotations().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearAnnotations() { - internalGetMutableAnnotations().getMutableMap() - .clear(); - return this; - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - - public Builder removeAnnotations( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - internalGetMutableAnnotations().getMutableMap() - .remove(key); - return this; - } - /** - * Use alternate mutation accessors instead. - */ - @java.lang.Deprecated - public java.util.Map - getMutableAnnotations() { - return internalGetMutableAnnotations().getMutableMap(); - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - public Builder putAnnotations( - java.lang.String key, - java.lang.String value) { - if (key == null) { throw new java.lang.NullPointerException(); } - if (value == null) { throw new java.lang.NullPointerException(); } - internalGetMutableAnnotations().getMutableMap() - .put(key, value); - return this; - } - /** - *
-       * Pod annotations
-       * 
- * - * map<string, string> annotations = 3; - */ - - public Builder putAllAnnotations( - java.util.Map values) { - internalGetMutableAnnotations().getMutableMap() - .putAll(values); - return this; - } - - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> labels_; - private com.google.protobuf.MapField - internalGetLabels() { - if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField( - LabelsDefaultEntryHolder.defaultEntry); - } - return labels_; - } - private com.google.protobuf.MapField - internalGetMutableLabels() { - onChanged();; - if (labels_ == null) { - labels_ = com.google.protobuf.MapField.newMapField( - LabelsDefaultEntryHolder.defaultEntry); - } - if (!labels_.isMutable()) { - labels_ = labels_.copy(); - } - return labels_; - } - - public int getLabelsCount() { - return internalGetLabels().getMap().size(); - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - - public boolean containsLabels( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - return internalGetLabels().getMap().containsKey(key); - } - /** - * Use {@link #getLabelsMap()} instead. - */ - @java.lang.Deprecated - public java.util.Map getLabels() { - return getLabelsMap(); - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - - public java.util.Map getLabelsMap() { - return internalGetLabels().getMap(); - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - - public java.lang.String getLabelsOrDefault( - java.lang.String key, - java.lang.String defaultValue) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetLabels().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - - public java.lang.String getLabelsOrThrow( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - java.util.Map map = - internalGetLabels().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearLabels() { - internalGetMutableLabels().getMutableMap() - .clear(); - return this; - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - - public Builder removeLabels( - java.lang.String key) { - if (key == null) { throw new java.lang.NullPointerException(); } - internalGetMutableLabels().getMutableMap() - .remove(key); - return this; - } - /** - * Use alternate mutation accessors instead. - */ - @java.lang.Deprecated - public java.util.Map - getMutableLabels() { - return internalGetMutableLabels().getMutableMap(); - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - public Builder putLabels( - java.lang.String key, - java.lang.String value) { - if (key == null) { throw new java.lang.NullPointerException(); } - if (value == null) { throw new java.lang.NullPointerException(); } - internalGetMutableLabels().getMutableMap() - .put(key, value); - return this; - } - /** - *
-       * Pod labels
-       * 
- * - * map<string, string> labels = 4; - */ - - public Builder putAllLabels( - java.util.Map values) { - internalGetMutableLabels().getMutableMap() - .putAll(values); - 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:flyteidl.plugins.SidecarJob) - } - - // @@protoc_insertion_point(class_scope:flyteidl.plugins.SidecarJob) - private static final flyteidl.plugins.Sidecar.SidecarJob DEFAULT_INSTANCE; - static { - DEFAULT_INSTANCE = new flyteidl.plugins.Sidecar.SidecarJob(); - } - - public static flyteidl.plugins.Sidecar.SidecarJob getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public SidecarJob parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new SidecarJob(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 flyteidl.plugins.Sidecar.SidecarJob getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - - } - - private static final com.google.protobuf.Descriptors.Descriptor - internal_static_flyteidl_plugins_SidecarJob_descriptor; - private static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_flyteidl_plugins_SidecarJob_fieldAccessorTable; - private static final com.google.protobuf.Descriptors.Descriptor - internal_static_flyteidl_plugins_SidecarJob_AnnotationsEntry_descriptor; - private static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_flyteidl_plugins_SidecarJob_AnnotationsEntry_fieldAccessorTable; - private static final com.google.protobuf.Descriptors.Descriptor - internal_static_flyteidl_plugins_SidecarJob_LabelsEntry_descriptor; - private static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_flyteidl_plugins_SidecarJob_LabelsEntry_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n\036flyteidl/plugins/sidecar.proto\022\020flytei" + - "dl.plugins\032\"k8s.io/api/core/v1/generated" + - ".proto\"\274\002\n\nSidecarJob\022-\n\010pod_spec\030\001 \001(\0132" + - "\033.k8s.io.api.core.v1.PodSpec\022\036\n\026primary_" + - "container_name\030\002 \001(\t\022B\n\013annotations\030\003 \003(" + - "\0132-.flyteidl.plugins.SidecarJob.Annotati" + - "onsEntry\0228\n\006labels\030\004 \003(\0132(.flyteidl.plug" + - "ins.SidecarJob.LabelsEntry\0322\n\020Annotation" + - "sEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\032-" + - "\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(" + - "\t:\0028\001B9Z7github.com/flyteorg/flyteidl/ge" + - "n/pb-go/flyteidl/pluginsb\006proto3" - }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - k8s.io.api.core.v1.Generated.getDescriptor(), - }, assigner); - internal_static_flyteidl_plugins_SidecarJob_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_flyteidl_plugins_SidecarJob_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_flyteidl_plugins_SidecarJob_descriptor, - new java.lang.String[] { "PodSpec", "PrimaryContainerName", "Annotations", "Labels", }); - internal_static_flyteidl_plugins_SidecarJob_AnnotationsEntry_descriptor = - internal_static_flyteidl_plugins_SidecarJob_descriptor.getNestedTypes().get(0); - internal_static_flyteidl_plugins_SidecarJob_AnnotationsEntry_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_flyteidl_plugins_SidecarJob_AnnotationsEntry_descriptor, - new java.lang.String[] { "Key", "Value", }); - internal_static_flyteidl_plugins_SidecarJob_LabelsEntry_descriptor = - internal_static_flyteidl_plugins_SidecarJob_descriptor.getNestedTypes().get(1); - internal_static_flyteidl_plugins_SidecarJob_LabelsEntry_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_flyteidl_plugins_SidecarJob_LabelsEntry_descriptor, - new java.lang.String[] { "Key", "Value", }); - k8s.io.api.core.v1.Generated.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/flyteidl/gen/pb_python/flyteidl/plugins/sidecar_pb2.py b/flyteidl/gen/pb_python/flyteidl/plugins/sidecar_pb2.py deleted file mode 100644 index 6e529ed2546..00000000000 --- a/flyteidl/gen/pb_python/flyteidl/plugins/sidecar_pb2.py +++ /dev/null @@ -1,191 +0,0 @@ -# -*- coding: utf-8 -*- -# Generated by the protocol buffer compiler. DO NOT EDIT! -# source: flyteidl/plugins/sidecar.proto - -import sys -_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) -from google.protobuf import descriptor as _descriptor -from google.protobuf import message as _message -from google.protobuf import reflection as _reflection -from google.protobuf import symbol_database as _symbol_database -# @@protoc_insertion_point(imports) - -_sym_db = _symbol_database.Default() - - -from k8s.io.api.core.v1 import generated_pb2 as k8s_dot_io_dot_api_dot_core_dot_v1_dot_generated__pb2 - - -DESCRIPTOR = _descriptor.FileDescriptor( - name='flyteidl/plugins/sidecar.proto', - package='flyteidl.plugins', - syntax='proto3', - serialized_options=_b('Z7github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/plugins'), - serialized_pb=_b('\n\x1e\x66lyteidl/plugins/sidecar.proto\x12\x10\x66lyteidl.plugins\x1a\"k8s.io/api/core/v1/generated.proto\"\xbc\x02\n\nSidecarJob\x12-\n\x08pod_spec\x18\x01 \x01(\x0b\x32\x1b.k8s.io.api.core.v1.PodSpec\x12\x1e\n\x16primary_container_name\x18\x02 \x01(\t\x12\x42\n\x0b\x61nnotations\x18\x03 \x03(\x0b\x32-.flyteidl.plugins.SidecarJob.AnnotationsEntry\x12\x38\n\x06labels\x18\x04 \x03(\x0b\x32(.flyteidl.plugins.SidecarJob.LabelsEntry\x1a\x32\n\x10\x41nnotationsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x39Z7github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/pluginsb\x06proto3') - , - dependencies=[k8s_dot_io_dot_api_dot_core_dot_v1_dot_generated__pb2.DESCRIPTOR,]) - - - - -_SIDECARJOB_ANNOTATIONSENTRY = _descriptor.Descriptor( - name='AnnotationsEntry', - full_name='flyteidl.plugins.SidecarJob.AnnotationsEntry', - filename=None, - file=DESCRIPTOR, - containing_type=None, - fields=[ - _descriptor.FieldDescriptor( - name='key', full_name='flyteidl.plugins.SidecarJob.AnnotationsEntry.key', index=0, - number=1, 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='value', full_name='flyteidl.plugins.SidecarJob.AnnotationsEntry.value', 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), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=_b('8\001'), - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=308, - serialized_end=358, -) - -_SIDECARJOB_LABELSENTRY = _descriptor.Descriptor( - name='LabelsEntry', - full_name='flyteidl.plugins.SidecarJob.LabelsEntry', - filename=None, - file=DESCRIPTOR, - containing_type=None, - fields=[ - _descriptor.FieldDescriptor( - name='key', full_name='flyteidl.plugins.SidecarJob.LabelsEntry.key', index=0, - number=1, 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='value', full_name='flyteidl.plugins.SidecarJob.LabelsEntry.value', 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), - ], - extensions=[ - ], - nested_types=[], - enum_types=[ - ], - serialized_options=_b('8\001'), - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=360, - serialized_end=405, -) - -_SIDECARJOB = _descriptor.Descriptor( - name='SidecarJob', - full_name='flyteidl.plugins.SidecarJob', - filename=None, - file=DESCRIPTOR, - containing_type=None, - fields=[ - _descriptor.FieldDescriptor( - name='pod_spec', full_name='flyteidl.plugins.SidecarJob.pod_spec', 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='primary_container_name', full_name='flyteidl.plugins.SidecarJob.primary_container_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='annotations', full_name='flyteidl.plugins.SidecarJob.annotations', index=2, - number=3, type=11, cpp_type=10, label=3, - has_default_value=False, default_value=[], - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR), - _descriptor.FieldDescriptor( - name='labels', full_name='flyteidl.plugins.SidecarJob.labels', index=3, - number=4, type=11, cpp_type=10, label=3, - has_default_value=False, default_value=[], - message_type=None, enum_type=None, containing_type=None, - is_extension=False, extension_scope=None, - serialized_options=None, file=DESCRIPTOR), - ], - extensions=[ - ], - nested_types=[_SIDECARJOB_ANNOTATIONSENTRY, _SIDECARJOB_LABELSENTRY, ], - enum_types=[ - ], - serialized_options=None, - is_extendable=False, - syntax='proto3', - extension_ranges=[], - oneofs=[ - ], - serialized_start=89, - serialized_end=405, -) - -_SIDECARJOB_ANNOTATIONSENTRY.containing_type = _SIDECARJOB -_SIDECARJOB_LABELSENTRY.containing_type = _SIDECARJOB -_SIDECARJOB.fields_by_name['pod_spec'].message_type = k8s_dot_io_dot_api_dot_core_dot_v1_dot_generated__pb2._PODSPEC -_SIDECARJOB.fields_by_name['annotations'].message_type = _SIDECARJOB_ANNOTATIONSENTRY -_SIDECARJOB.fields_by_name['labels'].message_type = _SIDECARJOB_LABELSENTRY -DESCRIPTOR.message_types_by_name['SidecarJob'] = _SIDECARJOB -_sym_db.RegisterFileDescriptor(DESCRIPTOR) - -SidecarJob = _reflection.GeneratedProtocolMessageType('SidecarJob', (_message.Message,), dict( - - AnnotationsEntry = _reflection.GeneratedProtocolMessageType('AnnotationsEntry', (_message.Message,), dict( - DESCRIPTOR = _SIDECARJOB_ANNOTATIONSENTRY, - __module__ = 'flyteidl.plugins.sidecar_pb2' - # @@protoc_insertion_point(class_scope:flyteidl.plugins.SidecarJob.AnnotationsEntry) - )) - , - - LabelsEntry = _reflection.GeneratedProtocolMessageType('LabelsEntry', (_message.Message,), dict( - DESCRIPTOR = _SIDECARJOB_LABELSENTRY, - __module__ = 'flyteidl.plugins.sidecar_pb2' - # @@protoc_insertion_point(class_scope:flyteidl.plugins.SidecarJob.LabelsEntry) - )) - , - DESCRIPTOR = _SIDECARJOB, - __module__ = 'flyteidl.plugins.sidecar_pb2' - # @@protoc_insertion_point(class_scope:flyteidl.plugins.SidecarJob) - )) -_sym_db.RegisterMessage(SidecarJob) -_sym_db.RegisterMessage(SidecarJob.AnnotationsEntry) -_sym_db.RegisterMessage(SidecarJob.LabelsEntry) - - -DESCRIPTOR._options = None -_SIDECARJOB_ANNOTATIONSENTRY._options = None -_SIDECARJOB_LABELSENTRY._options = None -# @@protoc_insertion_point(module_scope) diff --git a/flyteidl/gen/pb_python/flyteidl/plugins/sidecar_pb2_grpc.py b/flyteidl/gen/pb_python/flyteidl/plugins/sidecar_pb2_grpc.py deleted file mode 100644 index a89435267cb..00000000000 --- a/flyteidl/gen/pb_python/flyteidl/plugins/sidecar_pb2_grpc.py +++ /dev/null @@ -1,3 +0,0 @@ -# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT! -import grpc - diff --git a/flyteidl/protos/docs/plugins/plugins.rst b/flyteidl/protos/docs/plugins/plugins.rst index 089eb6d87f2..a1aa83ce935 100644 --- a/flyteidl/protos/docs/plugins/plugins.rst +++ b/flyteidl/protos/docs/plugins/plugins.rst @@ -281,102 +281,6 @@ of a hive task's TaskTemplate -.. - end messages - - -.. - end enums - - -.. - end HasExtensions - - -.. - end services - - - - -.. _ref_flyteidl/plugins/sidecar.proto: - -flyteidl/plugins/sidecar.proto -================================================================== - - - - - -.. _ref_flyteidl.plugins.SidecarJob: - -SidecarJob ------------------------------------------------------------------- - -A sidecar job brings up the desired pod_spec. -The plugin executor is responsible for keeping the pod alive until the primary container terminates -or the task itself times out. - - - -.. csv-table:: SidecarJob type fields - :header: "Field", "Type", "Label", "Description" - :widths: auto - - "pod_spec", ":ref:`ref_k8s.io.api.core.v1.PodSpec`", "", "" - "primary_container_name", ":ref:`ref_string`", "", "" - "annotations", ":ref:`ref_flyteidl.plugins.SidecarJob.AnnotationsEntry`", "repeated", "Pod annotations" - "labels", ":ref:`ref_flyteidl.plugins.SidecarJob.LabelsEntry`", "repeated", "Pod labels" - - - - - - - -.. _ref_flyteidl.plugins.SidecarJob.AnnotationsEntry: - -SidecarJob.AnnotationsEntry ------------------------------------------------------------------- - - - - - -.. csv-table:: SidecarJob.AnnotationsEntry type fields - :header: "Field", "Type", "Label", "Description" - :widths: auto - - "key", ":ref:`ref_string`", "", "" - "value", ":ref:`ref_string`", "", "" - - - - - - - -.. _ref_flyteidl.plugins.SidecarJob.LabelsEntry: - -SidecarJob.LabelsEntry ------------------------------------------------------------------- - - - - - -.. csv-table:: SidecarJob.LabelsEntry type fields - :header: "Field", "Type", "Label", "Description" - :widths: auto - - "key", ":ref:`ref_string`", "", "" - "value", ":ref:`ref_string`", "", "" - - - - - - .. end messages diff --git a/flyteidl/protos/flyteidl/plugins/sidecar.proto b/flyteidl/protos/flyteidl/plugins/sidecar.proto deleted file mode 100644 index 8f5b6f55ff0..00000000000 --- a/flyteidl/protos/flyteidl/plugins/sidecar.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; - -package flyteidl.plugins; - -option go_package = "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/plugins"; - -import "k8s.io/api/core/v1/generated.proto"; - -// A sidecar job brings up the desired pod_spec. -// The plugin executor is responsible for keeping the pod alive until the primary container terminates -// or the task itself times out. -message SidecarJob { - k8s.io.api.core.v1.PodSpec pod_spec = 1; - - string primary_container_name = 2; - - // Pod annotations - map annotations = 3; - - // Pod labels - map labels = 4; -}