diff --git a/go.mod b/go.mod index 7bb6617ffb91e..fe0e9b7070153 100644 --- a/go.mod +++ b/go.mod @@ -20,7 +20,7 @@ require ( github.com/golang/protobuf v1.5.3 github.com/klauspost/compress v1.14.4 github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d - github.com/milvus-io/milvus-proto/go-api v0.0.0-20230515081521-d963c95b041f + github.com/milvus-io/milvus-proto/go-api v0.0.0-20230517025117-8ba62a3f3a63 github.com/milvus-io/milvus/pkg v0.0.0-00010101000000-000000000000 github.com/minio/minio-go/v7 v7.0.17 github.com/panjf2000/ants/v2 v2.7.2 diff --git a/go.sum b/go.sum index 8a9abd547cd0f..80a0b8eca1724 100644 --- a/go.sum +++ b/go.sum @@ -583,6 +583,8 @@ github.com/milvus-io/milvus-proto/go-api v0.0.0-20230421091228-eaa38c831a61 h1:E github.com/milvus-io/milvus-proto/go-api v0.0.0-20230421091228-eaa38c831a61/go.mod h1:148qnlmZ0Fdm1Fq+Mj/OW2uDoEP25g3mjh0vMGtkgmk= github.com/milvus-io/milvus-proto/go-api v0.0.0-20230515081521-d963c95b041f h1:uZzVaSbUtxMdEix9By6z+M/H/XNkXRQJdZQ9HP/wHtc= github.com/milvus-io/milvus-proto/go-api v0.0.0-20230515081521-d963c95b041f/go.mod h1:148qnlmZ0Fdm1Fq+Mj/OW2uDoEP25g3mjh0vMGtkgmk= +github.com/milvus-io/milvus-proto/go-api v0.0.0-20230517025117-8ba62a3f3a63 h1:V962mSHjOFUbuMgAXziBdbYPOCVZmN1MkqEeKpME+MA= +github.com/milvus-io/milvus-proto/go-api v0.0.0-20230517025117-8ba62a3f3a63/go.mod h1:148qnlmZ0Fdm1Fq+Mj/OW2uDoEP25g3mjh0vMGtkgmk= github.com/milvus-io/pulsar-client-go v0.6.10 h1:eqpJjU+/QX0iIhEo3nhOqMNXL+TyInAs1IAHZCrCM/A= github.com/milvus-io/pulsar-client-go v0.6.10/go.mod h1:lQqCkgwDF8YFYjKA+zOheTk1tev2B+bKj5j7+nm8M1w= github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8 h1:AMFGa4R4MiIpspGNG7Z948v4n35fFGB3RR3G/ry4FWs= diff --git a/internal/core/src/pb/common.pb.cc b/internal/core/src/pb/common.pb.cc index b7da0f9860c04..e5821a43c59e8 100755 --- a/internal/core/src/pb/common.pb.cc +++ b/internal/core/src/pb/common.pb.cc @@ -195,10 +195,68 @@ struct SegmentStatsDefaultTypeInternal { }; }; PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 SegmentStatsDefaultTypeInternal _SegmentStats_default_instance_; +PROTOBUF_CONSTEXPR ClientInfo_ReservedEntry_DoNotUse::ClientInfo_ReservedEntry_DoNotUse( + ::_pbi::ConstantInitialized) {} +struct ClientInfo_ReservedEntry_DoNotUseDefaultTypeInternal { + PROTOBUF_CONSTEXPR ClientInfo_ReservedEntry_DoNotUseDefaultTypeInternal() + : _instance(::_pbi::ConstantInitialized{}) {} + ~ClientInfo_ReservedEntry_DoNotUseDefaultTypeInternal() {} + union { + ClientInfo_ReservedEntry_DoNotUse _instance; + }; +}; +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ClientInfo_ReservedEntry_DoNotUseDefaultTypeInternal _ClientInfo_ReservedEntry_DoNotUse_default_instance_; +PROTOBUF_CONSTEXPR ClientInfo::ClientInfo( + ::_pbi::ConstantInitialized): _impl_{ + /*decltype(_impl_.reserved_)*/{::_pbi::ConstantInitialized()} + , /*decltype(_impl_.sdk_type_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.sdk_version_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.local_time_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.user_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.host_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_._cached_size_)*/{}} {} +struct ClientInfoDefaultTypeInternal { + PROTOBUF_CONSTEXPR ClientInfoDefaultTypeInternal() + : _instance(::_pbi::ConstantInitialized{}) {} + ~ClientInfoDefaultTypeInternal() {} + union { + ClientInfo _instance; + }; +}; +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ClientInfoDefaultTypeInternal _ClientInfo_default_instance_; +PROTOBUF_CONSTEXPR ServerInfo_ReservedEntry_DoNotUse::ServerInfo_ReservedEntry_DoNotUse( + ::_pbi::ConstantInitialized) {} +struct ServerInfo_ReservedEntry_DoNotUseDefaultTypeInternal { + PROTOBUF_CONSTEXPR ServerInfo_ReservedEntry_DoNotUseDefaultTypeInternal() + : _instance(::_pbi::ConstantInitialized{}) {} + ~ServerInfo_ReservedEntry_DoNotUseDefaultTypeInternal() {} + union { + ServerInfo_ReservedEntry_DoNotUse _instance; + }; +}; +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ServerInfo_ReservedEntry_DoNotUseDefaultTypeInternal _ServerInfo_ReservedEntry_DoNotUse_default_instance_; +PROTOBUF_CONSTEXPR ServerInfo::ServerInfo( + ::_pbi::ConstantInitialized): _impl_{ + /*decltype(_impl_.reserved_)*/{::_pbi::ConstantInitialized()} + , /*decltype(_impl_.build_tags_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.build_time_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.git_commit_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.go_version_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_.deploy_mode_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} + , /*decltype(_impl_._cached_size_)*/{}} {} +struct ServerInfoDefaultTypeInternal { + PROTOBUF_CONSTEXPR ServerInfoDefaultTypeInternal() + : _instance(::_pbi::ConstantInitialized{}) {} + ~ServerInfoDefaultTypeInternal() {} + union { + ServerInfo _instance; + }; +}; +PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ServerInfoDefaultTypeInternal _ServerInfo_default_instance_; } // namespace common } // namespace proto } // namespace milvus -static ::_pb::Metadata file_level_metadata_common_2eproto[12]; +static ::_pb::Metadata file_level_metadata_common_2eproto[16]; static const ::_pb::EnumDescriptor* file_level_enum_descriptors_common_2eproto[13]; static constexpr ::_pb::ServiceDescriptor const** file_level_service_descriptors_common_2eproto = nullptr; @@ -303,6 +361,50 @@ const uint32_t TableStruct_common_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(p ~0u, // no _inlined_string_donated_ PROTOBUF_FIELD_OFFSET(::milvus::proto::common::SegmentStats, _impl_.segmentid_), PROTOBUF_FIELD_OFFSET(::milvus::proto::common::SegmentStats, _impl_.numrows_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse, _has_bits_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse, key_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse, value_), + 0, + 1, + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _impl_.sdk_type_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _impl_.sdk_version_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _impl_.local_time_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _impl_.user_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _impl_.host_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ClientInfo, _impl_.reserved_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse, _has_bits_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse, key_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse, value_), + 0, + 1, + ~0u, // no _has_bits_ + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _internal_metadata_), + ~0u, // no _extensions_ + ~0u, // no _oneof_case_ + ~0u, // no _weak_field_map_ + ~0u, // no _inlined_string_donated_ + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _impl_.build_tags_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _impl_.build_time_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _impl_.git_commit_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _impl_.go_version_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _impl_.deploy_mode_), + PROTOBUF_FIELD_OFFSET(::milvus::proto::common::ServerInfo, _impl_.reserved_), }; static const ::_pbi::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { { 0, -1, -1, sizeof(::milvus::proto::common::Status)}, @@ -317,6 +419,10 @@ static const ::_pbi::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protode { 74, -1, -1, sizeof(::milvus::proto::common::DMLMsgHeader)}, { 82, -1, -1, sizeof(::milvus::proto::common::PrivilegeExt)}, { 92, -1, -1, sizeof(::milvus::proto::common::SegmentStats)}, + { 100, 108, -1, sizeof(::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse)}, + { 110, -1, -1, sizeof(::milvus::proto::common::ClientInfo)}, + { 122, 130, -1, sizeof(::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse)}, + { 132, -1, -1, sizeof(::milvus::proto::common::ServerInfo)}, }; static const ::_pb::Message* const file_default_instances[] = { @@ -332,6 +438,10 @@ static const ::_pb::Message* const file_default_instances[] = { &::milvus::proto::common::_DMLMsgHeader_default_instance_._instance, &::milvus::proto::common::_PrivilegeExt_default_instance_._instance, &::milvus::proto::common::_SegmentStats_default_instance_._instance, + &::milvus::proto::common::_ClientInfo_ReservedEntry_DoNotUse_default_instance_._instance, + &::milvus::proto::common::_ClientInfo_default_instance_._instance, + &::milvus::proto::common::_ServerInfo_ReservedEntry_DoNotUse_default_instance_._instance, + &::milvus::proto::common::_ServerInfo_default_instance_._instance, }; const char descriptor_table_protodef_common_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = @@ -359,150 +469,162 @@ const char descriptor_table_protodef_common_2eproto[] PROTOBUF_SECTION_VARIABLE( "ilege\030\002 \001(\0162$.milvus.proto.common.Object" "Privilege\022\031\n\021object_name_index\030\003 \001(\005\022\032\n\022" "object_name_indexs\030\004 \001(\005\"2\n\014SegmentStats" - "\022\021\n\tSegmentID\030\001 \001(\003\022\017\n\007NumRows\030\002 \001(\003*\303\n\n" - "\tErrorCode\022\013\n\007Success\020\000\022\023\n\017UnexpectedErr" - "or\020\001\022\021\n\rConnectFailed\020\002\022\024\n\020PermissionDen" - "ied\020\003\022\027\n\023CollectionNotExists\020\004\022\023\n\017Illega" - "lArgument\020\005\022\024\n\020IllegalDimension\020\007\022\024\n\020Ill" - "egalIndexType\020\010\022\031\n\025IllegalCollectionName" - "\020\t\022\017\n\013IllegalTOPK\020\n\022\024\n\020IllegalRowRecord\020" - "\013\022\023\n\017IllegalVectorID\020\014\022\027\n\023IllegalSearchR" - "esult\020\r\022\020\n\014FileNotFound\020\016\022\016\n\nMetaFailed\020" - "\017\022\017\n\013CacheFailed\020\020\022\026\n\022CannotCreateFolder" - "\020\021\022\024\n\020CannotCreateFile\020\022\022\026\n\022CannotDelete" - "Folder\020\023\022\024\n\020CannotDeleteFile\020\024\022\023\n\017BuildI" - "ndexError\020\025\022\020\n\014IllegalNLIST\020\026\022\025\n\021Illegal" - "MetricType\020\027\022\017\n\013OutOfMemory\020\030\022\021\n\rIndexNo" - "tExist\020\031\022\023\n\017EmptyCollection\020\032\022\033\n\027UpdateI" - "mportTaskFailure\020\033\022\032\n\026CollectionNameNotF" - "ound\020\034\022\033\n\027CreateCredentialFailure\020\035\022\033\n\027U" - "pdateCredentialFailure\020\036\022\033\n\027DeleteCreden" - "tialFailure\020\037\022\030\n\024GetCredentialFailure\020 \022" - "\030\n\024ListCredUsersFailure\020!\022\022\n\016GetUserFail" - "ure\020\"\022\025\n\021CreateRoleFailure\020#\022\023\n\017DropRole" - "Failure\020$\022\032\n\026OperateUserRoleFailure\020%\022\025\n" - "\021SelectRoleFailure\020&\022\025\n\021SelectUserFailur" - "e\020\'\022\031\n\025SelectResourceFailure\020(\022\033\n\027Operat" - "ePrivilegeFailure\020)\022\026\n\022SelectGrantFailur" - "e\020*\022!\n\035RefreshPolicyInfoCacheFailure\020+\022\025" - "\n\021ListPolicyFailure\020,\022\022\n\016NotShardLeader\020" - "-\022\026\n\022NoReplicaAvailable\020.\022\023\n\017SegmentNotF" - "ound\020/\022\r\n\tForceDeny\0200\022\r\n\tRateLimit\0201\022\022\n\016" - "NodeIDNotMatch\0202\022\024\n\020UpsertAutoIDTrue\0203\022\034" - "\n\030InsufficientMemoryToLoad\0204\022\030\n\024MemoryQu" - "otaExhausted\0205\022\026\n\022DiskQuotaExhausted\0206\022\025" - "\n\021TimeTickLongDelay\0207\022\021\n\rNotReadyServe\0208" - "\022\033\n\027NotReadyCoordActivating\0209\022\017\n\013DataCoo" - "rdNA\020d\022\022\n\rDDRequestRace\020\350\007*c\n\nIndexState" - "\022\022\n\016IndexStateNone\020\000\022\014\n\010Unissued\020\001\022\016\n\nIn" - "Progress\020\002\022\014\n\010Finished\020\003\022\n\n\006Failed\020\004\022\t\n\005" - "Retry\020\005*\202\001\n\014SegmentState\022\024\n\020SegmentState" - "None\020\000\022\014\n\010NotExist\020\001\022\013\n\007Growing\020\002\022\n\n\006Sea" - "led\020\003\022\013\n\007Flushed\020\004\022\014\n\010Flushing\020\005\022\013\n\007Drop" - "ped\020\006\022\r\n\tImporting\020\007*>\n\017PlaceholderType\022" - "\010\n\004None\020\000\022\020\n\014BinaryVector\020d\022\017\n\013FloatVect" - "or\020e*\277\017\n\007MsgType\022\r\n\tUndefined\020\000\022\024\n\020Creat" - "eCollection\020d\022\022\n\016DropCollection\020e\022\021\n\rHas" - "Collection\020f\022\026\n\022DescribeCollection\020g\022\023\n\017" - "ShowCollections\020h\022\024\n\020GetSystemConfigs\020i\022" - "\022\n\016LoadCollection\020j\022\025\n\021ReleaseCollection" - "\020k\022\017\n\013CreateAlias\020l\022\r\n\tDropAlias\020m\022\016\n\nAl" - "terAlias\020n\022\023\n\017AlterCollection\020o\022\024\n\020Renam" - "eCollection\020p\022\021\n\rDescribeAlias\020q\022\017\n\013List" - "Aliases\020r\022\024\n\017CreatePartition\020\310\001\022\022\n\rDropP" - "artition\020\311\001\022\021\n\014HasPartition\020\312\001\022\026\n\021Descri" - "bePartition\020\313\001\022\023\n\016ShowPartitions\020\314\001\022\023\n\016L" - "oadPartitions\020\315\001\022\026\n\021ReleasePartitions\020\316\001" - "\022\021\n\014ShowSegments\020\372\001\022\024\n\017DescribeSegment\020\373" - "\001\022\021\n\014LoadSegments\020\374\001\022\024\n\017ReleaseSegments\020" - "\375\001\022\024\n\017HandoffSegments\020\376\001\022\030\n\023LoadBalanceS" - "egments\020\377\001\022\025\n\020DescribeSegments\020\200\002\022\034\n\027Fed" - "erListIndexedSegment\020\201\002\022\"\n\035FederDescribe" - "SegmentIndexData\020\202\002\022\020\n\013CreateIndex\020\254\002\022\022\n" - "\rDescribeIndex\020\255\002\022\016\n\tDropIndex\020\256\002\022\027\n\022Get" - "IndexStatistics\020\257\002\022\013\n\006Insert\020\220\003\022\013\n\006Delet" - "e\020\221\003\022\n\n\005Flush\020\222\003\022\027\n\022ResendSegmentStats\020\223" - "\003\022\013\n\006Upsert\020\224\003\022\013\n\006Search\020\364\003\022\021\n\014SearchRes" - "ult\020\365\003\022\022\n\rGetIndexState\020\366\003\022\032\n\025GetIndexBu" - "ildProgress\020\367\003\022\034\n\027GetCollectionStatistic" - "s\020\370\003\022\033\n\026GetPartitionStatistics\020\371\003\022\r\n\010Ret" - "rieve\020\372\003\022\023\n\016RetrieveResult\020\373\003\022\024\n\017WatchDm" - "Channels\020\374\003\022\025\n\020RemoveDmChannels\020\375\003\022\027\n\022Wa" - "tchQueryChannels\020\376\003\022\030\n\023RemoveQueryChanne" - "ls\020\377\003\022\035\n\030SealedSegmentsChangeInfo\020\200\004\022\027\n\022" - "WatchDeltaChannels\020\201\004\022\024\n\017GetShardLeaders" - "\020\202\004\022\020\n\013GetReplicas\020\203\004\022\023\n\016UnsubDmChannel\020" - "\204\004\022\024\n\017GetDistribution\020\205\004\022\025\n\020SyncDistribu" - "tion\020\206\004\022\020\n\013SegmentInfo\020\330\004\022\017\n\nSystemInfo\020" - "\331\004\022\024\n\017GetRecoveryInfo\020\332\004\022\024\n\017GetSegmentSt" - "ate\020\333\004\022\r\n\010TimeTick\020\260\t\022\023\n\016QueryNodeStats\020" - "\261\t\022\016\n\tLoadIndex\020\262\t\022\016\n\tRequestID\020\263\t\022\017\n\nRe" - "questTSO\020\264\t\022\024\n\017AllocateSegment\020\265\t\022\026\n\021Seg" - "mentStatistics\020\266\t\022\025\n\020SegmentFlushDone\020\267\t" - "\022\017\n\nDataNodeTt\020\270\t\022\025\n\020CreateCredential\020\334\013" - "\022\022\n\rGetCredential\020\335\013\022\025\n\020DeleteCredential" - "\020\336\013\022\025\n\020UpdateCredential\020\337\013\022\026\n\021ListCredUs" - "ernames\020\340\013\022\017\n\nCreateRole\020\300\014\022\r\n\010DropRole\020" - "\301\014\022\024\n\017OperateUserRole\020\302\014\022\017\n\nSelectRole\020\303" - "\014\022\017\n\nSelectUser\020\304\014\022\023\n\016SelectResource\020\305\014\022" - "\025\n\020OperatePrivilege\020\306\014\022\020\n\013SelectGrant\020\307\014" - "\022\033\n\026RefreshPolicyInfoCache\020\310\014\022\017\n\nListPol" - "icy\020\311\014\022\030\n\023CreateResourceGroup\020\244\r\022\026\n\021Drop" - "ResourceGroup\020\245\r\022\027\n\022ListResourceGroups\020\246" - "\r\022\032\n\025DescribeResourceGroup\020\247\r\022\021\n\014Transfe" - "rNode\020\250\r\022\024\n\017TransferReplica\020\251\r*\"\n\007DslTyp" - "e\022\007\n\003Dsl\020\000\022\016\n\nBoolExprV1\020\001*B\n\017Compaction" - "State\022\021\n\rUndefiedState\020\000\022\r\n\tExecuting\020\001\022" - "\r\n\tCompleted\020\002*X\n\020ConsistencyLevel\022\n\n\006St" - "rong\020\000\022\013\n\007Session\020\001\022\013\n\007Bounded\020\002\022\016\n\nEven" - "tually\020\003\022\016\n\nCustomized\020\004*\236\001\n\013ImportState" - "\022\021\n\rImportPending\020\000\022\020\n\014ImportFailed\020\001\022\021\n" - "\rImportStarted\020\002\022\023\n\017ImportPersisted\020\005\022\021\n" - "\rImportFlushed\020\010\022\023\n\017ImportCompleted\020\006\022\032\n" - "\026ImportFailedAndCleaned\020\007*2\n\nObjectType\022" - "\016\n\nCollection\020\000\022\n\n\006Global\020\001\022\010\n\004User\020\002*\227\007" - "\n\017ObjectPrivilege\022\020\n\014PrivilegeAll\020\000\022\035\n\031P" - "rivilegeCreateCollection\020\001\022\033\n\027PrivilegeD" - "ropCollection\020\002\022\037\n\033PrivilegeDescribeColl" - "ection\020\003\022\034\n\030PrivilegeShowCollections\020\004\022\021" - "\n\rPrivilegeLoad\020\005\022\024\n\020PrivilegeRelease\020\006\022" - "\027\n\023PrivilegeCompaction\020\007\022\023\n\017PrivilegeIns" - "ert\020\010\022\023\n\017PrivilegeDelete\020\t\022\032\n\026PrivilegeG" - "etStatistics\020\n\022\030\n\024PrivilegeCreateIndex\020\013" - "\022\030\n\024PrivilegeIndexDetail\020\014\022\026\n\022PrivilegeD" - "ropIndex\020\r\022\023\n\017PrivilegeSearch\020\016\022\022\n\016Privi" - "legeFlush\020\017\022\022\n\016PrivilegeQuery\020\020\022\030\n\024Privi" - "legeLoadBalance\020\021\022\023\n\017PrivilegeImport\020\022\022\034" - "\n\030PrivilegeCreateOwnership\020\023\022\027\n\023Privileg" - "eUpdateUser\020\024\022\032\n\026PrivilegeDropOwnership\020" - "\025\022\034\n\030PrivilegeSelectOwnership\020\026\022\034\n\030Privi" - "legeManageOwnership\020\027\022\027\n\023PrivilegeSelect" - "User\020\030\022\023\n\017PrivilegeUpsert\020\031\022 \n\034Privilege" - "CreateResourceGroup\020\032\022\036\n\032PrivilegeDropRe" - "sourceGroup\020\033\022\"\n\036PrivilegeDescribeResour" - "ceGroup\020\034\022\037\n\033PrivilegeListResourceGroups" - "\020\035\022\031\n\025PrivilegeTransferNode\020\036\022\034\n\030Privile" - "geTransferReplica\020\037\022\037\n\033PrivilegeGetLoadi" - "ngProgress\020 \022\031\n\025PrivilegeGetLoadState\020!*" - "S\n\tStateCode\022\020\n\014Initializing\020\000\022\013\n\007Health" - "y\020\001\022\014\n\010Abnormal\020\002\022\013\n\007StandBy\020\003\022\014\n\010Stoppi" - "ng\020\004*c\n\tLoadState\022\025\n\021LoadStateNotExist\020\000" - "\022\024\n\020LoadStateNotLoad\020\001\022\024\n\020LoadStateLoadi" - "ng\020\002\022\023\n\017LoadStateLoaded\020\003:^\n\021privilege_e" - "xt_obj\022\037.google.protobuf.MessageOptions\030" - "\351\007 \001(\0132!.milvus.proto.common.PrivilegeEx" - "tBf\n\016io.milvus.grpcB\013CommonProtoP\001Z1gith" - "ub.com/milvus-io/milvus-proto/go-api/com" - "monpb\240\001\001\252\002\016IO.Milvus.Grpcb\006proto3" + "\022\021\n\tSegmentID\030\001 \001(\003\022\017\n\007NumRows\030\002 \001(\003\"\325\001\n" + "\nClientInfo\022\020\n\010sdk_type\030\001 \001(\t\022\023\n\013sdk_ver" + "sion\030\002 \001(\t\022\022\n\nlocal_time\030\003 \001(\t\022\014\n\004user\030\004" + " \001(\t\022\014\n\004host\030\005 \001(\t\022\?\n\010reserved\030\006 \003(\0132-.m" + "ilvus.proto.common.ClientInfo.ReservedEn" + "try\032/\n\rReservedEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005val" + "ue\030\002 \001(\t:\0028\001\"\343\001\n\nServerInfo\022\022\n\nbuild_tag" + "s\030\001 \001(\t\022\022\n\nbuild_time\030\002 \001(\t\022\022\n\ngit_commi" + "t\030\003 \001(\t\022\022\n\ngo_version\030\004 \001(\t\022\023\n\013deploy_mo" + "de\030\005 \001(\t\022\?\n\010reserved\030\006 \003(\0132-.milvus.prot" + "o.common.ServerInfo.ReservedEntry\032/\n\rRes" + "ervedEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\002" + "8\001*\303\n\n\tErrorCode\022\013\n\007Success\020\000\022\023\n\017Unexpec" + "tedError\020\001\022\021\n\rConnectFailed\020\002\022\024\n\020Permiss" + "ionDenied\020\003\022\027\n\023CollectionNotExists\020\004\022\023\n\017" + "IllegalArgument\020\005\022\024\n\020IllegalDimension\020\007\022" + "\024\n\020IllegalIndexType\020\010\022\031\n\025IllegalCollecti" + "onName\020\t\022\017\n\013IllegalTOPK\020\n\022\024\n\020IllegalRowR" + "ecord\020\013\022\023\n\017IllegalVectorID\020\014\022\027\n\023IllegalS" + "earchResult\020\r\022\020\n\014FileNotFound\020\016\022\016\n\nMetaF" + "ailed\020\017\022\017\n\013CacheFailed\020\020\022\026\n\022CannotCreate" + "Folder\020\021\022\024\n\020CannotCreateFile\020\022\022\026\n\022Cannot" + "DeleteFolder\020\023\022\024\n\020CannotDeleteFile\020\024\022\023\n\017" + "BuildIndexError\020\025\022\020\n\014IllegalNLIST\020\026\022\025\n\021I" + "llegalMetricType\020\027\022\017\n\013OutOfMemory\020\030\022\021\n\rI" + "ndexNotExist\020\031\022\023\n\017EmptyCollection\020\032\022\033\n\027U" + "pdateImportTaskFailure\020\033\022\032\n\026CollectionNa" + "meNotFound\020\034\022\033\n\027CreateCredentialFailure\020" + "\035\022\033\n\027UpdateCredentialFailure\020\036\022\033\n\027Delete" + "CredentialFailure\020\037\022\030\n\024GetCredentialFail" + "ure\020 \022\030\n\024ListCredUsersFailure\020!\022\022\n\016GetUs" + "erFailure\020\"\022\025\n\021CreateRoleFailure\020#\022\023\n\017Dr" + "opRoleFailure\020$\022\032\n\026OperateUserRoleFailur" + "e\020%\022\025\n\021SelectRoleFailure\020&\022\025\n\021SelectUser" + "Failure\020\'\022\031\n\025SelectResourceFailure\020(\022\033\n\027" + "OperatePrivilegeFailure\020)\022\026\n\022SelectGrant" + "Failure\020*\022!\n\035RefreshPolicyInfoCacheFailu" + "re\020+\022\025\n\021ListPolicyFailure\020,\022\022\n\016NotShardL" + "eader\020-\022\026\n\022NoReplicaAvailable\020.\022\023\n\017Segme" + "ntNotFound\020/\022\r\n\tForceDeny\0200\022\r\n\tRateLimit" + "\0201\022\022\n\016NodeIDNotMatch\0202\022\024\n\020UpsertAutoIDTr" + "ue\0203\022\034\n\030InsufficientMemoryToLoad\0204\022\030\n\024Me" + "moryQuotaExhausted\0205\022\026\n\022DiskQuotaExhaust" + "ed\0206\022\025\n\021TimeTickLongDelay\0207\022\021\n\rNotReadyS" + "erve\0208\022\033\n\027NotReadyCoordActivating\0209\022\017\n\013D" + "ataCoordNA\020d\022\022\n\rDDRequestRace\020\350\007*c\n\nInde" + "xState\022\022\n\016IndexStateNone\020\000\022\014\n\010Unissued\020\001" + "\022\016\n\nInProgress\020\002\022\014\n\010Finished\020\003\022\n\n\006Failed" + "\020\004\022\t\n\005Retry\020\005*\202\001\n\014SegmentState\022\024\n\020Segmen" + "tStateNone\020\000\022\014\n\010NotExist\020\001\022\013\n\007Growing\020\002\022" + "\n\n\006Sealed\020\003\022\013\n\007Flushed\020\004\022\014\n\010Flushing\020\005\022\013" + "\n\007Dropped\020\006\022\r\n\tImporting\020\007*>\n\017Placeholde" + "rType\022\010\n\004None\020\000\022\020\n\014BinaryVector\020d\022\017\n\013Flo" + "atVector\020e*\343\017\n\007MsgType\022\r\n\tUndefined\020\000\022\024\n" + "\020CreateCollection\020d\022\022\n\016DropCollection\020e\022" + "\021\n\rHasCollection\020f\022\026\n\022DescribeCollection" + "\020g\022\023\n\017ShowCollections\020h\022\024\n\020GetSystemConf" + "igs\020i\022\022\n\016LoadCollection\020j\022\025\n\021ReleaseColl" + "ection\020k\022\017\n\013CreateAlias\020l\022\r\n\tDropAlias\020m" + "\022\016\n\nAlterAlias\020n\022\023\n\017AlterCollection\020o\022\024\n" + "\020RenameCollection\020p\022\021\n\rDescribeAlias\020q\022\017" + "\n\013ListAliases\020r\022\024\n\017CreatePartition\020\310\001\022\022\n" + "\rDropPartition\020\311\001\022\021\n\014HasPartition\020\312\001\022\026\n\021" + "DescribePartition\020\313\001\022\023\n\016ShowPartitions\020\314" + "\001\022\023\n\016LoadPartitions\020\315\001\022\026\n\021ReleasePartiti" + "ons\020\316\001\022\021\n\014ShowSegments\020\372\001\022\024\n\017DescribeSeg" + "ment\020\373\001\022\021\n\014LoadSegments\020\374\001\022\024\n\017ReleaseSeg" + "ments\020\375\001\022\024\n\017HandoffSegments\020\376\001\022\030\n\023LoadBa" + "lanceSegments\020\377\001\022\025\n\020DescribeSegments\020\200\002\022" + "\034\n\027FederListIndexedSegment\020\201\002\022\"\n\035FederDe" + "scribeSegmentIndexData\020\202\002\022\020\n\013CreateIndex" + "\020\254\002\022\022\n\rDescribeIndex\020\255\002\022\016\n\tDropIndex\020\256\002\022" + "\027\n\022GetIndexStatistics\020\257\002\022\013\n\006Insert\020\220\003\022\013\n" + "\006Delete\020\221\003\022\n\n\005Flush\020\222\003\022\027\n\022ResendSegmentS" + "tats\020\223\003\022\013\n\006Upsert\020\224\003\022\013\n\006Search\020\364\003\022\021\n\014Sea" + "rchResult\020\365\003\022\022\n\rGetIndexState\020\366\003\022\032\n\025GetI" + "ndexBuildProgress\020\367\003\022\034\n\027GetCollectionSta" + "tistics\020\370\003\022\033\n\026GetPartitionStatistics\020\371\003\022" + "\r\n\010Retrieve\020\372\003\022\023\n\016RetrieveResult\020\373\003\022\024\n\017W" + "atchDmChannels\020\374\003\022\025\n\020RemoveDmChannels\020\375\003" + "\022\027\n\022WatchQueryChannels\020\376\003\022\030\n\023RemoveQuery" + "Channels\020\377\003\022\035\n\030SealedSegmentsChangeInfo\020" + "\200\004\022\027\n\022WatchDeltaChannels\020\201\004\022\024\n\017GetShardL" + "eaders\020\202\004\022\020\n\013GetReplicas\020\203\004\022\023\n\016UnsubDmCh" + "annel\020\204\004\022\024\n\017GetDistribution\020\205\004\022\025\n\020SyncDi" + "stribution\020\206\004\022\020\n\013SegmentInfo\020\330\004\022\017\n\nSyste" + "mInfo\020\331\004\022\024\n\017GetRecoveryInfo\020\332\004\022\024\n\017GetSeg" + "mentState\020\333\004\022\r\n\010TimeTick\020\260\t\022\023\n\016QueryNode" + "Stats\020\261\t\022\016\n\tLoadIndex\020\262\t\022\016\n\tRequestID\020\263\t" + "\022\017\n\nRequestTSO\020\264\t\022\024\n\017AllocateSegment\020\265\t\022" + "\026\n\021SegmentStatistics\020\266\t\022\025\n\020SegmentFlushD" + "one\020\267\t\022\017\n\nDataNodeTt\020\270\t\022\014\n\007Connect\020\271\t\022\024\n" + "\017ListClientInfos\020\272\t\022\025\n\020CreateCredential\020" + "\334\013\022\022\n\rGetCredential\020\335\013\022\025\n\020DeleteCredenti" + "al\020\336\013\022\025\n\020UpdateCredential\020\337\013\022\026\n\021ListCred" + "Usernames\020\340\013\022\017\n\nCreateRole\020\300\014\022\r\n\010DropRol" + "e\020\301\014\022\024\n\017OperateUserRole\020\302\014\022\017\n\nSelectRole" + "\020\303\014\022\017\n\nSelectUser\020\304\014\022\023\n\016SelectResource\020\305" + "\014\022\025\n\020OperatePrivilege\020\306\014\022\020\n\013SelectGrant\020" + "\307\014\022\033\n\026RefreshPolicyInfoCache\020\310\014\022\017\n\nListP" + "olicy\020\311\014\022\030\n\023CreateResourceGroup\020\244\r\022\026\n\021Dr" + "opResourceGroup\020\245\r\022\027\n\022ListResourceGroups" + "\020\246\r\022\032\n\025DescribeResourceGroup\020\247\r\022\021\n\014Trans" + "ferNode\020\250\r\022\024\n\017TransferReplica\020\251\r*\"\n\007DslT" + "ype\022\007\n\003Dsl\020\000\022\016\n\nBoolExprV1\020\001*B\n\017Compacti" + "onState\022\021\n\rUndefiedState\020\000\022\r\n\tExecuting\020" + "\001\022\r\n\tCompleted\020\002*X\n\020ConsistencyLevel\022\n\n\006" + "Strong\020\000\022\013\n\007Session\020\001\022\013\n\007Bounded\020\002\022\016\n\nEv" + "entually\020\003\022\016\n\nCustomized\020\004*\236\001\n\013ImportSta" + "te\022\021\n\rImportPending\020\000\022\020\n\014ImportFailed\020\001\022" + "\021\n\rImportStarted\020\002\022\023\n\017ImportPersisted\020\005\022" + "\021\n\rImportFlushed\020\010\022\023\n\017ImportCompleted\020\006\022" + "\032\n\026ImportFailedAndCleaned\020\007*2\n\nObjectTyp" + "e\022\016\n\nCollection\020\000\022\n\n\006Global\020\001\022\010\n\004User\020\002*" + "\227\007\n\017ObjectPrivilege\022\020\n\014PrivilegeAll\020\000\022\035\n" + "\031PrivilegeCreateCollection\020\001\022\033\n\027Privileg" + "eDropCollection\020\002\022\037\n\033PrivilegeDescribeCo" + "llection\020\003\022\034\n\030PrivilegeShowCollections\020\004" + "\022\021\n\rPrivilegeLoad\020\005\022\024\n\020PrivilegeRelease\020" + "\006\022\027\n\023PrivilegeCompaction\020\007\022\023\n\017PrivilegeI" + "nsert\020\010\022\023\n\017PrivilegeDelete\020\t\022\032\n\026Privileg" + "eGetStatistics\020\n\022\030\n\024PrivilegeCreateIndex" + "\020\013\022\030\n\024PrivilegeIndexDetail\020\014\022\026\n\022Privileg" + "eDropIndex\020\r\022\023\n\017PrivilegeSearch\020\016\022\022\n\016Pri" + "vilegeFlush\020\017\022\022\n\016PrivilegeQuery\020\020\022\030\n\024Pri" + "vilegeLoadBalance\020\021\022\023\n\017PrivilegeImport\020\022" + "\022\034\n\030PrivilegeCreateOwnership\020\023\022\027\n\023Privil" + "egeUpdateUser\020\024\022\032\n\026PrivilegeDropOwnershi" + "p\020\025\022\034\n\030PrivilegeSelectOwnership\020\026\022\034\n\030Pri" + "vilegeManageOwnership\020\027\022\027\n\023PrivilegeSele" + "ctUser\020\030\022\023\n\017PrivilegeUpsert\020\031\022 \n\034Privile" + "geCreateResourceGroup\020\032\022\036\n\032PrivilegeDrop" + "ResourceGroup\020\033\022\"\n\036PrivilegeDescribeReso" + "urceGroup\020\034\022\037\n\033PrivilegeListResourceGrou" + "ps\020\035\022\031\n\025PrivilegeTransferNode\020\036\022\034\n\030Privi" + "legeTransferReplica\020\037\022\037\n\033PrivilegeGetLoa" + "dingProgress\020 \022\031\n\025PrivilegeGetLoadState\020" + "!*S\n\tStateCode\022\020\n\014Initializing\020\000\022\013\n\007Heal" + "thy\020\001\022\014\n\010Abnormal\020\002\022\013\n\007StandBy\020\003\022\014\n\010Stop" + "ping\020\004*c\n\tLoadState\022\025\n\021LoadStateNotExist" + "\020\000\022\024\n\020LoadStateNotLoad\020\001\022\024\n\020LoadStateLoa" + "ding\020\002\022\023\n\017LoadStateLoaded\020\003:^\n\021privilege" + "_ext_obj\022\037.google.protobuf.MessageOption" + "s\030\351\007 \001(\0132!.milvus.proto.common.Privilege" + "ExtBf\n\016io.milvus.grpcB\013CommonProtoP\001Z1gi" + "thub.com/milvus-io/milvus-proto/go-api/c" + "ommonpb\240\001\001\252\002\016IO.Milvus.Grpcb\006proto3" ; static const ::_pbi::DescriptorTable* const descriptor_table_common_2eproto_deps[1] = { &::descriptor_table_google_2fprotobuf_2fdescriptor_2eproto, }; static ::_pbi::once_flag descriptor_table_common_2eproto_once; const ::_pbi::DescriptorTable descriptor_table_common_2eproto = { - false, false, 6353, descriptor_table_protodef_common_2eproto, + false, false, 6835, descriptor_table_protodef_common_2eproto, "common.proto", - &descriptor_table_common_2eproto_once, descriptor_table_common_2eproto_deps, 1, 12, + &descriptor_table_common_2eproto_once, descriptor_table_common_2eproto_deps, 1, 16, schemas, file_default_instances, TableStruct_common_2eproto::offsets, file_level_metadata_common_2eproto, file_level_enum_descriptors_common_2eproto, file_level_service_descriptors_common_2eproto, @@ -719,6 +841,8 @@ bool MsgType_IsValid(int value) { case 1206: case 1207: case 1208: + case 1209: + case 1210: case 1500: case 1501: case 1502: @@ -3752,62 +3876,1048 @@ ::PROTOBUF_NAMESPACE_ID::Metadata SegmentStats::GetMetadata() const { &descriptor_table_common_2eproto_getter, &descriptor_table_common_2eproto_once, file_level_metadata_common_2eproto[11]); } -PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 ::PROTOBUF_NAMESPACE_ID::internal::ExtensionIdentifier< ::PROTOBUF_NAMESPACE_ID::MessageOptions, - ::PROTOBUF_NAMESPACE_ID::internal::MessageTypeTraits< ::milvus::proto::common::PrivilegeExt >, 11, false> - privilege_ext_obj(kPrivilegeExtObjFieldNumber, ::milvus::proto::common::PrivilegeExt::default_instance(), nullptr); -// @@protoc_insertion_point(namespace_scope) -} // namespace common -} // namespace proto -} // namespace milvus -PROTOBUF_NAMESPACE_OPEN -template<> PROTOBUF_NOINLINE ::milvus::proto::common::Status* -Arena::CreateMaybeMessage< ::milvus::proto::common::Status >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::Status >(arena); +// =================================================================== + +ClientInfo_ReservedEntry_DoNotUse::ClientInfo_ReservedEntry_DoNotUse() {} +ClientInfo_ReservedEntry_DoNotUse::ClientInfo_ReservedEntry_DoNotUse(::PROTOBUF_NAMESPACE_ID::Arena* arena) + : SuperType(arena) {} +void ClientInfo_ReservedEntry_DoNotUse::MergeFrom(const ClientInfo_ReservedEntry_DoNotUse& other) { + MergeFromInternal(other); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::KeyValuePair* -Arena::CreateMaybeMessage< ::milvus::proto::common::KeyValuePair >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::KeyValuePair >(arena); +::PROTOBUF_NAMESPACE_ID::Metadata ClientInfo_ReservedEntry_DoNotUse::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_common_2eproto_getter, &descriptor_table_common_2eproto_once, + file_level_metadata_common_2eproto[12]); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::KeyDataPair* -Arena::CreateMaybeMessage< ::milvus::proto::common::KeyDataPair >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::KeyDataPair >(arena); + +// =================================================================== + +class ClientInfo::_Internal { + public: +}; + +ClientInfo::ClientInfo(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned) + : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) { + SharedCtor(arena, is_message_owned); + if (arena != nullptr && !is_message_owned) { + arena->OwnCustomDestructor(this, &ClientInfo::ArenaDtor); + } + // @@protoc_insertion_point(arena_constructor:milvus.proto.common.ClientInfo) } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::Blob* -Arena::CreateMaybeMessage< ::milvus::proto::common::Blob >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::Blob >(arena); +ClientInfo::ClientInfo(const ClientInfo& from) + : ::PROTOBUF_NAMESPACE_ID::Message() { + ClientInfo* const _this = this; (void)_this; + new (&_impl_) Impl_{ + /*decltype(_impl_.reserved_)*/{} + , decltype(_impl_.sdk_type_){} + , decltype(_impl_.sdk_version_){} + , decltype(_impl_.local_time_){} + , decltype(_impl_.user_){} + , decltype(_impl_.host_){} + , /*decltype(_impl_._cached_size_)*/{}}; + + _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + _this->_impl_.reserved_.MergeFrom(from._impl_.reserved_); + _impl_.sdk_type_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.sdk_type_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_sdk_type().empty()) { + _this->_impl_.sdk_type_.Set(from._internal_sdk_type(), + _this->GetArenaForAllocation()); + } + _impl_.sdk_version_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.sdk_version_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_sdk_version().empty()) { + _this->_impl_.sdk_version_.Set(from._internal_sdk_version(), + _this->GetArenaForAllocation()); + } + _impl_.local_time_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.local_time_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_local_time().empty()) { + _this->_impl_.local_time_.Set(from._internal_local_time(), + _this->GetArenaForAllocation()); + } + _impl_.user_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.user_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_user().empty()) { + _this->_impl_.user_.Set(from._internal_user(), + _this->GetArenaForAllocation()); + } + _impl_.host_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.host_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_host().empty()) { + _this->_impl_.host_.Set(from._internal_host(), + _this->GetArenaForAllocation()); + } + // @@protoc_insertion_point(copy_constructor:milvus.proto.common.ClientInfo) } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::PlaceholderValue* -Arena::CreateMaybeMessage< ::milvus::proto::common::PlaceholderValue >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::PlaceholderValue >(arena); + +inline void ClientInfo::SharedCtor( + ::_pb::Arena* arena, bool is_message_owned) { + (void)arena; + (void)is_message_owned; + new (&_impl_) Impl_{ + /*decltype(_impl_.reserved_)*/{::_pbi::ArenaInitialized(), arena} + , decltype(_impl_.sdk_type_){} + , decltype(_impl_.sdk_version_){} + , decltype(_impl_.local_time_){} + , decltype(_impl_.user_){} + , decltype(_impl_.host_){} + , /*decltype(_impl_._cached_size_)*/{} + }; + _impl_.sdk_type_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.sdk_type_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.sdk_version_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.sdk_version_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.local_time_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.local_time_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.user_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.user_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.host_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.host_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::PlaceholderGroup* -Arena::CreateMaybeMessage< ::milvus::proto::common::PlaceholderGroup >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::PlaceholderGroup >(arena); + +ClientInfo::~ClientInfo() { + // @@protoc_insertion_point(destructor:milvus.proto.common.ClientInfo) + if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) { + (void)arena; + ArenaDtor(this); + return; + } + SharedDtor(); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::Address* -Arena::CreateMaybeMessage< ::milvus::proto::common::Address >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::Address >(arena); + +inline void ClientInfo::SharedDtor() { + GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); + _impl_.reserved_.Destruct(); + _impl_.reserved_.~MapField(); + _impl_.sdk_type_.Destroy(); + _impl_.sdk_version_.Destroy(); + _impl_.local_time_.Destroy(); + _impl_.user_.Destroy(); + _impl_.host_.Destroy(); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::MsgBase* -Arena::CreateMaybeMessage< ::milvus::proto::common::MsgBase >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::MsgBase >(arena); + +void ClientInfo::ArenaDtor(void* object) { + ClientInfo* _this = reinterpret_cast< ClientInfo* >(object); + _this->_impl_.reserved_.Destruct(); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::MsgHeader* -Arena::CreateMaybeMessage< ::milvus::proto::common::MsgHeader >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::MsgHeader >(arena); +void ClientInfo::SetCachedSize(int size) const { + _impl_._cached_size_.Set(size); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::DMLMsgHeader* -Arena::CreateMaybeMessage< ::milvus::proto::common::DMLMsgHeader >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::DMLMsgHeader >(arena); + +void ClientInfo::Clear() { +// @@protoc_insertion_point(message_clear_start:milvus.proto.common.ClientInfo) + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + _impl_.reserved_.Clear(); + _impl_.sdk_type_.ClearToEmpty(); + _impl_.sdk_version_.ClearToEmpty(); + _impl_.local_time_.ClearToEmpty(); + _impl_.user_.ClearToEmpty(); + _impl_.host_.ClearToEmpty(); + _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::PrivilegeExt* -Arena::CreateMaybeMessage< ::milvus::proto::common::PrivilegeExt >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::PrivilegeExt >(arena); + +const char* ClientInfo::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) { +#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure + while (!ctx->Done(&ptr)) { + uint32_t tag; + ptr = ::_pbi::ReadTag(ptr, &tag); + switch (tag >> 3) { + // string sdk_type = 1; + case 1: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 10)) { + auto str = _internal_mutable_sdk_type(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ClientInfo.sdk_type")); + } else + goto handle_unusual; + continue; + // string sdk_version = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 18)) { + auto str = _internal_mutable_sdk_version(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ClientInfo.sdk_version")); + } else + goto handle_unusual; + continue; + // string local_time = 3; + case 3: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 26)) { + auto str = _internal_mutable_local_time(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ClientInfo.local_time")); + } else + goto handle_unusual; + continue; + // string user = 4; + case 4: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 34)) { + auto str = _internal_mutable_user(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ClientInfo.user")); + } else + goto handle_unusual; + continue; + // string host = 5; + case 5: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 42)) { + auto str = _internal_mutable_host(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ClientInfo.host")); + } else + goto handle_unusual; + continue; + // map reserved = 6; + case 6: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 50)) { + ptr -= 1; + do { + ptr += 1; + ptr = ctx->ParseMessage(&_impl_.reserved_, ptr); + CHK_(ptr); + if (!ctx->DataAvailable(ptr)) break; + } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<50>(ptr)); + } else + goto handle_unusual; + continue; + default: + goto handle_unusual; + } // switch + handle_unusual: + if ((tag == 0) || ((tag & 7) == 4)) { + CHK_(ptr); + ctx->SetLastTag(tag); + goto message_done; + } + ptr = UnknownFieldParse( + tag, + _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), + ptr, ctx); + CHK_(ptr != nullptr); + } // while +message_done: + return ptr; +failure: + ptr = nullptr; + goto message_done; +#undef CHK_ } -template<> PROTOBUF_NOINLINE ::milvus::proto::common::SegmentStats* -Arena::CreateMaybeMessage< ::milvus::proto::common::SegmentStats >(Arena* arena) { - return Arena::CreateMessageInternal< ::milvus::proto::common::SegmentStats >(arena); + +uint8_t* ClientInfo::_InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { + // @@protoc_insertion_point(serialize_to_array_start:milvus.proto.common.ClientInfo) + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + // string sdk_type = 1; + if (!this->_internal_sdk_type().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_sdk_type().data(), static_cast(this->_internal_sdk_type().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.sdk_type"); + target = stream->WriteStringMaybeAliased( + 1, this->_internal_sdk_type(), target); + } + + // string sdk_version = 2; + if (!this->_internal_sdk_version().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_sdk_version().data(), static_cast(this->_internal_sdk_version().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.sdk_version"); + target = stream->WriteStringMaybeAliased( + 2, this->_internal_sdk_version(), target); + } + + // string local_time = 3; + if (!this->_internal_local_time().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_local_time().data(), static_cast(this->_internal_local_time().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.local_time"); + target = stream->WriteStringMaybeAliased( + 3, this->_internal_local_time(), target); + } + + // string user = 4; + if (!this->_internal_user().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_user().data(), static_cast(this->_internal_user().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.user"); + target = stream->WriteStringMaybeAliased( + 4, this->_internal_user(), target); + } + + // string host = 5; + if (!this->_internal_host().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_host().data(), static_cast(this->_internal_host().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.host"); + target = stream->WriteStringMaybeAliased( + 5, this->_internal_host(), target); + } + + // map reserved = 6; + if (!this->_internal_reserved().empty()) { + using MapType = ::_pb::Map; + using WireHelper = ClientInfo_ReservedEntry_DoNotUse::Funcs; + const auto& map_field = this->_internal_reserved(); + auto check_utf8 = [](const MapType::value_type& entry) { + (void)entry; + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + entry.first.data(), static_cast(entry.first.length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.ReservedEntry.key"); + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + entry.second.data(), static_cast(entry.second.length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ClientInfo.ReservedEntry.value"); + }; + + if (stream->IsSerializationDeterministic() && map_field.size() > 1) { + for (const auto& entry : ::_pbi::MapSorterPtr(map_field)) { + target = WireHelper::InternalSerialize(6, entry.first, entry.second, target, stream); + check_utf8(entry); + } + } else { + for (const auto& entry : map_field) { + target = WireHelper::InternalSerialize(6, entry.first, entry.second, target, stream); + check_utf8(entry); + } + } + } + + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { + target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); + } + // @@protoc_insertion_point(serialize_to_array_end:milvus.proto.common.ClientInfo) + return target; +} + +size_t ClientInfo::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:milvus.proto.common.ClientInfo) + size_t total_size = 0; + + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + // map reserved = 6; + total_size += 1 * + ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(this->_internal_reserved_size()); + for (::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >::const_iterator + it = this->_internal_reserved().begin(); + it != this->_internal_reserved().end(); ++it) { + total_size += ClientInfo_ReservedEntry_DoNotUse::Funcs::ByteSizeLong(it->first, it->second); + } + + // string sdk_type = 1; + if (!this->_internal_sdk_type().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_sdk_type()); + } + + // string sdk_version = 2; + if (!this->_internal_sdk_version().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_sdk_version()); + } + + // string local_time = 3; + if (!this->_internal_local_time().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_local_time()); + } + + // string user = 4; + if (!this->_internal_user().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_user()); + } + + // string host = 5; + if (!this->_internal_host().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_host()); + } + + return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); +} + +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData ClientInfo::_class_data_ = { + ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, + ClientInfo::MergeImpl +}; +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*ClientInfo::GetClassData() const { return &_class_data_; } + + +void ClientInfo::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:milvus.proto.common.ClientInfo) + GOOGLE_DCHECK_NE(&from, _this); + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + _this->_impl_.reserved_.MergeFrom(from._impl_.reserved_); + if (!from._internal_sdk_type().empty()) { + _this->_internal_set_sdk_type(from._internal_sdk_type()); + } + if (!from._internal_sdk_version().empty()) { + _this->_internal_set_sdk_version(from._internal_sdk_version()); + } + if (!from._internal_local_time().empty()) { + _this->_internal_set_local_time(from._internal_local_time()); + } + if (!from._internal_user().empty()) { + _this->_internal_set_user(from._internal_user()); + } + if (!from._internal_host().empty()) { + _this->_internal_set_host(from._internal_host()); + } + _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); +} + +void ClientInfo::CopyFrom(const ClientInfo& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:milvus.proto.common.ClientInfo) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ClientInfo::IsInitialized() const { + return true; +} + +void ClientInfo::InternalSwap(ClientInfo* other) { + using std::swap; + auto* lhs_arena = GetArenaForAllocation(); + auto* rhs_arena = other->GetArenaForAllocation(); + _internal_metadata_.InternalSwap(&other->_internal_metadata_); + _impl_.reserved_.InternalSwap(&other->_impl_.reserved_); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.sdk_type_, lhs_arena, + &other->_impl_.sdk_type_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.sdk_version_, lhs_arena, + &other->_impl_.sdk_version_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.local_time_, lhs_arena, + &other->_impl_.local_time_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.user_, lhs_arena, + &other->_impl_.user_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.host_, lhs_arena, + &other->_impl_.host_, rhs_arena + ); +} + +::PROTOBUF_NAMESPACE_ID::Metadata ClientInfo::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_common_2eproto_getter, &descriptor_table_common_2eproto_once, + file_level_metadata_common_2eproto[13]); +} + +// =================================================================== + +ServerInfo_ReservedEntry_DoNotUse::ServerInfo_ReservedEntry_DoNotUse() {} +ServerInfo_ReservedEntry_DoNotUse::ServerInfo_ReservedEntry_DoNotUse(::PROTOBUF_NAMESPACE_ID::Arena* arena) + : SuperType(arena) {} +void ServerInfo_ReservedEntry_DoNotUse::MergeFrom(const ServerInfo_ReservedEntry_DoNotUse& other) { + MergeFromInternal(other); +} +::PROTOBUF_NAMESPACE_ID::Metadata ServerInfo_ReservedEntry_DoNotUse::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_common_2eproto_getter, &descriptor_table_common_2eproto_once, + file_level_metadata_common_2eproto[14]); +} + +// =================================================================== + +class ServerInfo::_Internal { + public: +}; + +ServerInfo::ServerInfo(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned) + : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) { + SharedCtor(arena, is_message_owned); + if (arena != nullptr && !is_message_owned) { + arena->OwnCustomDestructor(this, &ServerInfo::ArenaDtor); + } + // @@protoc_insertion_point(arena_constructor:milvus.proto.common.ServerInfo) +} +ServerInfo::ServerInfo(const ServerInfo& from) + : ::PROTOBUF_NAMESPACE_ID::Message() { + ServerInfo* const _this = this; (void)_this; + new (&_impl_) Impl_{ + /*decltype(_impl_.reserved_)*/{} + , decltype(_impl_.build_tags_){} + , decltype(_impl_.build_time_){} + , decltype(_impl_.git_commit_){} + , decltype(_impl_.go_version_){} + , decltype(_impl_.deploy_mode_){} + , /*decltype(_impl_._cached_size_)*/{}}; + + _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); + _this->_impl_.reserved_.MergeFrom(from._impl_.reserved_); + _impl_.build_tags_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.build_tags_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_build_tags().empty()) { + _this->_impl_.build_tags_.Set(from._internal_build_tags(), + _this->GetArenaForAllocation()); + } + _impl_.build_time_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.build_time_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_build_time().empty()) { + _this->_impl_.build_time_.Set(from._internal_build_time(), + _this->GetArenaForAllocation()); + } + _impl_.git_commit_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.git_commit_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_git_commit().empty()) { + _this->_impl_.git_commit_.Set(from._internal_git_commit(), + _this->GetArenaForAllocation()); + } + _impl_.go_version_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.go_version_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_go_version().empty()) { + _this->_impl_.go_version_.Set(from._internal_go_version(), + _this->GetArenaForAllocation()); + } + _impl_.deploy_mode_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.deploy_mode_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (!from._internal_deploy_mode().empty()) { + _this->_impl_.deploy_mode_.Set(from._internal_deploy_mode(), + _this->GetArenaForAllocation()); + } + // @@protoc_insertion_point(copy_constructor:milvus.proto.common.ServerInfo) +} + +inline void ServerInfo::SharedCtor( + ::_pb::Arena* arena, bool is_message_owned) { + (void)arena; + (void)is_message_owned; + new (&_impl_) Impl_{ + /*decltype(_impl_.reserved_)*/{::_pbi::ArenaInitialized(), arena} + , decltype(_impl_.build_tags_){} + , decltype(_impl_.build_time_){} + , decltype(_impl_.git_commit_){} + , decltype(_impl_.go_version_){} + , decltype(_impl_.deploy_mode_){} + , /*decltype(_impl_._cached_size_)*/{} + }; + _impl_.build_tags_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.build_tags_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.build_time_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.build_time_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.git_commit_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.git_commit_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.go_version_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.go_version_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.deploy_mode_.InitDefault(); + #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + _impl_.deploy_mode_.Set("", GetArenaForAllocation()); + #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING +} + +ServerInfo::~ServerInfo() { + // @@protoc_insertion_point(destructor:milvus.proto.common.ServerInfo) + if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) { + (void)arena; + ArenaDtor(this); + return; + } + SharedDtor(); +} + +inline void ServerInfo::SharedDtor() { + GOOGLE_DCHECK(GetArenaForAllocation() == nullptr); + _impl_.reserved_.Destruct(); + _impl_.reserved_.~MapField(); + _impl_.build_tags_.Destroy(); + _impl_.build_time_.Destroy(); + _impl_.git_commit_.Destroy(); + _impl_.go_version_.Destroy(); + _impl_.deploy_mode_.Destroy(); +} + +void ServerInfo::ArenaDtor(void* object) { + ServerInfo* _this = reinterpret_cast< ServerInfo* >(object); + _this->_impl_.reserved_.Destruct(); +} +void ServerInfo::SetCachedSize(int size) const { + _impl_._cached_size_.Set(size); +} + +void ServerInfo::Clear() { +// @@protoc_insertion_point(message_clear_start:milvus.proto.common.ServerInfo) + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + _impl_.reserved_.Clear(); + _impl_.build_tags_.ClearToEmpty(); + _impl_.build_time_.ClearToEmpty(); + _impl_.git_commit_.ClearToEmpty(); + _impl_.go_version_.ClearToEmpty(); + _impl_.deploy_mode_.ClearToEmpty(); + _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); +} + +const char* ServerInfo::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) { +#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure + while (!ctx->Done(&ptr)) { + uint32_t tag; + ptr = ::_pbi::ReadTag(ptr, &tag); + switch (tag >> 3) { + // string build_tags = 1; + case 1: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 10)) { + auto str = _internal_mutable_build_tags(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ServerInfo.build_tags")); + } else + goto handle_unusual; + continue; + // string build_time = 2; + case 2: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 18)) { + auto str = _internal_mutable_build_time(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ServerInfo.build_time")); + } else + goto handle_unusual; + continue; + // string git_commit = 3; + case 3: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 26)) { + auto str = _internal_mutable_git_commit(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ServerInfo.git_commit")); + } else + goto handle_unusual; + continue; + // string go_version = 4; + case 4: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 34)) { + auto str = _internal_mutable_go_version(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ServerInfo.go_version")); + } else + goto handle_unusual; + continue; + // string deploy_mode = 5; + case 5: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 42)) { + auto str = _internal_mutable_deploy_mode(); + ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx); + CHK_(ptr); + CHK_(::_pbi::VerifyUTF8(str, "milvus.proto.common.ServerInfo.deploy_mode")); + } else + goto handle_unusual; + continue; + // map reserved = 6; + case 6: + if (PROTOBUF_PREDICT_TRUE(static_cast(tag) == 50)) { + ptr -= 1; + do { + ptr += 1; + ptr = ctx->ParseMessage(&_impl_.reserved_, ptr); + CHK_(ptr); + if (!ctx->DataAvailable(ptr)) break; + } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<50>(ptr)); + } else + goto handle_unusual; + continue; + default: + goto handle_unusual; + } // switch + handle_unusual: + if ((tag == 0) || ((tag & 7) == 4)) { + CHK_(ptr); + ctx->SetLastTag(tag); + goto message_done; + } + ptr = UnknownFieldParse( + tag, + _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(), + ptr, ctx); + CHK_(ptr != nullptr); + } // while +message_done: + return ptr; +failure: + ptr = nullptr; + goto message_done; +#undef CHK_ +} + +uint8_t* ServerInfo::_InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { + // @@protoc_insertion_point(serialize_to_array_start:milvus.proto.common.ServerInfo) + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + // string build_tags = 1; + if (!this->_internal_build_tags().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_build_tags().data(), static_cast(this->_internal_build_tags().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.build_tags"); + target = stream->WriteStringMaybeAliased( + 1, this->_internal_build_tags(), target); + } + + // string build_time = 2; + if (!this->_internal_build_time().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_build_time().data(), static_cast(this->_internal_build_time().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.build_time"); + target = stream->WriteStringMaybeAliased( + 2, this->_internal_build_time(), target); + } + + // string git_commit = 3; + if (!this->_internal_git_commit().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_git_commit().data(), static_cast(this->_internal_git_commit().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.git_commit"); + target = stream->WriteStringMaybeAliased( + 3, this->_internal_git_commit(), target); + } + + // string go_version = 4; + if (!this->_internal_go_version().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_go_version().data(), static_cast(this->_internal_go_version().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.go_version"); + target = stream->WriteStringMaybeAliased( + 4, this->_internal_go_version(), target); + } + + // string deploy_mode = 5; + if (!this->_internal_deploy_mode().empty()) { + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + this->_internal_deploy_mode().data(), static_cast(this->_internal_deploy_mode().length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.deploy_mode"); + target = stream->WriteStringMaybeAliased( + 5, this->_internal_deploy_mode(), target); + } + + // map reserved = 6; + if (!this->_internal_reserved().empty()) { + using MapType = ::_pb::Map; + using WireHelper = ServerInfo_ReservedEntry_DoNotUse::Funcs; + const auto& map_field = this->_internal_reserved(); + auto check_utf8 = [](const MapType::value_type& entry) { + (void)entry; + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + entry.first.data(), static_cast(entry.first.length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.ReservedEntry.key"); + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( + entry.second.data(), static_cast(entry.second.length()), + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, + "milvus.proto.common.ServerInfo.ReservedEntry.value"); + }; + + if (stream->IsSerializationDeterministic() && map_field.size() > 1) { + for (const auto& entry : ::_pbi::MapSorterPtr(map_field)) { + target = WireHelper::InternalSerialize(6, entry.first, entry.second, target, stream); + check_utf8(entry); + } + } else { + for (const auto& entry : map_field) { + target = WireHelper::InternalSerialize(6, entry.first, entry.second, target, stream); + check_utf8(entry); + } + } + } + + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { + target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( + _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); + } + // @@protoc_insertion_point(serialize_to_array_end:milvus.proto.common.ServerInfo) + return target; +} + +size_t ServerInfo::ByteSizeLong() const { +// @@protoc_insertion_point(message_byte_size_start:milvus.proto.common.ServerInfo) + size_t total_size = 0; + + uint32_t cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + + // map reserved = 6; + total_size += 1 * + ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(this->_internal_reserved_size()); + for (::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >::const_iterator + it = this->_internal_reserved().begin(); + it != this->_internal_reserved().end(); ++it) { + total_size += ServerInfo_ReservedEntry_DoNotUse::Funcs::ByteSizeLong(it->first, it->second); + } + + // string build_tags = 1; + if (!this->_internal_build_tags().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_build_tags()); + } + + // string build_time = 2; + if (!this->_internal_build_time().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_build_time()); + } + + // string git_commit = 3; + if (!this->_internal_git_commit().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_git_commit()); + } + + // string go_version = 4; + if (!this->_internal_go_version().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_go_version()); + } + + // string deploy_mode = 5; + if (!this->_internal_deploy_mode().empty()) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( + this->_internal_deploy_mode()); + } + + return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); +} + +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData ServerInfo::_class_data_ = { + ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck, + ServerInfo::MergeImpl +}; +const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*ServerInfo::GetClassData() const { return &_class_data_; } + + +void ServerInfo::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { + auto* const _this = static_cast(&to_msg); + auto& from = static_cast(from_msg); + // @@protoc_insertion_point(class_specific_merge_from_start:milvus.proto.common.ServerInfo) + GOOGLE_DCHECK_NE(&from, _this); + uint32_t cached_has_bits = 0; + (void) cached_has_bits; + + _this->_impl_.reserved_.MergeFrom(from._impl_.reserved_); + if (!from._internal_build_tags().empty()) { + _this->_internal_set_build_tags(from._internal_build_tags()); + } + if (!from._internal_build_time().empty()) { + _this->_internal_set_build_time(from._internal_build_time()); + } + if (!from._internal_git_commit().empty()) { + _this->_internal_set_git_commit(from._internal_git_commit()); + } + if (!from._internal_go_version().empty()) { + _this->_internal_set_go_version(from._internal_go_version()); + } + if (!from._internal_deploy_mode().empty()) { + _this->_internal_set_deploy_mode(from._internal_deploy_mode()); + } + _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); +} + +void ServerInfo::CopyFrom(const ServerInfo& from) { +// @@protoc_insertion_point(class_specific_copy_from_start:milvus.proto.common.ServerInfo) + if (&from == this) return; + Clear(); + MergeFrom(from); +} + +bool ServerInfo::IsInitialized() const { + return true; +} + +void ServerInfo::InternalSwap(ServerInfo* other) { + using std::swap; + auto* lhs_arena = GetArenaForAllocation(); + auto* rhs_arena = other->GetArenaForAllocation(); + _internal_metadata_.InternalSwap(&other->_internal_metadata_); + _impl_.reserved_.InternalSwap(&other->_impl_.reserved_); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.build_tags_, lhs_arena, + &other->_impl_.build_tags_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.build_time_, lhs_arena, + &other->_impl_.build_time_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.git_commit_, lhs_arena, + &other->_impl_.git_commit_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.go_version_, lhs_arena, + &other->_impl_.go_version_, rhs_arena + ); + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap( + &_impl_.deploy_mode_, lhs_arena, + &other->_impl_.deploy_mode_, rhs_arena + ); +} + +::PROTOBUF_NAMESPACE_ID::Metadata ServerInfo::GetMetadata() const { + return ::_pbi::AssignDescriptors( + &descriptor_table_common_2eproto_getter, &descriptor_table_common_2eproto_once, + file_level_metadata_common_2eproto[15]); +} +PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 ::PROTOBUF_NAMESPACE_ID::internal::ExtensionIdentifier< ::PROTOBUF_NAMESPACE_ID::MessageOptions, + ::PROTOBUF_NAMESPACE_ID::internal::MessageTypeTraits< ::milvus::proto::common::PrivilegeExt >, 11, false> + privilege_ext_obj(kPrivilegeExtObjFieldNumber, ::milvus::proto::common::PrivilegeExt::default_instance(), nullptr); + +// @@protoc_insertion_point(namespace_scope) +} // namespace common +} // namespace proto +} // namespace milvus +PROTOBUF_NAMESPACE_OPEN +template<> PROTOBUF_NOINLINE ::milvus::proto::common::Status* +Arena::CreateMaybeMessage< ::milvus::proto::common::Status >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::Status >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::KeyValuePair* +Arena::CreateMaybeMessage< ::milvus::proto::common::KeyValuePair >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::KeyValuePair >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::KeyDataPair* +Arena::CreateMaybeMessage< ::milvus::proto::common::KeyDataPair >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::KeyDataPair >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::Blob* +Arena::CreateMaybeMessage< ::milvus::proto::common::Blob >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::Blob >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::PlaceholderValue* +Arena::CreateMaybeMessage< ::milvus::proto::common::PlaceholderValue >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::PlaceholderValue >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::PlaceholderGroup* +Arena::CreateMaybeMessage< ::milvus::proto::common::PlaceholderGroup >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::PlaceholderGroup >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::Address* +Arena::CreateMaybeMessage< ::milvus::proto::common::Address >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::Address >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::MsgBase* +Arena::CreateMaybeMessage< ::milvus::proto::common::MsgBase >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::MsgBase >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::MsgHeader* +Arena::CreateMaybeMessage< ::milvus::proto::common::MsgHeader >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::MsgHeader >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::DMLMsgHeader* +Arena::CreateMaybeMessage< ::milvus::proto::common::DMLMsgHeader >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::DMLMsgHeader >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::PrivilegeExt* +Arena::CreateMaybeMessage< ::milvus::proto::common::PrivilegeExt >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::PrivilegeExt >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::SegmentStats* +Arena::CreateMaybeMessage< ::milvus::proto::common::SegmentStats >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::SegmentStats >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse* +Arena::CreateMaybeMessage< ::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::ClientInfo* +Arena::CreateMaybeMessage< ::milvus::proto::common::ClientInfo >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::ClientInfo >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse* +Arena::CreateMaybeMessage< ::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse >(arena); +} +template<> PROTOBUF_NOINLINE ::milvus::proto::common::ServerInfo* +Arena::CreateMaybeMessage< ::milvus::proto::common::ServerInfo >(Arena* arena) { + return Arena::CreateMessageInternal< ::milvus::proto::common::ServerInfo >(arena); } PROTOBUF_NAMESPACE_CLOSE diff --git a/internal/core/src/pb/common.pb.h b/internal/core/src/pb/common.pb.h index f1ecc6878e1ca..835d502e2fde1 100755 --- a/internal/core/src/pb/common.pb.h +++ b/internal/core/src/pb/common.pb.h @@ -29,6 +29,9 @@ #include #include // IWYU pragma: export #include // IWYU pragma: export +#include // IWYU pragma: export +#include +#include #include #include #include @@ -55,6 +58,12 @@ extern AddressDefaultTypeInternal _Address_default_instance_; class Blob; struct BlobDefaultTypeInternal; extern BlobDefaultTypeInternal _Blob_default_instance_; +class ClientInfo; +struct ClientInfoDefaultTypeInternal; +extern ClientInfoDefaultTypeInternal _ClientInfo_default_instance_; +class ClientInfo_ReservedEntry_DoNotUse; +struct ClientInfo_ReservedEntry_DoNotUseDefaultTypeInternal; +extern ClientInfo_ReservedEntry_DoNotUseDefaultTypeInternal _ClientInfo_ReservedEntry_DoNotUse_default_instance_; class DMLMsgHeader; struct DMLMsgHeaderDefaultTypeInternal; extern DMLMsgHeaderDefaultTypeInternal _DMLMsgHeader_default_instance_; @@ -82,6 +91,12 @@ extern PrivilegeExtDefaultTypeInternal _PrivilegeExt_default_instance_; class SegmentStats; struct SegmentStatsDefaultTypeInternal; extern SegmentStatsDefaultTypeInternal _SegmentStats_default_instance_; +class ServerInfo; +struct ServerInfoDefaultTypeInternal; +extern ServerInfoDefaultTypeInternal _ServerInfo_default_instance_; +class ServerInfo_ReservedEntry_DoNotUse; +struct ServerInfo_ReservedEntry_DoNotUseDefaultTypeInternal; +extern ServerInfo_ReservedEntry_DoNotUseDefaultTypeInternal _ServerInfo_ReservedEntry_DoNotUse_default_instance_; class Status; struct StatusDefaultTypeInternal; extern StatusDefaultTypeInternal _Status_default_instance_; @@ -91,6 +106,8 @@ extern StatusDefaultTypeInternal _Status_default_instance_; PROTOBUF_NAMESPACE_OPEN template<> ::milvus::proto::common::Address* Arena::CreateMaybeMessage<::milvus::proto::common::Address>(Arena*); template<> ::milvus::proto::common::Blob* Arena::CreateMaybeMessage<::milvus::proto::common::Blob>(Arena*); +template<> ::milvus::proto::common::ClientInfo* Arena::CreateMaybeMessage<::milvus::proto::common::ClientInfo>(Arena*); +template<> ::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse* Arena::CreateMaybeMessage<::milvus::proto::common::ClientInfo_ReservedEntry_DoNotUse>(Arena*); template<> ::milvus::proto::common::DMLMsgHeader* Arena::CreateMaybeMessage<::milvus::proto::common::DMLMsgHeader>(Arena*); template<> ::milvus::proto::common::KeyDataPair* Arena::CreateMaybeMessage<::milvus::proto::common::KeyDataPair>(Arena*); template<> ::milvus::proto::common::KeyValuePair* Arena::CreateMaybeMessage<::milvus::proto::common::KeyValuePair>(Arena*); @@ -100,6 +117,8 @@ template<> ::milvus::proto::common::PlaceholderGroup* Arena::CreateMaybeMessage< template<> ::milvus::proto::common::PlaceholderValue* Arena::CreateMaybeMessage<::milvus::proto::common::PlaceholderValue>(Arena*); template<> ::milvus::proto::common::PrivilegeExt* Arena::CreateMaybeMessage<::milvus::proto::common::PrivilegeExt>(Arena*); template<> ::milvus::proto::common::SegmentStats* Arena::CreateMaybeMessage<::milvus::proto::common::SegmentStats>(Arena*); +template<> ::milvus::proto::common::ServerInfo* Arena::CreateMaybeMessage<::milvus::proto::common::ServerInfo>(Arena*); +template<> ::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse* Arena::CreateMaybeMessage<::milvus::proto::common::ServerInfo_ReservedEntry_DoNotUse>(Arena*); template<> ::milvus::proto::common::Status* Arena::CreateMaybeMessage<::milvus::proto::common::Status>(Arena*); PROTOBUF_NAMESPACE_CLOSE namespace milvus { @@ -348,6 +367,8 @@ enum MsgType : int { SegmentStatistics = 1206, SegmentFlushDone = 1207, DataNodeTt = 1208, + Connect = 1209, + ListClientInfos = 1210, CreateCredential = 1500, GetCredential = 1501, DeleteCredential = 1502, @@ -2677,6 +2698,548 @@ class SegmentStats final : union { Impl_ _impl_; }; friend struct ::TableStruct_common_2eproto; }; +// ------------------------------------------------------------------- + +class ClientInfo_ReservedEntry_DoNotUse : public ::PROTOBUF_NAMESPACE_ID::internal::MapEntry { +public: + typedef ::PROTOBUF_NAMESPACE_ID::internal::MapEntry SuperType; + ClientInfo_ReservedEntry_DoNotUse(); + explicit PROTOBUF_CONSTEXPR ClientInfo_ReservedEntry_DoNotUse( + ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + explicit ClientInfo_ReservedEntry_DoNotUse(::PROTOBUF_NAMESPACE_ID::Arena* arena); + void MergeFrom(const ClientInfo_ReservedEntry_DoNotUse& other); + static const ClientInfo_ReservedEntry_DoNotUse* internal_default_instance() { return reinterpret_cast(&_ClientInfo_ReservedEntry_DoNotUse_default_instance_); } + static bool ValidateKey(std::string* s) { + return ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(s->data(), static_cast(s->size()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, "milvus.proto.common.ClientInfo.ReservedEntry.key"); + } + static bool ValidateValue(std::string* s) { + return ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(s->data(), static_cast(s->size()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, "milvus.proto.common.ClientInfo.ReservedEntry.value"); + } + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + friend struct ::TableStruct_common_2eproto; +}; + +// ------------------------------------------------------------------- + +class ClientInfo final : + public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:milvus.proto.common.ClientInfo) */ { + public: + inline ClientInfo() : ClientInfo(nullptr) {} + ~ClientInfo() override; + explicit PROTOBUF_CONSTEXPR ClientInfo(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + + ClientInfo(const ClientInfo& from); + ClientInfo(ClientInfo&& from) noexcept + : ClientInfo() { + *this = ::std::move(from); + } + + inline ClientInfo& operator=(const ClientInfo& from) { + CopyFrom(from); + return *this; + } + inline ClientInfo& operator=(ClientInfo&& from) noexcept { + if (this == &from) return *this; + if (GetOwningArena() == from.GetOwningArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetOwningArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const ClientInfo& default_instance() { + return *internal_default_instance(); + } + static inline const ClientInfo* internal_default_instance() { + return reinterpret_cast( + &_ClientInfo_default_instance_); + } + static constexpr int kIndexInFileMessages = + 13; + + friend void swap(ClientInfo& a, ClientInfo& b) { + a.Swap(&b); + } + inline void Swap(ClientInfo* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() != nullptr && + GetOwningArena() == other->GetOwningArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() == other->GetOwningArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(ClientInfo* other) { + if (other == this) return; + GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + ClientInfo* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; + void CopyFrom(const ClientInfo& from); + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + void MergeFrom( const ClientInfo& from) { + ClientInfo::MergeImpl(*this, from); + } + private: + static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); + public: + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; + uint8_t* _InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; + int GetCachedSize() const final { return _impl_._cached_size_.Get(); } + + private: + void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(ClientInfo* other); + + private: + friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; + static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { + return "milvus.proto.common.ClientInfo"; + } + protected: + explicit ClientInfo(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned = false); + private: + static void ArenaDtor(void* object); + public: + + static const ClassData _class_data_; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*GetClassData() const final; + + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + + // accessors ------------------------------------------------------- + + enum : int { + kReservedFieldNumber = 6, + kSdkTypeFieldNumber = 1, + kSdkVersionFieldNumber = 2, + kLocalTimeFieldNumber = 3, + kUserFieldNumber = 4, + kHostFieldNumber = 5, + }; + // map reserved = 6; + int reserved_size() const; + private: + int _internal_reserved_size() const; + public: + void clear_reserved(); + private: + const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& + _internal_reserved() const; + ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* + _internal_mutable_reserved(); + public: + const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& + reserved() const; + ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* + mutable_reserved(); + + // string sdk_type = 1; + void clear_sdk_type(); + const std::string& sdk_type() const; + template + void set_sdk_type(ArgT0&& arg0, ArgT... args); + std::string* mutable_sdk_type(); + PROTOBUF_NODISCARD std::string* release_sdk_type(); + void set_allocated_sdk_type(std::string* sdk_type); + private: + const std::string& _internal_sdk_type() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_sdk_type(const std::string& value); + std::string* _internal_mutable_sdk_type(); + public: + + // string sdk_version = 2; + void clear_sdk_version(); + const std::string& sdk_version() const; + template + void set_sdk_version(ArgT0&& arg0, ArgT... args); + std::string* mutable_sdk_version(); + PROTOBUF_NODISCARD std::string* release_sdk_version(); + void set_allocated_sdk_version(std::string* sdk_version); + private: + const std::string& _internal_sdk_version() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_sdk_version(const std::string& value); + std::string* _internal_mutable_sdk_version(); + public: + + // string local_time = 3; + void clear_local_time(); + const std::string& local_time() const; + template + void set_local_time(ArgT0&& arg0, ArgT... args); + std::string* mutable_local_time(); + PROTOBUF_NODISCARD std::string* release_local_time(); + void set_allocated_local_time(std::string* local_time); + private: + const std::string& _internal_local_time() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_local_time(const std::string& value); + std::string* _internal_mutable_local_time(); + public: + + // string user = 4; + void clear_user(); + const std::string& user() const; + template + void set_user(ArgT0&& arg0, ArgT... args); + std::string* mutable_user(); + PROTOBUF_NODISCARD std::string* release_user(); + void set_allocated_user(std::string* user); + private: + const std::string& _internal_user() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_user(const std::string& value); + std::string* _internal_mutable_user(); + public: + + // string host = 5; + void clear_host(); + const std::string& host() const; + template + void set_host(ArgT0&& arg0, ArgT... args); + std::string* mutable_host(); + PROTOBUF_NODISCARD std::string* release_host(); + void set_allocated_host(std::string* host); + private: + const std::string& _internal_host() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_host(const std::string& value); + std::string* _internal_mutable_host(); + public: + + // @@protoc_insertion_point(class_scope:milvus.proto.common.ClientInfo) + private: + class _Internal; + + template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; + typedef void InternalArenaConstructable_; + typedef void DestructorSkippable_; + struct Impl_ { + ::PROTOBUF_NAMESPACE_ID::internal::MapField< + ClientInfo_ReservedEntry_DoNotUse, + std::string, std::string, + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_STRING, + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_STRING> reserved_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr sdk_type_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr sdk_version_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr local_time_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr user_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr host_; + mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_common_2eproto; +}; +// ------------------------------------------------------------------- + +class ServerInfo_ReservedEntry_DoNotUse : public ::PROTOBUF_NAMESPACE_ID::internal::MapEntry { +public: + typedef ::PROTOBUF_NAMESPACE_ID::internal::MapEntry SuperType; + ServerInfo_ReservedEntry_DoNotUse(); + explicit PROTOBUF_CONSTEXPR ServerInfo_ReservedEntry_DoNotUse( + ::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + explicit ServerInfo_ReservedEntry_DoNotUse(::PROTOBUF_NAMESPACE_ID::Arena* arena); + void MergeFrom(const ServerInfo_ReservedEntry_DoNotUse& other); + static const ServerInfo_ReservedEntry_DoNotUse* internal_default_instance() { return reinterpret_cast(&_ServerInfo_ReservedEntry_DoNotUse_default_instance_); } + static bool ValidateKey(std::string* s) { + return ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(s->data(), static_cast(s->size()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, "milvus.proto.common.ServerInfo.ReservedEntry.key"); + } + static bool ValidateValue(std::string* s) { + return ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(s->data(), static_cast(s->size()), ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, "milvus.proto.common.ServerInfo.ReservedEntry.value"); + } + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + friend struct ::TableStruct_common_2eproto; +}; + +// ------------------------------------------------------------------- + +class ServerInfo final : + public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:milvus.proto.common.ServerInfo) */ { + public: + inline ServerInfo() : ServerInfo(nullptr) {} + ~ServerInfo() override; + explicit PROTOBUF_CONSTEXPR ServerInfo(::PROTOBUF_NAMESPACE_ID::internal::ConstantInitialized); + + ServerInfo(const ServerInfo& from); + ServerInfo(ServerInfo&& from) noexcept + : ServerInfo() { + *this = ::std::move(from); + } + + inline ServerInfo& operator=(const ServerInfo& from) { + CopyFrom(from); + return *this; + } + inline ServerInfo& operator=(ServerInfo&& from) noexcept { + if (this == &from) return *this; + if (GetOwningArena() == from.GetOwningArena() + #ifdef PROTOBUF_FORCE_COPY_IN_MOVE + && GetOwningArena() != nullptr + #endif // !PROTOBUF_FORCE_COPY_IN_MOVE + ) { + InternalSwap(&from); + } else { + CopyFrom(from); + } + return *this; + } + + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() { + return GetDescriptor(); + } + static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() { + return default_instance().GetMetadata().descriptor; + } + static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() { + return default_instance().GetMetadata().reflection; + } + static const ServerInfo& default_instance() { + return *internal_default_instance(); + } + static inline const ServerInfo* internal_default_instance() { + return reinterpret_cast( + &_ServerInfo_default_instance_); + } + static constexpr int kIndexInFileMessages = + 15; + + friend void swap(ServerInfo& a, ServerInfo& b) { + a.Swap(&b); + } + inline void Swap(ServerInfo* other) { + if (other == this) return; + #ifdef PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() != nullptr && + GetOwningArena() == other->GetOwningArena()) { + #else // PROTOBUF_FORCE_COPY_IN_SWAP + if (GetOwningArena() == other->GetOwningArena()) { + #endif // !PROTOBUF_FORCE_COPY_IN_SWAP + InternalSwap(other); + } else { + ::PROTOBUF_NAMESPACE_ID::internal::GenericSwap(this, other); + } + } + void UnsafeArenaSwap(ServerInfo* other) { + if (other == this) return; + GOOGLE_DCHECK(GetOwningArena() == other->GetOwningArena()); + InternalSwap(other); + } + + // implements Message ---------------------------------------------- + + ServerInfo* New(::PROTOBUF_NAMESPACE_ID::Arena* arena = nullptr) const final { + return CreateMaybeMessage(arena); + } + using ::PROTOBUF_NAMESPACE_ID::Message::CopyFrom; + void CopyFrom(const ServerInfo& from); + using ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom; + void MergeFrom( const ServerInfo& from) { + ServerInfo::MergeImpl(*this, from); + } + private: + static void MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg); + public: + PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final; + bool IsInitialized() const final; + + size_t ByteSizeLong() const final; + const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final; + uint8_t* _InternalSerialize( + uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const final; + int GetCachedSize() const final { return _impl_._cached_size_.Get(); } + + private: + void SharedCtor(::PROTOBUF_NAMESPACE_ID::Arena* arena, bool is_message_owned); + void SharedDtor(); + void SetCachedSize(int size) const final; + void InternalSwap(ServerInfo* other); + + private: + friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata; + static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() { + return "milvus.proto.common.ServerInfo"; + } + protected: + explicit ServerInfo(::PROTOBUF_NAMESPACE_ID::Arena* arena, + bool is_message_owned = false); + private: + static void ArenaDtor(void* object); + public: + + static const ClassData _class_data_; + const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*GetClassData() const final; + + ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final; + + // nested types ---------------------------------------------------- + + + // accessors ------------------------------------------------------- + + enum : int { + kReservedFieldNumber = 6, + kBuildTagsFieldNumber = 1, + kBuildTimeFieldNumber = 2, + kGitCommitFieldNumber = 3, + kGoVersionFieldNumber = 4, + kDeployModeFieldNumber = 5, + }; + // map reserved = 6; + int reserved_size() const; + private: + int _internal_reserved_size() const; + public: + void clear_reserved(); + private: + const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& + _internal_reserved() const; + ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* + _internal_mutable_reserved(); + public: + const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& + reserved() const; + ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* + mutable_reserved(); + + // string build_tags = 1; + void clear_build_tags(); + const std::string& build_tags() const; + template + void set_build_tags(ArgT0&& arg0, ArgT... args); + std::string* mutable_build_tags(); + PROTOBUF_NODISCARD std::string* release_build_tags(); + void set_allocated_build_tags(std::string* build_tags); + private: + const std::string& _internal_build_tags() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_build_tags(const std::string& value); + std::string* _internal_mutable_build_tags(); + public: + + // string build_time = 2; + void clear_build_time(); + const std::string& build_time() const; + template + void set_build_time(ArgT0&& arg0, ArgT... args); + std::string* mutable_build_time(); + PROTOBUF_NODISCARD std::string* release_build_time(); + void set_allocated_build_time(std::string* build_time); + private: + const std::string& _internal_build_time() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_build_time(const std::string& value); + std::string* _internal_mutable_build_time(); + public: + + // string git_commit = 3; + void clear_git_commit(); + const std::string& git_commit() const; + template + void set_git_commit(ArgT0&& arg0, ArgT... args); + std::string* mutable_git_commit(); + PROTOBUF_NODISCARD std::string* release_git_commit(); + void set_allocated_git_commit(std::string* git_commit); + private: + const std::string& _internal_git_commit() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_git_commit(const std::string& value); + std::string* _internal_mutable_git_commit(); + public: + + // string go_version = 4; + void clear_go_version(); + const std::string& go_version() const; + template + void set_go_version(ArgT0&& arg0, ArgT... args); + std::string* mutable_go_version(); + PROTOBUF_NODISCARD std::string* release_go_version(); + void set_allocated_go_version(std::string* go_version); + private: + const std::string& _internal_go_version() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_go_version(const std::string& value); + std::string* _internal_mutable_go_version(); + public: + + // string deploy_mode = 5; + void clear_deploy_mode(); + const std::string& deploy_mode() const; + template + void set_deploy_mode(ArgT0&& arg0, ArgT... args); + std::string* mutable_deploy_mode(); + PROTOBUF_NODISCARD std::string* release_deploy_mode(); + void set_allocated_deploy_mode(std::string* deploy_mode); + private: + const std::string& _internal_deploy_mode() const; + inline PROTOBUF_ALWAYS_INLINE void _internal_set_deploy_mode(const std::string& value); + std::string* _internal_mutable_deploy_mode(); + public: + + // @@protoc_insertion_point(class_scope:milvus.proto.common.ServerInfo) + private: + class _Internal; + + template friend class ::PROTOBUF_NAMESPACE_ID::Arena::InternalHelper; + typedef void InternalArenaConstructable_; + typedef void DestructorSkippable_; + struct Impl_ { + ::PROTOBUF_NAMESPACE_ID::internal::MapField< + ServerInfo_ReservedEntry_DoNotUse, + std::string, std::string, + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_STRING, + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_STRING> reserved_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr build_tags_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr build_time_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr git_commit_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr go_version_; + ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr deploy_mode_; + mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; + }; + union { Impl_ _impl_; }; + friend struct ::TableStruct_common_2eproto; +}; // =================================================================== static const int kPrivilegeExtObjFieldNumber = 1001; @@ -2696,1089 +3259,1659 @@ extern ::PROTOBUF_NAMESPACE_ID::internal::ExtensionIdentifier< ::PROTOBUF_NAMESP inline void Status::clear_error_code() { _impl_.error_code_ = 0; } -inline ::milvus::proto::common::ErrorCode Status::_internal_error_code() const { - return static_cast< ::milvus::proto::common::ErrorCode >(_impl_.error_code_); +inline ::milvus::proto::common::ErrorCode Status::_internal_error_code() const { + return static_cast< ::milvus::proto::common::ErrorCode >(_impl_.error_code_); +} +inline ::milvus::proto::common::ErrorCode Status::error_code() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.Status.error_code) + return _internal_error_code(); +} +inline void Status::_internal_set_error_code(::milvus::proto::common::ErrorCode value) { + + _impl_.error_code_ = value; +} +inline void Status::set_error_code(::milvus::proto::common::ErrorCode value) { + _internal_set_error_code(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.Status.error_code) +} + +// string reason = 2; +inline void Status::clear_reason() { + _impl_.reason_.ClearToEmpty(); +} +inline const std::string& Status::reason() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.Status.reason) + return _internal_reason(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void Status::set_reason(ArgT0&& arg0, ArgT... args) { + + _impl_.reason_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.Status.reason) +} +inline std::string* Status::mutable_reason() { + std::string* _s = _internal_mutable_reason(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.Status.reason) + return _s; +} +inline const std::string& Status::_internal_reason() const { + return _impl_.reason_.Get(); +} +inline void Status::_internal_set_reason(const std::string& value) { + + _impl_.reason_.Set(value, GetArenaForAllocation()); +} +inline std::string* Status::_internal_mutable_reason() { + + return _impl_.reason_.Mutable(GetArenaForAllocation()); +} +inline std::string* Status::release_reason() { + // @@protoc_insertion_point(field_release:milvus.proto.common.Status.reason) + return _impl_.reason_.Release(); +} +inline void Status::set_allocated_reason(std::string* reason) { + if (reason != nullptr) { + + } else { + + } + _impl_.reason_.SetAllocated(reason, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.reason_.IsDefault()) { + _impl_.reason_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.Status.reason) +} + +// int32 code = 3; +inline void Status::clear_code() { + _impl_.code_ = 0; +} +inline int32_t Status::_internal_code() const { + return _impl_.code_; +} +inline int32_t Status::code() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.Status.code) + return _internal_code(); +} +inline void Status::_internal_set_code(int32_t value) { + + _impl_.code_ = value; +} +inline void Status::set_code(int32_t value) { + _internal_set_code(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.Status.code) +} + +// ------------------------------------------------------------------- + +// KeyValuePair + +// string key = 1; +inline void KeyValuePair::clear_key() { + _impl_.key_.ClearToEmpty(); +} +inline const std::string& KeyValuePair::key() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.KeyValuePair.key) + return _internal_key(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void KeyValuePair::set_key(ArgT0&& arg0, ArgT... args) { + + _impl_.key_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.KeyValuePair.key) +} +inline std::string* KeyValuePair::mutable_key() { + std::string* _s = _internal_mutable_key(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyValuePair.key) + return _s; +} +inline const std::string& KeyValuePair::_internal_key() const { + return _impl_.key_.Get(); +} +inline void KeyValuePair::_internal_set_key(const std::string& value) { + + _impl_.key_.Set(value, GetArenaForAllocation()); +} +inline std::string* KeyValuePair::_internal_mutable_key() { + + return _impl_.key_.Mutable(GetArenaForAllocation()); +} +inline std::string* KeyValuePair::release_key() { + // @@protoc_insertion_point(field_release:milvus.proto.common.KeyValuePair.key) + return _impl_.key_.Release(); +} +inline void KeyValuePair::set_allocated_key(std::string* key) { + if (key != nullptr) { + + } else { + + } + _impl_.key_.SetAllocated(key, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.key_.IsDefault()) { + _impl_.key_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyValuePair.key) +} + +// string value = 2; +inline void KeyValuePair::clear_value() { + _impl_.value_.ClearToEmpty(); +} +inline const std::string& KeyValuePair::value() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.KeyValuePair.value) + return _internal_value(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void KeyValuePair::set_value(ArgT0&& arg0, ArgT... args) { + + _impl_.value_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.KeyValuePair.value) +} +inline std::string* KeyValuePair::mutable_value() { + std::string* _s = _internal_mutable_value(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyValuePair.value) + return _s; +} +inline const std::string& KeyValuePair::_internal_value() const { + return _impl_.value_.Get(); +} +inline void KeyValuePair::_internal_set_value(const std::string& value) { + + _impl_.value_.Set(value, GetArenaForAllocation()); +} +inline std::string* KeyValuePair::_internal_mutable_value() { + + return _impl_.value_.Mutable(GetArenaForAllocation()); +} +inline std::string* KeyValuePair::release_value() { + // @@protoc_insertion_point(field_release:milvus.proto.common.KeyValuePair.value) + return _impl_.value_.Release(); +} +inline void KeyValuePair::set_allocated_value(std::string* value) { + if (value != nullptr) { + + } else { + + } + _impl_.value_.SetAllocated(value, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.value_.IsDefault()) { + _impl_.value_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyValuePair.value) +} + +// ------------------------------------------------------------------- + +// KeyDataPair + +// string key = 1; +inline void KeyDataPair::clear_key() { + _impl_.key_.ClearToEmpty(); +} +inline const std::string& KeyDataPair::key() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.KeyDataPair.key) + return _internal_key(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void KeyDataPair::set_key(ArgT0&& arg0, ArgT... args) { + + _impl_.key_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.KeyDataPair.key) +} +inline std::string* KeyDataPair::mutable_key() { + std::string* _s = _internal_mutable_key(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyDataPair.key) + return _s; } -inline ::milvus::proto::common::ErrorCode Status::error_code() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.Status.error_code) - return _internal_error_code(); +inline const std::string& KeyDataPair::_internal_key() const { + return _impl_.key_.Get(); } -inline void Status::_internal_set_error_code(::milvus::proto::common::ErrorCode value) { +inline void KeyDataPair::_internal_set_key(const std::string& value) { - _impl_.error_code_ = value; + _impl_.key_.Set(value, GetArenaForAllocation()); } -inline void Status::set_error_code(::milvus::proto::common::ErrorCode value) { - _internal_set_error_code(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.Status.error_code) +inline std::string* KeyDataPair::_internal_mutable_key() { + + return _impl_.key_.Mutable(GetArenaForAllocation()); +} +inline std::string* KeyDataPair::release_key() { + // @@protoc_insertion_point(field_release:milvus.proto.common.KeyDataPair.key) + return _impl_.key_.Release(); +} +inline void KeyDataPair::set_allocated_key(std::string* key) { + if (key != nullptr) { + + } else { + + } + _impl_.key_.SetAllocated(key, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.key_.IsDefault()) { + _impl_.key_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyDataPair.key) } -// string reason = 2; -inline void Status::clear_reason() { - _impl_.reason_.ClearToEmpty(); +// bytes data = 2; +inline void KeyDataPair::clear_data() { + _impl_.data_.ClearToEmpty(); } -inline const std::string& Status::reason() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.Status.reason) - return _internal_reason(); +inline const std::string& KeyDataPair::data() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.KeyDataPair.data) + return _internal_data(); } template inline PROTOBUF_ALWAYS_INLINE -void Status::set_reason(ArgT0&& arg0, ArgT... args) { +void KeyDataPair::set_data(ArgT0&& arg0, ArgT... args) { - _impl_.reason_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.Status.reason) + _impl_.data_.SetBytes(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.KeyDataPair.data) } -inline std::string* Status::mutable_reason() { - std::string* _s = _internal_mutable_reason(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.Status.reason) +inline std::string* KeyDataPair::mutable_data() { + std::string* _s = _internal_mutable_data(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyDataPair.data) return _s; } -inline const std::string& Status::_internal_reason() const { - return _impl_.reason_.Get(); +inline const std::string& KeyDataPair::_internal_data() const { + return _impl_.data_.Get(); } -inline void Status::_internal_set_reason(const std::string& value) { +inline void KeyDataPair::_internal_set_data(const std::string& value) { - _impl_.reason_.Set(value, GetArenaForAllocation()); + _impl_.data_.Set(value, GetArenaForAllocation()); } -inline std::string* Status::_internal_mutable_reason() { +inline std::string* KeyDataPair::_internal_mutable_data() { - return _impl_.reason_.Mutable(GetArenaForAllocation()); + return _impl_.data_.Mutable(GetArenaForAllocation()); } -inline std::string* Status::release_reason() { - // @@protoc_insertion_point(field_release:milvus.proto.common.Status.reason) - return _impl_.reason_.Release(); +inline std::string* KeyDataPair::release_data() { + // @@protoc_insertion_point(field_release:milvus.proto.common.KeyDataPair.data) + return _impl_.data_.Release(); } -inline void Status::set_allocated_reason(std::string* reason) { - if (reason != nullptr) { +inline void KeyDataPair::set_allocated_data(std::string* data) { + if (data != nullptr) { } else { } - _impl_.reason_.SetAllocated(reason, GetArenaForAllocation()); + _impl_.data_.SetAllocated(data, GetArenaForAllocation()); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.reason_.IsDefault()) { - _impl_.reason_.Set("", GetArenaForAllocation()); + if (_impl_.data_.IsDefault()) { + _impl_.data_.Set("", GetArenaForAllocation()); } #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.Status.reason) + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyDataPair.data) } -// int32 code = 3; -inline void Status::clear_code() { - _impl_.code_ = 0; +// ------------------------------------------------------------------- + +// Blob + +// bytes value = 1; +inline void Blob::clear_value() { + _impl_.value_.ClearToEmpty(); } -inline int32_t Status::_internal_code() const { - return _impl_.code_; +inline const std::string& Blob::value() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.Blob.value) + return _internal_value(); } -inline int32_t Status::code() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.Status.code) - return _internal_code(); +template +inline PROTOBUF_ALWAYS_INLINE +void Blob::set_value(ArgT0&& arg0, ArgT... args) { + + _impl_.value_.SetBytes(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.Blob.value) } -inline void Status::_internal_set_code(int32_t value) { +inline std::string* Blob::mutable_value() { + std::string* _s = _internal_mutable_value(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.Blob.value) + return _s; +} +inline const std::string& Blob::_internal_value() const { + return _impl_.value_.Get(); +} +inline void Blob::_internal_set_value(const std::string& value) { - _impl_.code_ = value; + _impl_.value_.Set(value, GetArenaForAllocation()); } -inline void Status::set_code(int32_t value) { - _internal_set_code(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.Status.code) +inline std::string* Blob::_internal_mutable_value() { + + return _impl_.value_.Mutable(GetArenaForAllocation()); +} +inline std::string* Blob::release_value() { + // @@protoc_insertion_point(field_release:milvus.proto.common.Blob.value) + return _impl_.value_.Release(); +} +inline void Blob::set_allocated_value(std::string* value) { + if (value != nullptr) { + + } else { + + } + _impl_.value_.SetAllocated(value, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.value_.IsDefault()) { + _impl_.value_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.Blob.value) } // ------------------------------------------------------------------- -// KeyValuePair +// PlaceholderValue -// string key = 1; -inline void KeyValuePair::clear_key() { - _impl_.key_.ClearToEmpty(); +// string tag = 1; +inline void PlaceholderValue::clear_tag() { + _impl_.tag_.ClearToEmpty(); } -inline const std::string& KeyValuePair::key() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.KeyValuePair.key) - return _internal_key(); +inline const std::string& PlaceholderValue::tag() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderValue.tag) + return _internal_tag(); } template inline PROTOBUF_ALWAYS_INLINE -void KeyValuePair::set_key(ArgT0&& arg0, ArgT... args) { +void PlaceholderValue::set_tag(ArgT0&& arg0, ArgT... args) { - _impl_.key_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.KeyValuePair.key) + _impl_.tag_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.tag) } -inline std::string* KeyValuePair::mutable_key() { - std::string* _s = _internal_mutable_key(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyValuePair.key) +inline std::string* PlaceholderValue::mutable_tag() { + std::string* _s = _internal_mutable_tag(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.PlaceholderValue.tag) return _s; } -inline const std::string& KeyValuePair::_internal_key() const { - return _impl_.key_.Get(); +inline const std::string& PlaceholderValue::_internal_tag() const { + return _impl_.tag_.Get(); } -inline void KeyValuePair::_internal_set_key(const std::string& value) { +inline void PlaceholderValue::_internal_set_tag(const std::string& value) { - _impl_.key_.Set(value, GetArenaForAllocation()); + _impl_.tag_.Set(value, GetArenaForAllocation()); } -inline std::string* KeyValuePair::_internal_mutable_key() { +inline std::string* PlaceholderValue::_internal_mutable_tag() { - return _impl_.key_.Mutable(GetArenaForAllocation()); + return _impl_.tag_.Mutable(GetArenaForAllocation()); } -inline std::string* KeyValuePair::release_key() { - // @@protoc_insertion_point(field_release:milvus.proto.common.KeyValuePair.key) - return _impl_.key_.Release(); +inline std::string* PlaceholderValue::release_tag() { + // @@protoc_insertion_point(field_release:milvus.proto.common.PlaceholderValue.tag) + return _impl_.tag_.Release(); } -inline void KeyValuePair::set_allocated_key(std::string* key) { - if (key != nullptr) { +inline void PlaceholderValue::set_allocated_tag(std::string* tag) { + if (tag != nullptr) { } else { } - _impl_.key_.SetAllocated(key, GetArenaForAllocation()); + _impl_.tag_.SetAllocated(tag, GetArenaForAllocation()); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.key_.IsDefault()) { - _impl_.key_.Set("", GetArenaForAllocation()); + if (_impl_.tag_.IsDefault()) { + _impl_.tag_.Set("", GetArenaForAllocation()); } #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyValuePair.key) + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.PlaceholderValue.tag) +} + +// .milvus.proto.common.PlaceholderType type = 2; +inline void PlaceholderValue::clear_type() { + _impl_.type_ = 0; +} +inline ::milvus::proto::common::PlaceholderType PlaceholderValue::_internal_type() const { + return static_cast< ::milvus::proto::common::PlaceholderType >(_impl_.type_); +} +inline ::milvus::proto::common::PlaceholderType PlaceholderValue::type() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderValue.type) + return _internal_type(); +} +inline void PlaceholderValue::_internal_set_type(::milvus::proto::common::PlaceholderType value) { + + _impl_.type_ = value; +} +inline void PlaceholderValue::set_type(::milvus::proto::common::PlaceholderType value) { + _internal_set_type(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.type) +} + +// repeated bytes values = 3; +inline int PlaceholderValue::_internal_values_size() const { + return _impl_.values_.size(); +} +inline int PlaceholderValue::values_size() const { + return _internal_values_size(); +} +inline void PlaceholderValue::clear_values() { + _impl_.values_.Clear(); +} +inline std::string* PlaceholderValue::add_values() { + std::string* _s = _internal_add_values(); + // @@protoc_insertion_point(field_add_mutable:milvus.proto.common.PlaceholderValue.values) + return _s; +} +inline const std::string& PlaceholderValue::_internal_values(int index) const { + return _impl_.values_.Get(index); +} +inline const std::string& PlaceholderValue::values(int index) const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderValue.values) + return _internal_values(index); +} +inline std::string* PlaceholderValue::mutable_values(int index) { + // @@protoc_insertion_point(field_mutable:milvus.proto.common.PlaceholderValue.values) + return _impl_.values_.Mutable(index); } - -// string value = 2; -inline void KeyValuePair::clear_value() { - _impl_.value_.ClearToEmpty(); +inline void PlaceholderValue::set_values(int index, const std::string& value) { + _impl_.values_.Mutable(index)->assign(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.values) } -inline const std::string& KeyValuePair::value() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.KeyValuePair.value) - return _internal_value(); +inline void PlaceholderValue::set_values(int index, std::string&& value) { + _impl_.values_.Mutable(index)->assign(std::move(value)); + // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.values) } -template -inline PROTOBUF_ALWAYS_INLINE -void KeyValuePair::set_value(ArgT0&& arg0, ArgT... args) { - - _impl_.value_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.KeyValuePair.value) +inline void PlaceholderValue::set_values(int index, const char* value) { + GOOGLE_DCHECK(value != nullptr); + _impl_.values_.Mutable(index)->assign(value); + // @@protoc_insertion_point(field_set_char:milvus.proto.common.PlaceholderValue.values) } -inline std::string* KeyValuePair::mutable_value() { - std::string* _s = _internal_mutable_value(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyValuePair.value) - return _s; +inline void PlaceholderValue::set_values(int index, const void* value, size_t size) { + _impl_.values_.Mutable(index)->assign( + reinterpret_cast(value), size); + // @@protoc_insertion_point(field_set_pointer:milvus.proto.common.PlaceholderValue.values) } -inline const std::string& KeyValuePair::_internal_value() const { - return _impl_.value_.Get(); +inline std::string* PlaceholderValue::_internal_add_values() { + return _impl_.values_.Add(); } -inline void KeyValuePair::_internal_set_value(const std::string& value) { - - _impl_.value_.Set(value, GetArenaForAllocation()); +inline void PlaceholderValue::add_values(const std::string& value) { + _impl_.values_.Add()->assign(value); + // @@protoc_insertion_point(field_add:milvus.proto.common.PlaceholderValue.values) } -inline std::string* KeyValuePair::_internal_mutable_value() { - - return _impl_.value_.Mutable(GetArenaForAllocation()); +inline void PlaceholderValue::add_values(std::string&& value) { + _impl_.values_.Add(std::move(value)); + // @@protoc_insertion_point(field_add:milvus.proto.common.PlaceholderValue.values) } -inline std::string* KeyValuePair::release_value() { - // @@protoc_insertion_point(field_release:milvus.proto.common.KeyValuePair.value) - return _impl_.value_.Release(); +inline void PlaceholderValue::add_values(const char* value) { + GOOGLE_DCHECK(value != nullptr); + _impl_.values_.Add()->assign(value); + // @@protoc_insertion_point(field_add_char:milvus.proto.common.PlaceholderValue.values) } -inline void KeyValuePair::set_allocated_value(std::string* value) { - if (value != nullptr) { - - } else { - - } - _impl_.value_.SetAllocated(value, GetArenaForAllocation()); -#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.value_.IsDefault()) { - _impl_.value_.Set("", GetArenaForAllocation()); - } -#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyValuePair.value) +inline void PlaceholderValue::add_values(const void* value, size_t size) { + _impl_.values_.Add()->assign(reinterpret_cast(value), size); + // @@protoc_insertion_point(field_add_pointer:milvus.proto.common.PlaceholderValue.values) +} +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField& +PlaceholderValue::values() const { + // @@protoc_insertion_point(field_list:milvus.proto.common.PlaceholderValue.values) + return _impl_.values_; +} +inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField* +PlaceholderValue::mutable_values() { + // @@protoc_insertion_point(field_mutable_list:milvus.proto.common.PlaceholderValue.values) + return &_impl_.values_; } // ------------------------------------------------------------------- -// KeyDataPair +// PlaceholderGroup -// string key = 1; -inline void KeyDataPair::clear_key() { - _impl_.key_.ClearToEmpty(); +// repeated .milvus.proto.common.PlaceholderValue placeholders = 1; +inline int PlaceholderGroup::_internal_placeholders_size() const { + return _impl_.placeholders_.size(); } -inline const std::string& KeyDataPair::key() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.KeyDataPair.key) - return _internal_key(); +inline int PlaceholderGroup::placeholders_size() const { + return _internal_placeholders_size(); } -template -inline PROTOBUF_ALWAYS_INLINE -void KeyDataPair::set_key(ArgT0&& arg0, ArgT... args) { - - _impl_.key_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.KeyDataPair.key) +inline void PlaceholderGroup::clear_placeholders() { + _impl_.placeholders_.Clear(); } -inline std::string* KeyDataPair::mutable_key() { - std::string* _s = _internal_mutable_key(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyDataPair.key) - return _s; +inline ::milvus::proto::common::PlaceholderValue* PlaceholderGroup::mutable_placeholders(int index) { + // @@protoc_insertion_point(field_mutable:milvus.proto.common.PlaceholderGroup.placeholders) + return _impl_.placeholders_.Mutable(index); } -inline const std::string& KeyDataPair::_internal_key() const { - return _impl_.key_.Get(); +inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::common::PlaceholderValue >* +PlaceholderGroup::mutable_placeholders() { + // @@protoc_insertion_point(field_mutable_list:milvus.proto.common.PlaceholderGroup.placeholders) + return &_impl_.placeholders_; } -inline void KeyDataPair::_internal_set_key(const std::string& value) { - - _impl_.key_.Set(value, GetArenaForAllocation()); +inline const ::milvus::proto::common::PlaceholderValue& PlaceholderGroup::_internal_placeholders(int index) const { + return _impl_.placeholders_.Get(index); } -inline std::string* KeyDataPair::_internal_mutable_key() { - - return _impl_.key_.Mutable(GetArenaForAllocation()); +inline const ::milvus::proto::common::PlaceholderValue& PlaceholderGroup::placeholders(int index) const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderGroup.placeholders) + return _internal_placeholders(index); } -inline std::string* KeyDataPair::release_key() { - // @@protoc_insertion_point(field_release:milvus.proto.common.KeyDataPair.key) - return _impl_.key_.Release(); +inline ::milvus::proto::common::PlaceholderValue* PlaceholderGroup::_internal_add_placeholders() { + return _impl_.placeholders_.Add(); } -inline void KeyDataPair::set_allocated_key(std::string* key) { - if (key != nullptr) { - - } else { - - } - _impl_.key_.SetAllocated(key, GetArenaForAllocation()); -#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.key_.IsDefault()) { - _impl_.key_.Set("", GetArenaForAllocation()); - } -#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyDataPair.key) +inline ::milvus::proto::common::PlaceholderValue* PlaceholderGroup::add_placeholders() { + ::milvus::proto::common::PlaceholderValue* _add = _internal_add_placeholders(); + // @@protoc_insertion_point(field_add:milvus.proto.common.PlaceholderGroup.placeholders) + return _add; +} +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::common::PlaceholderValue >& +PlaceholderGroup::placeholders() const { + // @@protoc_insertion_point(field_list:milvus.proto.common.PlaceholderGroup.placeholders) + return _impl_.placeholders_; } -// bytes data = 2; -inline void KeyDataPair::clear_data() { - _impl_.data_.ClearToEmpty(); +// ------------------------------------------------------------------- + +// Address + +// string ip = 1; +inline void Address::clear_ip() { + _impl_.ip_.ClearToEmpty(); } -inline const std::string& KeyDataPair::data() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.KeyDataPair.data) - return _internal_data(); +inline const std::string& Address::ip() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.Address.ip) + return _internal_ip(); } template inline PROTOBUF_ALWAYS_INLINE -void KeyDataPair::set_data(ArgT0&& arg0, ArgT... args) { +void Address::set_ip(ArgT0&& arg0, ArgT... args) { - _impl_.data_.SetBytes(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.KeyDataPair.data) + _impl_.ip_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.Address.ip) } -inline std::string* KeyDataPair::mutable_data() { - std::string* _s = _internal_mutable_data(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.KeyDataPair.data) +inline std::string* Address::mutable_ip() { + std::string* _s = _internal_mutable_ip(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.Address.ip) return _s; } -inline const std::string& KeyDataPair::_internal_data() const { - return _impl_.data_.Get(); +inline const std::string& Address::_internal_ip() const { + return _impl_.ip_.Get(); } -inline void KeyDataPair::_internal_set_data(const std::string& value) { +inline void Address::_internal_set_ip(const std::string& value) { - _impl_.data_.Set(value, GetArenaForAllocation()); + _impl_.ip_.Set(value, GetArenaForAllocation()); } -inline std::string* KeyDataPair::_internal_mutable_data() { +inline std::string* Address::_internal_mutable_ip() { - return _impl_.data_.Mutable(GetArenaForAllocation()); + return _impl_.ip_.Mutable(GetArenaForAllocation()); } -inline std::string* KeyDataPair::release_data() { - // @@protoc_insertion_point(field_release:milvus.proto.common.KeyDataPair.data) - return _impl_.data_.Release(); +inline std::string* Address::release_ip() { + // @@protoc_insertion_point(field_release:milvus.proto.common.Address.ip) + return _impl_.ip_.Release(); } -inline void KeyDataPair::set_allocated_data(std::string* data) { - if (data != nullptr) { +inline void Address::set_allocated_ip(std::string* ip) { + if (ip != nullptr) { } else { } - _impl_.data_.SetAllocated(data, GetArenaForAllocation()); + _impl_.ip_.SetAllocated(ip, GetArenaForAllocation()); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.data_.IsDefault()) { - _impl_.data_.Set("", GetArenaForAllocation()); + if (_impl_.ip_.IsDefault()) { + _impl_.ip_.Set("", GetArenaForAllocation()); } #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.KeyDataPair.data) + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.Address.ip) } -// ------------------------------------------------------------------- - -// Blob - -// bytes value = 1; -inline void Blob::clear_value() { - _impl_.value_.ClearToEmpty(); -} -inline const std::string& Blob::value() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.Blob.value) - return _internal_value(); -} -template -inline PROTOBUF_ALWAYS_INLINE -void Blob::set_value(ArgT0&& arg0, ArgT... args) { - - _impl_.value_.SetBytes(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.Blob.value) -} -inline std::string* Blob::mutable_value() { - std::string* _s = _internal_mutable_value(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.Blob.value) - return _s; +// int64 port = 2; +inline void Address::clear_port() { + _impl_.port_ = int64_t{0}; } -inline const std::string& Blob::_internal_value() const { - return _impl_.value_.Get(); +inline int64_t Address::_internal_port() const { + return _impl_.port_; } -inline void Blob::_internal_set_value(const std::string& value) { - - _impl_.value_.Set(value, GetArenaForAllocation()); +inline int64_t Address::port() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.Address.port) + return _internal_port(); } -inline std::string* Blob::_internal_mutable_value() { +inline void Address::_internal_set_port(int64_t value) { - return _impl_.value_.Mutable(GetArenaForAllocation()); -} -inline std::string* Blob::release_value() { - // @@protoc_insertion_point(field_release:milvus.proto.common.Blob.value) - return _impl_.value_.Release(); + _impl_.port_ = value; } -inline void Blob::set_allocated_value(std::string* value) { - if (value != nullptr) { - - } else { - - } - _impl_.value_.SetAllocated(value, GetArenaForAllocation()); -#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.value_.IsDefault()) { - _impl_.value_.Set("", GetArenaForAllocation()); - } -#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.Blob.value) +inline void Address::set_port(int64_t value) { + _internal_set_port(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.Address.port) } // ------------------------------------------------------------------- -// PlaceholderValue +// MsgBase -// string tag = 1; -inline void PlaceholderValue::clear_tag() { - _impl_.tag_.ClearToEmpty(); +// .milvus.proto.common.MsgType msg_type = 1; +inline void MsgBase::clear_msg_type() { + _impl_.msg_type_ = 0; } -inline const std::string& PlaceholderValue::tag() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderValue.tag) - return _internal_tag(); +inline ::milvus::proto::common::MsgType MsgBase::_internal_msg_type() const { + return static_cast< ::milvus::proto::common::MsgType >(_impl_.msg_type_); } -template -inline PROTOBUF_ALWAYS_INLINE -void PlaceholderValue::set_tag(ArgT0&& arg0, ArgT... args) { - - _impl_.tag_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.tag) +inline ::milvus::proto::common::MsgType MsgBase::msg_type() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.msg_type) + return _internal_msg_type(); } -inline std::string* PlaceholderValue::mutable_tag() { - std::string* _s = _internal_mutable_tag(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.PlaceholderValue.tag) - return _s; +inline void MsgBase::_internal_set_msg_type(::milvus::proto::common::MsgType value) { + + _impl_.msg_type_ = value; } -inline const std::string& PlaceholderValue::_internal_tag() const { - return _impl_.tag_.Get(); +inline void MsgBase::set_msg_type(::milvus::proto::common::MsgType value) { + _internal_set_msg_type(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.msg_type) } -inline void PlaceholderValue::_internal_set_tag(const std::string& value) { - - _impl_.tag_.Set(value, GetArenaForAllocation()); + +// int64 msgID = 2; +inline void MsgBase::clear_msgid() { + _impl_.msgid_ = int64_t{0}; } -inline std::string* PlaceholderValue::_internal_mutable_tag() { - - return _impl_.tag_.Mutable(GetArenaForAllocation()); +inline int64_t MsgBase::_internal_msgid() const { + return _impl_.msgid_; } -inline std::string* PlaceholderValue::release_tag() { - // @@protoc_insertion_point(field_release:milvus.proto.common.PlaceholderValue.tag) - return _impl_.tag_.Release(); +inline int64_t MsgBase::msgid() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.msgID) + return _internal_msgid(); } -inline void PlaceholderValue::set_allocated_tag(std::string* tag) { - if (tag != nullptr) { - - } else { - - } - _impl_.tag_.SetAllocated(tag, GetArenaForAllocation()); -#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.tag_.IsDefault()) { - _impl_.tag_.Set("", GetArenaForAllocation()); - } -#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.PlaceholderValue.tag) +inline void MsgBase::_internal_set_msgid(int64_t value) { + + _impl_.msgid_ = value; +} +inline void MsgBase::set_msgid(int64_t value) { + _internal_set_msgid(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.msgID) } -// .milvus.proto.common.PlaceholderType type = 2; -inline void PlaceholderValue::clear_type() { - _impl_.type_ = 0; +// uint64 timestamp = 3; +inline void MsgBase::clear_timestamp() { + _impl_.timestamp_ = uint64_t{0u}; } -inline ::milvus::proto::common::PlaceholderType PlaceholderValue::_internal_type() const { - return static_cast< ::milvus::proto::common::PlaceholderType >(_impl_.type_); +inline uint64_t MsgBase::_internal_timestamp() const { + return _impl_.timestamp_; } -inline ::milvus::proto::common::PlaceholderType PlaceholderValue::type() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderValue.type) - return _internal_type(); +inline uint64_t MsgBase::timestamp() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.timestamp) + return _internal_timestamp(); } -inline void PlaceholderValue::_internal_set_type(::milvus::proto::common::PlaceholderType value) { +inline void MsgBase::_internal_set_timestamp(uint64_t value) { - _impl_.type_ = value; + _impl_.timestamp_ = value; } -inline void PlaceholderValue::set_type(::milvus::proto::common::PlaceholderType value) { - _internal_set_type(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.type) +inline void MsgBase::set_timestamp(uint64_t value) { + _internal_set_timestamp(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.timestamp) } -// repeated bytes values = 3; -inline int PlaceholderValue::_internal_values_size() const { - return _impl_.values_.size(); +// int64 sourceID = 4; +inline void MsgBase::clear_sourceid() { + _impl_.sourceid_ = int64_t{0}; } -inline int PlaceholderValue::values_size() const { - return _internal_values_size(); +inline int64_t MsgBase::_internal_sourceid() const { + return _impl_.sourceid_; } -inline void PlaceholderValue::clear_values() { - _impl_.values_.Clear(); +inline int64_t MsgBase::sourceid() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.sourceID) + return _internal_sourceid(); } -inline std::string* PlaceholderValue::add_values() { - std::string* _s = _internal_add_values(); - // @@protoc_insertion_point(field_add_mutable:milvus.proto.common.PlaceholderValue.values) - return _s; +inline void MsgBase::_internal_set_sourceid(int64_t value) { + + _impl_.sourceid_ = value; } -inline const std::string& PlaceholderValue::_internal_values(int index) const { - return _impl_.values_.Get(index); +inline void MsgBase::set_sourceid(int64_t value) { + _internal_set_sourceid(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.sourceID) } -inline const std::string& PlaceholderValue::values(int index) const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderValue.values) - return _internal_values(index); + +// int64 targetID = 5; +inline void MsgBase::clear_targetid() { + _impl_.targetid_ = int64_t{0}; } -inline std::string* PlaceholderValue::mutable_values(int index) { - // @@protoc_insertion_point(field_mutable:milvus.proto.common.PlaceholderValue.values) - return _impl_.values_.Mutable(index); +inline int64_t MsgBase::_internal_targetid() const { + return _impl_.targetid_; } -inline void PlaceholderValue::set_values(int index, const std::string& value) { - _impl_.values_.Mutable(index)->assign(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.values) +inline int64_t MsgBase::targetid() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.targetID) + return _internal_targetid(); } -inline void PlaceholderValue::set_values(int index, std::string&& value) { - _impl_.values_.Mutable(index)->assign(std::move(value)); - // @@protoc_insertion_point(field_set:milvus.proto.common.PlaceholderValue.values) +inline void MsgBase::_internal_set_targetid(int64_t value) { + + _impl_.targetid_ = value; } -inline void PlaceholderValue::set_values(int index, const char* value) { - GOOGLE_DCHECK(value != nullptr); - _impl_.values_.Mutable(index)->assign(value); - // @@protoc_insertion_point(field_set_char:milvus.proto.common.PlaceholderValue.values) +inline void MsgBase::set_targetid(int64_t value) { + _internal_set_targetid(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.targetID) } -inline void PlaceholderValue::set_values(int index, const void* value, size_t size) { - _impl_.values_.Mutable(index)->assign( - reinterpret_cast(value), size); - // @@protoc_insertion_point(field_set_pointer:milvus.proto.common.PlaceholderValue.values) + +// ------------------------------------------------------------------- + +// MsgHeader + +// .milvus.proto.common.MsgBase base = 1; +inline bool MsgHeader::_internal_has_base() const { + return this != internal_default_instance() && _impl_.base_ != nullptr; } -inline std::string* PlaceholderValue::_internal_add_values() { - return _impl_.values_.Add(); +inline bool MsgHeader::has_base() const { + return _internal_has_base(); } -inline void PlaceholderValue::add_values(const std::string& value) { - _impl_.values_.Add()->assign(value); - // @@protoc_insertion_point(field_add:milvus.proto.common.PlaceholderValue.values) +inline void MsgHeader::clear_base() { + if (GetArenaForAllocation() == nullptr && _impl_.base_ != nullptr) { + delete _impl_.base_; + } + _impl_.base_ = nullptr; } -inline void PlaceholderValue::add_values(std::string&& value) { - _impl_.values_.Add(std::move(value)); - // @@protoc_insertion_point(field_add:milvus.proto.common.PlaceholderValue.values) +inline const ::milvus::proto::common::MsgBase& MsgHeader::_internal_base() const { + const ::milvus::proto::common::MsgBase* p = _impl_.base_; + return p != nullptr ? *p : reinterpret_cast( + ::milvus::proto::common::_MsgBase_default_instance_); } -inline void PlaceholderValue::add_values(const char* value) { - GOOGLE_DCHECK(value != nullptr); - _impl_.values_.Add()->assign(value); - // @@protoc_insertion_point(field_add_char:milvus.proto.common.PlaceholderValue.values) +inline const ::milvus::proto::common::MsgBase& MsgHeader::base() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.MsgHeader.base) + return _internal_base(); } -inline void PlaceholderValue::add_values(const void* value, size_t size) { - _impl_.values_.Add()->assign(reinterpret_cast(value), size); - // @@protoc_insertion_point(field_add_pointer:milvus.proto.common.PlaceholderValue.values) +inline void MsgHeader::unsafe_arena_set_allocated_base( + ::milvus::proto::common::MsgBase* base) { + if (GetArenaForAllocation() == nullptr) { + delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.base_); + } + _impl_.base_ = base; + if (base) { + + } else { + + } + // @@protoc_insertion_point(field_unsafe_arena_set_allocated:milvus.proto.common.MsgHeader.base) +} +inline ::milvus::proto::common::MsgBase* MsgHeader::release_base() { + + ::milvus::proto::common::MsgBase* temp = _impl_.base_; + _impl_.base_ = nullptr; +#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE + auto* old = reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp); + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + if (GetArenaForAllocation() == nullptr) { delete old; } +#else // PROTOBUF_FORCE_COPY_IN_RELEASE + if (GetArenaForAllocation() != nullptr) { + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + } +#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE + return temp; +} +inline ::milvus::proto::common::MsgBase* MsgHeader::unsafe_arena_release_base() { + // @@protoc_insertion_point(field_release:milvus.proto.common.MsgHeader.base) + + ::milvus::proto::common::MsgBase* temp = _impl_.base_; + _impl_.base_ = nullptr; + return temp; +} +inline ::milvus::proto::common::MsgBase* MsgHeader::_internal_mutable_base() { + + if (_impl_.base_ == nullptr) { + auto* p = CreateMaybeMessage<::milvus::proto::common::MsgBase>(GetArenaForAllocation()); + _impl_.base_ = p; + } + return _impl_.base_; } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField& -PlaceholderValue::values() const { - // @@protoc_insertion_point(field_list:milvus.proto.common.PlaceholderValue.values) - return _impl_.values_; +inline ::milvus::proto::common::MsgBase* MsgHeader::mutable_base() { + ::milvus::proto::common::MsgBase* _msg = _internal_mutable_base(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.MsgHeader.base) + return _msg; } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField* -PlaceholderValue::mutable_values() { - // @@protoc_insertion_point(field_mutable_list:milvus.proto.common.PlaceholderValue.values) - return &_impl_.values_; +inline void MsgHeader::set_allocated_base(::milvus::proto::common::MsgBase* base) { + ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); + if (message_arena == nullptr) { + delete _impl_.base_; + } + if (base) { + ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = + ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(base); + if (message_arena != submessage_arena) { + base = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( + message_arena, base, submessage_arena); + } + + } else { + + } + _impl_.base_ = base; + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.MsgHeader.base) } // ------------------------------------------------------------------- -// PlaceholderGroup +// DMLMsgHeader -// repeated .milvus.proto.common.PlaceholderValue placeholders = 1; -inline int PlaceholderGroup::_internal_placeholders_size() const { - return _impl_.placeholders_.size(); +// .milvus.proto.common.MsgBase base = 1; +inline bool DMLMsgHeader::_internal_has_base() const { + return this != internal_default_instance() && _impl_.base_ != nullptr; } -inline int PlaceholderGroup::placeholders_size() const { - return _internal_placeholders_size(); +inline bool DMLMsgHeader::has_base() const { + return _internal_has_base(); } -inline void PlaceholderGroup::clear_placeholders() { - _impl_.placeholders_.Clear(); +inline void DMLMsgHeader::clear_base() { + if (GetArenaForAllocation() == nullptr && _impl_.base_ != nullptr) { + delete _impl_.base_; + } + _impl_.base_ = nullptr; } -inline ::milvus::proto::common::PlaceholderValue* PlaceholderGroup::mutable_placeholders(int index) { - // @@protoc_insertion_point(field_mutable:milvus.proto.common.PlaceholderGroup.placeholders) - return _impl_.placeholders_.Mutable(index); +inline const ::milvus::proto::common::MsgBase& DMLMsgHeader::_internal_base() const { + const ::milvus::proto::common::MsgBase* p = _impl_.base_; + return p != nullptr ? *p : reinterpret_cast( + ::milvus::proto::common::_MsgBase_default_instance_); } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::common::PlaceholderValue >* -PlaceholderGroup::mutable_placeholders() { - // @@protoc_insertion_point(field_mutable_list:milvus.proto.common.PlaceholderGroup.placeholders) - return &_impl_.placeholders_; +inline const ::milvus::proto::common::MsgBase& DMLMsgHeader::base() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.DMLMsgHeader.base) + return _internal_base(); } -inline const ::milvus::proto::common::PlaceholderValue& PlaceholderGroup::_internal_placeholders(int index) const { - return _impl_.placeholders_.Get(index); +inline void DMLMsgHeader::unsafe_arena_set_allocated_base( + ::milvus::proto::common::MsgBase* base) { + if (GetArenaForAllocation() == nullptr) { + delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.base_); + } + _impl_.base_ = base; + if (base) { + + } else { + + } + // @@protoc_insertion_point(field_unsafe_arena_set_allocated:milvus.proto.common.DMLMsgHeader.base) } -inline const ::milvus::proto::common::PlaceholderValue& PlaceholderGroup::placeholders(int index) const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PlaceholderGroup.placeholders) - return _internal_placeholders(index); +inline ::milvus::proto::common::MsgBase* DMLMsgHeader::release_base() { + + ::milvus::proto::common::MsgBase* temp = _impl_.base_; + _impl_.base_ = nullptr; +#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE + auto* old = reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp); + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + if (GetArenaForAllocation() == nullptr) { delete old; } +#else // PROTOBUF_FORCE_COPY_IN_RELEASE + if (GetArenaForAllocation() != nullptr) { + temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + } +#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE + return temp; } -inline ::milvus::proto::common::PlaceholderValue* PlaceholderGroup::_internal_add_placeholders() { - return _impl_.placeholders_.Add(); +inline ::milvus::proto::common::MsgBase* DMLMsgHeader::unsafe_arena_release_base() { + // @@protoc_insertion_point(field_release:milvus.proto.common.DMLMsgHeader.base) + + ::milvus::proto::common::MsgBase* temp = _impl_.base_; + _impl_.base_ = nullptr; + return temp; } -inline ::milvus::proto::common::PlaceholderValue* PlaceholderGroup::add_placeholders() { - ::milvus::proto::common::PlaceholderValue* _add = _internal_add_placeholders(); - // @@protoc_insertion_point(field_add:milvus.proto.common.PlaceholderGroup.placeholders) - return _add; +inline ::milvus::proto::common::MsgBase* DMLMsgHeader::_internal_mutable_base() { + + if (_impl_.base_ == nullptr) { + auto* p = CreateMaybeMessage<::milvus::proto::common::MsgBase>(GetArenaForAllocation()); + _impl_.base_ = p; + } + return _impl_.base_; } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::common::PlaceholderValue >& -PlaceholderGroup::placeholders() const { - // @@protoc_insertion_point(field_list:milvus.proto.common.PlaceholderGroup.placeholders) - return _impl_.placeholders_; +inline ::milvus::proto::common::MsgBase* DMLMsgHeader::mutable_base() { + ::milvus::proto::common::MsgBase* _msg = _internal_mutable_base(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.DMLMsgHeader.base) + return _msg; +} +inline void DMLMsgHeader::set_allocated_base(::milvus::proto::common::MsgBase* base) { + ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); + if (message_arena == nullptr) { + delete _impl_.base_; + } + if (base) { + ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = + ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(base); + if (message_arena != submessage_arena) { + base = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( + message_arena, base, submessage_arena); + } + + } else { + + } + _impl_.base_ = base; + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.DMLMsgHeader.base) } -// ------------------------------------------------------------------- - -// Address - -// string ip = 1; -inline void Address::clear_ip() { - _impl_.ip_.ClearToEmpty(); +// string shardName = 2; +inline void DMLMsgHeader::clear_shardname() { + _impl_.shardname_.ClearToEmpty(); } -inline const std::string& Address::ip() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.Address.ip) - return _internal_ip(); +inline const std::string& DMLMsgHeader::shardname() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.DMLMsgHeader.shardName) + return _internal_shardname(); } template inline PROTOBUF_ALWAYS_INLINE -void Address::set_ip(ArgT0&& arg0, ArgT... args) { +void DMLMsgHeader::set_shardname(ArgT0&& arg0, ArgT... args) { - _impl_.ip_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.Address.ip) + _impl_.shardname_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.DMLMsgHeader.shardName) } -inline std::string* Address::mutable_ip() { - std::string* _s = _internal_mutable_ip(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.Address.ip) +inline std::string* DMLMsgHeader::mutable_shardname() { + std::string* _s = _internal_mutable_shardname(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.DMLMsgHeader.shardName) return _s; } -inline const std::string& Address::_internal_ip() const { - return _impl_.ip_.Get(); +inline const std::string& DMLMsgHeader::_internal_shardname() const { + return _impl_.shardname_.Get(); } -inline void Address::_internal_set_ip(const std::string& value) { +inline void DMLMsgHeader::_internal_set_shardname(const std::string& value) { - _impl_.ip_.Set(value, GetArenaForAllocation()); + _impl_.shardname_.Set(value, GetArenaForAllocation()); } -inline std::string* Address::_internal_mutable_ip() { +inline std::string* DMLMsgHeader::_internal_mutable_shardname() { - return _impl_.ip_.Mutable(GetArenaForAllocation()); + return _impl_.shardname_.Mutable(GetArenaForAllocation()); } -inline std::string* Address::release_ip() { - // @@protoc_insertion_point(field_release:milvus.proto.common.Address.ip) - return _impl_.ip_.Release(); +inline std::string* DMLMsgHeader::release_shardname() { + // @@protoc_insertion_point(field_release:milvus.proto.common.DMLMsgHeader.shardName) + return _impl_.shardname_.Release(); } -inline void Address::set_allocated_ip(std::string* ip) { - if (ip != nullptr) { +inline void DMLMsgHeader::set_allocated_shardname(std::string* shardname) { + if (shardname != nullptr) { } else { } - _impl_.ip_.SetAllocated(ip, GetArenaForAllocation()); + _impl_.shardname_.SetAllocated(shardname, GetArenaForAllocation()); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.ip_.IsDefault()) { - _impl_.ip_.Set("", GetArenaForAllocation()); + if (_impl_.shardname_.IsDefault()) { + _impl_.shardname_.Set("", GetArenaForAllocation()); } #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.Address.ip) + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.DMLMsgHeader.shardName) } -// int64 port = 2; -inline void Address::clear_port() { - _impl_.port_ = int64_t{0}; +// ------------------------------------------------------------------- + +// PrivilegeExt + +// .milvus.proto.common.ObjectType object_type = 1; +inline void PrivilegeExt::clear_object_type() { + _impl_.object_type_ = 0; } -inline int64_t Address::_internal_port() const { - return _impl_.port_; +inline ::milvus::proto::common::ObjectType PrivilegeExt::_internal_object_type() const { + return static_cast< ::milvus::proto::common::ObjectType >(_impl_.object_type_); } -inline int64_t Address::port() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.Address.port) - return _internal_port(); +inline ::milvus::proto::common::ObjectType PrivilegeExt::object_type() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_type) + return _internal_object_type(); } -inline void Address::_internal_set_port(int64_t value) { +inline void PrivilegeExt::_internal_set_object_type(::milvus::proto::common::ObjectType value) { - _impl_.port_ = value; + _impl_.object_type_ = value; } -inline void Address::set_port(int64_t value) { - _internal_set_port(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.Address.port) +inline void PrivilegeExt::set_object_type(::milvus::proto::common::ObjectType value) { + _internal_set_object_type(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_type) } -// ------------------------------------------------------------------- - -// MsgBase - -// .milvus.proto.common.MsgType msg_type = 1; -inline void MsgBase::clear_msg_type() { - _impl_.msg_type_ = 0; +// .milvus.proto.common.ObjectPrivilege object_privilege = 2; +inline void PrivilegeExt::clear_object_privilege() { + _impl_.object_privilege_ = 0; } -inline ::milvus::proto::common::MsgType MsgBase::_internal_msg_type() const { - return static_cast< ::milvus::proto::common::MsgType >(_impl_.msg_type_); +inline ::milvus::proto::common::ObjectPrivilege PrivilegeExt::_internal_object_privilege() const { + return static_cast< ::milvus::proto::common::ObjectPrivilege >(_impl_.object_privilege_); } -inline ::milvus::proto::common::MsgType MsgBase::msg_type() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.msg_type) - return _internal_msg_type(); +inline ::milvus::proto::common::ObjectPrivilege PrivilegeExt::object_privilege() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_privilege) + return _internal_object_privilege(); } -inline void MsgBase::_internal_set_msg_type(::milvus::proto::common::MsgType value) { +inline void PrivilegeExt::_internal_set_object_privilege(::milvus::proto::common::ObjectPrivilege value) { - _impl_.msg_type_ = value; + _impl_.object_privilege_ = value; } -inline void MsgBase::set_msg_type(::milvus::proto::common::MsgType value) { - _internal_set_msg_type(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.msg_type) +inline void PrivilegeExt::set_object_privilege(::milvus::proto::common::ObjectPrivilege value) { + _internal_set_object_privilege(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_privilege) } -// int64 msgID = 2; -inline void MsgBase::clear_msgid() { - _impl_.msgid_ = int64_t{0}; +// int32 object_name_index = 3; +inline void PrivilegeExt::clear_object_name_index() { + _impl_.object_name_index_ = 0; } -inline int64_t MsgBase::_internal_msgid() const { - return _impl_.msgid_; +inline int32_t PrivilegeExt::_internal_object_name_index() const { + return _impl_.object_name_index_; } -inline int64_t MsgBase::msgid() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.msgID) - return _internal_msgid(); +inline int32_t PrivilegeExt::object_name_index() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_name_index) + return _internal_object_name_index(); } -inline void MsgBase::_internal_set_msgid(int64_t value) { +inline void PrivilegeExt::_internal_set_object_name_index(int32_t value) { - _impl_.msgid_ = value; + _impl_.object_name_index_ = value; } -inline void MsgBase::set_msgid(int64_t value) { - _internal_set_msgid(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.msgID) +inline void PrivilegeExt::set_object_name_index(int32_t value) { + _internal_set_object_name_index(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_name_index) } -// uint64 timestamp = 3; -inline void MsgBase::clear_timestamp() { - _impl_.timestamp_ = uint64_t{0u}; +// int32 object_name_indexs = 4; +inline void PrivilegeExt::clear_object_name_indexs() { + _impl_.object_name_indexs_ = 0; } -inline uint64_t MsgBase::_internal_timestamp() const { - return _impl_.timestamp_; +inline int32_t PrivilegeExt::_internal_object_name_indexs() const { + return _impl_.object_name_indexs_; } -inline uint64_t MsgBase::timestamp() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.timestamp) - return _internal_timestamp(); +inline int32_t PrivilegeExt::object_name_indexs() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_name_indexs) + return _internal_object_name_indexs(); } -inline void MsgBase::_internal_set_timestamp(uint64_t value) { +inline void PrivilegeExt::_internal_set_object_name_indexs(int32_t value) { - _impl_.timestamp_ = value; + _impl_.object_name_indexs_ = value; } -inline void MsgBase::set_timestamp(uint64_t value) { - _internal_set_timestamp(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.timestamp) +inline void PrivilegeExt::set_object_name_indexs(int32_t value) { + _internal_set_object_name_indexs(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_name_indexs) } -// int64 sourceID = 4; -inline void MsgBase::clear_sourceid() { - _impl_.sourceid_ = int64_t{0}; +// ------------------------------------------------------------------- + +// SegmentStats + +// int64 SegmentID = 1; +inline void SegmentStats::clear_segmentid() { + _impl_.segmentid_ = int64_t{0}; } -inline int64_t MsgBase::_internal_sourceid() const { - return _impl_.sourceid_; +inline int64_t SegmentStats::_internal_segmentid() const { + return _impl_.segmentid_; } -inline int64_t MsgBase::sourceid() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.sourceID) - return _internal_sourceid(); +inline int64_t SegmentStats::segmentid() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.SegmentStats.SegmentID) + return _internal_segmentid(); } -inline void MsgBase::_internal_set_sourceid(int64_t value) { +inline void SegmentStats::_internal_set_segmentid(int64_t value) { - _impl_.sourceid_ = value; + _impl_.segmentid_ = value; } -inline void MsgBase::set_sourceid(int64_t value) { - _internal_set_sourceid(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.sourceID) +inline void SegmentStats::set_segmentid(int64_t value) { + _internal_set_segmentid(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.SegmentStats.SegmentID) } -// int64 targetID = 5; -inline void MsgBase::clear_targetid() { - _impl_.targetid_ = int64_t{0}; +// int64 NumRows = 2; +inline void SegmentStats::clear_numrows() { + _impl_.numrows_ = int64_t{0}; } -inline int64_t MsgBase::_internal_targetid() const { - return _impl_.targetid_; +inline int64_t SegmentStats::_internal_numrows() const { + return _impl_.numrows_; } -inline int64_t MsgBase::targetid() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.MsgBase.targetID) - return _internal_targetid(); +inline int64_t SegmentStats::numrows() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.SegmentStats.NumRows) + return _internal_numrows(); } -inline void MsgBase::_internal_set_targetid(int64_t value) { +inline void SegmentStats::_internal_set_numrows(int64_t value) { - _impl_.targetid_ = value; + _impl_.numrows_ = value; } -inline void MsgBase::set_targetid(int64_t value) { - _internal_set_targetid(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.MsgBase.targetID) +inline void SegmentStats::set_numrows(int64_t value) { + _internal_set_numrows(value); + // @@protoc_insertion_point(field_set:milvus.proto.common.SegmentStats.NumRows) } // ------------------------------------------------------------------- -// MsgHeader +// ------------------------------------------------------------------- -// .milvus.proto.common.MsgBase base = 1; -inline bool MsgHeader::_internal_has_base() const { - return this != internal_default_instance() && _impl_.base_ != nullptr; +// ClientInfo + +// string sdk_type = 1; +inline void ClientInfo::clear_sdk_type() { + _impl_.sdk_type_.ClearToEmpty(); } -inline bool MsgHeader::has_base() const { - return _internal_has_base(); +inline const std::string& ClientInfo::sdk_type() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ClientInfo.sdk_type) + return _internal_sdk_type(); } -inline void MsgHeader::clear_base() { - if (GetArenaForAllocation() == nullptr && _impl_.base_ != nullptr) { - delete _impl_.base_; - } - _impl_.base_ = nullptr; +template +inline PROTOBUF_ALWAYS_INLINE +void ClientInfo::set_sdk_type(ArgT0&& arg0, ArgT... args) { + + _impl_.sdk_type_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ClientInfo.sdk_type) } -inline const ::milvus::proto::common::MsgBase& MsgHeader::_internal_base() const { - const ::milvus::proto::common::MsgBase* p = _impl_.base_; - return p != nullptr ? *p : reinterpret_cast( - ::milvus::proto::common::_MsgBase_default_instance_); +inline std::string* ClientInfo::mutable_sdk_type() { + std::string* _s = _internal_mutable_sdk_type(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ClientInfo.sdk_type) + return _s; } -inline const ::milvus::proto::common::MsgBase& MsgHeader::base() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.MsgHeader.base) - return _internal_base(); +inline const std::string& ClientInfo::_internal_sdk_type() const { + return _impl_.sdk_type_.Get(); } -inline void MsgHeader::unsafe_arena_set_allocated_base( - ::milvus::proto::common::MsgBase* base) { - if (GetArenaForAllocation() == nullptr) { - delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.base_); - } - _impl_.base_ = base; - if (base) { +inline void ClientInfo::_internal_set_sdk_type(const std::string& value) { + + _impl_.sdk_type_.Set(value, GetArenaForAllocation()); +} +inline std::string* ClientInfo::_internal_mutable_sdk_type() { + + return _impl_.sdk_type_.Mutable(GetArenaForAllocation()); +} +inline std::string* ClientInfo::release_sdk_type() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ClientInfo.sdk_type) + return _impl_.sdk_type_.Release(); +} +inline void ClientInfo::set_allocated_sdk_type(std::string* sdk_type) { + if (sdk_type != nullptr) { } else { } - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:milvus.proto.common.MsgHeader.base) -} -inline ::milvus::proto::common::MsgBase* MsgHeader::release_base() { - - ::milvus::proto::common::MsgBase* temp = _impl_.base_; - _impl_.base_ = nullptr; -#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE - auto* old = reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp); - temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); - if (GetArenaForAllocation() == nullptr) { delete old; } -#else // PROTOBUF_FORCE_COPY_IN_RELEASE - if (GetArenaForAllocation() != nullptr) { - temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + _impl_.sdk_type_.SetAllocated(sdk_type, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.sdk_type_.IsDefault()) { + _impl_.sdk_type_.Set("", GetArenaForAllocation()); } -#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE - return temp; +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ClientInfo.sdk_type) } -inline ::milvus::proto::common::MsgBase* MsgHeader::unsafe_arena_release_base() { - // @@protoc_insertion_point(field_release:milvus.proto.common.MsgHeader.base) + +// string sdk_version = 2; +inline void ClientInfo::clear_sdk_version() { + _impl_.sdk_version_.ClearToEmpty(); +} +inline const std::string& ClientInfo::sdk_version() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ClientInfo.sdk_version) + return _internal_sdk_version(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void ClientInfo::set_sdk_version(ArgT0&& arg0, ArgT... args) { + + _impl_.sdk_version_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ClientInfo.sdk_version) +} +inline std::string* ClientInfo::mutable_sdk_version() { + std::string* _s = _internal_mutable_sdk_version(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ClientInfo.sdk_version) + return _s; +} +inline const std::string& ClientInfo::_internal_sdk_version() const { + return _impl_.sdk_version_.Get(); +} +inline void ClientInfo::_internal_set_sdk_version(const std::string& value) { - ::milvus::proto::common::MsgBase* temp = _impl_.base_; - _impl_.base_ = nullptr; - return temp; + _impl_.sdk_version_.Set(value, GetArenaForAllocation()); } -inline ::milvus::proto::common::MsgBase* MsgHeader::_internal_mutable_base() { +inline std::string* ClientInfo::_internal_mutable_sdk_version() { - if (_impl_.base_ == nullptr) { - auto* p = CreateMaybeMessage<::milvus::proto::common::MsgBase>(GetArenaForAllocation()); - _impl_.base_ = p; - } - return _impl_.base_; + return _impl_.sdk_version_.Mutable(GetArenaForAllocation()); } -inline ::milvus::proto::common::MsgBase* MsgHeader::mutable_base() { - ::milvus::proto::common::MsgBase* _msg = _internal_mutable_base(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.MsgHeader.base) - return _msg; +inline std::string* ClientInfo::release_sdk_version() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ClientInfo.sdk_version) + return _impl_.sdk_version_.Release(); } -inline void MsgHeader::set_allocated_base(::milvus::proto::common::MsgBase* base) { - ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); - if (message_arena == nullptr) { - delete _impl_.base_; - } - if (base) { - ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = - ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(base); - if (message_arena != submessage_arena) { - base = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( - message_arena, base, submessage_arena); - } +inline void ClientInfo::set_allocated_sdk_version(std::string* sdk_version) { + if (sdk_version != nullptr) { } else { } - _impl_.base_ = base; - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.MsgHeader.base) + _impl_.sdk_version_.SetAllocated(sdk_version, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.sdk_version_.IsDefault()) { + _impl_.sdk_version_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ClientInfo.sdk_version) } -// ------------------------------------------------------------------- - -// DMLMsgHeader - -// .milvus.proto.common.MsgBase base = 1; -inline bool DMLMsgHeader::_internal_has_base() const { - return this != internal_default_instance() && _impl_.base_ != nullptr; +// string local_time = 3; +inline void ClientInfo::clear_local_time() { + _impl_.local_time_.ClearToEmpty(); } -inline bool DMLMsgHeader::has_base() const { - return _internal_has_base(); +inline const std::string& ClientInfo::local_time() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ClientInfo.local_time) + return _internal_local_time(); } -inline void DMLMsgHeader::clear_base() { - if (GetArenaForAllocation() == nullptr && _impl_.base_ != nullptr) { - delete _impl_.base_; - } - _impl_.base_ = nullptr; +template +inline PROTOBUF_ALWAYS_INLINE +void ClientInfo::set_local_time(ArgT0&& arg0, ArgT... args) { + + _impl_.local_time_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ClientInfo.local_time) } -inline const ::milvus::proto::common::MsgBase& DMLMsgHeader::_internal_base() const { - const ::milvus::proto::common::MsgBase* p = _impl_.base_; - return p != nullptr ? *p : reinterpret_cast( - ::milvus::proto::common::_MsgBase_default_instance_); +inline std::string* ClientInfo::mutable_local_time() { + std::string* _s = _internal_mutable_local_time(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ClientInfo.local_time) + return _s; } -inline const ::milvus::proto::common::MsgBase& DMLMsgHeader::base() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.DMLMsgHeader.base) - return _internal_base(); +inline const std::string& ClientInfo::_internal_local_time() const { + return _impl_.local_time_.Get(); } -inline void DMLMsgHeader::unsafe_arena_set_allocated_base( - ::milvus::proto::common::MsgBase* base) { - if (GetArenaForAllocation() == nullptr) { - delete reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(_impl_.base_); - } - _impl_.base_ = base; - if (base) { +inline void ClientInfo::_internal_set_local_time(const std::string& value) { + + _impl_.local_time_.Set(value, GetArenaForAllocation()); +} +inline std::string* ClientInfo::_internal_mutable_local_time() { + + return _impl_.local_time_.Mutable(GetArenaForAllocation()); +} +inline std::string* ClientInfo::release_local_time() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ClientInfo.local_time) + return _impl_.local_time_.Release(); +} +inline void ClientInfo::set_allocated_local_time(std::string* local_time) { + if (local_time != nullptr) { } else { } - // @@protoc_insertion_point(field_unsafe_arena_set_allocated:milvus.proto.common.DMLMsgHeader.base) -} -inline ::milvus::proto::common::MsgBase* DMLMsgHeader::release_base() { - - ::milvus::proto::common::MsgBase* temp = _impl_.base_; - _impl_.base_ = nullptr; -#ifdef PROTOBUF_FORCE_COPY_IN_RELEASE - auto* old = reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(temp); - temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); - if (GetArenaForAllocation() == nullptr) { delete old; } -#else // PROTOBUF_FORCE_COPY_IN_RELEASE - if (GetArenaForAllocation() != nullptr) { - temp = ::PROTOBUF_NAMESPACE_ID::internal::DuplicateIfNonNull(temp); + _impl_.local_time_.SetAllocated(local_time, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.local_time_.IsDefault()) { + _impl_.local_time_.Set("", GetArenaForAllocation()); } -#endif // !PROTOBUF_FORCE_COPY_IN_RELEASE - return temp; +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ClientInfo.local_time) } -inline ::milvus::proto::common::MsgBase* DMLMsgHeader::unsafe_arena_release_base() { - // @@protoc_insertion_point(field_release:milvus.proto.common.DMLMsgHeader.base) + +// string user = 4; +inline void ClientInfo::clear_user() { + _impl_.user_.ClearToEmpty(); +} +inline const std::string& ClientInfo::user() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ClientInfo.user) + return _internal_user(); +} +template +inline PROTOBUF_ALWAYS_INLINE +void ClientInfo::set_user(ArgT0&& arg0, ArgT... args) { + + _impl_.user_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ClientInfo.user) +} +inline std::string* ClientInfo::mutable_user() { + std::string* _s = _internal_mutable_user(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ClientInfo.user) + return _s; +} +inline const std::string& ClientInfo::_internal_user() const { + return _impl_.user_.Get(); +} +inline void ClientInfo::_internal_set_user(const std::string& value) { - ::milvus::proto::common::MsgBase* temp = _impl_.base_; - _impl_.base_ = nullptr; - return temp; + _impl_.user_.Set(value, GetArenaForAllocation()); } -inline ::milvus::proto::common::MsgBase* DMLMsgHeader::_internal_mutable_base() { +inline std::string* ClientInfo::_internal_mutable_user() { - if (_impl_.base_ == nullptr) { - auto* p = CreateMaybeMessage<::milvus::proto::common::MsgBase>(GetArenaForAllocation()); - _impl_.base_ = p; - } - return _impl_.base_; + return _impl_.user_.Mutable(GetArenaForAllocation()); } -inline ::milvus::proto::common::MsgBase* DMLMsgHeader::mutable_base() { - ::milvus::proto::common::MsgBase* _msg = _internal_mutable_base(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.DMLMsgHeader.base) - return _msg; +inline std::string* ClientInfo::release_user() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ClientInfo.user) + return _impl_.user_.Release(); } -inline void DMLMsgHeader::set_allocated_base(::milvus::proto::common::MsgBase* base) { - ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation(); - if (message_arena == nullptr) { - delete _impl_.base_; - } - if (base) { - ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = - ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(base); - if (message_arena != submessage_arena) { - base = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage( - message_arena, base, submessage_arena); - } +inline void ClientInfo::set_allocated_user(std::string* user) { + if (user != nullptr) { } else { } - _impl_.base_ = base; - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.DMLMsgHeader.base) + _impl_.user_.SetAllocated(user, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.user_.IsDefault()) { + _impl_.user_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ClientInfo.user) } -// string shardName = 2; -inline void DMLMsgHeader::clear_shardname() { - _impl_.shardname_.ClearToEmpty(); +// string host = 5; +inline void ClientInfo::clear_host() { + _impl_.host_.ClearToEmpty(); } -inline const std::string& DMLMsgHeader::shardname() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.DMLMsgHeader.shardName) - return _internal_shardname(); +inline const std::string& ClientInfo::host() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ClientInfo.host) + return _internal_host(); } template inline PROTOBUF_ALWAYS_INLINE -void DMLMsgHeader::set_shardname(ArgT0&& arg0, ArgT... args) { +void ClientInfo::set_host(ArgT0&& arg0, ArgT... args) { - _impl_.shardname_.Set(static_cast(arg0), args..., GetArenaForAllocation()); - // @@protoc_insertion_point(field_set:milvus.proto.common.DMLMsgHeader.shardName) + _impl_.host_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ClientInfo.host) } -inline std::string* DMLMsgHeader::mutable_shardname() { - std::string* _s = _internal_mutable_shardname(); - // @@protoc_insertion_point(field_mutable:milvus.proto.common.DMLMsgHeader.shardName) +inline std::string* ClientInfo::mutable_host() { + std::string* _s = _internal_mutable_host(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ClientInfo.host) return _s; } -inline const std::string& DMLMsgHeader::_internal_shardname() const { - return _impl_.shardname_.Get(); +inline const std::string& ClientInfo::_internal_host() const { + return _impl_.host_.Get(); } -inline void DMLMsgHeader::_internal_set_shardname(const std::string& value) { +inline void ClientInfo::_internal_set_host(const std::string& value) { - _impl_.shardname_.Set(value, GetArenaForAllocation()); + _impl_.host_.Set(value, GetArenaForAllocation()); } -inline std::string* DMLMsgHeader::_internal_mutable_shardname() { +inline std::string* ClientInfo::_internal_mutable_host() { - return _impl_.shardname_.Mutable(GetArenaForAllocation()); + return _impl_.host_.Mutable(GetArenaForAllocation()); } -inline std::string* DMLMsgHeader::release_shardname() { - // @@protoc_insertion_point(field_release:milvus.proto.common.DMLMsgHeader.shardName) - return _impl_.shardname_.Release(); +inline std::string* ClientInfo::release_host() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ClientInfo.host) + return _impl_.host_.Release(); } -inline void DMLMsgHeader::set_allocated_shardname(std::string* shardname) { - if (shardname != nullptr) { +inline void ClientInfo::set_allocated_host(std::string* host) { + if (host != nullptr) { } else { } - _impl_.shardname_.SetAllocated(shardname, GetArenaForAllocation()); + _impl_.host_.SetAllocated(host, GetArenaForAllocation()); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING - if (_impl_.shardname_.IsDefault()) { - _impl_.shardname_.Set("", GetArenaForAllocation()); + if (_impl_.host_.IsDefault()) { + _impl_.host_.Set("", GetArenaForAllocation()); } #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING - // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.DMLMsgHeader.shardName) + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ClientInfo.host) +} + +// map reserved = 6; +inline int ClientInfo::_internal_reserved_size() const { + return _impl_.reserved_.size(); +} +inline int ClientInfo::reserved_size() const { + return _internal_reserved_size(); +} +inline void ClientInfo::clear_reserved() { + _impl_.reserved_.Clear(); +} +inline const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& +ClientInfo::_internal_reserved() const { + return _impl_.reserved_.GetMap(); +} +inline const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& +ClientInfo::reserved() const { + // @@protoc_insertion_point(field_map:milvus.proto.common.ClientInfo.reserved) + return _internal_reserved(); +} +inline ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* +ClientInfo::_internal_mutable_reserved() { + return _impl_.reserved_.MutableMap(); +} +inline ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* +ClientInfo::mutable_reserved() { + // @@protoc_insertion_point(field_mutable_map:milvus.proto.common.ClientInfo.reserved) + return _internal_mutable_reserved(); } // ------------------------------------------------------------------- -// PrivilegeExt +// ------------------------------------------------------------------- -// .milvus.proto.common.ObjectType object_type = 1; -inline void PrivilegeExt::clear_object_type() { - _impl_.object_type_ = 0; +// ServerInfo + +// string build_tags = 1; +inline void ServerInfo::clear_build_tags() { + _impl_.build_tags_.ClearToEmpty(); } -inline ::milvus::proto::common::ObjectType PrivilegeExt::_internal_object_type() const { - return static_cast< ::milvus::proto::common::ObjectType >(_impl_.object_type_); +inline const std::string& ServerInfo::build_tags() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ServerInfo.build_tags) + return _internal_build_tags(); } -inline ::milvus::proto::common::ObjectType PrivilegeExt::object_type() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_type) - return _internal_object_type(); +template +inline PROTOBUF_ALWAYS_INLINE +void ServerInfo::set_build_tags(ArgT0&& arg0, ArgT... args) { + + _impl_.build_tags_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ServerInfo.build_tags) } -inline void PrivilegeExt::_internal_set_object_type(::milvus::proto::common::ObjectType value) { +inline std::string* ServerInfo::mutable_build_tags() { + std::string* _s = _internal_mutable_build_tags(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ServerInfo.build_tags) + return _s; +} +inline const std::string& ServerInfo::_internal_build_tags() const { + return _impl_.build_tags_.Get(); +} +inline void ServerInfo::_internal_set_build_tags(const std::string& value) { - _impl_.object_type_ = value; + _impl_.build_tags_.Set(value, GetArenaForAllocation()); } -inline void PrivilegeExt::set_object_type(::milvus::proto::common::ObjectType value) { - _internal_set_object_type(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_type) +inline std::string* ServerInfo::_internal_mutable_build_tags() { + + return _impl_.build_tags_.Mutable(GetArenaForAllocation()); +} +inline std::string* ServerInfo::release_build_tags() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ServerInfo.build_tags) + return _impl_.build_tags_.Release(); +} +inline void ServerInfo::set_allocated_build_tags(std::string* build_tags) { + if (build_tags != nullptr) { + + } else { + + } + _impl_.build_tags_.SetAllocated(build_tags, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.build_tags_.IsDefault()) { + _impl_.build_tags_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ServerInfo.build_tags) } -// .milvus.proto.common.ObjectPrivilege object_privilege = 2; -inline void PrivilegeExt::clear_object_privilege() { - _impl_.object_privilege_ = 0; +// string build_time = 2; +inline void ServerInfo::clear_build_time() { + _impl_.build_time_.ClearToEmpty(); } -inline ::milvus::proto::common::ObjectPrivilege PrivilegeExt::_internal_object_privilege() const { - return static_cast< ::milvus::proto::common::ObjectPrivilege >(_impl_.object_privilege_); +inline const std::string& ServerInfo::build_time() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ServerInfo.build_time) + return _internal_build_time(); } -inline ::milvus::proto::common::ObjectPrivilege PrivilegeExt::object_privilege() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_privilege) - return _internal_object_privilege(); +template +inline PROTOBUF_ALWAYS_INLINE +void ServerInfo::set_build_time(ArgT0&& arg0, ArgT... args) { + + _impl_.build_time_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ServerInfo.build_time) } -inline void PrivilegeExt::_internal_set_object_privilege(::milvus::proto::common::ObjectPrivilege value) { +inline std::string* ServerInfo::mutable_build_time() { + std::string* _s = _internal_mutable_build_time(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ServerInfo.build_time) + return _s; +} +inline const std::string& ServerInfo::_internal_build_time() const { + return _impl_.build_time_.Get(); +} +inline void ServerInfo::_internal_set_build_time(const std::string& value) { - _impl_.object_privilege_ = value; + _impl_.build_time_.Set(value, GetArenaForAllocation()); } -inline void PrivilegeExt::set_object_privilege(::milvus::proto::common::ObjectPrivilege value) { - _internal_set_object_privilege(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_privilege) +inline std::string* ServerInfo::_internal_mutable_build_time() { + + return _impl_.build_time_.Mutable(GetArenaForAllocation()); +} +inline std::string* ServerInfo::release_build_time() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ServerInfo.build_time) + return _impl_.build_time_.Release(); +} +inline void ServerInfo::set_allocated_build_time(std::string* build_time) { + if (build_time != nullptr) { + + } else { + + } + _impl_.build_time_.SetAllocated(build_time, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.build_time_.IsDefault()) { + _impl_.build_time_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ServerInfo.build_time) } -// int32 object_name_index = 3; -inline void PrivilegeExt::clear_object_name_index() { - _impl_.object_name_index_ = 0; +// string git_commit = 3; +inline void ServerInfo::clear_git_commit() { + _impl_.git_commit_.ClearToEmpty(); } -inline int32_t PrivilegeExt::_internal_object_name_index() const { - return _impl_.object_name_index_; +inline const std::string& ServerInfo::git_commit() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ServerInfo.git_commit) + return _internal_git_commit(); } -inline int32_t PrivilegeExt::object_name_index() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_name_index) - return _internal_object_name_index(); +template +inline PROTOBUF_ALWAYS_INLINE +void ServerInfo::set_git_commit(ArgT0&& arg0, ArgT... args) { + + _impl_.git_commit_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ServerInfo.git_commit) } -inline void PrivilegeExt::_internal_set_object_name_index(int32_t value) { +inline std::string* ServerInfo::mutable_git_commit() { + std::string* _s = _internal_mutable_git_commit(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ServerInfo.git_commit) + return _s; +} +inline const std::string& ServerInfo::_internal_git_commit() const { + return _impl_.git_commit_.Get(); +} +inline void ServerInfo::_internal_set_git_commit(const std::string& value) { - _impl_.object_name_index_ = value; + _impl_.git_commit_.Set(value, GetArenaForAllocation()); } -inline void PrivilegeExt::set_object_name_index(int32_t value) { - _internal_set_object_name_index(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_name_index) +inline std::string* ServerInfo::_internal_mutable_git_commit() { + + return _impl_.git_commit_.Mutable(GetArenaForAllocation()); +} +inline std::string* ServerInfo::release_git_commit() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ServerInfo.git_commit) + return _impl_.git_commit_.Release(); +} +inline void ServerInfo::set_allocated_git_commit(std::string* git_commit) { + if (git_commit != nullptr) { + + } else { + + } + _impl_.git_commit_.SetAllocated(git_commit, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.git_commit_.IsDefault()) { + _impl_.git_commit_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ServerInfo.git_commit) } -// int32 object_name_indexs = 4; -inline void PrivilegeExt::clear_object_name_indexs() { - _impl_.object_name_indexs_ = 0; +// string go_version = 4; +inline void ServerInfo::clear_go_version() { + _impl_.go_version_.ClearToEmpty(); } -inline int32_t PrivilegeExt::_internal_object_name_indexs() const { - return _impl_.object_name_indexs_; +inline const std::string& ServerInfo::go_version() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ServerInfo.go_version) + return _internal_go_version(); } -inline int32_t PrivilegeExt::object_name_indexs() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.PrivilegeExt.object_name_indexs) - return _internal_object_name_indexs(); +template +inline PROTOBUF_ALWAYS_INLINE +void ServerInfo::set_go_version(ArgT0&& arg0, ArgT... args) { + + _impl_.go_version_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ServerInfo.go_version) } -inline void PrivilegeExt::_internal_set_object_name_indexs(int32_t value) { +inline std::string* ServerInfo::mutable_go_version() { + std::string* _s = _internal_mutable_go_version(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ServerInfo.go_version) + return _s; +} +inline const std::string& ServerInfo::_internal_go_version() const { + return _impl_.go_version_.Get(); +} +inline void ServerInfo::_internal_set_go_version(const std::string& value) { - _impl_.object_name_indexs_ = value; + _impl_.go_version_.Set(value, GetArenaForAllocation()); } -inline void PrivilegeExt::set_object_name_indexs(int32_t value) { - _internal_set_object_name_indexs(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.PrivilegeExt.object_name_indexs) +inline std::string* ServerInfo::_internal_mutable_go_version() { + + return _impl_.go_version_.Mutable(GetArenaForAllocation()); +} +inline std::string* ServerInfo::release_go_version() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ServerInfo.go_version) + return _impl_.go_version_.Release(); +} +inline void ServerInfo::set_allocated_go_version(std::string* go_version) { + if (go_version != nullptr) { + + } else { + + } + _impl_.go_version_.SetAllocated(go_version, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.go_version_.IsDefault()) { + _impl_.go_version_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ServerInfo.go_version) } -// ------------------------------------------------------------------- - -// SegmentStats - -// int64 SegmentID = 1; -inline void SegmentStats::clear_segmentid() { - _impl_.segmentid_ = int64_t{0}; +// string deploy_mode = 5; +inline void ServerInfo::clear_deploy_mode() { + _impl_.deploy_mode_.ClearToEmpty(); } -inline int64_t SegmentStats::_internal_segmentid() const { - return _impl_.segmentid_; +inline const std::string& ServerInfo::deploy_mode() const { + // @@protoc_insertion_point(field_get:milvus.proto.common.ServerInfo.deploy_mode) + return _internal_deploy_mode(); } -inline int64_t SegmentStats::segmentid() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.SegmentStats.SegmentID) - return _internal_segmentid(); +template +inline PROTOBUF_ALWAYS_INLINE +void ServerInfo::set_deploy_mode(ArgT0&& arg0, ArgT... args) { + + _impl_.deploy_mode_.Set(static_cast(arg0), args..., GetArenaForAllocation()); + // @@protoc_insertion_point(field_set:milvus.proto.common.ServerInfo.deploy_mode) } -inline void SegmentStats::_internal_set_segmentid(int64_t value) { +inline std::string* ServerInfo::mutable_deploy_mode() { + std::string* _s = _internal_mutable_deploy_mode(); + // @@protoc_insertion_point(field_mutable:milvus.proto.common.ServerInfo.deploy_mode) + return _s; +} +inline const std::string& ServerInfo::_internal_deploy_mode() const { + return _impl_.deploy_mode_.Get(); +} +inline void ServerInfo::_internal_set_deploy_mode(const std::string& value) { - _impl_.segmentid_ = value; + _impl_.deploy_mode_.Set(value, GetArenaForAllocation()); } -inline void SegmentStats::set_segmentid(int64_t value) { - _internal_set_segmentid(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.SegmentStats.SegmentID) +inline std::string* ServerInfo::_internal_mutable_deploy_mode() { + + return _impl_.deploy_mode_.Mutable(GetArenaForAllocation()); +} +inline std::string* ServerInfo::release_deploy_mode() { + // @@protoc_insertion_point(field_release:milvus.proto.common.ServerInfo.deploy_mode) + return _impl_.deploy_mode_.Release(); +} +inline void ServerInfo::set_allocated_deploy_mode(std::string* deploy_mode) { + if (deploy_mode != nullptr) { + + } else { + + } + _impl_.deploy_mode_.SetAllocated(deploy_mode, GetArenaForAllocation()); +#ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING + if (_impl_.deploy_mode_.IsDefault()) { + _impl_.deploy_mode_.Set("", GetArenaForAllocation()); + } +#endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING + // @@protoc_insertion_point(field_set_allocated:milvus.proto.common.ServerInfo.deploy_mode) } -// int64 NumRows = 2; -inline void SegmentStats::clear_numrows() { - _impl_.numrows_ = int64_t{0}; +// map reserved = 6; +inline int ServerInfo::_internal_reserved_size() const { + return _impl_.reserved_.size(); } -inline int64_t SegmentStats::_internal_numrows() const { - return _impl_.numrows_; +inline int ServerInfo::reserved_size() const { + return _internal_reserved_size(); } -inline int64_t SegmentStats::numrows() const { - // @@protoc_insertion_point(field_get:milvus.proto.common.SegmentStats.NumRows) - return _internal_numrows(); +inline void ServerInfo::clear_reserved() { + _impl_.reserved_.Clear(); } -inline void SegmentStats::_internal_set_numrows(int64_t value) { - - _impl_.numrows_ = value; +inline const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& +ServerInfo::_internal_reserved() const { + return _impl_.reserved_.GetMap(); } -inline void SegmentStats::set_numrows(int64_t value) { - _internal_set_numrows(value); - // @@protoc_insertion_point(field_set:milvus.proto.common.SegmentStats.NumRows) +inline const ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >& +ServerInfo::reserved() const { + // @@protoc_insertion_point(field_map:milvus.proto.common.ServerInfo.reserved) + return _internal_reserved(); +} +inline ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* +ServerInfo::_internal_mutable_reserved() { + return _impl_.reserved_.MutableMap(); +} +inline ::PROTOBUF_NAMESPACE_ID::Map< std::string, std::string >* +ServerInfo::mutable_reserved() { + // @@protoc_insertion_point(field_mutable_map:milvus.proto.common.ServerInfo.reserved) + return _internal_mutable_reserved(); } #ifdef __GNUC__ @@ -3806,6 +4939,14 @@ inline void SegmentStats::set_numrows(int64_t value) { // ------------------------------------------------------------------- +// ------------------------------------------------------------------- + +// ------------------------------------------------------------------- + +// ------------------------------------------------------------------- + +// ------------------------------------------------------------------- + // @@protoc_insertion_point(namespace_scope) diff --git a/internal/distributed/proxy/client/client.go b/internal/distributed/proxy/client/client.go index a8648c4ce122f..7877a5d7a1dd9 100644 --- a/internal/distributed/proxy/client/client.go +++ b/internal/distributed/proxy/client/client.go @@ -236,3 +236,21 @@ func (c *Client) SetRates(ctx context.Context, req *proxypb.SetRatesRequest) (*c } return ret.(*commonpb.Status), err } + +func (c *Client) ListClientInfos(ctx context.Context, req *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) { + req = typeutil.Clone(req) + commonpbutil.UpdateMsgBase( + req.GetBase(), + commonpbutil.FillMsgBaseFromClient(paramtable.GetNodeID(), commonpbutil.WithTargetID(c.grpcClient.GetNodeID())), + ) + ret, err := c.grpcClient.ReCall(ctx, func(client proxypb.ProxyClient) (any, error) { + if !funcutil.CheckCtxValid(ctx) { + return nil, ctx.Err() + } + return client.ListClientInfos(ctx, req) + }) + if err != nil { + return nil, err + } + return ret.(*proxypb.ListClientInfosResponse), nil +} diff --git a/internal/distributed/proxy/service.go b/internal/distributed/proxy/service.go index f3d4cd884b21d..7a71ce425df55 100644 --- a/internal/distributed/proxy/service.go +++ b/internal/distributed/proxy/service.go @@ -176,6 +176,7 @@ func (s *Server) startExternalGrpc(grpcPort int, errChan chan error) { logutil.UnaryTraceLoggerInterceptor, proxy.RateLimitInterceptor(limiter), accesslog.UnaryAccessLoggerInterceptor, + proxy.KeepActiveInterceptor, )), } @@ -923,3 +924,11 @@ func (s *Server) ListIndexedSegment(ctx context.Context, req *federpb.ListIndexe func (s *Server) DescribeSegmentIndexData(ctx context.Context, req *federpb.DescribeSegmentIndexDataRequest) (*federpb.DescribeSegmentIndexDataResponse, error) { panic("TODO: implement me") } + +func (s *Server) Connect(ctx context.Context, req *milvuspb.ConnectRequest) (*milvuspb.ConnectResponse, error) { + return s.proxy.Connect(ctx, req) +} + +func (s *Server) ListClientInfos(ctx context.Context, req *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) { + return s.proxy.ListClientInfos(ctx, req) +} diff --git a/internal/distributed/proxy/service_test.go b/internal/distributed/proxy/service_test.go index 78351d230ab7b..08757a5287e8f 100644 --- a/internal/distributed/proxy/service_test.go +++ b/internal/distributed/proxy/service_test.go @@ -514,6 +514,10 @@ func (m *MockProxy) Register() error { return m.regErr } +func (m *MockProxy) ListClientInfos(ctx context.Context, request *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) { + return nil, nil +} + func (m *MockProxy) InvalidateCollectionMetaCache(ctx context.Context, request *proxypb.InvalidateCollMetaCacheRequest) (*commonpb.Status, error) { return nil, nil } @@ -852,6 +856,10 @@ func (m *MockProxy) RenameCollection(ctx context.Context, req *milvuspb.RenameCo return nil, nil } +func (m *MockProxy) Connect(ctx context.Context, req *milvuspb.ConnectRequest) (*milvuspb.ConnectResponse, error) { + return nil, nil +} + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// type WaitOption struct { diff --git a/internal/mocks/mock_proxy.go b/internal/mocks/mock_proxy.go index a36654c9eda1d..e7dd9ae84c1ed 100644 --- a/internal/mocks/mock_proxy.go +++ b/internal/mocks/mock_proxy.go @@ -220,6 +220,53 @@ func (_c *Proxy_CheckHealth_Call) Return(_a0 *milvuspb.CheckHealthResponse, _a1 return _c } +// Connect provides a mock function with given fields: ctx, req +func (_m *Proxy) Connect(ctx context.Context, req *milvuspb.ConnectRequest) (*milvuspb.ConnectResponse, error) { + ret := _m.Called(ctx, req) + + var r0 *milvuspb.ConnectResponse + if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ConnectRequest) *milvuspb.ConnectResponse); ok { + r0 = rf(ctx, req) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*milvuspb.ConnectResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ConnectRequest) error); ok { + r1 = rf(ctx, req) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// Proxy_Connect_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Connect' +type Proxy_Connect_Call struct { + *mock.Call +} + +// Connect is a helper method to define mock.On call +// - ctx context.Context +// - req *milvuspb.ConnectRequest +func (_e *Proxy_Expecter) Connect(ctx interface{}, req interface{}) *Proxy_Connect_Call { + return &Proxy_Connect_Call{Call: _e.mock.On("Connect", ctx, req)} +} + +func (_c *Proxy_Connect_Call) Run(run func(ctx context.Context, req *milvuspb.ConnectRequest)) *Proxy_Connect_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(*milvuspb.ConnectRequest)) + }) + return _c +} + +func (_c *Proxy_Connect_Call) Return(_a0 *milvuspb.ConnectResponse, _a1 error) *Proxy_Connect_Call { + _c.Call.Return(_a0, _a1) + return _c +} + // CreateAlias provides a mock function with given fields: ctx, request func (_m *Proxy) CreateAlias(ctx context.Context, request *milvuspb.CreateAliasRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) @@ -2544,6 +2591,53 @@ func (_c *Proxy_InvalidateCredentialCache_Call) Return(_a0 *commonpb.Status, _a1 return _c } +// ListClientInfos provides a mock function with given fields: ctx, req +func (_m *Proxy) ListClientInfos(ctx context.Context, req *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) { + ret := _m.Called(ctx, req) + + var r0 *proxypb.ListClientInfosResponse + if rf, ok := ret.Get(0).(func(context.Context, *proxypb.ListClientInfosRequest) *proxypb.ListClientInfosResponse); ok { + r0 = rf(ctx, req) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*proxypb.ListClientInfosResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *proxypb.ListClientInfosRequest) error); ok { + r1 = rf(ctx, req) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// Proxy_ListClientInfos_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListClientInfos' +type Proxy_ListClientInfos_Call struct { + *mock.Call +} + +// ListClientInfos is a helper method to define mock.On call +// - ctx context.Context +// - req *proxypb.ListClientInfosRequest +func (_e *Proxy_Expecter) ListClientInfos(ctx interface{}, req interface{}) *Proxy_ListClientInfos_Call { + return &Proxy_ListClientInfos_Call{Call: _e.mock.On("ListClientInfos", ctx, req)} +} + +func (_c *Proxy_ListClientInfos_Call) Run(run func(ctx context.Context, req *proxypb.ListClientInfosRequest)) *Proxy_ListClientInfos_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(*proxypb.ListClientInfosRequest)) + }) + return _c +} + +func (_c *Proxy_ListClientInfos_Call) Return(_a0 *proxypb.ListClientInfosResponse, _a1 error) *Proxy_ListClientInfos_Call { + _c.Call.Return(_a0, _a1) + return _c +} + // ListCredUsers provides a mock function with given fields: ctx, req func (_m *Proxy) ListCredUsers(ctx context.Context, req *milvuspb.ListCredUsersRequest) (*milvuspb.ListCredUsersResponse, error) { ret := _m.Called(ctx, req) diff --git a/internal/proto/proxy.proto b/internal/proto/proxy.proto index 1255344d5af35..9c443995e01c5 100644 --- a/internal/proto/proxy.proto +++ b/internal/proto/proxy.proto @@ -20,6 +20,8 @@ service Proxy { rpc RefreshPolicyInfoCache(RefreshPolicyInfoCacheRequest) returns (common.Status) {} rpc GetProxyMetrics(milvus.GetMetricsRequest) returns (milvus.GetMetricsResponse) {} rpc SetRates(SetRatesRequest) returns (common.Status) {} + + rpc ListClientInfos(ListClientInfosRequest) returns (ListClientInfosResponse) {} } message InvalidateCollMetaCacheRequest { @@ -61,3 +63,12 @@ message SetRatesRequest { common.MsgBase base = 1; repeated CollectionRate rates = 2; } + +message ListClientInfosRequest { + common.MsgBase base = 1; +} + +message ListClientInfosResponse { + common.Status status = 1; + repeated common.ClientInfo client_infos = 2; +} diff --git a/internal/proto/proxypb/proxy.pb.go b/internal/proto/proxypb/proxy.pb.go index 8358949ea7239..9a769c7828f7a 100644 --- a/internal/proto/proxypb/proxy.pb.go +++ b/internal/proto/proxypb/proxy.pb.go @@ -361,6 +361,92 @@ func (m *SetRatesRequest) GetRates() []*CollectionRate { return nil } +type ListClientInfosRequest struct { + Base *commonpb.MsgBase `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *ListClientInfosRequest) Reset() { *m = ListClientInfosRequest{} } +func (m *ListClientInfosRequest) String() string { return proto.CompactTextString(m) } +func (*ListClientInfosRequest) ProtoMessage() {} +func (*ListClientInfosRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_700b50b08ed8dbaf, []int{6} +} + +func (m *ListClientInfosRequest) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_ListClientInfosRequest.Unmarshal(m, b) +} +func (m *ListClientInfosRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_ListClientInfosRequest.Marshal(b, m, deterministic) +} +func (m *ListClientInfosRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_ListClientInfosRequest.Merge(m, src) +} +func (m *ListClientInfosRequest) XXX_Size() int { + return xxx_messageInfo_ListClientInfosRequest.Size(m) +} +func (m *ListClientInfosRequest) XXX_DiscardUnknown() { + xxx_messageInfo_ListClientInfosRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_ListClientInfosRequest proto.InternalMessageInfo + +func (m *ListClientInfosRequest) GetBase() *commonpb.MsgBase { + if m != nil { + return m.Base + } + return nil +} + +type ListClientInfosResponse struct { + Status *commonpb.Status `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` + ClientInfos []*commonpb.ClientInfo `protobuf:"bytes,2,rep,name=client_infos,json=clientInfos,proto3" json:"client_infos,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` +} + +func (m *ListClientInfosResponse) Reset() { *m = ListClientInfosResponse{} } +func (m *ListClientInfosResponse) String() string { return proto.CompactTextString(m) } +func (*ListClientInfosResponse) ProtoMessage() {} +func (*ListClientInfosResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_700b50b08ed8dbaf, []int{7} +} + +func (m *ListClientInfosResponse) XXX_Unmarshal(b []byte) error { + return xxx_messageInfo_ListClientInfosResponse.Unmarshal(m, b) +} +func (m *ListClientInfosResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + return xxx_messageInfo_ListClientInfosResponse.Marshal(b, m, deterministic) +} +func (m *ListClientInfosResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_ListClientInfosResponse.Merge(m, src) +} +func (m *ListClientInfosResponse) XXX_Size() int { + return xxx_messageInfo_ListClientInfosResponse.Size(m) +} +func (m *ListClientInfosResponse) XXX_DiscardUnknown() { + xxx_messageInfo_ListClientInfosResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_ListClientInfosResponse proto.InternalMessageInfo + +func (m *ListClientInfosResponse) GetStatus() *commonpb.Status { + if m != nil { + return m.Status + } + return nil +} + +func (m *ListClientInfosResponse) GetClientInfos() []*commonpb.ClientInfo { + if m != nil { + return m.ClientInfos + } + return nil +} + func init() { proto.RegisterType((*InvalidateCollMetaCacheRequest)(nil), "milvus.proto.proxy.InvalidateCollMetaCacheRequest") proto.RegisterType((*InvalidateCredCacheRequest)(nil), "milvus.proto.proxy.InvalidateCredCacheRequest") @@ -368,54 +454,60 @@ func init() { proto.RegisterType((*RefreshPolicyInfoCacheRequest)(nil), "milvus.proto.proxy.RefreshPolicyInfoCacheRequest") proto.RegisterType((*CollectionRate)(nil), "milvus.proto.proxy.CollectionRate") proto.RegisterType((*SetRatesRequest)(nil), "milvus.proto.proxy.SetRatesRequest") + proto.RegisterType((*ListClientInfosRequest)(nil), "milvus.proto.proxy.ListClientInfosRequest") + proto.RegisterType((*ListClientInfosResponse)(nil), "milvus.proto.proxy.ListClientInfosResponse") } func init() { proto.RegisterFile("proxy.proto", fileDescriptor_700b50b08ed8dbaf) } var fileDescriptor_700b50b08ed8dbaf = []byte{ - // 657 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x54, 0xd1, 0x4e, 0x13, 0x41, - 0x14, 0x65, 0x29, 0x2d, 0x78, 0x69, 0x4a, 0x32, 0x41, 0xac, 0x45, 0xb0, 0x59, 0x8c, 0x34, 0x24, - 0x6e, 0xa5, 0x92, 0xe8, 0x33, 0xc5, 0x34, 0xc4, 0x40, 0x70, 0xab, 0x2f, 0xbe, 0x98, 0xd9, 0xdd, - 0x0b, 0x5d, 0xb2, 0x9d, 0x59, 0x66, 0xa6, 0x68, 0x1f, 0x8c, 0x89, 0x7f, 0xe4, 0x9b, 0xdf, 0xe1, - 0x17, 0x99, 0xdd, 0xd9, 0x6e, 0xbb, 0x65, 0x61, 0xa3, 0xc4, 0xb7, 0xde, 0x99, 0x73, 0x7b, 0xce, - 0xb9, 0x77, 0xf6, 0xc0, 0x6a, 0x28, 0xf8, 0xd7, 0xb1, 0x15, 0x0a, 0xae, 0x38, 0x21, 0x43, 0x3f, - 0xb8, 0x1e, 0x49, 0x5d, 0x59, 0xf1, 0x4d, 0xa3, 0xea, 0xf2, 0xe1, 0x90, 0x33, 0x7d, 0xd6, 0xa8, - 0xf9, 0x4c, 0xa1, 0x60, 0x34, 0x48, 0xea, 0xea, 0x6c, 0x87, 0xf9, 0xcb, 0x80, 0xed, 0x63, 0x76, - 0x4d, 0x03, 0xdf, 0xa3, 0x0a, 0xbb, 0x3c, 0x08, 0x4e, 0x50, 0xd1, 0x2e, 0x75, 0x07, 0x68, 0xe3, - 0xd5, 0x08, 0xa5, 0x22, 0x2f, 0x61, 0xc9, 0xa1, 0x12, 0xeb, 0x46, 0xd3, 0x68, 0xad, 0x76, 0x9e, - 0x58, 0x19, 0xc6, 0x84, 0xea, 0x44, 0x5e, 0x1c, 0x52, 0x89, 0x76, 0x8c, 0x24, 0x8f, 0x60, 0xd9, - 0x73, 0x3e, 0x33, 0x3a, 0xc4, 0xfa, 0x62, 0xd3, 0x68, 0x3d, 0xb0, 0x2b, 0x9e, 0x73, 0x4a, 0x87, - 0x48, 0x76, 0x61, 0xcd, 0xe5, 0x41, 0x80, 0xae, 0xf2, 0x39, 0xd3, 0x80, 0x52, 0x0c, 0xa8, 0x4d, - 0x8f, 0x63, 0xa0, 0x09, 0xd5, 0xe9, 0xc9, 0xf1, 0x51, 0x7d, 0xa9, 0x69, 0xb4, 0x4a, 0x76, 0xe6, - 0xcc, 0xbc, 0x84, 0xc6, 0x8c, 0x72, 0x81, 0xde, 0x3d, 0x55, 0x37, 0x60, 0x65, 0x24, 0xa3, 0x49, - 0xa5, 0xb2, 0xd3, 0xda, 0xfc, 0x61, 0xc0, 0xc6, 0xc7, 0xf0, 0xff, 0x13, 0x45, 0x77, 0x21, 0x95, - 0xf2, 0x0b, 0x17, 0x5e, 0x32, 0x9a, 0xb4, 0x36, 0xbf, 0xc3, 0x96, 0x8d, 0xe7, 0x02, 0xe5, 0xe0, - 0x8c, 0x07, 0xbe, 0x3b, 0x3e, 0x66, 0xe7, 0xfc, 0x9e, 0x52, 0x36, 0xa0, 0xc2, 0xc3, 0x0f, 0xe3, - 0x50, 0x0b, 0x29, 0xdb, 0x49, 0x45, 0xd6, 0xa1, 0xcc, 0xc3, 0x77, 0x38, 0x4e, 0x34, 0xe8, 0xc2, - 0xfc, 0x6d, 0x40, 0xad, 0x9b, 0xae, 0xc0, 0xa6, 0x0a, 0xc9, 0x36, 0xc0, 0x74, 0x29, 0x31, 0x71, - 0xc9, 0x9e, 0x39, 0x21, 0xfb, 0x50, 0x16, 0x54, 0xa1, 0xac, 0x2f, 0x36, 0x4b, 0xad, 0xd5, 0xce, - 0x66, 0x56, 0x53, 0xfa, 0x34, 0xa3, 0xff, 0xb2, 0x35, 0x92, 0xbc, 0x86, 0x8a, 0x54, 0x71, 0x4f, - 0xa9, 0x59, 0x6a, 0xd5, 0x3a, 0x4f, 0xb3, 0x3d, 0x49, 0xf1, 0x7e, 0xc4, 0x15, 0xed, 0x47, 0x38, - 0x3b, 0x81, 0x93, 0x03, 0x28, 0xbb, 0xdc, 0x43, 0x59, 0x5f, 0x8a, 0xfb, 0xb6, 0x73, 0xfd, 0xbf, - 0x15, 0x82, 0x8b, 0x2e, 0xf7, 0xd0, 0xd6, 0x60, 0xf3, 0x1b, 0xac, 0xf5, 0x51, 0x45, 0x02, 0xe4, - 0xbf, 0xcf, 0xf1, 0x4d, 0xd6, 0xa6, 0x69, 0xdd, 0xfc, 0x2c, 0xad, 0xec, 0xe4, 0x12, 0xb7, 0x9d, - 0x9f, 0xcb, 0x50, 0x3e, 0x8b, 0xee, 0x49, 0x00, 0xa4, 0x87, 0xaa, 0xcb, 0x87, 0x21, 0x67, 0xc8, - 0x54, 0x5f, 0x9b, 0xb2, 0x72, 0xdd, 0xdf, 0x04, 0x26, 0xda, 0x1b, 0xcf, 0x72, 0xf1, 0x73, 0x60, - 0x73, 0x81, 0x5c, 0xc1, 0x7a, 0x0f, 0xe3, 0xd2, 0x97, 0xca, 0x77, 0x65, 0x77, 0x40, 0x19, 0xc3, - 0x80, 0x74, 0x6e, 0xd9, 0x50, 0x1e, 0x78, 0xc2, 0xb9, 0x93, 0xcb, 0xd9, 0x57, 0xc2, 0x67, 0x17, - 0x36, 0xca, 0x90, 0x33, 0x89, 0xe6, 0x02, 0x11, 0xb0, 0x95, 0x8d, 0x1a, 0x3d, 0x8d, 0x34, 0x70, - 0xe6, 0xb9, 0xf5, 0xd8, 0xee, 0x4e, 0xa7, 0xc6, 0x66, 0xee, 0x76, 0x22, 0xa9, 0xa3, 0xc8, 0x26, - 0x85, 0x6a, 0x0f, 0xd5, 0x91, 0x37, 0xb1, 0xb7, 0x77, 0xbb, 0xbd, 0x14, 0xf4, 0x97, 0xb6, 0x2e, - 0xe1, 0x71, 0x36, 0x87, 0x90, 0x29, 0x9f, 0x06, 0xda, 0x92, 0x55, 0x60, 0x69, 0x2e, 0x4d, 0x8a, - 0xec, 0x38, 0xf0, 0x70, 0x1a, 0x43, 0xb3, 0x3c, 0x7b, 0x79, 0x3c, 0xf9, 0x89, 0x55, 0xc4, 0x71, - 0x09, 0x1b, 0xf9, 0x31, 0x43, 0xf6, 0xf3, 0x48, 0xee, 0x8c, 0xa4, 0x22, 0x2e, 0x0f, 0xd6, 0x7a, - 0xa8, 0xe2, 0xf7, 0x7f, 0x82, 0x4a, 0xf8, 0xae, 0x24, 0xcf, 0x6f, 0x7b, 0xf0, 0x09, 0x60, 0xf2, - 0xcf, 0xbb, 0x85, 0xb8, 0x74, 0x43, 0xa7, 0xb0, 0x32, 0xf9, 0xc4, 0xc9, 0x4e, 0x9e, 0x87, 0xb9, - 0x00, 0x28, 0x50, 0x7d, 0x78, 0xf0, 0xa9, 0x73, 0xe1, 0xab, 0xc1, 0xc8, 0x89, 0x6e, 0xda, 0x1a, - 0xfa, 0xc2, 0xe7, 0xc9, 0xaf, 0xf6, 0xe4, 0x51, 0xb5, 0xe3, 0xee, 0x76, 0x4c, 0x11, 0x3a, 0x4e, - 0x25, 0x2e, 0x5f, 0xfd, 0x09, 0x00, 0x00, 0xff, 0xff, 0x9a, 0xf6, 0x3d, 0x98, 0xc0, 0x07, 0x00, - 0x00, + // 735 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x54, 0xdd, 0x4e, 0x1a, 0x5b, + 0x14, 0x76, 0x44, 0x38, 0x9e, 0x05, 0x81, 0x64, 0xc7, 0x83, 0x1c, 0x3c, 0x2a, 0x19, 0x4f, 0x2a, + 0xb1, 0x29, 0x54, 0x34, 0x69, 0xaf, 0xc5, 0x86, 0xd8, 0x56, 0x63, 0x87, 0xf6, 0xa6, 0x37, 0x66, + 0x33, 0xb3, 0x94, 0x6d, 0x86, 0xbd, 0xc7, 0xd9, 0x1b, 0x5b, 0x2e, 0x9a, 0x26, 0x7d, 0x84, 0xbe, + 0x40, 0x5f, 0xa3, 0xcf, 0xd1, 0x27, 0x6a, 0xe6, 0x87, 0x81, 0xc1, 0xad, 0xb4, 0x9a, 0xde, 0xb1, + 0xf6, 0x7c, 0x6b, 0x7d, 0xdf, 0xfa, 0xe1, 0x83, 0xbc, 0xe7, 0x8b, 0x8f, 0xa3, 0x86, 0xe7, 0x0b, + 0x25, 0x08, 0x19, 0x30, 0xf7, 0x7a, 0x28, 0xa3, 0xa8, 0x11, 0x7e, 0xa9, 0x16, 0x6c, 0x31, 0x18, + 0x08, 0x1e, 0xbd, 0x55, 0x8b, 0x8c, 0x2b, 0xf4, 0x39, 0x75, 0xe3, 0xb8, 0x30, 0x9d, 0x61, 0x7e, + 0x37, 0x60, 0xe3, 0x88, 0x5f, 0x53, 0x97, 0x39, 0x54, 0x61, 0x5b, 0xb8, 0xee, 0x31, 0x2a, 0xda, + 0xa6, 0x76, 0x1f, 0x2d, 0xbc, 0x1a, 0xa2, 0x54, 0xe4, 0x29, 0x2c, 0xf5, 0xa8, 0xc4, 0x8a, 0x51, + 0x33, 0xea, 0xf9, 0xd6, 0x7f, 0x8d, 0x14, 0x63, 0x4c, 0x75, 0x2c, 0x2f, 0x0e, 0xa8, 0x44, 0x2b, + 0x44, 0x92, 0x55, 0xf8, 0xcb, 0xe9, 0x9d, 0x71, 0x3a, 0xc0, 0xca, 0x62, 0xcd, 0xa8, 0xff, 0x6d, + 0xe5, 0x9c, 0xde, 0x09, 0x1d, 0x20, 0xd9, 0x86, 0x92, 0x2d, 0x5c, 0x17, 0x6d, 0xc5, 0x04, 0x8f, + 0x00, 0x99, 0x10, 0x50, 0x9c, 0x3c, 0x87, 0x40, 0x13, 0x0a, 0x93, 0x97, 0xa3, 0xc3, 0xca, 0x52, + 0xcd, 0xa8, 0x67, 0xac, 0xd4, 0x9b, 0x79, 0x09, 0xd5, 0x29, 0xe5, 0x3e, 0x3a, 0x0f, 0x54, 0x5d, + 0x85, 0xe5, 0xa1, 0x0c, 0x26, 0x95, 0xc8, 0x4e, 0x62, 0xf3, 0x8b, 0x01, 0xe5, 0x77, 0xde, 0x9f, + 0x27, 0x0a, 0xbe, 0x79, 0x54, 0xca, 0x0f, 0xc2, 0x77, 0xe2, 0xd1, 0x24, 0xb1, 0xf9, 0x19, 0xd6, + 0x2d, 0x3c, 0xf7, 0x51, 0xf6, 0x4f, 0x85, 0xcb, 0xec, 0xd1, 0x11, 0x3f, 0x17, 0x0f, 0x94, 0x52, + 0x86, 0x9c, 0xf0, 0xde, 0x8e, 0xbc, 0x48, 0x48, 0xd6, 0x8a, 0x23, 0xb2, 0x02, 0x59, 0xe1, 0xbd, + 0xc2, 0x51, 0xac, 0x21, 0x0a, 0xcc, 0x1f, 0x06, 0x14, 0xdb, 0xc9, 0x0a, 0x2c, 0xaa, 0x90, 0x6c, + 0x00, 0x4c, 0x96, 0x12, 0x12, 0x67, 0xac, 0xa9, 0x17, 0xb2, 0x0b, 0x59, 0x9f, 0x2a, 0x94, 0x95, + 0xc5, 0x5a, 0xa6, 0x9e, 0x6f, 0xad, 0xa5, 0x35, 0x25, 0xa7, 0x19, 0xd4, 0xb2, 0x22, 0x24, 0x79, + 0x06, 0x39, 0xa9, 0xc2, 0x9c, 0x4c, 0x2d, 0x53, 0x2f, 0xb6, 0x36, 0xd3, 0x39, 0x71, 0xf0, 0x66, + 0x28, 0x14, 0xed, 0x06, 0x38, 0x2b, 0x86, 0x93, 0x7d, 0xc8, 0xda, 0xc2, 0x41, 0x59, 0x59, 0x0a, + 0xf3, 0x36, 0xb4, 0xfd, 0xbf, 0xf0, 0x7d, 0xe1, 0xb7, 0x85, 0x83, 0x56, 0x04, 0x36, 0x3f, 0x41, + 0xa9, 0x8b, 0x2a, 0x10, 0x20, 0xef, 0x3f, 0xc7, 0xe7, 0xe9, 0x36, 0xcd, 0xc6, 0xcd, 0xbf, 0x65, + 0x23, 0x3d, 0xb9, 0xb8, 0x5b, 0xf3, 0x25, 0x94, 0x5f, 0x33, 0xa9, 0xda, 0x2e, 0x43, 0xae, 0x82, + 0x8d, 0xde, 0x5f, 0x85, 0xf9, 0xd5, 0x80, 0xd5, 0x1b, 0xc5, 0xa4, 0x27, 0xb8, 0x44, 0xb2, 0x17, + 0x4d, 0x75, 0x28, 0xe3, 0x7a, 0x6b, 0xda, 0x7a, 0xdd, 0x10, 0x62, 0xc5, 0x50, 0x72, 0x00, 0x05, + 0x3b, 0xac, 0x75, 0xc6, 0x82, 0x62, 0x71, 0x77, 0x9b, 0xda, 0xd4, 0x09, 0xa9, 0x95, 0xb7, 0x27, + 0x02, 0x5a, 0xdf, 0x96, 0x21, 0x7b, 0x1a, 0x0c, 0x80, 0xb8, 0x40, 0x3a, 0xa8, 0xda, 0x62, 0xe0, + 0x09, 0x8e, 0x5c, 0x75, 0xa3, 0xad, 0x35, 0xb4, 0xeb, 0xbd, 0x09, 0x8c, 0xc7, 0x52, 0xfd, 0x5f, + 0x8b, 0x9f, 0x01, 0x9b, 0x0b, 0xe4, 0x0a, 0x56, 0x3a, 0x18, 0x86, 0x4c, 0x2a, 0x66, 0xcb, 0x76, + 0x9f, 0x72, 0x8e, 0x2e, 0x69, 0xdd, 0x72, 0x82, 0x3a, 0xf0, 0x98, 0x73, 0x4b, 0xcb, 0xd9, 0x55, + 0x3e, 0xe3, 0x17, 0xe3, 0x09, 0x9b, 0x0b, 0xc4, 0x87, 0xf5, 0xb4, 0x97, 0x46, 0xeb, 0x4e, 0x1c, + 0x75, 0x96, 0x3b, 0xba, 0x8b, 0xbb, 0xed, 0xb7, 0x7a, 0xd7, 0xa2, 0xcc, 0x05, 0x42, 0xa1, 0xd0, + 0x41, 0x75, 0xe8, 0x8c, 0xdb, 0xdb, 0xb9, 0xbd, 0xbd, 0x04, 0xf4, 0x9b, 0x6d, 0x5d, 0xc2, 0xbf, + 0x69, 0xa3, 0x45, 0xae, 0x18, 0x75, 0xa3, 0x96, 0x1a, 0x73, 0x5a, 0x9a, 0xb1, 0xcb, 0x79, 0xed, + 0xf4, 0xe0, 0x9f, 0x89, 0xcf, 0x4e, 0xf3, 0xec, 0xe8, 0x78, 0xf4, 0x96, 0x3c, 0x8f, 0xe3, 0x12, + 0xca, 0x7a, 0x1f, 0x25, 0xbb, 0x3a, 0x92, 0x3b, 0x3d, 0x77, 0x1e, 0x97, 0x03, 0xa5, 0x0e, 0xaa, + 0xf0, 0xfe, 0x8f, 0x51, 0xf9, 0xcc, 0x96, 0xe4, 0xd1, 0x6d, 0x07, 0x1f, 0x03, 0xc6, 0x95, 0xb7, + 0xe7, 0xe2, 0x92, 0x0d, 0x9d, 0xc0, 0xf2, 0xd8, 0xc3, 0xc8, 0x96, 0xae, 0x87, 0x19, 0x87, 0x9b, + 0xa7, 0xda, 0x85, 0xd2, 0x8c, 0x8f, 0xe8, 0xe7, 0xaf, 0x77, 0xae, 0xea, 0xe3, 0x5f, 0xc2, 0x8e, + 0xd5, 0x1f, 0xec, 0xbf, 0x6f, 0x5d, 0x30, 0xd5, 0x1f, 0xf6, 0x02, 0x1d, 0xcd, 0x28, 0xf5, 0x09, + 0x13, 0xf1, 0xaf, 0xe6, 0xf8, 0x84, 0x9b, 0x61, 0xb5, 0x66, 0x58, 0xcd, 0xeb, 0xf5, 0x72, 0x61, + 0xb8, 0xf7, 0x33, 0x00, 0x00, 0xff, 0xff, 0x0e, 0x7a, 0xad, 0xdf, 0x0f, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -439,6 +531,7 @@ type ProxyClient interface { RefreshPolicyInfoCache(ctx context.Context, in *RefreshPolicyInfoCacheRequest, opts ...grpc.CallOption) (*commonpb.Status, error) GetProxyMetrics(ctx context.Context, in *milvuspb.GetMetricsRequest, opts ...grpc.CallOption) (*milvuspb.GetMetricsResponse, error) SetRates(ctx context.Context, in *SetRatesRequest, opts ...grpc.CallOption) (*commonpb.Status, error) + ListClientInfos(ctx context.Context, in *ListClientInfosRequest, opts ...grpc.CallOption) (*ListClientInfosResponse, error) } type proxyClient struct { @@ -530,6 +623,15 @@ func (c *proxyClient) SetRates(ctx context.Context, in *SetRatesRequest, opts .. return out, nil } +func (c *proxyClient) ListClientInfos(ctx context.Context, in *ListClientInfosRequest, opts ...grpc.CallOption) (*ListClientInfosResponse, error) { + out := new(ListClientInfosResponse) + err := c.cc.Invoke(ctx, "/milvus.proto.proxy.Proxy/ListClientInfos", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // ProxyServer is the server API for Proxy service. type ProxyServer interface { GetComponentStates(context.Context, *milvuspb.GetComponentStatesRequest) (*milvuspb.ComponentStates, error) @@ -541,6 +643,7 @@ type ProxyServer interface { RefreshPolicyInfoCache(context.Context, *RefreshPolicyInfoCacheRequest) (*commonpb.Status, error) GetProxyMetrics(context.Context, *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error) SetRates(context.Context, *SetRatesRequest) (*commonpb.Status, error) + ListClientInfos(context.Context, *ListClientInfosRequest) (*ListClientInfosResponse, error) } // UnimplementedProxyServer can be embedded to have forward compatible implementations. @@ -574,6 +677,9 @@ func (*UnimplementedProxyServer) GetProxyMetrics(ctx context.Context, req *milvu func (*UnimplementedProxyServer) SetRates(ctx context.Context, req *SetRatesRequest) (*commonpb.Status, error) { return nil, status.Errorf(codes.Unimplemented, "method SetRates not implemented") } +func (*UnimplementedProxyServer) ListClientInfos(ctx context.Context, req *ListClientInfosRequest) (*ListClientInfosResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method ListClientInfos not implemented") +} func RegisterProxyServer(s *grpc.Server, srv ProxyServer) { s.RegisterService(&_Proxy_serviceDesc, srv) @@ -741,6 +847,24 @@ func _Proxy_SetRates_Handler(srv interface{}, ctx context.Context, dec func(inte return interceptor(ctx, in, info, handler) } +func _Proxy_ListClientInfos_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ListClientInfosRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ProxyServer).ListClientInfos(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/milvus.proto.proxy.Proxy/ListClientInfos", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ProxyServer).ListClientInfos(ctx, req.(*ListClientInfosRequest)) + } + return interceptor(ctx, in, info, handler) +} + var _Proxy_serviceDesc = grpc.ServiceDesc{ ServiceName: "milvus.proto.proxy.Proxy", HandlerType: (*ProxyServer)(nil), @@ -781,6 +905,10 @@ var _Proxy_serviceDesc = grpc.ServiceDesc{ MethodName: "SetRates", Handler: _Proxy_SetRates_Handler, }, + { + MethodName: "ListClientInfos", + Handler: _Proxy_ListClientInfos_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "proxy.proto", diff --git a/internal/proxy/client_info.go b/internal/proxy/client_info.go new file mode 100644 index 0000000000000..b6d41b578794b --- /dev/null +++ b/internal/proxy/client_info.go @@ -0,0 +1,49 @@ +package proxy + +import ( + "context" + "time" + + "github.com/milvus-io/milvus-proto/go-api/commonpb" + "github.com/milvus-io/milvus/pkg/log" + "go.uber.org/zap" +) + +type clientInfo struct { + *commonpb.ClientInfo + identifier int64 + lastActiveTime time.Time +} + +func getLoggerOfClientInfo(info *commonpb.ClientInfo) []zap.Field { + fields := []zap.Field{ + zap.String("sdk_type", info.GetSdkType()), + zap.String("sdk_version", info.GetSdkVersion()), + zap.String("local_time", info.GetLocalTime()), + zap.String("user", info.GetUser()), + zap.String("host", info.GetHost()), + } + + for k, v := range info.GetReserved() { + fields = append(fields, zap.String(k, v)) + } + + return fields +} + +func (c clientInfo) getLogger() []zap.Field { + fields := getLoggerOfClientInfo(c.ClientInfo) + fields = append(fields, + zap.Int64("identifier", c.identifier), + zap.Time("last_active_time", c.lastActiveTime), + ) + return fields +} + +func (c clientInfo) ctxLogRegister(ctx context.Context) { + log.Ctx(ctx).Info("client register", c.getLogger()...) +} + +func (c clientInfo) logDeregister() { + log.Info("client deregister", c.getLogger()...) +} diff --git a/internal/proxy/connection_manager.go b/internal/proxy/connection_manager.go new file mode 100644 index 0000000000000..6f781f50ef468 --- /dev/null +++ b/internal/proxy/connection_manager.go @@ -0,0 +1,180 @@ +package proxy + +import ( + "context" + "strconv" + "sync" + "time" + + "github.com/golang/protobuf/proto" + + "github.com/milvus-io/milvus-proto/go-api/commonpb" + + "github.com/milvus-io/milvus/pkg/log" +) + +const ( + // we shouldn't check this too frequently. + defaultConnCheckDuration = 2 * time.Minute + defaultTTLForInactiveConn = 24 * time.Hour +) + +type connectionManager struct { + mu sync.RWMutex + + initOnce sync.Once + stopOnce sync.Once + + closeSignal chan struct{} + wg sync.WaitGroup + + buffer chan int64 + duration time.Duration + ttl time.Duration + + clientInfos map[int64]clientInfo +} + +type connectionManagerOption func(s *connectionManager) + +func withDuration(duration time.Duration) connectionManagerOption { + return func(s *connectionManager) { + s.duration = duration + } +} + +func withTTL(ttl time.Duration) connectionManagerOption { + return func(s *connectionManager) { + s.ttl = ttl + } +} + +func (s *connectionManager) apply(opts ...connectionManagerOption) { + for _, opt := range opts { + opt(s) + } +} + +func (s *connectionManager) init() { + s.initOnce.Do(func() { + s.wg.Add(1) + go s.checkLoop() + }) +} + +func (s *connectionManager) stop() { + s.stopOnce.Do(func() { + close(s.closeSignal) + s.wg.Wait() + }) +} + +func (s *connectionManager) checkLoop() { + defer s.wg.Done() + + t := time.NewTicker(s.duration) + defer t.Stop() + + for { + select { + case <-s.closeSignal: + log.Info("connection manager closed") + return + case identifier := <-s.buffer: + s.update(identifier) + case <-t.C: + s.removeLongInactiveClients() + } + } +} + +func (s *connectionManager) register(ctx context.Context, identifier int64, info *commonpb.ClientInfo) { + cli := clientInfo{ + ClientInfo: info, + identifier: identifier, + lastActiveTime: time.Now(), + } + + s.mu.Lock() + defer s.mu.Unlock() + + s.clientInfos[identifier] = cli + cli.ctxLogRegister(ctx) +} + +func (s *connectionManager) keepActive(identifier int64) { + // make this asynchronous and then the rpc won't be blocked too long. + s.buffer <- identifier +} + +func (s *connectionManager) update(identifier int64) { + s.mu.Lock() + defer s.mu.Unlock() + + cli, ok := s.clientInfos[identifier] + if ok { + cli.lastActiveTime = time.Now() + s.clientInfos[identifier] = cli + } +} + +func (s *connectionManager) removeLongInactiveClients() { + s.mu.Lock() + defer s.mu.Unlock() + + for candidate, cli := range s.clientInfos { + if time.Since(cli.lastActiveTime) > s.ttl { + cli.logDeregister() + delete(s.clientInfos, candidate) + } + } +} + +func (s *connectionManager) list() []*commonpb.ClientInfo { + s.mu.RLock() + defer s.mu.RUnlock() + + clients := make([]*commonpb.ClientInfo, 0, len(s.clientInfos)) + + for identifier, cli := range s.clientInfos { + if cli.ClientInfo != nil { + client := proto.Clone(cli.ClientInfo).(*commonpb.ClientInfo) + if client.Reserved == nil { + client.Reserved = make(map[string]string) + } + client.Reserved["identifier"] = string(strconv.AppendInt(nil, identifier, 10)) + client.Reserved["last_active_time"] = cli.lastActiveTime.String() + + clients = append(clients, client) + } + } + + return clients +} + +func newConnectionManager(opts ...connectionManagerOption) *connectionManager { + s := &connectionManager{ + closeSignal: make(chan struct{}, 1), + buffer: make(chan int64, 64), + duration: defaultConnCheckDuration, + ttl: defaultTTLForInactiveConn, + clientInfos: make(map[int64]clientInfo), + } + s.apply(opts...) + s.init() + + return s +} + +var connectionManagerInstance *connectionManager + +var getConnectionManagerInstanceOnce sync.Once + +func GetConnectionManager() *connectionManager { + getConnectionManagerInstanceOnce.Do(func() { + connectionManagerInstance = newConnectionManager( + withDuration(defaultConnCheckDuration), + withTTL(defaultTTLForInactiveConn)) + }) + return connectionManagerInstance +} diff --git a/internal/proxy/connection_manager_test.go b/internal/proxy/connection_manager_test.go new file mode 100644 index 0000000000000..bc3a0c610b4aa --- /dev/null +++ b/internal/proxy/connection_manager_test.go @@ -0,0 +1,69 @@ +package proxy + +import ( + "context" + "testing" + "time" + + "github.com/milvus-io/milvus-proto/go-api/commonpb" + + "github.com/stretchr/testify/assert" +) + +func Test_withDuration(t *testing.T) { + s := &connectionManager{} + s.apply(withDuration(defaultConnCheckDuration)) + assert.Equal(t, defaultConnCheckDuration, s.duration) +} + +func Test_withTTL(t *testing.T) { + s := &connectionManager{} + s.apply(withTTL(defaultTTLForInactiveConn)) + assert.Equal(t, defaultTTLForInactiveConn, s.ttl) +} + +func Test_connectionManager_apply(t *testing.T) { + s := &connectionManager{} + s.apply( + withDuration(defaultConnCheckDuration), + withTTL(defaultTTLForInactiveConn)) + assert.Equal(t, defaultConnCheckDuration, s.duration) + assert.Equal(t, defaultTTLForInactiveConn, s.ttl) +} + +func TestGetConnectionManager(t *testing.T) { + s := GetConnectionManager() + assert.Equal(t, defaultConnCheckDuration, s.duration) + assert.Equal(t, defaultTTLForInactiveConn, s.ttl) +} + +func TestConnectionManager(t *testing.T) { + s := newConnectionManager( + withDuration(time.Millisecond*5), + withTTL(time.Millisecond*100)) + + s.register(context.TODO(), 1, &commonpb.ClientInfo{ + Reserved: map[string]string{"for_test": "for_test"}, + }) + assert.Equal(t, 1, len(s.list())) + + // register duplicate. + s.register(context.TODO(), 1, &commonpb.ClientInfo{}) + assert.Equal(t, 1, len(s.list())) + + s.register(context.TODO(), 2, &commonpb.ClientInfo{}) + assert.Equal(t, 2, len(s.list())) + + s.keepActive(1) + s.keepActive(2) + + time.Sleep(time.Millisecond * 5) + assert.Equal(t, 2, len(s.list())) + + time.Sleep(time.Millisecond * 100) + assert.Equal(t, 0, len(s.list())) + + s.stop() + + time.Sleep(time.Millisecond * 5) +} diff --git a/internal/proxy/impl.go b/internal/proxy/impl.go index 48bf3ed3952f9..6ff56bccd244d 100644 --- a/internal/proxy/impl.go +++ b/internal/proxy/impl.go @@ -5053,3 +5053,49 @@ func (node *Proxy) ListIndexedSegment(ctx context.Context, request *federpb.List func (node *Proxy) DescribeSegmentIndexData(ctx context.Context, request *federpb.DescribeSegmentIndexDataRequest) (*federpb.DescribeSegmentIndexDataResponse, error) { panic("TODO: implement me") } + +func (node *Proxy) Connect(ctx context.Context, request *milvuspb.ConnectRequest) (*milvuspb.ConnectResponse, error) { + if !node.checkHealthy() { + return &milvuspb.ConnectResponse{Status: unhealthyStatus()}, nil + } + + ts, err := node.tsoAllocator.AllocOne(ctx) + if err != nil { + return &milvuspb.ConnectResponse{ + Status: &commonpb.Status{ + ErrorCode: commonpb.ErrorCode_UnexpectedError, + Reason: err.Error(), + }, + }, nil + } + + serverInfo := &commonpb.ServerInfo{ + BuildTags: os.Getenv(metricsinfo.GitBuildTagsEnvKey), + BuildTime: os.Getenv(metricsinfo.MilvusBuildTimeEnvKey), + GitCommit: os.Getenv(metricsinfo.GitCommitEnvKey), + GoVersion: os.Getenv(metricsinfo.MilvusUsedGoVersion), + DeployMode: os.Getenv(metricsinfo.DeployModeEnvKey), + Reserved: make(map[string]string), + } + + GetConnectionManager().register(ctx, int64(ts), request.GetClientInfo()) + + return &milvuspb.ConnectResponse{ + Status: &commonpb.Status{ErrorCode: commonpb.ErrorCode_Success}, + ServerInfo: serverInfo, + Identifier: int64(ts), + }, nil +} + +func (node *Proxy) ListClientInfos(ctx context.Context, req *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) { + if !node.checkHealthy() { + return &proxypb.ListClientInfosResponse{Status: unhealthyStatus()}, nil + } + + clients := GetConnectionManager().list() + + return &proxypb.ListClientInfosResponse{ + Status: &commonpb.Status{ErrorCode: commonpb.ErrorCode_Success}, + ClientInfos: clients, + }, nil +} diff --git a/internal/proxy/impl_test.go b/internal/proxy/impl_test.go index e05e8b874ad36..9837682a4b15c 100644 --- a/internal/proxy/impl_test.go +++ b/internal/proxy/impl_test.go @@ -20,6 +20,8 @@ import ( "context" "testing" + "github.com/milvus-io/milvus/internal/proto/rootcoordpb" + "github.com/cockroachdb/errors" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" @@ -541,3 +543,75 @@ func TestProxy_GetReplicas(t *testing.T) { assert.Equal(t, resp.GetStatus().GetErrorCode(), commonpb.ErrorCode_UnexpectedError) }) } + +func TestProxy_Connect(t *testing.T) { + t.Run("proxy unhealthy", func(t *testing.T) { + node := &Proxy{} + node.UpdateStateCode(commonpb.StateCode_Abnormal) + + resp, err := node.Connect(context.TODO(), nil) + assert.NoError(t, err) + assert.NotEqual(t, commonpb.ErrorCode_Success, resp.GetStatus().GetErrorCode()) + }) + + t.Run("failed to allocate ts", func(t *testing.T) { + m := newMockTimestampAllocator(t) + m.On("AllocTimestamp", + mock.Anything, + mock.Anything, + ).Return(nil, errors.New("error mock AllocateTimestamp")) + alloc, _ := newTimestampAllocator(m, 199) + node := Proxy{ + tsoAllocator: alloc, + } + node.UpdateStateCode(commonpb.StateCode_Healthy) + resp, err := node.Connect(context.TODO(), nil) + assert.NoError(t, err) + assert.NotEqual(t, commonpb.ErrorCode_Success, resp.GetStatus().GetErrorCode()) + }) + + t.Run("normal case", func(t *testing.T) { + m := newMockTimestampAllocator(t) + m.On("AllocTimestamp", + mock.Anything, + mock.Anything, + ).Return(&rootcoordpb.AllocTimestampResponse{ + Status: &commonpb.Status{ + ErrorCode: commonpb.ErrorCode_Success, + }, + Timestamp: 20230518, + Count: 1, + }, nil) + alloc, _ := newTimestampAllocator(m, 199) + node := Proxy{ + tsoAllocator: alloc, + } + node.UpdateStateCode(commonpb.StateCode_Healthy) + resp, err := node.Connect(context.TODO(), &milvuspb.ConnectRequest{ + ClientInfo: &commonpb.ClientInfo{}, + }) + assert.NoError(t, err) + assert.Equal(t, commonpb.ErrorCode_Success, resp.GetStatus().GetErrorCode()) + }) +} + +func TestProxy_ListClientInfos(t *testing.T) { + t.Run("proxy unhealthy", func(t *testing.T) { + node := &Proxy{} + node.UpdateStateCode(commonpb.StateCode_Abnormal) + + resp, err := node.ListClientInfos(context.TODO(), nil) + assert.NoError(t, err) + assert.NotEqual(t, commonpb.ErrorCode_Success, resp.GetStatus().GetErrorCode()) + }) + + t.Run("normal case", func(t *testing.T) { + node := Proxy{} + node.UpdateStateCode(commonpb.StateCode_Healthy) + + resp, err := node.ListClientInfos(context.TODO(), nil) + assert.NoError(t, err) + assert.Equal(t, commonpb.ErrorCode_Success, resp.GetStatus().GetErrorCode()) + + }) +} diff --git a/internal/proxy/interface_def.go b/internal/proxy/interface_def.go index aeb77db870003..6851e99e5ffe5 100644 --- a/internal/proxy/interface_def.go +++ b/internal/proxy/interface_def.go @@ -29,6 +29,7 @@ type tsoAllocator interface { } // use timestampAllocatorInterface to keep other components testable +//go:generate mockery --name=timestampAllocatorInterface --filename=mock_tso_test.go --outpkg=proxy --output=. --inpackage --structname=mockTimestampAllocator --with-expecter type timestampAllocatorInterface interface { AllocTimestamp(ctx context.Context, req *rootcoordpb.AllocTimestampRequest) (*rootcoordpb.AllocTimestampResponse, error) } diff --git a/internal/proxy/keep_active_interceptor.go b/internal/proxy/keep_active_interceptor.go new file mode 100644 index 0000000000000..0359279517c36 --- /dev/null +++ b/internal/proxy/keep_active_interceptor.go @@ -0,0 +1,45 @@ +package proxy + +import ( + "context" + "fmt" + "strconv" + + "github.com/milvus-io/milvus/pkg/util" + + "github.com/milvus-io/milvus/pkg/util/funcutil" + + "google.golang.org/grpc/metadata" + + "google.golang.org/grpc" +) + +func getIdentifierFromContext(ctx context.Context) (int64, error) { + md, ok := metadata.FromIncomingContext(ctx) + if !ok { + return 0, fmt.Errorf("fail to get metadata from the context") + } + identifierContent, ok := md[util.IdentifierKey] + if !ok || len(identifierContent) < 1 { + return 0, fmt.Errorf("no identifier found in metadata") + } + identifier, err := strconv.ParseInt(identifierContent[0], 10, 64) + if err != nil { + return 0, fmt.Errorf("failed to parse identifier: %s, error: %s", identifierContent[0], err.Error()) + } + return identifier, nil +} + +func KeepActiveInterceptor(ctx context.Context, req interface{}, info *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (resp interface{}, err error) { + // We shouldn't block the normal rpc. though this may be not very accurate enough. + // On the other hand, too many goroutines will also influence the rpc. + // Not sure which way is better, since actually we already make the `keepActive` asynchronous. + go func() { + identifier, err := getIdentifierFromContext(ctx) + if err == nil && funcutil.CheckCtxValid(ctx) { + GetConnectionManager().keepActive(identifier) + } + }() + + return handler(ctx, req) +} diff --git a/internal/proxy/keep_active_interceptor_test.go b/internal/proxy/keep_active_interceptor_test.go new file mode 100644 index 0000000000000..1fc5139f3f6cf --- /dev/null +++ b/internal/proxy/keep_active_interceptor_test.go @@ -0,0 +1,66 @@ +package proxy + +import ( + "context" + "testing" + + "google.golang.org/grpc" + + "github.com/stretchr/testify/assert" + "google.golang.org/grpc/metadata" +) + +func Test_getIdentifierFromContext(t *testing.T) { + t.Run("metadata not found", func(t *testing.T) { + ctx := context.TODO() + _, err := getIdentifierFromContext(ctx) + assert.Error(t, err) + }) + + t.Run("no identifier", func(t *testing.T) { + md := metadata.New(map[string]string{}) + ctx := metadata.NewIncomingContext(context.TODO(), md) + _, err := getIdentifierFromContext(ctx) + assert.Error(t, err) + }) + + t.Run("invalid identifier", func(t *testing.T) { + md := metadata.New(map[string]string{ + "identifier": "i-am-not-invalid-identifier", + }) + ctx := metadata.NewIncomingContext(context.TODO(), md) + _, err := getIdentifierFromContext(ctx) + assert.Error(t, err) + }) + + t.Run("normal case", func(t *testing.T) { + md := metadata.New(map[string]string{ + "identifier": "20230518", + }) + ctx := metadata.NewIncomingContext(context.TODO(), md) + identifier, err := getIdentifierFromContext(ctx) + assert.NoError(t, err) + assert.Equal(t, int64(20230518), identifier) + }) +} + +func TestKeepActiveInterceptor(t *testing.T) { + md := metadata.New(map[string]string{ + "identifier": "20230518", + }) + ctx := metadata.NewIncomingContext(context.TODO(), md) + + rpcCalled := false + rpcChan := make(chan struct{}, 1) + var handler grpc.UnaryHandler = func(ctx context.Context, req interface{}) (interface{}, error) { + rpcCalled = true + rpcChan <- struct{}{} + return "not-important", nil + } + + got, err := KeepActiveInterceptor(ctx, nil, nil, handler) + <-rpcChan + assert.True(t, rpcCalled) + assert.NoError(t, err) + assert.Equal(t, "not-important", got) +} diff --git a/internal/proxy/mock_tso_test.go b/internal/proxy/mock_tso_test.go new file mode 100644 index 0000000000000..a40a5e9ab5f22 --- /dev/null +++ b/internal/proxy/mock_tso_test.go @@ -0,0 +1,85 @@ +// Code generated by mockery v2.16.0. DO NOT EDIT. + +package proxy + +import ( + context "context" + + rootcoordpb "github.com/milvus-io/milvus/internal/proto/rootcoordpb" + mock "github.com/stretchr/testify/mock" +) + +// mockTimestampAllocator is an autogenerated mock type for the timestampAllocatorInterface type +type mockTimestampAllocator struct { + mock.Mock +} + +type mockTimestampAllocator_Expecter struct { + mock *mock.Mock +} + +func (_m *mockTimestampAllocator) EXPECT() *mockTimestampAllocator_Expecter { + return &mockTimestampAllocator_Expecter{mock: &_m.Mock} +} + +// AllocTimestamp provides a mock function with given fields: ctx, req +func (_m *mockTimestampAllocator) AllocTimestamp(ctx context.Context, req *rootcoordpb.AllocTimestampRequest) (*rootcoordpb.AllocTimestampResponse, error) { + ret := _m.Called(ctx, req) + + var r0 *rootcoordpb.AllocTimestampResponse + if rf, ok := ret.Get(0).(func(context.Context, *rootcoordpb.AllocTimestampRequest) *rootcoordpb.AllocTimestampResponse); ok { + r0 = rf(ctx, req) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*rootcoordpb.AllocTimestampResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *rootcoordpb.AllocTimestampRequest) error); ok { + r1 = rf(ctx, req) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// mockTimestampAllocator_AllocTimestamp_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AllocTimestamp' +type mockTimestampAllocator_AllocTimestamp_Call struct { + *mock.Call +} + +// AllocTimestamp is a helper method to define mock.On call +// - ctx context.Context +// - req *rootcoordpb.AllocTimestampRequest +func (_e *mockTimestampAllocator_Expecter) AllocTimestamp(ctx interface{}, req interface{}) *mockTimestampAllocator_AllocTimestamp_Call { + return &mockTimestampAllocator_AllocTimestamp_Call{Call: _e.mock.On("AllocTimestamp", ctx, req)} +} + +func (_c *mockTimestampAllocator_AllocTimestamp_Call) Run(run func(ctx context.Context, req *rootcoordpb.AllocTimestampRequest)) *mockTimestampAllocator_AllocTimestamp_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(*rootcoordpb.AllocTimestampRequest)) + }) + return _c +} + +func (_c *mockTimestampAllocator_AllocTimestamp_Call) Return(_a0 *rootcoordpb.AllocTimestampResponse, _a1 error) *mockTimestampAllocator_AllocTimestamp_Call { + _c.Call.Return(_a0, _a1) + return _c +} + +type mockConstructorTestingTnewMockTimestampAllocator interface { + mock.TestingT + Cleanup(func()) +} + +// newMockTimestampAllocator creates a new instance of mockTimestampAllocator. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +func newMockTimestampAllocator(t mockConstructorTestingTnewMockTimestampAllocator) *mockTimestampAllocator { + mock := &mockTimestampAllocator{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/internal/proxy/proxy.go b/internal/proxy/proxy.go index f20b3dd8686de..9a0849b5a9bc4 100644 --- a/internal/proxy/proxy.go +++ b/internal/proxy/proxy.go @@ -435,6 +435,8 @@ func (node *Proxy) Stop() error { // https://github.com/milvus-io/milvus/issues/12282 node.UpdateStateCode(commonpb.StateCode_Abnormal) + GetConnectionManager().stop() + return nil } diff --git a/internal/types/mock_proxy.go b/internal/types/mock_proxy.go index c861dc6957486..514a0f35816b9 100644 --- a/internal/types/mock_proxy.go +++ b/internal/types/mock_proxy.go @@ -1,4 +1,4 @@ -// Code generated by mockery v2.21.1. DO NOT EDIT. +// Code generated by mockery v2.16.0. DO NOT EDIT. package types @@ -35,10 +35,6 @@ func (_m *MockProxy) AlterAlias(ctx context.Context, request *milvuspb.AlterAlia ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.AlterAliasRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.AlterAliasRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -47,6 +43,7 @@ func (_m *MockProxy) AlterAlias(ctx context.Context, request *milvuspb.AlterAlia } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.AlterAliasRequest) error); ok { r1 = rf(ctx, request) } else { @@ -62,8 +59,8 @@ type MockProxy_AlterAlias_Call struct { } // AlterAlias is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.AlterAliasRequest +// - ctx context.Context +// - request *milvuspb.AlterAliasRequest func (_e *MockProxy_Expecter) AlterAlias(ctx interface{}, request interface{}) *MockProxy_AlterAlias_Call { return &MockProxy_AlterAlias_Call{Call: _e.mock.On("AlterAlias", ctx, request)} } @@ -80,20 +77,11 @@ func (_c *MockProxy_AlterAlias_Call) Return(_a0 *commonpb.Status, _a1 error) *Mo return _c } -func (_c *MockProxy_AlterAlias_Call) RunAndReturn(run func(context.Context, *milvuspb.AlterAliasRequest) (*commonpb.Status, error)) *MockProxy_AlterAlias_Call { - _c.Call.Return(run) - return _c -} - // AlterCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) AlterCollection(ctx context.Context, request *milvuspb.AlterCollectionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.AlterCollectionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.AlterCollectionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -102,6 +90,7 @@ func (_m *MockProxy) AlterCollection(ctx context.Context, request *milvuspb.Alte } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.AlterCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -117,8 +106,8 @@ type MockProxy_AlterCollection_Call struct { } // AlterCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.AlterCollectionRequest +// - ctx context.Context +// - request *milvuspb.AlterCollectionRequest func (_e *MockProxy_Expecter) AlterCollection(ctx interface{}, request interface{}) *MockProxy_AlterCollection_Call { return &MockProxy_AlterCollection_Call{Call: _e.mock.On("AlterCollection", ctx, request)} } @@ -135,20 +124,11 @@ func (_c *MockProxy_AlterCollection_Call) Return(_a0 *commonpb.Status, _a1 error return _c } -func (_c *MockProxy_AlterCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.AlterCollectionRequest) (*commonpb.Status, error)) *MockProxy_AlterCollection_Call { - _c.Call.Return(run) - return _c -} - // CalcDistance provides a mock function with given fields: ctx, request func (_m *MockProxy) CalcDistance(ctx context.Context, request *milvuspb.CalcDistanceRequest) (*milvuspb.CalcDistanceResults, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.CalcDistanceResults - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CalcDistanceRequest) (*milvuspb.CalcDistanceResults, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CalcDistanceRequest) *milvuspb.CalcDistanceResults); ok { r0 = rf(ctx, request) } else { @@ -157,6 +137,7 @@ func (_m *MockProxy) CalcDistance(ctx context.Context, request *milvuspb.CalcDis } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CalcDistanceRequest) error); ok { r1 = rf(ctx, request) } else { @@ -172,8 +153,8 @@ type MockProxy_CalcDistance_Call struct { } // CalcDistance is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.CalcDistanceRequest +// - ctx context.Context +// - request *milvuspb.CalcDistanceRequest func (_e *MockProxy_Expecter) CalcDistance(ctx interface{}, request interface{}) *MockProxy_CalcDistance_Call { return &MockProxy_CalcDistance_Call{Call: _e.mock.On("CalcDistance", ctx, request)} } @@ -190,20 +171,11 @@ func (_c *MockProxy_CalcDistance_Call) Return(_a0 *milvuspb.CalcDistanceResults, return _c } -func (_c *MockProxy_CalcDistance_Call) RunAndReturn(run func(context.Context, *milvuspb.CalcDistanceRequest) (*milvuspb.CalcDistanceResults, error)) *MockProxy_CalcDistance_Call { - _c.Call.Return(run) - return _c -} - // CheckHealth provides a mock function with given fields: ctx, req func (_m *MockProxy) CheckHealth(ctx context.Context, req *milvuspb.CheckHealthRequest) (*milvuspb.CheckHealthResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.CheckHealthResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CheckHealthRequest) (*milvuspb.CheckHealthResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CheckHealthRequest) *milvuspb.CheckHealthResponse); ok { r0 = rf(ctx, req) } else { @@ -212,6 +184,7 @@ func (_m *MockProxy) CheckHealth(ctx context.Context, req *milvuspb.CheckHealthR } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CheckHealthRequest) error); ok { r1 = rf(ctx, req) } else { @@ -227,8 +200,8 @@ type MockProxy_CheckHealth_Call struct { } // CheckHealth is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.CheckHealthRequest +// - ctx context.Context +// - req *milvuspb.CheckHealthRequest func (_e *MockProxy_Expecter) CheckHealth(ctx interface{}, req interface{}) *MockProxy_CheckHealth_Call { return &MockProxy_CheckHealth_Call{Call: _e.mock.On("CheckHealth", ctx, req)} } @@ -245,8 +218,50 @@ func (_c *MockProxy_CheckHealth_Call) Return(_a0 *milvuspb.CheckHealthResponse, return _c } -func (_c *MockProxy_CheckHealth_Call) RunAndReturn(run func(context.Context, *milvuspb.CheckHealthRequest) (*milvuspb.CheckHealthResponse, error)) *MockProxy_CheckHealth_Call { - _c.Call.Return(run) +// Connect provides a mock function with given fields: ctx, req +func (_m *MockProxy) Connect(ctx context.Context, req *milvuspb.ConnectRequest) (*milvuspb.ConnectResponse, error) { + ret := _m.Called(ctx, req) + + var r0 *milvuspb.ConnectResponse + if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ConnectRequest) *milvuspb.ConnectResponse); ok { + r0 = rf(ctx, req) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*milvuspb.ConnectResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ConnectRequest) error); ok { + r1 = rf(ctx, req) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// MockProxy_Connect_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Connect' +type MockProxy_Connect_Call struct { + *mock.Call +} + +// Connect is a helper method to define mock.On call +// - ctx context.Context +// - req *milvuspb.ConnectRequest +func (_e *MockProxy_Expecter) Connect(ctx interface{}, req interface{}) *MockProxy_Connect_Call { + return &MockProxy_Connect_Call{Call: _e.mock.On("Connect", ctx, req)} +} + +func (_c *MockProxy_Connect_Call) Run(run func(ctx context.Context, req *milvuspb.ConnectRequest)) *MockProxy_Connect_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(*milvuspb.ConnectRequest)) + }) + return _c +} + +func (_c *MockProxy_Connect_Call) Return(_a0 *milvuspb.ConnectResponse, _a1 error) *MockProxy_Connect_Call { + _c.Call.Return(_a0, _a1) return _c } @@ -255,10 +270,6 @@ func (_m *MockProxy) CreateAlias(ctx context.Context, request *milvuspb.CreateAl ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateAliasRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateAliasRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -267,6 +278,7 @@ func (_m *MockProxy) CreateAlias(ctx context.Context, request *milvuspb.CreateAl } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreateAliasRequest) error); ok { r1 = rf(ctx, request) } else { @@ -282,8 +294,8 @@ type MockProxy_CreateAlias_Call struct { } // CreateAlias is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.CreateAliasRequest +// - ctx context.Context +// - request *milvuspb.CreateAliasRequest func (_e *MockProxy_Expecter) CreateAlias(ctx interface{}, request interface{}) *MockProxy_CreateAlias_Call { return &MockProxy_CreateAlias_Call{Call: _e.mock.On("CreateAlias", ctx, request)} } @@ -300,20 +312,11 @@ func (_c *MockProxy_CreateAlias_Call) Return(_a0 *commonpb.Status, _a1 error) *M return _c } -func (_c *MockProxy_CreateAlias_Call) RunAndReturn(run func(context.Context, *milvuspb.CreateAliasRequest) (*commonpb.Status, error)) *MockProxy_CreateAlias_Call { - _c.Call.Return(run) - return _c -} - // CreateCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) CreateCollection(ctx context.Context, request *milvuspb.CreateCollectionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateCollectionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateCollectionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -322,6 +325,7 @@ func (_m *MockProxy) CreateCollection(ctx context.Context, request *milvuspb.Cre } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreateCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -337,8 +341,8 @@ type MockProxy_CreateCollection_Call struct { } // CreateCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.CreateCollectionRequest +// - ctx context.Context +// - request *milvuspb.CreateCollectionRequest func (_e *MockProxy_Expecter) CreateCollection(ctx interface{}, request interface{}) *MockProxy_CreateCollection_Call { return &MockProxy_CreateCollection_Call{Call: _e.mock.On("CreateCollection", ctx, request)} } @@ -355,20 +359,11 @@ func (_c *MockProxy_CreateCollection_Call) Return(_a0 *commonpb.Status, _a1 erro return _c } -func (_c *MockProxy_CreateCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.CreateCollectionRequest) (*commonpb.Status, error)) *MockProxy_CreateCollection_Call { - _c.Call.Return(run) - return _c -} - // CreateCredential provides a mock function with given fields: ctx, req func (_m *MockProxy) CreateCredential(ctx context.Context, req *milvuspb.CreateCredentialRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateCredentialRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateCredentialRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -377,6 +372,7 @@ func (_m *MockProxy) CreateCredential(ctx context.Context, req *milvuspb.CreateC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreateCredentialRequest) error); ok { r1 = rf(ctx, req) } else { @@ -392,8 +388,8 @@ type MockProxy_CreateCredential_Call struct { } // CreateCredential is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.CreateCredentialRequest +// - ctx context.Context +// - req *milvuspb.CreateCredentialRequest func (_e *MockProxy_Expecter) CreateCredential(ctx interface{}, req interface{}) *MockProxy_CreateCredential_Call { return &MockProxy_CreateCredential_Call{Call: _e.mock.On("CreateCredential", ctx, req)} } @@ -410,20 +406,11 @@ func (_c *MockProxy_CreateCredential_Call) Return(_a0 *commonpb.Status, _a1 erro return _c } -func (_c *MockProxy_CreateCredential_Call) RunAndReturn(run func(context.Context, *milvuspb.CreateCredentialRequest) (*commonpb.Status, error)) *MockProxy_CreateCredential_Call { - _c.Call.Return(run) - return _c -} - // CreateIndex provides a mock function with given fields: ctx, request func (_m *MockProxy) CreateIndex(ctx context.Context, request *milvuspb.CreateIndexRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateIndexRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateIndexRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -432,6 +419,7 @@ func (_m *MockProxy) CreateIndex(ctx context.Context, request *milvuspb.CreateIn } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreateIndexRequest) error); ok { r1 = rf(ctx, request) } else { @@ -447,8 +435,8 @@ type MockProxy_CreateIndex_Call struct { } // CreateIndex is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.CreateIndexRequest +// - ctx context.Context +// - request *milvuspb.CreateIndexRequest func (_e *MockProxy_Expecter) CreateIndex(ctx interface{}, request interface{}) *MockProxy_CreateIndex_Call { return &MockProxy_CreateIndex_Call{Call: _e.mock.On("CreateIndex", ctx, request)} } @@ -465,20 +453,11 @@ func (_c *MockProxy_CreateIndex_Call) Return(_a0 *commonpb.Status, _a1 error) *M return _c } -func (_c *MockProxy_CreateIndex_Call) RunAndReturn(run func(context.Context, *milvuspb.CreateIndexRequest) (*commonpb.Status, error)) *MockProxy_CreateIndex_Call { - _c.Call.Return(run) - return _c -} - // CreatePartition provides a mock function with given fields: ctx, request func (_m *MockProxy) CreatePartition(ctx context.Context, request *milvuspb.CreatePartitionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreatePartitionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreatePartitionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -487,6 +466,7 @@ func (_m *MockProxy) CreatePartition(ctx context.Context, request *milvuspb.Crea } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreatePartitionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -502,8 +482,8 @@ type MockProxy_CreatePartition_Call struct { } // CreatePartition is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.CreatePartitionRequest +// - ctx context.Context +// - request *milvuspb.CreatePartitionRequest func (_e *MockProxy_Expecter) CreatePartition(ctx interface{}, request interface{}) *MockProxy_CreatePartition_Call { return &MockProxy_CreatePartition_Call{Call: _e.mock.On("CreatePartition", ctx, request)} } @@ -520,20 +500,11 @@ func (_c *MockProxy_CreatePartition_Call) Return(_a0 *commonpb.Status, _a1 error return _c } -func (_c *MockProxy_CreatePartition_Call) RunAndReturn(run func(context.Context, *milvuspb.CreatePartitionRequest) (*commonpb.Status, error)) *MockProxy_CreatePartition_Call { - _c.Call.Return(run) - return _c -} - // CreateResourceGroup provides a mock function with given fields: ctx, req func (_m *MockProxy) CreateResourceGroup(ctx context.Context, req *milvuspb.CreateResourceGroupRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateResourceGroupRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateResourceGroupRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -542,6 +513,7 @@ func (_m *MockProxy) CreateResourceGroup(ctx context.Context, req *milvuspb.Crea } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreateResourceGroupRequest) error); ok { r1 = rf(ctx, req) } else { @@ -557,8 +529,8 @@ type MockProxy_CreateResourceGroup_Call struct { } // CreateResourceGroup is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.CreateResourceGroupRequest +// - ctx context.Context +// - req *milvuspb.CreateResourceGroupRequest func (_e *MockProxy_Expecter) CreateResourceGroup(ctx interface{}, req interface{}) *MockProxy_CreateResourceGroup_Call { return &MockProxy_CreateResourceGroup_Call{Call: _e.mock.On("CreateResourceGroup", ctx, req)} } @@ -575,20 +547,11 @@ func (_c *MockProxy_CreateResourceGroup_Call) Return(_a0 *commonpb.Status, _a1 e return _c } -func (_c *MockProxy_CreateResourceGroup_Call) RunAndReturn(run func(context.Context, *milvuspb.CreateResourceGroupRequest) (*commonpb.Status, error)) *MockProxy_CreateResourceGroup_Call { - _c.Call.Return(run) - return _c -} - // CreateRole provides a mock function with given fields: ctx, req func (_m *MockProxy) CreateRole(ctx context.Context, req *milvuspb.CreateRoleRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateRoleRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.CreateRoleRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -597,6 +560,7 @@ func (_m *MockProxy) CreateRole(ctx context.Context, req *milvuspb.CreateRoleReq } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.CreateRoleRequest) error); ok { r1 = rf(ctx, req) } else { @@ -612,8 +576,8 @@ type MockProxy_CreateRole_Call struct { } // CreateRole is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.CreateRoleRequest +// - ctx context.Context +// - req *milvuspb.CreateRoleRequest func (_e *MockProxy_Expecter) CreateRole(ctx interface{}, req interface{}) *MockProxy_CreateRole_Call { return &MockProxy_CreateRole_Call{Call: _e.mock.On("CreateRole", ctx, req)} } @@ -630,20 +594,11 @@ func (_c *MockProxy_CreateRole_Call) Return(_a0 *commonpb.Status, _a1 error) *Mo return _c } -func (_c *MockProxy_CreateRole_Call) RunAndReturn(run func(context.Context, *milvuspb.CreateRoleRequest) (*commonpb.Status, error)) *MockProxy_CreateRole_Call { - _c.Call.Return(run) - return _c -} - // Delete provides a mock function with given fields: ctx, request func (_m *MockProxy) Delete(ctx context.Context, request *milvuspb.DeleteRequest) (*milvuspb.MutationResult, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.MutationResult - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DeleteRequest) (*milvuspb.MutationResult, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DeleteRequest) *milvuspb.MutationResult); ok { r0 = rf(ctx, request) } else { @@ -652,6 +607,7 @@ func (_m *MockProxy) Delete(ctx context.Context, request *milvuspb.DeleteRequest } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DeleteRequest) error); ok { r1 = rf(ctx, request) } else { @@ -667,8 +623,8 @@ type MockProxy_Delete_Call struct { } // Delete is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DeleteRequest +// - ctx context.Context +// - request *milvuspb.DeleteRequest func (_e *MockProxy_Expecter) Delete(ctx interface{}, request interface{}) *MockProxy_Delete_Call { return &MockProxy_Delete_Call{Call: _e.mock.On("Delete", ctx, request)} } @@ -685,20 +641,11 @@ func (_c *MockProxy_Delete_Call) Return(_a0 *milvuspb.MutationResult, _a1 error) return _c } -func (_c *MockProxy_Delete_Call) RunAndReturn(run func(context.Context, *milvuspb.DeleteRequest) (*milvuspb.MutationResult, error)) *MockProxy_Delete_Call { - _c.Call.Return(run) - return _c -} - // DeleteCredential provides a mock function with given fields: ctx, req func (_m *MockProxy) DeleteCredential(ctx context.Context, req *milvuspb.DeleteCredentialRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DeleteCredentialRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DeleteCredentialRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -707,6 +654,7 @@ func (_m *MockProxy) DeleteCredential(ctx context.Context, req *milvuspb.DeleteC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DeleteCredentialRequest) error); ok { r1 = rf(ctx, req) } else { @@ -722,8 +670,8 @@ type MockProxy_DeleteCredential_Call struct { } // DeleteCredential is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.DeleteCredentialRequest +// - ctx context.Context +// - req *milvuspb.DeleteCredentialRequest func (_e *MockProxy_Expecter) DeleteCredential(ctx interface{}, req interface{}) *MockProxy_DeleteCredential_Call { return &MockProxy_DeleteCredential_Call{Call: _e.mock.On("DeleteCredential", ctx, req)} } @@ -740,20 +688,11 @@ func (_c *MockProxy_DeleteCredential_Call) Return(_a0 *commonpb.Status, _a1 erro return _c } -func (_c *MockProxy_DeleteCredential_Call) RunAndReturn(run func(context.Context, *milvuspb.DeleteCredentialRequest) (*commonpb.Status, error)) *MockProxy_DeleteCredential_Call { - _c.Call.Return(run) - return _c -} - // DescribeCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) DescribeCollection(ctx context.Context, request *milvuspb.DescribeCollectionRequest) (*milvuspb.DescribeCollectionResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.DescribeCollectionResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DescribeCollectionRequest) (*milvuspb.DescribeCollectionResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DescribeCollectionRequest) *milvuspb.DescribeCollectionResponse); ok { r0 = rf(ctx, request) } else { @@ -762,6 +701,7 @@ func (_m *MockProxy) DescribeCollection(ctx context.Context, request *milvuspb.D } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DescribeCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -777,8 +717,8 @@ type MockProxy_DescribeCollection_Call struct { } // DescribeCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DescribeCollectionRequest +// - ctx context.Context +// - request *milvuspb.DescribeCollectionRequest func (_e *MockProxy_Expecter) DescribeCollection(ctx interface{}, request interface{}) *MockProxy_DescribeCollection_Call { return &MockProxy_DescribeCollection_Call{Call: _e.mock.On("DescribeCollection", ctx, request)} } @@ -795,20 +735,11 @@ func (_c *MockProxy_DescribeCollection_Call) Return(_a0 *milvuspb.DescribeCollec return _c } -func (_c *MockProxy_DescribeCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.DescribeCollectionRequest) (*milvuspb.DescribeCollectionResponse, error)) *MockProxy_DescribeCollection_Call { - _c.Call.Return(run) - return _c -} - // DescribeIndex provides a mock function with given fields: ctx, request func (_m *MockProxy) DescribeIndex(ctx context.Context, request *milvuspb.DescribeIndexRequest) (*milvuspb.DescribeIndexResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.DescribeIndexResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DescribeIndexRequest) (*milvuspb.DescribeIndexResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DescribeIndexRequest) *milvuspb.DescribeIndexResponse); ok { r0 = rf(ctx, request) } else { @@ -817,6 +748,7 @@ func (_m *MockProxy) DescribeIndex(ctx context.Context, request *milvuspb.Descri } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DescribeIndexRequest) error); ok { r1 = rf(ctx, request) } else { @@ -832,8 +764,8 @@ type MockProxy_DescribeIndex_Call struct { } // DescribeIndex is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DescribeIndexRequest +// - ctx context.Context +// - request *milvuspb.DescribeIndexRequest func (_e *MockProxy_Expecter) DescribeIndex(ctx interface{}, request interface{}) *MockProxy_DescribeIndex_Call { return &MockProxy_DescribeIndex_Call{Call: _e.mock.On("DescribeIndex", ctx, request)} } @@ -850,20 +782,11 @@ func (_c *MockProxy_DescribeIndex_Call) Return(_a0 *milvuspb.DescribeIndexRespon return _c } -func (_c *MockProxy_DescribeIndex_Call) RunAndReturn(run func(context.Context, *milvuspb.DescribeIndexRequest) (*milvuspb.DescribeIndexResponse, error)) *MockProxy_DescribeIndex_Call { - _c.Call.Return(run) - return _c -} - // DescribeResourceGroup provides a mock function with given fields: ctx, req func (_m *MockProxy) DescribeResourceGroup(ctx context.Context, req *milvuspb.DescribeResourceGroupRequest) (*milvuspb.DescribeResourceGroupResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.DescribeResourceGroupResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DescribeResourceGroupRequest) (*milvuspb.DescribeResourceGroupResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DescribeResourceGroupRequest) *milvuspb.DescribeResourceGroupResponse); ok { r0 = rf(ctx, req) } else { @@ -872,6 +795,7 @@ func (_m *MockProxy) DescribeResourceGroup(ctx context.Context, req *milvuspb.De } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DescribeResourceGroupRequest) error); ok { r1 = rf(ctx, req) } else { @@ -887,8 +811,8 @@ type MockProxy_DescribeResourceGroup_Call struct { } // DescribeResourceGroup is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.DescribeResourceGroupRequest +// - ctx context.Context +// - req *milvuspb.DescribeResourceGroupRequest func (_e *MockProxy_Expecter) DescribeResourceGroup(ctx interface{}, req interface{}) *MockProxy_DescribeResourceGroup_Call { return &MockProxy_DescribeResourceGroup_Call{Call: _e.mock.On("DescribeResourceGroup", ctx, req)} } @@ -905,20 +829,11 @@ func (_c *MockProxy_DescribeResourceGroup_Call) Return(_a0 *milvuspb.DescribeRes return _c } -func (_c *MockProxy_DescribeResourceGroup_Call) RunAndReturn(run func(context.Context, *milvuspb.DescribeResourceGroupRequest) (*milvuspb.DescribeResourceGroupResponse, error)) *MockProxy_DescribeResourceGroup_Call { - _c.Call.Return(run) - return _c -} - // DropAlias provides a mock function with given fields: ctx, request func (_m *MockProxy) DropAlias(ctx context.Context, request *milvuspb.DropAliasRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropAliasRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropAliasRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -927,6 +842,7 @@ func (_m *MockProxy) DropAlias(ctx context.Context, request *milvuspb.DropAliasR } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DropAliasRequest) error); ok { r1 = rf(ctx, request) } else { @@ -942,8 +858,8 @@ type MockProxy_DropAlias_Call struct { } // DropAlias is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DropAliasRequest +// - ctx context.Context +// - request *milvuspb.DropAliasRequest func (_e *MockProxy_Expecter) DropAlias(ctx interface{}, request interface{}) *MockProxy_DropAlias_Call { return &MockProxy_DropAlias_Call{Call: _e.mock.On("DropAlias", ctx, request)} } @@ -960,20 +876,11 @@ func (_c *MockProxy_DropAlias_Call) Return(_a0 *commonpb.Status, _a1 error) *Moc return _c } -func (_c *MockProxy_DropAlias_Call) RunAndReturn(run func(context.Context, *milvuspb.DropAliasRequest) (*commonpb.Status, error)) *MockProxy_DropAlias_Call { - _c.Call.Return(run) - return _c -} - // DropCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) DropCollection(ctx context.Context, request *milvuspb.DropCollectionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropCollectionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropCollectionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -982,6 +889,7 @@ func (_m *MockProxy) DropCollection(ctx context.Context, request *milvuspb.DropC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DropCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -997,8 +905,8 @@ type MockProxy_DropCollection_Call struct { } // DropCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DropCollectionRequest +// - ctx context.Context +// - request *milvuspb.DropCollectionRequest func (_e *MockProxy_Expecter) DropCollection(ctx interface{}, request interface{}) *MockProxy_DropCollection_Call { return &MockProxy_DropCollection_Call{Call: _e.mock.On("DropCollection", ctx, request)} } @@ -1015,20 +923,11 @@ func (_c *MockProxy_DropCollection_Call) Return(_a0 *commonpb.Status, _a1 error) return _c } -func (_c *MockProxy_DropCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.DropCollectionRequest) (*commonpb.Status, error)) *MockProxy_DropCollection_Call { - _c.Call.Return(run) - return _c -} - // DropIndex provides a mock function with given fields: ctx, request func (_m *MockProxy) DropIndex(ctx context.Context, request *milvuspb.DropIndexRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropIndexRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropIndexRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -1037,6 +936,7 @@ func (_m *MockProxy) DropIndex(ctx context.Context, request *milvuspb.DropIndexR } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DropIndexRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1052,8 +952,8 @@ type MockProxy_DropIndex_Call struct { } // DropIndex is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DropIndexRequest +// - ctx context.Context +// - request *milvuspb.DropIndexRequest func (_e *MockProxy_Expecter) DropIndex(ctx interface{}, request interface{}) *MockProxy_DropIndex_Call { return &MockProxy_DropIndex_Call{Call: _e.mock.On("DropIndex", ctx, request)} } @@ -1070,20 +970,11 @@ func (_c *MockProxy_DropIndex_Call) Return(_a0 *commonpb.Status, _a1 error) *Moc return _c } -func (_c *MockProxy_DropIndex_Call) RunAndReturn(run func(context.Context, *milvuspb.DropIndexRequest) (*commonpb.Status, error)) *MockProxy_DropIndex_Call { - _c.Call.Return(run) - return _c -} - // DropPartition provides a mock function with given fields: ctx, request func (_m *MockProxy) DropPartition(ctx context.Context, request *milvuspb.DropPartitionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropPartitionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropPartitionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -1092,6 +983,7 @@ func (_m *MockProxy) DropPartition(ctx context.Context, request *milvuspb.DropPa } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DropPartitionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1107,8 +999,8 @@ type MockProxy_DropPartition_Call struct { } // DropPartition is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DropPartitionRequest +// - ctx context.Context +// - request *milvuspb.DropPartitionRequest func (_e *MockProxy_Expecter) DropPartition(ctx interface{}, request interface{}) *MockProxy_DropPartition_Call { return &MockProxy_DropPartition_Call{Call: _e.mock.On("DropPartition", ctx, request)} } @@ -1125,20 +1017,11 @@ func (_c *MockProxy_DropPartition_Call) Return(_a0 *commonpb.Status, _a1 error) return _c } -func (_c *MockProxy_DropPartition_Call) RunAndReturn(run func(context.Context, *milvuspb.DropPartitionRequest) (*commonpb.Status, error)) *MockProxy_DropPartition_Call { - _c.Call.Return(run) - return _c -} - // DropResourceGroup provides a mock function with given fields: ctx, req func (_m *MockProxy) DropResourceGroup(ctx context.Context, req *milvuspb.DropResourceGroupRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropResourceGroupRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropResourceGroupRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -1147,6 +1030,7 @@ func (_m *MockProxy) DropResourceGroup(ctx context.Context, req *milvuspb.DropRe } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DropResourceGroupRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1162,8 +1046,8 @@ type MockProxy_DropResourceGroup_Call struct { } // DropResourceGroup is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.DropResourceGroupRequest +// - ctx context.Context +// - req *milvuspb.DropResourceGroupRequest func (_e *MockProxy_Expecter) DropResourceGroup(ctx interface{}, req interface{}) *MockProxy_DropResourceGroup_Call { return &MockProxy_DropResourceGroup_Call{Call: _e.mock.On("DropResourceGroup", ctx, req)} } @@ -1180,20 +1064,11 @@ func (_c *MockProxy_DropResourceGroup_Call) Return(_a0 *commonpb.Status, _a1 err return _c } -func (_c *MockProxy_DropResourceGroup_Call) RunAndReturn(run func(context.Context, *milvuspb.DropResourceGroupRequest) (*commonpb.Status, error)) *MockProxy_DropResourceGroup_Call { - _c.Call.Return(run) - return _c -} - // DropRole provides a mock function with given fields: ctx, req func (_m *MockProxy) DropRole(ctx context.Context, req *milvuspb.DropRoleRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropRoleRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DropRoleRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -1202,6 +1077,7 @@ func (_m *MockProxy) DropRole(ctx context.Context, req *milvuspb.DropRoleRequest } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DropRoleRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1217,8 +1093,8 @@ type MockProxy_DropRole_Call struct { } // DropRole is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.DropRoleRequest +// - ctx context.Context +// - req *milvuspb.DropRoleRequest func (_e *MockProxy_Expecter) DropRole(ctx interface{}, req interface{}) *MockProxy_DropRole_Call { return &MockProxy_DropRole_Call{Call: _e.mock.On("DropRole", ctx, req)} } @@ -1235,20 +1111,11 @@ func (_c *MockProxy_DropRole_Call) Return(_a0 *commonpb.Status, _a1 error) *Mock return _c } -func (_c *MockProxy_DropRole_Call) RunAndReturn(run func(context.Context, *milvuspb.DropRoleRequest) (*commonpb.Status, error)) *MockProxy_DropRole_Call { - _c.Call.Return(run) - return _c -} - // Dummy provides a mock function with given fields: ctx, request func (_m *MockProxy) Dummy(ctx context.Context, request *milvuspb.DummyRequest) (*milvuspb.DummyResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.DummyResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DummyRequest) (*milvuspb.DummyResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.DummyRequest) *milvuspb.DummyResponse); ok { r0 = rf(ctx, request) } else { @@ -1257,6 +1124,7 @@ func (_m *MockProxy) Dummy(ctx context.Context, request *milvuspb.DummyRequest) } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.DummyRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1272,8 +1140,8 @@ type MockProxy_Dummy_Call struct { } // Dummy is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.DummyRequest +// - ctx context.Context +// - request *milvuspb.DummyRequest func (_e *MockProxy_Expecter) Dummy(ctx interface{}, request interface{}) *MockProxy_Dummy_Call { return &MockProxy_Dummy_Call{Call: _e.mock.On("Dummy", ctx, request)} } @@ -1290,20 +1158,11 @@ func (_c *MockProxy_Dummy_Call) Return(_a0 *milvuspb.DummyResponse, _a1 error) * return _c } -func (_c *MockProxy_Dummy_Call) RunAndReturn(run func(context.Context, *milvuspb.DummyRequest) (*milvuspb.DummyResponse, error)) *MockProxy_Dummy_Call { - _c.Call.Return(run) - return _c -} - // Flush provides a mock function with given fields: ctx, request func (_m *MockProxy) Flush(ctx context.Context, request *milvuspb.FlushRequest) (*milvuspb.FlushResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.FlushResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.FlushRequest) (*milvuspb.FlushResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.FlushRequest) *milvuspb.FlushResponse); ok { r0 = rf(ctx, request) } else { @@ -1312,6 +1171,7 @@ func (_m *MockProxy) Flush(ctx context.Context, request *milvuspb.FlushRequest) } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.FlushRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1327,8 +1187,8 @@ type MockProxy_Flush_Call struct { } // Flush is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.FlushRequest +// - ctx context.Context +// - request *milvuspb.FlushRequest func (_e *MockProxy_Expecter) Flush(ctx interface{}, request interface{}) *MockProxy_Flush_Call { return &MockProxy_Flush_Call{Call: _e.mock.On("Flush", ctx, request)} } @@ -1345,20 +1205,11 @@ func (_c *MockProxy_Flush_Call) Return(_a0 *milvuspb.FlushResponse, _a1 error) * return _c } -func (_c *MockProxy_Flush_Call) RunAndReturn(run func(context.Context, *milvuspb.FlushRequest) (*milvuspb.FlushResponse, error)) *MockProxy_Flush_Call { - _c.Call.Return(run) - return _c -} - // FlushAll provides a mock function with given fields: ctx, request func (_m *MockProxy) FlushAll(ctx context.Context, request *milvuspb.FlushAllRequest) (*milvuspb.FlushAllResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.FlushAllResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.FlushAllRequest) (*milvuspb.FlushAllResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.FlushAllRequest) *milvuspb.FlushAllResponse); ok { r0 = rf(ctx, request) } else { @@ -1367,6 +1218,7 @@ func (_m *MockProxy) FlushAll(ctx context.Context, request *milvuspb.FlushAllReq } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.FlushAllRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1382,8 +1234,8 @@ type MockProxy_FlushAll_Call struct { } // FlushAll is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.FlushAllRequest +// - ctx context.Context +// - request *milvuspb.FlushAllRequest func (_e *MockProxy_Expecter) FlushAll(ctx interface{}, request interface{}) *MockProxy_FlushAll_Call { return &MockProxy_FlushAll_Call{Call: _e.mock.On("FlushAll", ctx, request)} } @@ -1400,11 +1252,6 @@ func (_c *MockProxy_FlushAll_Call) Return(_a0 *milvuspb.FlushAllResponse, _a1 er return _c } -func (_c *MockProxy_FlushAll_Call) RunAndReturn(run func(context.Context, *milvuspb.FlushAllRequest) (*milvuspb.FlushAllResponse, error)) *MockProxy_FlushAll_Call { - _c.Call.Return(run) - return _c -} - // GetAddress provides a mock function with given fields: func (_m *MockProxy) GetAddress() string { ret := _m.Called() @@ -1441,20 +1288,11 @@ func (_c *MockProxy_GetAddress_Call) Return(_a0 string) *MockProxy_GetAddress_Ca return _c } -func (_c *MockProxy_GetAddress_Call) RunAndReturn(run func() string) *MockProxy_GetAddress_Call { - _c.Call.Return(run) - return _c -} - // GetCollectionStatistics provides a mock function with given fields: ctx, request func (_m *MockProxy) GetCollectionStatistics(ctx context.Context, request *milvuspb.GetCollectionStatisticsRequest) (*milvuspb.GetCollectionStatisticsResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetCollectionStatisticsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCollectionStatisticsRequest) (*milvuspb.GetCollectionStatisticsResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCollectionStatisticsRequest) *milvuspb.GetCollectionStatisticsResponse); ok { r0 = rf(ctx, request) } else { @@ -1463,6 +1301,7 @@ func (_m *MockProxy) GetCollectionStatistics(ctx context.Context, request *milvu } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetCollectionStatisticsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1478,8 +1317,8 @@ type MockProxy_GetCollectionStatistics_Call struct { } // GetCollectionStatistics is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetCollectionStatisticsRequest +// - ctx context.Context +// - request *milvuspb.GetCollectionStatisticsRequest func (_e *MockProxy_Expecter) GetCollectionStatistics(ctx interface{}, request interface{}) *MockProxy_GetCollectionStatistics_Call { return &MockProxy_GetCollectionStatistics_Call{Call: _e.mock.On("GetCollectionStatistics", ctx, request)} } @@ -1496,20 +1335,11 @@ func (_c *MockProxy_GetCollectionStatistics_Call) Return(_a0 *milvuspb.GetCollec return _c } -func (_c *MockProxy_GetCollectionStatistics_Call) RunAndReturn(run func(context.Context, *milvuspb.GetCollectionStatisticsRequest) (*milvuspb.GetCollectionStatisticsResponse, error)) *MockProxy_GetCollectionStatistics_Call { - _c.Call.Return(run) - return _c -} - // GetCompactionState provides a mock function with given fields: ctx, req func (_m *MockProxy) GetCompactionState(ctx context.Context, req *milvuspb.GetCompactionStateRequest) (*milvuspb.GetCompactionStateResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.GetCompactionStateResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionStateRequest) (*milvuspb.GetCompactionStateResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionStateRequest) *milvuspb.GetCompactionStateResponse); ok { r0 = rf(ctx, req) } else { @@ -1518,6 +1348,7 @@ func (_m *MockProxy) GetCompactionState(ctx context.Context, req *milvuspb.GetCo } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetCompactionStateRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1533,8 +1364,8 @@ type MockProxy_GetCompactionState_Call struct { } // GetCompactionState is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.GetCompactionStateRequest +// - ctx context.Context +// - req *milvuspb.GetCompactionStateRequest func (_e *MockProxy_Expecter) GetCompactionState(ctx interface{}, req interface{}) *MockProxy_GetCompactionState_Call { return &MockProxy_GetCompactionState_Call{Call: _e.mock.On("GetCompactionState", ctx, req)} } @@ -1551,20 +1382,11 @@ func (_c *MockProxy_GetCompactionState_Call) Return(_a0 *milvuspb.GetCompactionS return _c } -func (_c *MockProxy_GetCompactionState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetCompactionStateRequest) (*milvuspb.GetCompactionStateResponse, error)) *MockProxy_GetCompactionState_Call { - _c.Call.Return(run) - return _c -} - // GetCompactionStateWithPlans provides a mock function with given fields: ctx, req func (_m *MockProxy) GetCompactionStateWithPlans(ctx context.Context, req *milvuspb.GetCompactionPlansRequest) (*milvuspb.GetCompactionPlansResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.GetCompactionPlansResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionPlansRequest) (*milvuspb.GetCompactionPlansResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetCompactionPlansRequest) *milvuspb.GetCompactionPlansResponse); ok { r0 = rf(ctx, req) } else { @@ -1573,6 +1395,7 @@ func (_m *MockProxy) GetCompactionStateWithPlans(ctx context.Context, req *milvu } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetCompactionPlansRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1588,8 +1411,8 @@ type MockProxy_GetCompactionStateWithPlans_Call struct { } // GetCompactionStateWithPlans is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.GetCompactionPlansRequest +// - ctx context.Context +// - req *milvuspb.GetCompactionPlansRequest func (_e *MockProxy_Expecter) GetCompactionStateWithPlans(ctx interface{}, req interface{}) *MockProxy_GetCompactionStateWithPlans_Call { return &MockProxy_GetCompactionStateWithPlans_Call{Call: _e.mock.On("GetCompactionStateWithPlans", ctx, req)} } @@ -1606,20 +1429,11 @@ func (_c *MockProxy_GetCompactionStateWithPlans_Call) Return(_a0 *milvuspb.GetCo return _c } -func (_c *MockProxy_GetCompactionStateWithPlans_Call) RunAndReturn(run func(context.Context, *milvuspb.GetCompactionPlansRequest) (*milvuspb.GetCompactionPlansResponse, error)) *MockProxy_GetCompactionStateWithPlans_Call { - _c.Call.Return(run) - return _c -} - // GetComponentStates provides a mock function with given fields: ctx func (_m *MockProxy) GetComponentStates(ctx context.Context) (*milvuspb.ComponentStates, error) { ret := _m.Called(ctx) var r0 *milvuspb.ComponentStates - var r1 error - if rf, ok := ret.Get(0).(func(context.Context) (*milvuspb.ComponentStates, error)); ok { - return rf(ctx) - } if rf, ok := ret.Get(0).(func(context.Context) *milvuspb.ComponentStates); ok { r0 = rf(ctx) } else { @@ -1628,6 +1442,7 @@ func (_m *MockProxy) GetComponentStates(ctx context.Context) (*milvuspb.Componen } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context) error); ok { r1 = rf(ctx) } else { @@ -1643,7 +1458,7 @@ type MockProxy_GetComponentStates_Call struct { } // GetComponentStates is a helper method to define mock.On call -// - ctx context.Context +// - ctx context.Context func (_e *MockProxy_Expecter) GetComponentStates(ctx interface{}) *MockProxy_GetComponentStates_Call { return &MockProxy_GetComponentStates_Call{Call: _e.mock.On("GetComponentStates", ctx)} } @@ -1660,20 +1475,11 @@ func (_c *MockProxy_GetComponentStates_Call) Return(_a0 *milvuspb.ComponentState return _c } -func (_c *MockProxy_GetComponentStates_Call) RunAndReturn(run func(context.Context) (*milvuspb.ComponentStates, error)) *MockProxy_GetComponentStates_Call { - _c.Call.Return(run) - return _c -} - // GetDdChannel provides a mock function with given fields: ctx, request func (_m *MockProxy) GetDdChannel(ctx context.Context, request *internalpb.GetDdChannelRequest) (*milvuspb.StringResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.StringResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *internalpb.GetDdChannelRequest) (*milvuspb.StringResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *internalpb.GetDdChannelRequest) *milvuspb.StringResponse); ok { r0 = rf(ctx, request) } else { @@ -1682,6 +1488,7 @@ func (_m *MockProxy) GetDdChannel(ctx context.Context, request *internalpb.GetDd } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *internalpb.GetDdChannelRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1697,8 +1504,8 @@ type MockProxy_GetDdChannel_Call struct { } // GetDdChannel is a helper method to define mock.On call -// - ctx context.Context -// - request *internalpb.GetDdChannelRequest +// - ctx context.Context +// - request *internalpb.GetDdChannelRequest func (_e *MockProxy_Expecter) GetDdChannel(ctx interface{}, request interface{}) *MockProxy_GetDdChannel_Call { return &MockProxy_GetDdChannel_Call{Call: _e.mock.On("GetDdChannel", ctx, request)} } @@ -1715,20 +1522,11 @@ func (_c *MockProxy_GetDdChannel_Call) Return(_a0 *milvuspb.StringResponse, _a1 return _c } -func (_c *MockProxy_GetDdChannel_Call) RunAndReturn(run func(context.Context, *internalpb.GetDdChannelRequest) (*milvuspb.StringResponse, error)) *MockProxy_GetDdChannel_Call { - _c.Call.Return(run) - return _c -} - // GetFlushAllState provides a mock function with given fields: ctx, req func (_m *MockProxy) GetFlushAllState(ctx context.Context, req *milvuspb.GetFlushAllStateRequest) (*milvuspb.GetFlushAllStateResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.GetFlushAllStateResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetFlushAllStateRequest) (*milvuspb.GetFlushAllStateResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetFlushAllStateRequest) *milvuspb.GetFlushAllStateResponse); ok { r0 = rf(ctx, req) } else { @@ -1737,6 +1535,7 @@ func (_m *MockProxy) GetFlushAllState(ctx context.Context, req *milvuspb.GetFlus } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetFlushAllStateRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1752,8 +1551,8 @@ type MockProxy_GetFlushAllState_Call struct { } // GetFlushAllState is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.GetFlushAllStateRequest +// - ctx context.Context +// - req *milvuspb.GetFlushAllStateRequest func (_e *MockProxy_Expecter) GetFlushAllState(ctx interface{}, req interface{}) *MockProxy_GetFlushAllState_Call { return &MockProxy_GetFlushAllState_Call{Call: _e.mock.On("GetFlushAllState", ctx, req)} } @@ -1770,20 +1569,11 @@ func (_c *MockProxy_GetFlushAllState_Call) Return(_a0 *milvuspb.GetFlushAllState return _c } -func (_c *MockProxy_GetFlushAllState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetFlushAllStateRequest) (*milvuspb.GetFlushAllStateResponse, error)) *MockProxy_GetFlushAllState_Call { - _c.Call.Return(run) - return _c -} - // GetFlushState provides a mock function with given fields: ctx, req func (_m *MockProxy) GetFlushState(ctx context.Context, req *milvuspb.GetFlushStateRequest) (*milvuspb.GetFlushStateResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.GetFlushStateResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetFlushStateRequest) (*milvuspb.GetFlushStateResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetFlushStateRequest) *milvuspb.GetFlushStateResponse); ok { r0 = rf(ctx, req) } else { @@ -1792,6 +1582,7 @@ func (_m *MockProxy) GetFlushState(ctx context.Context, req *milvuspb.GetFlushSt } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetFlushStateRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1807,8 +1598,8 @@ type MockProxy_GetFlushState_Call struct { } // GetFlushState is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.GetFlushStateRequest +// - ctx context.Context +// - req *milvuspb.GetFlushStateRequest func (_e *MockProxy_Expecter) GetFlushState(ctx interface{}, req interface{}) *MockProxy_GetFlushState_Call { return &MockProxy_GetFlushState_Call{Call: _e.mock.On("GetFlushState", ctx, req)} } @@ -1825,20 +1616,11 @@ func (_c *MockProxy_GetFlushState_Call) Return(_a0 *milvuspb.GetFlushStateRespon return _c } -func (_c *MockProxy_GetFlushState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetFlushStateRequest) (*milvuspb.GetFlushStateResponse, error)) *MockProxy_GetFlushState_Call { - _c.Call.Return(run) - return _c -} - // GetImportState provides a mock function with given fields: ctx, req func (_m *MockProxy) GetImportState(ctx context.Context, req *milvuspb.GetImportStateRequest) (*milvuspb.GetImportStateResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.GetImportStateResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetImportStateRequest) (*milvuspb.GetImportStateResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetImportStateRequest) *milvuspb.GetImportStateResponse); ok { r0 = rf(ctx, req) } else { @@ -1847,6 +1629,7 @@ func (_m *MockProxy) GetImportState(ctx context.Context, req *milvuspb.GetImport } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetImportStateRequest) error); ok { r1 = rf(ctx, req) } else { @@ -1862,8 +1645,8 @@ type MockProxy_GetImportState_Call struct { } // GetImportState is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.GetImportStateRequest +// - ctx context.Context +// - req *milvuspb.GetImportStateRequest func (_e *MockProxy_Expecter) GetImportState(ctx interface{}, req interface{}) *MockProxy_GetImportState_Call { return &MockProxy_GetImportState_Call{Call: _e.mock.On("GetImportState", ctx, req)} } @@ -1880,20 +1663,11 @@ func (_c *MockProxy_GetImportState_Call) Return(_a0 *milvuspb.GetImportStateResp return _c } -func (_c *MockProxy_GetImportState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetImportStateRequest) (*milvuspb.GetImportStateResponse, error)) *MockProxy_GetImportState_Call { - _c.Call.Return(run) - return _c -} - // GetIndexBuildProgress provides a mock function with given fields: ctx, request func (_m *MockProxy) GetIndexBuildProgress(ctx context.Context, request *milvuspb.GetIndexBuildProgressRequest) (*milvuspb.GetIndexBuildProgressResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetIndexBuildProgressResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetIndexBuildProgressRequest) (*milvuspb.GetIndexBuildProgressResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetIndexBuildProgressRequest) *milvuspb.GetIndexBuildProgressResponse); ok { r0 = rf(ctx, request) } else { @@ -1902,6 +1676,7 @@ func (_m *MockProxy) GetIndexBuildProgress(ctx context.Context, request *milvusp } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetIndexBuildProgressRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1917,8 +1692,8 @@ type MockProxy_GetIndexBuildProgress_Call struct { } // GetIndexBuildProgress is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetIndexBuildProgressRequest +// - ctx context.Context +// - request *milvuspb.GetIndexBuildProgressRequest func (_e *MockProxy_Expecter) GetIndexBuildProgress(ctx interface{}, request interface{}) *MockProxy_GetIndexBuildProgress_Call { return &MockProxy_GetIndexBuildProgress_Call{Call: _e.mock.On("GetIndexBuildProgress", ctx, request)} } @@ -1935,20 +1710,11 @@ func (_c *MockProxy_GetIndexBuildProgress_Call) Return(_a0 *milvuspb.GetIndexBui return _c } -func (_c *MockProxy_GetIndexBuildProgress_Call) RunAndReturn(run func(context.Context, *milvuspb.GetIndexBuildProgressRequest) (*milvuspb.GetIndexBuildProgressResponse, error)) *MockProxy_GetIndexBuildProgress_Call { - _c.Call.Return(run) - return _c -} - // GetIndexState provides a mock function with given fields: ctx, request func (_m *MockProxy) GetIndexState(ctx context.Context, request *milvuspb.GetIndexStateRequest) (*milvuspb.GetIndexStateResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetIndexStateResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetIndexStateRequest) (*milvuspb.GetIndexStateResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetIndexStateRequest) *milvuspb.GetIndexStateResponse); ok { r0 = rf(ctx, request) } else { @@ -1957,6 +1723,7 @@ func (_m *MockProxy) GetIndexState(ctx context.Context, request *milvuspb.GetInd } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetIndexStateRequest) error); ok { r1 = rf(ctx, request) } else { @@ -1972,8 +1739,8 @@ type MockProxy_GetIndexState_Call struct { } // GetIndexState is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetIndexStateRequest +// - ctx context.Context +// - request *milvuspb.GetIndexStateRequest func (_e *MockProxy_Expecter) GetIndexState(ctx interface{}, request interface{}) *MockProxy_GetIndexState_Call { return &MockProxy_GetIndexState_Call{Call: _e.mock.On("GetIndexState", ctx, request)} } @@ -1990,8 +1757,50 @@ func (_c *MockProxy_GetIndexState_Call) Return(_a0 *milvuspb.GetIndexStateRespon return _c } -func (_c *MockProxy_GetIndexState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetIndexStateRequest) (*milvuspb.GetIndexStateResponse, error)) *MockProxy_GetIndexState_Call { - _c.Call.Return(run) +// GetIndexStatistics provides a mock function with given fields: ctx, request +func (_m *MockProxy) GetIndexStatistics(ctx context.Context, request *milvuspb.GetIndexStatisticsRequest) (*milvuspb.GetIndexStatisticsResponse, error) { + ret := _m.Called(ctx, request) + + var r0 *milvuspb.GetIndexStatisticsResponse + if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetIndexStatisticsRequest) *milvuspb.GetIndexStatisticsResponse); ok { + r0 = rf(ctx, request) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*milvuspb.GetIndexStatisticsResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetIndexStatisticsRequest) error); ok { + r1 = rf(ctx, request) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// MockProxy_GetIndexStatistics_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndexStatistics' +type MockProxy_GetIndexStatistics_Call struct { + *mock.Call +} + +// GetIndexStatistics is a helper method to define mock.On call +// - ctx context.Context +// - request *milvuspb.GetIndexStatisticsRequest +func (_e *MockProxy_Expecter) GetIndexStatistics(ctx interface{}, request interface{}) *MockProxy_GetIndexStatistics_Call { + return &MockProxy_GetIndexStatistics_Call{Call: _e.mock.On("GetIndexStatistics", ctx, request)} +} + +func (_c *MockProxy_GetIndexStatistics_Call) Run(run func(ctx context.Context, request *milvuspb.GetIndexStatisticsRequest)) *MockProxy_GetIndexStatistics_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(*milvuspb.GetIndexStatisticsRequest)) + }) + return _c +} + +func (_c *MockProxy_GetIndexStatistics_Call) Return(_a0 *milvuspb.GetIndexStatisticsResponse, _a1 error) *MockProxy_GetIndexStatistics_Call { + _c.Call.Return(_a0, _a1) return _c } @@ -2000,10 +1809,6 @@ func (_m *MockProxy) GetLoadState(ctx context.Context, request *milvuspb.GetLoad ret := _m.Called(ctx, request) var r0 *milvuspb.GetLoadStateResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetLoadStateRequest) (*milvuspb.GetLoadStateResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetLoadStateRequest) *milvuspb.GetLoadStateResponse); ok { r0 = rf(ctx, request) } else { @@ -2012,6 +1817,7 @@ func (_m *MockProxy) GetLoadState(ctx context.Context, request *milvuspb.GetLoad } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetLoadStateRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2027,8 +1833,8 @@ type MockProxy_GetLoadState_Call struct { } // GetLoadState is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetLoadStateRequest +// - ctx context.Context +// - request *milvuspb.GetLoadStateRequest func (_e *MockProxy_Expecter) GetLoadState(ctx interface{}, request interface{}) *MockProxy_GetLoadState_Call { return &MockProxy_GetLoadState_Call{Call: _e.mock.On("GetLoadState", ctx, request)} } @@ -2045,20 +1851,11 @@ func (_c *MockProxy_GetLoadState_Call) Return(_a0 *milvuspb.GetLoadStateResponse return _c } -func (_c *MockProxy_GetLoadState_Call) RunAndReturn(run func(context.Context, *milvuspb.GetLoadStateRequest) (*milvuspb.GetLoadStateResponse, error)) *MockProxy_GetLoadState_Call { - _c.Call.Return(run) - return _c -} - // GetLoadingProgress provides a mock function with given fields: ctx, request func (_m *MockProxy) GetLoadingProgress(ctx context.Context, request *milvuspb.GetLoadingProgressRequest) (*milvuspb.GetLoadingProgressResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetLoadingProgressResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetLoadingProgressRequest) (*milvuspb.GetLoadingProgressResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetLoadingProgressRequest) *milvuspb.GetLoadingProgressResponse); ok { r0 = rf(ctx, request) } else { @@ -2067,6 +1864,7 @@ func (_m *MockProxy) GetLoadingProgress(ctx context.Context, request *milvuspb.G } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetLoadingProgressRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2082,8 +1880,8 @@ type MockProxy_GetLoadingProgress_Call struct { } // GetLoadingProgress is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetLoadingProgressRequest +// - ctx context.Context +// - request *milvuspb.GetLoadingProgressRequest func (_e *MockProxy_Expecter) GetLoadingProgress(ctx interface{}, request interface{}) *MockProxy_GetLoadingProgress_Call { return &MockProxy_GetLoadingProgress_Call{Call: _e.mock.On("GetLoadingProgress", ctx, request)} } @@ -2100,20 +1898,11 @@ func (_c *MockProxy_GetLoadingProgress_Call) Return(_a0 *milvuspb.GetLoadingProg return _c } -func (_c *MockProxy_GetLoadingProgress_Call) RunAndReturn(run func(context.Context, *milvuspb.GetLoadingProgressRequest) (*milvuspb.GetLoadingProgressResponse, error)) *MockProxy_GetLoadingProgress_Call { - _c.Call.Return(run) - return _c -} - // GetMetrics provides a mock function with given fields: ctx, request func (_m *MockProxy) GetMetrics(ctx context.Context, request *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetMetricsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetMetricsRequest) *milvuspb.GetMetricsResponse); ok { r0 = rf(ctx, request) } else { @@ -2122,6 +1911,7 @@ func (_m *MockProxy) GetMetrics(ctx context.Context, request *milvuspb.GetMetric } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetMetricsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2137,8 +1927,8 @@ type MockProxy_GetMetrics_Call struct { } // GetMetrics is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetMetricsRequest +// - ctx context.Context +// - request *milvuspb.GetMetricsRequest func (_e *MockProxy_Expecter) GetMetrics(ctx interface{}, request interface{}) *MockProxy_GetMetrics_Call { return &MockProxy_GetMetrics_Call{Call: _e.mock.On("GetMetrics", ctx, request)} } @@ -2155,20 +1945,11 @@ func (_c *MockProxy_GetMetrics_Call) Return(_a0 *milvuspb.GetMetricsResponse, _a return _c } -func (_c *MockProxy_GetMetrics_Call) RunAndReturn(run func(context.Context, *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error)) *MockProxy_GetMetrics_Call { - _c.Call.Return(run) - return _c -} - // GetPartitionStatistics provides a mock function with given fields: ctx, request func (_m *MockProxy) GetPartitionStatistics(ctx context.Context, request *milvuspb.GetPartitionStatisticsRequest) (*milvuspb.GetPartitionStatisticsResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetPartitionStatisticsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetPartitionStatisticsRequest) (*milvuspb.GetPartitionStatisticsResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetPartitionStatisticsRequest) *milvuspb.GetPartitionStatisticsResponse); ok { r0 = rf(ctx, request) } else { @@ -2177,6 +1958,7 @@ func (_m *MockProxy) GetPartitionStatistics(ctx context.Context, request *milvus } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetPartitionStatisticsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2192,8 +1974,8 @@ type MockProxy_GetPartitionStatistics_Call struct { } // GetPartitionStatistics is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetPartitionStatisticsRequest +// - ctx context.Context +// - request *milvuspb.GetPartitionStatisticsRequest func (_e *MockProxy_Expecter) GetPartitionStatistics(ctx interface{}, request interface{}) *MockProxy_GetPartitionStatistics_Call { return &MockProxy_GetPartitionStatistics_Call{Call: _e.mock.On("GetPartitionStatistics", ctx, request)} } @@ -2210,20 +1992,11 @@ func (_c *MockProxy_GetPartitionStatistics_Call) Return(_a0 *milvuspb.GetPartiti return _c } -func (_c *MockProxy_GetPartitionStatistics_Call) RunAndReturn(run func(context.Context, *milvuspb.GetPartitionStatisticsRequest) (*milvuspb.GetPartitionStatisticsResponse, error)) *MockProxy_GetPartitionStatistics_Call { - _c.Call.Return(run) - return _c -} - // GetPersistentSegmentInfo provides a mock function with given fields: ctx, request func (_m *MockProxy) GetPersistentSegmentInfo(ctx context.Context, request *milvuspb.GetPersistentSegmentInfoRequest) (*milvuspb.GetPersistentSegmentInfoResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetPersistentSegmentInfoResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetPersistentSegmentInfoRequest) (*milvuspb.GetPersistentSegmentInfoResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetPersistentSegmentInfoRequest) *milvuspb.GetPersistentSegmentInfoResponse); ok { r0 = rf(ctx, request) } else { @@ -2232,6 +2005,7 @@ func (_m *MockProxy) GetPersistentSegmentInfo(ctx context.Context, request *milv } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetPersistentSegmentInfoRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2247,8 +2021,8 @@ type MockProxy_GetPersistentSegmentInfo_Call struct { } // GetPersistentSegmentInfo is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetPersistentSegmentInfoRequest +// - ctx context.Context +// - request *milvuspb.GetPersistentSegmentInfoRequest func (_e *MockProxy_Expecter) GetPersistentSegmentInfo(ctx interface{}, request interface{}) *MockProxy_GetPersistentSegmentInfo_Call { return &MockProxy_GetPersistentSegmentInfo_Call{Call: _e.mock.On("GetPersistentSegmentInfo", ctx, request)} } @@ -2265,20 +2039,11 @@ func (_c *MockProxy_GetPersistentSegmentInfo_Call) Return(_a0 *milvuspb.GetPersi return _c } -func (_c *MockProxy_GetPersistentSegmentInfo_Call) RunAndReturn(run func(context.Context, *milvuspb.GetPersistentSegmentInfoRequest) (*milvuspb.GetPersistentSegmentInfoResponse, error)) *MockProxy_GetPersistentSegmentInfo_Call { - _c.Call.Return(run) - return _c -} - // GetProxyMetrics provides a mock function with given fields: ctx, request func (_m *MockProxy) GetProxyMetrics(ctx context.Context, request *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetMetricsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetMetricsRequest) *milvuspb.GetMetricsResponse); ok { r0 = rf(ctx, request) } else { @@ -2287,6 +2052,7 @@ func (_m *MockProxy) GetProxyMetrics(ctx context.Context, request *milvuspb.GetM } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetMetricsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2302,8 +2068,8 @@ type MockProxy_GetProxyMetrics_Call struct { } // GetProxyMetrics is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetMetricsRequest +// - ctx context.Context +// - request *milvuspb.GetMetricsRequest func (_e *MockProxy_Expecter) GetProxyMetrics(ctx interface{}, request interface{}) *MockProxy_GetProxyMetrics_Call { return &MockProxy_GetProxyMetrics_Call{Call: _e.mock.On("GetProxyMetrics", ctx, request)} } @@ -2320,20 +2086,11 @@ func (_c *MockProxy_GetProxyMetrics_Call) Return(_a0 *milvuspb.GetMetricsRespons return _c } -func (_c *MockProxy_GetProxyMetrics_Call) RunAndReturn(run func(context.Context, *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error)) *MockProxy_GetProxyMetrics_Call { - _c.Call.Return(run) - return _c -} - // GetQuerySegmentInfo provides a mock function with given fields: ctx, request func (_m *MockProxy) GetQuerySegmentInfo(ctx context.Context, request *milvuspb.GetQuerySegmentInfoRequest) (*milvuspb.GetQuerySegmentInfoResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.GetQuerySegmentInfoResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetQuerySegmentInfoRequest) (*milvuspb.GetQuerySegmentInfoResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetQuerySegmentInfoRequest) *milvuspb.GetQuerySegmentInfoResponse); ok { r0 = rf(ctx, request) } else { @@ -2342,6 +2099,7 @@ func (_m *MockProxy) GetQuerySegmentInfo(ctx context.Context, request *milvuspb. } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetQuerySegmentInfoRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2357,8 +2115,8 @@ type MockProxy_GetQuerySegmentInfo_Call struct { } // GetQuerySegmentInfo is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.GetQuerySegmentInfoRequest +// - ctx context.Context +// - request *milvuspb.GetQuerySegmentInfoRequest func (_e *MockProxy_Expecter) GetQuerySegmentInfo(ctx interface{}, request interface{}) *MockProxy_GetQuerySegmentInfo_Call { return &MockProxy_GetQuerySegmentInfo_Call{Call: _e.mock.On("GetQuerySegmentInfo", ctx, request)} } @@ -2375,20 +2133,11 @@ func (_c *MockProxy_GetQuerySegmentInfo_Call) Return(_a0 *milvuspb.GetQuerySegme return _c } -func (_c *MockProxy_GetQuerySegmentInfo_Call) RunAndReturn(run func(context.Context, *milvuspb.GetQuerySegmentInfoRequest) (*milvuspb.GetQuerySegmentInfoResponse, error)) *MockProxy_GetQuerySegmentInfo_Call { - _c.Call.Return(run) - return _c -} - // GetRateLimiter provides a mock function with given fields: func (_m *MockProxy) GetRateLimiter() (Limiter, error) { ret := _m.Called() var r0 Limiter - var r1 error - if rf, ok := ret.Get(0).(func() (Limiter, error)); ok { - return rf() - } if rf, ok := ret.Get(0).(func() Limiter); ok { r0 = rf() } else { @@ -2397,6 +2146,7 @@ func (_m *MockProxy) GetRateLimiter() (Limiter, error) { } } + var r1 error if rf, ok := ret.Get(1).(func() error); ok { r1 = rf() } else { @@ -2428,20 +2178,11 @@ func (_c *MockProxy_GetRateLimiter_Call) Return(_a0 Limiter, _a1 error) *MockPro return _c } -func (_c *MockProxy_GetRateLimiter_Call) RunAndReturn(run func() (Limiter, error)) *MockProxy_GetRateLimiter_Call { - _c.Call.Return(run) - return _c -} - // GetReplicas provides a mock function with given fields: ctx, req func (_m *MockProxy) GetReplicas(ctx context.Context, req *milvuspb.GetReplicasRequest) (*milvuspb.GetReplicasResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.GetReplicasResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetReplicasRequest) (*milvuspb.GetReplicasResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.GetReplicasRequest) *milvuspb.GetReplicasResponse); ok { r0 = rf(ctx, req) } else { @@ -2450,6 +2191,7 @@ func (_m *MockProxy) GetReplicas(ctx context.Context, req *milvuspb.GetReplicasR } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.GetReplicasRequest) error); ok { r1 = rf(ctx, req) } else { @@ -2465,8 +2207,8 @@ type MockProxy_GetReplicas_Call struct { } // GetReplicas is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.GetReplicasRequest +// - ctx context.Context +// - req *milvuspb.GetReplicasRequest func (_e *MockProxy_Expecter) GetReplicas(ctx interface{}, req interface{}) *MockProxy_GetReplicas_Call { return &MockProxy_GetReplicas_Call{Call: _e.mock.On("GetReplicas", ctx, req)} } @@ -2483,20 +2225,11 @@ func (_c *MockProxy_GetReplicas_Call) Return(_a0 *milvuspb.GetReplicasResponse, return _c } -func (_c *MockProxy_GetReplicas_Call) RunAndReturn(run func(context.Context, *milvuspb.GetReplicasRequest) (*milvuspb.GetReplicasResponse, error)) *MockProxy_GetReplicas_Call { - _c.Call.Return(run) - return _c -} - // GetStatisticsChannel provides a mock function with given fields: ctx func (_m *MockProxy) GetStatisticsChannel(ctx context.Context) (*milvuspb.StringResponse, error) { ret := _m.Called(ctx) var r0 *milvuspb.StringResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context) (*milvuspb.StringResponse, error)); ok { - return rf(ctx) - } if rf, ok := ret.Get(0).(func(context.Context) *milvuspb.StringResponse); ok { r0 = rf(ctx) } else { @@ -2505,6 +2238,7 @@ func (_m *MockProxy) GetStatisticsChannel(ctx context.Context) (*milvuspb.String } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context) error); ok { r1 = rf(ctx) } else { @@ -2520,7 +2254,7 @@ type MockProxy_GetStatisticsChannel_Call struct { } // GetStatisticsChannel is a helper method to define mock.On call -// - ctx context.Context +// - ctx context.Context func (_e *MockProxy_Expecter) GetStatisticsChannel(ctx interface{}) *MockProxy_GetStatisticsChannel_Call { return &MockProxy_GetStatisticsChannel_Call{Call: _e.mock.On("GetStatisticsChannel", ctx)} } @@ -2537,20 +2271,11 @@ func (_c *MockProxy_GetStatisticsChannel_Call) Return(_a0 *milvuspb.StringRespon return _c } -func (_c *MockProxy_GetStatisticsChannel_Call) RunAndReturn(run func(context.Context) (*milvuspb.StringResponse, error)) *MockProxy_GetStatisticsChannel_Call { - _c.Call.Return(run) - return _c -} - // HasCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) HasCollection(ctx context.Context, request *milvuspb.HasCollectionRequest) (*milvuspb.BoolResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.BoolResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.HasCollectionRequest) (*milvuspb.BoolResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.HasCollectionRequest) *milvuspb.BoolResponse); ok { r0 = rf(ctx, request) } else { @@ -2559,6 +2284,7 @@ func (_m *MockProxy) HasCollection(ctx context.Context, request *milvuspb.HasCol } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.HasCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2574,8 +2300,8 @@ type MockProxy_HasCollection_Call struct { } // HasCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.HasCollectionRequest +// - ctx context.Context +// - request *milvuspb.HasCollectionRequest func (_e *MockProxy_Expecter) HasCollection(ctx interface{}, request interface{}) *MockProxy_HasCollection_Call { return &MockProxy_HasCollection_Call{Call: _e.mock.On("HasCollection", ctx, request)} } @@ -2592,20 +2318,11 @@ func (_c *MockProxy_HasCollection_Call) Return(_a0 *milvuspb.BoolResponse, _a1 e return _c } -func (_c *MockProxy_HasCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.HasCollectionRequest) (*milvuspb.BoolResponse, error)) *MockProxy_HasCollection_Call { - _c.Call.Return(run) - return _c -} - // HasPartition provides a mock function with given fields: ctx, request func (_m *MockProxy) HasPartition(ctx context.Context, request *milvuspb.HasPartitionRequest) (*milvuspb.BoolResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.BoolResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.HasPartitionRequest) (*milvuspb.BoolResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.HasPartitionRequest) *milvuspb.BoolResponse); ok { r0 = rf(ctx, request) } else { @@ -2614,6 +2331,7 @@ func (_m *MockProxy) HasPartition(ctx context.Context, request *milvuspb.HasPart } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.HasPartitionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2629,8 +2347,8 @@ type MockProxy_HasPartition_Call struct { } // HasPartition is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.HasPartitionRequest +// - ctx context.Context +// - request *milvuspb.HasPartitionRequest func (_e *MockProxy_Expecter) HasPartition(ctx interface{}, request interface{}) *MockProxy_HasPartition_Call { return &MockProxy_HasPartition_Call{Call: _e.mock.On("HasPartition", ctx, request)} } @@ -2647,20 +2365,11 @@ func (_c *MockProxy_HasPartition_Call) Return(_a0 *milvuspb.BoolResponse, _a1 er return _c } -func (_c *MockProxy_HasPartition_Call) RunAndReturn(run func(context.Context, *milvuspb.HasPartitionRequest) (*milvuspb.BoolResponse, error)) *MockProxy_HasPartition_Call { - _c.Call.Return(run) - return _c -} - // Import provides a mock function with given fields: ctx, req func (_m *MockProxy) Import(ctx context.Context, req *milvuspb.ImportRequest) (*milvuspb.ImportResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.ImportResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ImportRequest) (*milvuspb.ImportResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ImportRequest) *milvuspb.ImportResponse); ok { r0 = rf(ctx, req) } else { @@ -2669,6 +2378,7 @@ func (_m *MockProxy) Import(ctx context.Context, req *milvuspb.ImportRequest) (* } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ImportRequest) error); ok { r1 = rf(ctx, req) } else { @@ -2684,8 +2394,8 @@ type MockProxy_Import_Call struct { } // Import is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.ImportRequest +// - ctx context.Context +// - req *milvuspb.ImportRequest func (_e *MockProxy_Expecter) Import(ctx interface{}, req interface{}) *MockProxy_Import_Call { return &MockProxy_Import_Call{Call: _e.mock.On("Import", ctx, req)} } @@ -2702,11 +2412,6 @@ func (_c *MockProxy_Import_Call) Return(_a0 *milvuspb.ImportResponse, _a1 error) return _c } -func (_c *MockProxy_Import_Call) RunAndReturn(run func(context.Context, *milvuspb.ImportRequest) (*milvuspb.ImportResponse, error)) *MockProxy_Import_Call { - _c.Call.Return(run) - return _c -} - // Init provides a mock function with given fields: func (_m *MockProxy) Init() error { ret := _m.Called() @@ -2743,20 +2448,11 @@ func (_c *MockProxy_Init_Call) Return(_a0 error) *MockProxy_Init_Call { return _c } -func (_c *MockProxy_Init_Call) RunAndReturn(run func() error) *MockProxy_Init_Call { - _c.Call.Return(run) - return _c -} - // Insert provides a mock function with given fields: ctx, request func (_m *MockProxy) Insert(ctx context.Context, request *milvuspb.InsertRequest) (*milvuspb.MutationResult, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.MutationResult - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.InsertRequest) (*milvuspb.MutationResult, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.InsertRequest) *milvuspb.MutationResult); ok { r0 = rf(ctx, request) } else { @@ -2765,6 +2461,7 @@ func (_m *MockProxy) Insert(ctx context.Context, request *milvuspb.InsertRequest } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.InsertRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2780,8 +2477,8 @@ type MockProxy_Insert_Call struct { } // Insert is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.InsertRequest +// - ctx context.Context +// - request *milvuspb.InsertRequest func (_e *MockProxy_Expecter) Insert(ctx interface{}, request interface{}) *MockProxy_Insert_Call { return &MockProxy_Insert_Call{Call: _e.mock.On("Insert", ctx, request)} } @@ -2798,20 +2495,11 @@ func (_c *MockProxy_Insert_Call) Return(_a0 *milvuspb.MutationResult, _a1 error) return _c } -func (_c *MockProxy_Insert_Call) RunAndReturn(run func(context.Context, *milvuspb.InsertRequest) (*milvuspb.MutationResult, error)) *MockProxy_Insert_Call { - _c.Call.Return(run) - return _c -} - // InvalidateCollectionMetaCache provides a mock function with given fields: ctx, request func (_m *MockProxy) InvalidateCollectionMetaCache(ctx context.Context, request *proxypb.InvalidateCollMetaCacheRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *proxypb.InvalidateCollMetaCacheRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *proxypb.InvalidateCollMetaCacheRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -2820,6 +2508,7 @@ func (_m *MockProxy) InvalidateCollectionMetaCache(ctx context.Context, request } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *proxypb.InvalidateCollMetaCacheRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2835,8 +2524,8 @@ type MockProxy_InvalidateCollectionMetaCache_Call struct { } // InvalidateCollectionMetaCache is a helper method to define mock.On call -// - ctx context.Context -// - request *proxypb.InvalidateCollMetaCacheRequest +// - ctx context.Context +// - request *proxypb.InvalidateCollMetaCacheRequest func (_e *MockProxy_Expecter) InvalidateCollectionMetaCache(ctx interface{}, request interface{}) *MockProxy_InvalidateCollectionMetaCache_Call { return &MockProxy_InvalidateCollectionMetaCache_Call{Call: _e.mock.On("InvalidateCollectionMetaCache", ctx, request)} } @@ -2853,20 +2542,11 @@ func (_c *MockProxy_InvalidateCollectionMetaCache_Call) Return(_a0 *commonpb.Sta return _c } -func (_c *MockProxy_InvalidateCollectionMetaCache_Call) RunAndReturn(run func(context.Context, *proxypb.InvalidateCollMetaCacheRequest) (*commonpb.Status, error)) *MockProxy_InvalidateCollectionMetaCache_Call { - _c.Call.Return(run) - return _c -} - // InvalidateCredentialCache provides a mock function with given fields: ctx, request func (_m *MockProxy) InvalidateCredentialCache(ctx context.Context, request *proxypb.InvalidateCredCacheRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *proxypb.InvalidateCredCacheRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *proxypb.InvalidateCredCacheRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -2875,6 +2555,7 @@ func (_m *MockProxy) InvalidateCredentialCache(ctx context.Context, request *pro } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *proxypb.InvalidateCredCacheRequest) error); ok { r1 = rf(ctx, request) } else { @@ -2890,8 +2571,8 @@ type MockProxy_InvalidateCredentialCache_Call struct { } // InvalidateCredentialCache is a helper method to define mock.On call -// - ctx context.Context -// - request *proxypb.InvalidateCredCacheRequest +// - ctx context.Context +// - request *proxypb.InvalidateCredCacheRequest func (_e *MockProxy_Expecter) InvalidateCredentialCache(ctx interface{}, request interface{}) *MockProxy_InvalidateCredentialCache_Call { return &MockProxy_InvalidateCredentialCache_Call{Call: _e.mock.On("InvalidateCredentialCache", ctx, request)} } @@ -2908,8 +2589,50 @@ func (_c *MockProxy_InvalidateCredentialCache_Call) Return(_a0 *commonpb.Status, return _c } -func (_c *MockProxy_InvalidateCredentialCache_Call) RunAndReturn(run func(context.Context, *proxypb.InvalidateCredCacheRequest) (*commonpb.Status, error)) *MockProxy_InvalidateCredentialCache_Call { - _c.Call.Return(run) +// ListClientInfos provides a mock function with given fields: ctx, req +func (_m *MockProxy) ListClientInfos(ctx context.Context, req *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) { + ret := _m.Called(ctx, req) + + var r0 *proxypb.ListClientInfosResponse + if rf, ok := ret.Get(0).(func(context.Context, *proxypb.ListClientInfosRequest) *proxypb.ListClientInfosResponse); ok { + r0 = rf(ctx, req) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*proxypb.ListClientInfosResponse) + } + } + + var r1 error + if rf, ok := ret.Get(1).(func(context.Context, *proxypb.ListClientInfosRequest) error); ok { + r1 = rf(ctx, req) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// MockProxy_ListClientInfos_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListClientInfos' +type MockProxy_ListClientInfos_Call struct { + *mock.Call +} + +// ListClientInfos is a helper method to define mock.On call +// - ctx context.Context +// - req *proxypb.ListClientInfosRequest +func (_e *MockProxy_Expecter) ListClientInfos(ctx interface{}, req interface{}) *MockProxy_ListClientInfos_Call { + return &MockProxy_ListClientInfos_Call{Call: _e.mock.On("ListClientInfos", ctx, req)} +} + +func (_c *MockProxy_ListClientInfos_Call) Run(run func(ctx context.Context, req *proxypb.ListClientInfosRequest)) *MockProxy_ListClientInfos_Call { + _c.Call.Run(func(args mock.Arguments) { + run(args[0].(context.Context), args[1].(*proxypb.ListClientInfosRequest)) + }) + return _c +} + +func (_c *MockProxy_ListClientInfos_Call) Return(_a0 *proxypb.ListClientInfosResponse, _a1 error) *MockProxy_ListClientInfos_Call { + _c.Call.Return(_a0, _a1) return _c } @@ -2918,10 +2641,6 @@ func (_m *MockProxy) ListCredUsers(ctx context.Context, req *milvuspb.ListCredUs ret := _m.Called(ctx, req) var r0 *milvuspb.ListCredUsersResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ListCredUsersRequest) (*milvuspb.ListCredUsersResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ListCredUsersRequest) *milvuspb.ListCredUsersResponse); ok { r0 = rf(ctx, req) } else { @@ -2930,6 +2649,7 @@ func (_m *MockProxy) ListCredUsers(ctx context.Context, req *milvuspb.ListCredUs } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ListCredUsersRequest) error); ok { r1 = rf(ctx, req) } else { @@ -2945,8 +2665,8 @@ type MockProxy_ListCredUsers_Call struct { } // ListCredUsers is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.ListCredUsersRequest +// - ctx context.Context +// - req *milvuspb.ListCredUsersRequest func (_e *MockProxy_Expecter) ListCredUsers(ctx interface{}, req interface{}) *MockProxy_ListCredUsers_Call { return &MockProxy_ListCredUsers_Call{Call: _e.mock.On("ListCredUsers", ctx, req)} } @@ -2963,20 +2683,11 @@ func (_c *MockProxy_ListCredUsers_Call) Return(_a0 *milvuspb.ListCredUsersRespon return _c } -func (_c *MockProxy_ListCredUsers_Call) RunAndReturn(run func(context.Context, *milvuspb.ListCredUsersRequest) (*milvuspb.ListCredUsersResponse, error)) *MockProxy_ListCredUsers_Call { - _c.Call.Return(run) - return _c -} - // ListImportTasks provides a mock function with given fields: ctx, req func (_m *MockProxy) ListImportTasks(ctx context.Context, req *milvuspb.ListImportTasksRequest) (*milvuspb.ListImportTasksResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.ListImportTasksResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ListImportTasksRequest) (*milvuspb.ListImportTasksResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ListImportTasksRequest) *milvuspb.ListImportTasksResponse); ok { r0 = rf(ctx, req) } else { @@ -2985,6 +2696,7 @@ func (_m *MockProxy) ListImportTasks(ctx context.Context, req *milvuspb.ListImpo } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ListImportTasksRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3000,8 +2712,8 @@ type MockProxy_ListImportTasks_Call struct { } // ListImportTasks is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.ListImportTasksRequest +// - ctx context.Context +// - req *milvuspb.ListImportTasksRequest func (_e *MockProxy_Expecter) ListImportTasks(ctx interface{}, req interface{}) *MockProxy_ListImportTasks_Call { return &MockProxy_ListImportTasks_Call{Call: _e.mock.On("ListImportTasks", ctx, req)} } @@ -3018,20 +2730,11 @@ func (_c *MockProxy_ListImportTasks_Call) Return(_a0 *milvuspb.ListImportTasksRe return _c } -func (_c *MockProxy_ListImportTasks_Call) RunAndReturn(run func(context.Context, *milvuspb.ListImportTasksRequest) (*milvuspb.ListImportTasksResponse, error)) *MockProxy_ListImportTasks_Call { - _c.Call.Return(run) - return _c -} - // ListResourceGroups provides a mock function with given fields: ctx, req func (_m *MockProxy) ListResourceGroups(ctx context.Context, req *milvuspb.ListResourceGroupsRequest) (*milvuspb.ListResourceGroupsResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.ListResourceGroupsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ListResourceGroupsRequest) (*milvuspb.ListResourceGroupsResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ListResourceGroupsRequest) *milvuspb.ListResourceGroupsResponse); ok { r0 = rf(ctx, req) } else { @@ -3040,6 +2743,7 @@ func (_m *MockProxy) ListResourceGroups(ctx context.Context, req *milvuspb.ListR } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ListResourceGroupsRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3055,8 +2759,8 @@ type MockProxy_ListResourceGroups_Call struct { } // ListResourceGroups is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.ListResourceGroupsRequest +// - ctx context.Context +// - req *milvuspb.ListResourceGroupsRequest func (_e *MockProxy_Expecter) ListResourceGroups(ctx interface{}, req interface{}) *MockProxy_ListResourceGroups_Call { return &MockProxy_ListResourceGroups_Call{Call: _e.mock.On("ListResourceGroups", ctx, req)} } @@ -3073,20 +2777,11 @@ func (_c *MockProxy_ListResourceGroups_Call) Return(_a0 *milvuspb.ListResourceGr return _c } -func (_c *MockProxy_ListResourceGroups_Call) RunAndReturn(run func(context.Context, *milvuspb.ListResourceGroupsRequest) (*milvuspb.ListResourceGroupsResponse, error)) *MockProxy_ListResourceGroups_Call { - _c.Call.Return(run) - return _c -} - // LoadBalance provides a mock function with given fields: ctx, request func (_m *MockProxy) LoadBalance(ctx context.Context, request *milvuspb.LoadBalanceRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.LoadBalanceRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.LoadBalanceRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -3095,6 +2790,7 @@ func (_m *MockProxy) LoadBalance(ctx context.Context, request *milvuspb.LoadBala } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.LoadBalanceRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3110,8 +2806,8 @@ type MockProxy_LoadBalance_Call struct { } // LoadBalance is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.LoadBalanceRequest +// - ctx context.Context +// - request *milvuspb.LoadBalanceRequest func (_e *MockProxy_Expecter) LoadBalance(ctx interface{}, request interface{}) *MockProxy_LoadBalance_Call { return &MockProxy_LoadBalance_Call{Call: _e.mock.On("LoadBalance", ctx, request)} } @@ -3128,20 +2824,11 @@ func (_c *MockProxy_LoadBalance_Call) Return(_a0 *commonpb.Status, _a1 error) *M return _c } -func (_c *MockProxy_LoadBalance_Call) RunAndReturn(run func(context.Context, *milvuspb.LoadBalanceRequest) (*commonpb.Status, error)) *MockProxy_LoadBalance_Call { - _c.Call.Return(run) - return _c -} - // LoadCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) LoadCollection(ctx context.Context, request *milvuspb.LoadCollectionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.LoadCollectionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.LoadCollectionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -3150,6 +2837,7 @@ func (_m *MockProxy) LoadCollection(ctx context.Context, request *milvuspb.LoadC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.LoadCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3165,8 +2853,8 @@ type MockProxy_LoadCollection_Call struct { } // LoadCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.LoadCollectionRequest +// - ctx context.Context +// - request *milvuspb.LoadCollectionRequest func (_e *MockProxy_Expecter) LoadCollection(ctx interface{}, request interface{}) *MockProxy_LoadCollection_Call { return &MockProxy_LoadCollection_Call{Call: _e.mock.On("LoadCollection", ctx, request)} } @@ -3183,20 +2871,11 @@ func (_c *MockProxy_LoadCollection_Call) Return(_a0 *commonpb.Status, _a1 error) return _c } -func (_c *MockProxy_LoadCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.LoadCollectionRequest) (*commonpb.Status, error)) *MockProxy_LoadCollection_Call { - _c.Call.Return(run) - return _c -} - // LoadPartitions provides a mock function with given fields: ctx, request func (_m *MockProxy) LoadPartitions(ctx context.Context, request *milvuspb.LoadPartitionsRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.LoadPartitionsRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.LoadPartitionsRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -3205,6 +2884,7 @@ func (_m *MockProxy) LoadPartitions(ctx context.Context, request *milvuspb.LoadP } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.LoadPartitionsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3220,8 +2900,8 @@ type MockProxy_LoadPartitions_Call struct { } // LoadPartitions is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.LoadPartitionsRequest +// - ctx context.Context +// - request *milvuspb.LoadPartitionsRequest func (_e *MockProxy_Expecter) LoadPartitions(ctx interface{}, request interface{}) *MockProxy_LoadPartitions_Call { return &MockProxy_LoadPartitions_Call{Call: _e.mock.On("LoadPartitions", ctx, request)} } @@ -3238,20 +2918,11 @@ func (_c *MockProxy_LoadPartitions_Call) Return(_a0 *commonpb.Status, _a1 error) return _c } -func (_c *MockProxy_LoadPartitions_Call) RunAndReturn(run func(context.Context, *milvuspb.LoadPartitionsRequest) (*commonpb.Status, error)) *MockProxy_LoadPartitions_Call { - _c.Call.Return(run) - return _c -} - // ManualCompaction provides a mock function with given fields: ctx, req func (_m *MockProxy) ManualCompaction(ctx context.Context, req *milvuspb.ManualCompactionRequest) (*milvuspb.ManualCompactionResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.ManualCompactionResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ManualCompactionRequest) (*milvuspb.ManualCompactionResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ManualCompactionRequest) *milvuspb.ManualCompactionResponse); ok { r0 = rf(ctx, req) } else { @@ -3260,6 +2931,7 @@ func (_m *MockProxy) ManualCompaction(ctx context.Context, req *milvuspb.ManualC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ManualCompactionRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3275,8 +2947,8 @@ type MockProxy_ManualCompaction_Call struct { } // ManualCompaction is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.ManualCompactionRequest +// - ctx context.Context +// - req *milvuspb.ManualCompactionRequest func (_e *MockProxy_Expecter) ManualCompaction(ctx interface{}, req interface{}) *MockProxy_ManualCompaction_Call { return &MockProxy_ManualCompaction_Call{Call: _e.mock.On("ManualCompaction", ctx, req)} } @@ -3293,20 +2965,11 @@ func (_c *MockProxy_ManualCompaction_Call) Return(_a0 *milvuspb.ManualCompaction return _c } -func (_c *MockProxy_ManualCompaction_Call) RunAndReturn(run func(context.Context, *milvuspb.ManualCompactionRequest) (*milvuspb.ManualCompactionResponse, error)) *MockProxy_ManualCompaction_Call { - _c.Call.Return(run) - return _c -} - // OperatePrivilege provides a mock function with given fields: ctx, req func (_m *MockProxy) OperatePrivilege(ctx context.Context, req *milvuspb.OperatePrivilegeRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.OperatePrivilegeRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.OperatePrivilegeRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -3315,6 +2978,7 @@ func (_m *MockProxy) OperatePrivilege(ctx context.Context, req *milvuspb.Operate } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.OperatePrivilegeRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3330,8 +2994,8 @@ type MockProxy_OperatePrivilege_Call struct { } // OperatePrivilege is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.OperatePrivilegeRequest +// - ctx context.Context +// - req *milvuspb.OperatePrivilegeRequest func (_e *MockProxy_Expecter) OperatePrivilege(ctx interface{}, req interface{}) *MockProxy_OperatePrivilege_Call { return &MockProxy_OperatePrivilege_Call{Call: _e.mock.On("OperatePrivilege", ctx, req)} } @@ -3348,20 +3012,11 @@ func (_c *MockProxy_OperatePrivilege_Call) Return(_a0 *commonpb.Status, _a1 erro return _c } -func (_c *MockProxy_OperatePrivilege_Call) RunAndReturn(run func(context.Context, *milvuspb.OperatePrivilegeRequest) (*commonpb.Status, error)) *MockProxy_OperatePrivilege_Call { - _c.Call.Return(run) - return _c -} - // OperateUserRole provides a mock function with given fields: ctx, req func (_m *MockProxy) OperateUserRole(ctx context.Context, req *milvuspb.OperateUserRoleRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.OperateUserRoleRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.OperateUserRoleRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -3370,6 +3025,7 @@ func (_m *MockProxy) OperateUserRole(ctx context.Context, req *milvuspb.OperateU } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.OperateUserRoleRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3385,8 +3041,8 @@ type MockProxy_OperateUserRole_Call struct { } // OperateUserRole is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.OperateUserRoleRequest +// - ctx context.Context +// - req *milvuspb.OperateUserRoleRequest func (_e *MockProxy_Expecter) OperateUserRole(ctx interface{}, req interface{}) *MockProxy_OperateUserRole_Call { return &MockProxy_OperateUserRole_Call{Call: _e.mock.On("OperateUserRole", ctx, req)} } @@ -3403,20 +3059,11 @@ func (_c *MockProxy_OperateUserRole_Call) Return(_a0 *commonpb.Status, _a1 error return _c } -func (_c *MockProxy_OperateUserRole_Call) RunAndReturn(run func(context.Context, *milvuspb.OperateUserRoleRequest) (*commonpb.Status, error)) *MockProxy_OperateUserRole_Call { - _c.Call.Return(run) - return _c -} - // Query provides a mock function with given fields: ctx, request func (_m *MockProxy) Query(ctx context.Context, request *milvuspb.QueryRequest) (*milvuspb.QueryResults, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.QueryResults - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.QueryRequest) (*milvuspb.QueryResults, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.QueryRequest) *milvuspb.QueryResults); ok { r0 = rf(ctx, request) } else { @@ -3425,6 +3072,7 @@ func (_m *MockProxy) Query(ctx context.Context, request *milvuspb.QueryRequest) } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.QueryRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3440,8 +3088,8 @@ type MockProxy_Query_Call struct { } // Query is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.QueryRequest +// - ctx context.Context +// - request *milvuspb.QueryRequest func (_e *MockProxy_Expecter) Query(ctx interface{}, request interface{}) *MockProxy_Query_Call { return &MockProxy_Query_Call{Call: _e.mock.On("Query", ctx, request)} } @@ -3458,20 +3106,11 @@ func (_c *MockProxy_Query_Call) Return(_a0 *milvuspb.QueryResults, _a1 error) *M return _c } -func (_c *MockProxy_Query_Call) RunAndReturn(run func(context.Context, *milvuspb.QueryRequest) (*milvuspb.QueryResults, error)) *MockProxy_Query_Call { - _c.Call.Return(run) - return _c -} - // RefreshPolicyInfoCache provides a mock function with given fields: ctx, req func (_m *MockProxy) RefreshPolicyInfoCache(ctx context.Context, req *proxypb.RefreshPolicyInfoCacheRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *proxypb.RefreshPolicyInfoCacheRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *proxypb.RefreshPolicyInfoCacheRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -3480,6 +3119,7 @@ func (_m *MockProxy) RefreshPolicyInfoCache(ctx context.Context, req *proxypb.Re } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *proxypb.RefreshPolicyInfoCacheRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3495,8 +3135,8 @@ type MockProxy_RefreshPolicyInfoCache_Call struct { } // RefreshPolicyInfoCache is a helper method to define mock.On call -// - ctx context.Context -// - req *proxypb.RefreshPolicyInfoCacheRequest +// - ctx context.Context +// - req *proxypb.RefreshPolicyInfoCacheRequest func (_e *MockProxy_Expecter) RefreshPolicyInfoCache(ctx interface{}, req interface{}) *MockProxy_RefreshPolicyInfoCache_Call { return &MockProxy_RefreshPolicyInfoCache_Call{Call: _e.mock.On("RefreshPolicyInfoCache", ctx, req)} } @@ -3513,11 +3153,6 @@ func (_c *MockProxy_RefreshPolicyInfoCache_Call) Return(_a0 *commonpb.Status, _a return _c } -func (_c *MockProxy_RefreshPolicyInfoCache_Call) RunAndReturn(run func(context.Context, *proxypb.RefreshPolicyInfoCacheRequest) (*commonpb.Status, error)) *MockProxy_RefreshPolicyInfoCache_Call { - _c.Call.Return(run) - return _c -} - // Register provides a mock function with given fields: func (_m *MockProxy) Register() error { ret := _m.Called() @@ -3554,20 +3189,11 @@ func (_c *MockProxy_Register_Call) Return(_a0 error) *MockProxy_Register_Call { return _c } -func (_c *MockProxy_Register_Call) RunAndReturn(run func() error) *MockProxy_Register_Call { - _c.Call.Return(run) - return _c -} - // RegisterLink provides a mock function with given fields: ctx, request func (_m *MockProxy) RegisterLink(ctx context.Context, request *milvuspb.RegisterLinkRequest) (*milvuspb.RegisterLinkResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.RegisterLinkResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.RegisterLinkRequest) (*milvuspb.RegisterLinkResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.RegisterLinkRequest) *milvuspb.RegisterLinkResponse); ok { r0 = rf(ctx, request) } else { @@ -3576,6 +3202,7 @@ func (_m *MockProxy) RegisterLink(ctx context.Context, request *milvuspb.Registe } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.RegisterLinkRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3591,8 +3218,8 @@ type MockProxy_RegisterLink_Call struct { } // RegisterLink is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.RegisterLinkRequest +// - ctx context.Context +// - request *milvuspb.RegisterLinkRequest func (_e *MockProxy_Expecter) RegisterLink(ctx interface{}, request interface{}) *MockProxy_RegisterLink_Call { return &MockProxy_RegisterLink_Call{Call: _e.mock.On("RegisterLink", ctx, request)} } @@ -3609,20 +3236,11 @@ func (_c *MockProxy_RegisterLink_Call) Return(_a0 *milvuspb.RegisterLinkResponse return _c } -func (_c *MockProxy_RegisterLink_Call) RunAndReturn(run func(context.Context, *milvuspb.RegisterLinkRequest) (*milvuspb.RegisterLinkResponse, error)) *MockProxy_RegisterLink_Call { - _c.Call.Return(run) - return _c -} - // ReleaseCollection provides a mock function with given fields: ctx, request func (_m *MockProxy) ReleaseCollection(ctx context.Context, request *milvuspb.ReleaseCollectionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ReleaseCollectionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ReleaseCollectionRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -3631,6 +3249,7 @@ func (_m *MockProxy) ReleaseCollection(ctx context.Context, request *milvuspb.Re } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ReleaseCollectionRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3646,8 +3265,8 @@ type MockProxy_ReleaseCollection_Call struct { } // ReleaseCollection is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.ReleaseCollectionRequest +// - ctx context.Context +// - request *milvuspb.ReleaseCollectionRequest func (_e *MockProxy_Expecter) ReleaseCollection(ctx interface{}, request interface{}) *MockProxy_ReleaseCollection_Call { return &MockProxy_ReleaseCollection_Call{Call: _e.mock.On("ReleaseCollection", ctx, request)} } @@ -3664,20 +3283,11 @@ func (_c *MockProxy_ReleaseCollection_Call) Return(_a0 *commonpb.Status, _a1 err return _c } -func (_c *MockProxy_ReleaseCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.ReleaseCollectionRequest) (*commonpb.Status, error)) *MockProxy_ReleaseCollection_Call { - _c.Call.Return(run) - return _c -} - // ReleasePartitions provides a mock function with given fields: ctx, request func (_m *MockProxy) ReleasePartitions(ctx context.Context, request *milvuspb.ReleasePartitionsRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ReleasePartitionsRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ReleasePartitionsRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -3686,6 +3296,7 @@ func (_m *MockProxy) ReleasePartitions(ctx context.Context, request *milvuspb.Re } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ReleasePartitionsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3701,8 +3312,8 @@ type MockProxy_ReleasePartitions_Call struct { } // ReleasePartitions is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.ReleasePartitionsRequest +// - ctx context.Context +// - request *milvuspb.ReleasePartitionsRequest func (_e *MockProxy_Expecter) ReleasePartitions(ctx interface{}, request interface{}) *MockProxy_ReleasePartitions_Call { return &MockProxy_ReleasePartitions_Call{Call: _e.mock.On("ReleasePartitions", ctx, request)} } @@ -3719,20 +3330,11 @@ func (_c *MockProxy_ReleasePartitions_Call) Return(_a0 *commonpb.Status, _a1 err return _c } -func (_c *MockProxy_ReleasePartitions_Call) RunAndReturn(run func(context.Context, *milvuspb.ReleasePartitionsRequest) (*commonpb.Status, error)) *MockProxy_ReleasePartitions_Call { - _c.Call.Return(run) - return _c -} - // RenameCollection provides a mock function with given fields: ctx, req func (_m *MockProxy) RenameCollection(ctx context.Context, req *milvuspb.RenameCollectionRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.RenameCollectionRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.RenameCollectionRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -3741,6 +3343,7 @@ func (_m *MockProxy) RenameCollection(ctx context.Context, req *milvuspb.RenameC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.RenameCollectionRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3756,8 +3359,8 @@ type MockProxy_RenameCollection_Call struct { } // RenameCollection is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.RenameCollectionRequest +// - ctx context.Context +// - req *milvuspb.RenameCollectionRequest func (_e *MockProxy_Expecter) RenameCollection(ctx interface{}, req interface{}) *MockProxy_RenameCollection_Call { return &MockProxy_RenameCollection_Call{Call: _e.mock.On("RenameCollection", ctx, req)} } @@ -3774,20 +3377,11 @@ func (_c *MockProxy_RenameCollection_Call) Return(_a0 *commonpb.Status, _a1 erro return _c } -func (_c *MockProxy_RenameCollection_Call) RunAndReturn(run func(context.Context, *milvuspb.RenameCollectionRequest) (*commonpb.Status, error)) *MockProxy_RenameCollection_Call { - _c.Call.Return(run) - return _c -} - // Search provides a mock function with given fields: ctx, request func (_m *MockProxy) Search(ctx context.Context, request *milvuspb.SearchRequest) (*milvuspb.SearchResults, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.SearchResults - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SearchRequest) (*milvuspb.SearchResults, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SearchRequest) *milvuspb.SearchResults); ok { r0 = rf(ctx, request) } else { @@ -3796,6 +3390,7 @@ func (_m *MockProxy) Search(ctx context.Context, request *milvuspb.SearchRequest } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.SearchRequest) error); ok { r1 = rf(ctx, request) } else { @@ -3811,8 +3406,8 @@ type MockProxy_Search_Call struct { } // Search is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.SearchRequest +// - ctx context.Context +// - request *milvuspb.SearchRequest func (_e *MockProxy_Expecter) Search(ctx interface{}, request interface{}) *MockProxy_Search_Call { return &MockProxy_Search_Call{Call: _e.mock.On("Search", ctx, request)} } @@ -3829,20 +3424,11 @@ func (_c *MockProxy_Search_Call) Return(_a0 *milvuspb.SearchResults, _a1 error) return _c } -func (_c *MockProxy_Search_Call) RunAndReturn(run func(context.Context, *milvuspb.SearchRequest) (*milvuspb.SearchResults, error)) *MockProxy_Search_Call { - _c.Call.Return(run) - return _c -} - // SelectGrant provides a mock function with given fields: ctx, req func (_m *MockProxy) SelectGrant(ctx context.Context, req *milvuspb.SelectGrantRequest) (*milvuspb.SelectGrantResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.SelectGrantResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SelectGrantRequest) (*milvuspb.SelectGrantResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SelectGrantRequest) *milvuspb.SelectGrantResponse); ok { r0 = rf(ctx, req) } else { @@ -3851,6 +3437,7 @@ func (_m *MockProxy) SelectGrant(ctx context.Context, req *milvuspb.SelectGrantR } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.SelectGrantRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3866,8 +3453,8 @@ type MockProxy_SelectGrant_Call struct { } // SelectGrant is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.SelectGrantRequest +// - ctx context.Context +// - req *milvuspb.SelectGrantRequest func (_e *MockProxy_Expecter) SelectGrant(ctx interface{}, req interface{}) *MockProxy_SelectGrant_Call { return &MockProxy_SelectGrant_Call{Call: _e.mock.On("SelectGrant", ctx, req)} } @@ -3884,20 +3471,11 @@ func (_c *MockProxy_SelectGrant_Call) Return(_a0 *milvuspb.SelectGrantResponse, return _c } -func (_c *MockProxy_SelectGrant_Call) RunAndReturn(run func(context.Context, *milvuspb.SelectGrantRequest) (*milvuspb.SelectGrantResponse, error)) *MockProxy_SelectGrant_Call { - _c.Call.Return(run) - return _c -} - // SelectRole provides a mock function with given fields: ctx, req func (_m *MockProxy) SelectRole(ctx context.Context, req *milvuspb.SelectRoleRequest) (*milvuspb.SelectRoleResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.SelectRoleResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SelectRoleRequest) (*milvuspb.SelectRoleResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SelectRoleRequest) *milvuspb.SelectRoleResponse); ok { r0 = rf(ctx, req) } else { @@ -3906,6 +3484,7 @@ func (_m *MockProxy) SelectRole(ctx context.Context, req *milvuspb.SelectRoleReq } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.SelectRoleRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3921,8 +3500,8 @@ type MockProxy_SelectRole_Call struct { } // SelectRole is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.SelectRoleRequest +// - ctx context.Context +// - req *milvuspb.SelectRoleRequest func (_e *MockProxy_Expecter) SelectRole(ctx interface{}, req interface{}) *MockProxy_SelectRole_Call { return &MockProxy_SelectRole_Call{Call: _e.mock.On("SelectRole", ctx, req)} } @@ -3939,20 +3518,11 @@ func (_c *MockProxy_SelectRole_Call) Return(_a0 *milvuspb.SelectRoleResponse, _a return _c } -func (_c *MockProxy_SelectRole_Call) RunAndReturn(run func(context.Context, *milvuspb.SelectRoleRequest) (*milvuspb.SelectRoleResponse, error)) *MockProxy_SelectRole_Call { - _c.Call.Return(run) - return _c -} - // SelectUser provides a mock function with given fields: ctx, req func (_m *MockProxy) SelectUser(ctx context.Context, req *milvuspb.SelectUserRequest) (*milvuspb.SelectUserResponse, error) { ret := _m.Called(ctx, req) var r0 *milvuspb.SelectUserResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SelectUserRequest) (*milvuspb.SelectUserResponse, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.SelectUserRequest) *milvuspb.SelectUserResponse); ok { r0 = rf(ctx, req) } else { @@ -3961,6 +3531,7 @@ func (_m *MockProxy) SelectUser(ctx context.Context, req *milvuspb.SelectUserReq } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.SelectUserRequest) error); ok { r1 = rf(ctx, req) } else { @@ -3976,8 +3547,8 @@ type MockProxy_SelectUser_Call struct { } // SelectUser is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.SelectUserRequest +// - ctx context.Context +// - req *milvuspb.SelectUserRequest func (_e *MockProxy_Expecter) SelectUser(ctx interface{}, req interface{}) *MockProxy_SelectUser_Call { return &MockProxy_SelectUser_Call{Call: _e.mock.On("SelectUser", ctx, req)} } @@ -3994,11 +3565,6 @@ func (_c *MockProxy_SelectUser_Call) Return(_a0 *milvuspb.SelectUserResponse, _a return _c } -func (_c *MockProxy_SelectUser_Call) RunAndReturn(run func(context.Context, *milvuspb.SelectUserRequest) (*milvuspb.SelectUserResponse, error)) *MockProxy_SelectUser_Call { - _c.Call.Return(run) - return _c -} - // SetAddress provides a mock function with given fields: address func (_m *MockProxy) SetAddress(address string) { _m.Called(address) @@ -4010,7 +3576,7 @@ type MockProxy_SetAddress_Call struct { } // SetAddress is a helper method to define mock.On call -// - address string +// - address string func (_e *MockProxy_Expecter) SetAddress(address interface{}) *MockProxy_SetAddress_Call { return &MockProxy_SetAddress_Call{Call: _e.mock.On("SetAddress", address)} } @@ -4027,11 +3593,6 @@ func (_c *MockProxy_SetAddress_Call) Return() *MockProxy_SetAddress_Call { return _c } -func (_c *MockProxy_SetAddress_Call) RunAndReturn(run func(string)) *MockProxy_SetAddress_Call { - _c.Call.Return(run) - return _c -} - // SetDataCoordClient provides a mock function with given fields: dataCoord func (_m *MockProxy) SetDataCoordClient(dataCoord DataCoord) { _m.Called(dataCoord) @@ -4043,7 +3604,7 @@ type MockProxy_SetDataCoordClient_Call struct { } // SetDataCoordClient is a helper method to define mock.On call -// - dataCoord DataCoord +// - dataCoord DataCoord func (_e *MockProxy_Expecter) SetDataCoordClient(dataCoord interface{}) *MockProxy_SetDataCoordClient_Call { return &MockProxy_SetDataCoordClient_Call{Call: _e.mock.On("SetDataCoordClient", dataCoord)} } @@ -4060,11 +3621,6 @@ func (_c *MockProxy_SetDataCoordClient_Call) Return() *MockProxy_SetDataCoordCli return _c } -func (_c *MockProxy_SetDataCoordClient_Call) RunAndReturn(run func(DataCoord)) *MockProxy_SetDataCoordClient_Call { - _c.Call.Return(run) - return _c -} - // SetEtcdClient provides a mock function with given fields: etcdClient func (_m *MockProxy) SetEtcdClient(etcdClient *clientv3.Client) { _m.Called(etcdClient) @@ -4076,7 +3632,7 @@ type MockProxy_SetEtcdClient_Call struct { } // SetEtcdClient is a helper method to define mock.On call -// - etcdClient *clientv3.Client +// - etcdClient *clientv3.Client func (_e *MockProxy_Expecter) SetEtcdClient(etcdClient interface{}) *MockProxy_SetEtcdClient_Call { return &MockProxy_SetEtcdClient_Call{Call: _e.mock.On("SetEtcdClient", etcdClient)} } @@ -4093,11 +3649,6 @@ func (_c *MockProxy_SetEtcdClient_Call) Return() *MockProxy_SetEtcdClient_Call { return _c } -func (_c *MockProxy_SetEtcdClient_Call) RunAndReturn(run func(*clientv3.Client)) *MockProxy_SetEtcdClient_Call { - _c.Call.Return(run) - return _c -} - // SetQueryCoordClient provides a mock function with given fields: queryCoord func (_m *MockProxy) SetQueryCoordClient(queryCoord QueryCoord) { _m.Called(queryCoord) @@ -4109,7 +3660,7 @@ type MockProxy_SetQueryCoordClient_Call struct { } // SetQueryCoordClient is a helper method to define mock.On call -// - queryCoord QueryCoord +// - queryCoord QueryCoord func (_e *MockProxy_Expecter) SetQueryCoordClient(queryCoord interface{}) *MockProxy_SetQueryCoordClient_Call { return &MockProxy_SetQueryCoordClient_Call{Call: _e.mock.On("SetQueryCoordClient", queryCoord)} } @@ -4126,11 +3677,6 @@ func (_c *MockProxy_SetQueryCoordClient_Call) Return() *MockProxy_SetQueryCoordC return _c } -func (_c *MockProxy_SetQueryCoordClient_Call) RunAndReturn(run func(QueryCoord)) *MockProxy_SetQueryCoordClient_Call { - _c.Call.Return(run) - return _c -} - // SetQueryNodeCreator provides a mock function with given fields: _a0 func (_m *MockProxy) SetQueryNodeCreator(_a0 func(context.Context, string) (QueryNode, error)) { _m.Called(_a0) @@ -4142,7 +3688,7 @@ type MockProxy_SetQueryNodeCreator_Call struct { } // SetQueryNodeCreator is a helper method to define mock.On call -// - _a0 func(context.Context , string)(QueryNode , error) +// - _a0 func(context.Context , string)(QueryNode , error) func (_e *MockProxy_Expecter) SetQueryNodeCreator(_a0 interface{}) *MockProxy_SetQueryNodeCreator_Call { return &MockProxy_SetQueryNodeCreator_Call{Call: _e.mock.On("SetQueryNodeCreator", _a0)} } @@ -4159,20 +3705,11 @@ func (_c *MockProxy_SetQueryNodeCreator_Call) Return() *MockProxy_SetQueryNodeCr return _c } -func (_c *MockProxy_SetQueryNodeCreator_Call) RunAndReturn(run func(func(context.Context, string) (QueryNode, error))) *MockProxy_SetQueryNodeCreator_Call { - _c.Call.Return(run) - return _c -} - // SetRates provides a mock function with given fields: ctx, req func (_m *MockProxy) SetRates(ctx context.Context, req *proxypb.SetRatesRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *proxypb.SetRatesRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *proxypb.SetRatesRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -4181,6 +3718,7 @@ func (_m *MockProxy) SetRates(ctx context.Context, req *proxypb.SetRatesRequest) } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *proxypb.SetRatesRequest) error); ok { r1 = rf(ctx, req) } else { @@ -4196,8 +3734,8 @@ type MockProxy_SetRates_Call struct { } // SetRates is a helper method to define mock.On call -// - ctx context.Context -// - req *proxypb.SetRatesRequest +// - ctx context.Context +// - req *proxypb.SetRatesRequest func (_e *MockProxy_Expecter) SetRates(ctx interface{}, req interface{}) *MockProxy_SetRates_Call { return &MockProxy_SetRates_Call{Call: _e.mock.On("SetRates", ctx, req)} } @@ -4214,11 +3752,6 @@ func (_c *MockProxy_SetRates_Call) Return(_a0 *commonpb.Status, _a1 error) *Mock return _c } -func (_c *MockProxy_SetRates_Call) RunAndReturn(run func(context.Context, *proxypb.SetRatesRequest) (*commonpb.Status, error)) *MockProxy_SetRates_Call { - _c.Call.Return(run) - return _c -} - // SetRootCoordClient provides a mock function with given fields: rootCoord func (_m *MockProxy) SetRootCoordClient(rootCoord RootCoord) { _m.Called(rootCoord) @@ -4230,7 +3763,7 @@ type MockProxy_SetRootCoordClient_Call struct { } // SetRootCoordClient is a helper method to define mock.On call -// - rootCoord RootCoord +// - rootCoord RootCoord func (_e *MockProxy_Expecter) SetRootCoordClient(rootCoord interface{}) *MockProxy_SetRootCoordClient_Call { return &MockProxy_SetRootCoordClient_Call{Call: _e.mock.On("SetRootCoordClient", rootCoord)} } @@ -4247,20 +3780,11 @@ func (_c *MockProxy_SetRootCoordClient_Call) Return() *MockProxy_SetRootCoordCli return _c } -func (_c *MockProxy_SetRootCoordClient_Call) RunAndReturn(run func(RootCoord)) *MockProxy_SetRootCoordClient_Call { - _c.Call.Return(run) - return _c -} - // ShowCollections provides a mock function with given fields: ctx, request func (_m *MockProxy) ShowCollections(ctx context.Context, request *milvuspb.ShowCollectionsRequest) (*milvuspb.ShowCollectionsResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.ShowCollectionsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ShowCollectionsRequest) (*milvuspb.ShowCollectionsResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ShowCollectionsRequest) *milvuspb.ShowCollectionsResponse); ok { r0 = rf(ctx, request) } else { @@ -4269,6 +3793,7 @@ func (_m *MockProxy) ShowCollections(ctx context.Context, request *milvuspb.Show } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ShowCollectionsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -4284,8 +3809,8 @@ type MockProxy_ShowCollections_Call struct { } // ShowCollections is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.ShowCollectionsRequest +// - ctx context.Context +// - request *milvuspb.ShowCollectionsRequest func (_e *MockProxy_Expecter) ShowCollections(ctx interface{}, request interface{}) *MockProxy_ShowCollections_Call { return &MockProxy_ShowCollections_Call{Call: _e.mock.On("ShowCollections", ctx, request)} } @@ -4302,20 +3827,11 @@ func (_c *MockProxy_ShowCollections_Call) Return(_a0 *milvuspb.ShowCollectionsRe return _c } -func (_c *MockProxy_ShowCollections_Call) RunAndReturn(run func(context.Context, *milvuspb.ShowCollectionsRequest) (*milvuspb.ShowCollectionsResponse, error)) *MockProxy_ShowCollections_Call { - _c.Call.Return(run) - return _c -} - // ShowPartitions provides a mock function with given fields: ctx, request func (_m *MockProxy) ShowPartitions(ctx context.Context, request *milvuspb.ShowPartitionsRequest) (*milvuspb.ShowPartitionsResponse, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.ShowPartitionsResponse - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ShowPartitionsRequest) (*milvuspb.ShowPartitionsResponse, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.ShowPartitionsRequest) *milvuspb.ShowPartitionsResponse); ok { r0 = rf(ctx, request) } else { @@ -4324,6 +3840,7 @@ func (_m *MockProxy) ShowPartitions(ctx context.Context, request *milvuspb.ShowP } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.ShowPartitionsRequest) error); ok { r1 = rf(ctx, request) } else { @@ -4339,8 +3856,8 @@ type MockProxy_ShowPartitions_Call struct { } // ShowPartitions is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.ShowPartitionsRequest +// - ctx context.Context +// - request *milvuspb.ShowPartitionsRequest func (_e *MockProxy_Expecter) ShowPartitions(ctx interface{}, request interface{}) *MockProxy_ShowPartitions_Call { return &MockProxy_ShowPartitions_Call{Call: _e.mock.On("ShowPartitions", ctx, request)} } @@ -4357,11 +3874,6 @@ func (_c *MockProxy_ShowPartitions_Call) Return(_a0 *milvuspb.ShowPartitionsResp return _c } -func (_c *MockProxy_ShowPartitions_Call) RunAndReturn(run func(context.Context, *milvuspb.ShowPartitionsRequest) (*milvuspb.ShowPartitionsResponse, error)) *MockProxy_ShowPartitions_Call { - _c.Call.Return(run) - return _c -} - // Start provides a mock function with given fields: func (_m *MockProxy) Start() error { ret := _m.Called() @@ -4398,11 +3910,6 @@ func (_c *MockProxy_Start_Call) Return(_a0 error) *MockProxy_Start_Call { return _c } -func (_c *MockProxy_Start_Call) RunAndReturn(run func() error) *MockProxy_Start_Call { - _c.Call.Return(run) - return _c -} - // Stop provides a mock function with given fields: func (_m *MockProxy) Stop() error { ret := _m.Called() @@ -4439,20 +3946,11 @@ func (_c *MockProxy_Stop_Call) Return(_a0 error) *MockProxy_Stop_Call { return _c } -func (_c *MockProxy_Stop_Call) RunAndReturn(run func() error) *MockProxy_Stop_Call { - _c.Call.Return(run) - return _c -} - // TransferNode provides a mock function with given fields: ctx, req func (_m *MockProxy) TransferNode(ctx context.Context, req *milvuspb.TransferNodeRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.TransferNodeRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.TransferNodeRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -4461,6 +3959,7 @@ func (_m *MockProxy) TransferNode(ctx context.Context, req *milvuspb.TransferNod } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.TransferNodeRequest) error); ok { r1 = rf(ctx, req) } else { @@ -4476,8 +3975,8 @@ type MockProxy_TransferNode_Call struct { } // TransferNode is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.TransferNodeRequest +// - ctx context.Context +// - req *milvuspb.TransferNodeRequest func (_e *MockProxy_Expecter) TransferNode(ctx interface{}, req interface{}) *MockProxy_TransferNode_Call { return &MockProxy_TransferNode_Call{Call: _e.mock.On("TransferNode", ctx, req)} } @@ -4494,20 +3993,11 @@ func (_c *MockProxy_TransferNode_Call) Return(_a0 *commonpb.Status, _a1 error) * return _c } -func (_c *MockProxy_TransferNode_Call) RunAndReturn(run func(context.Context, *milvuspb.TransferNodeRequest) (*commonpb.Status, error)) *MockProxy_TransferNode_Call { - _c.Call.Return(run) - return _c -} - // TransferReplica provides a mock function with given fields: ctx, req func (_m *MockProxy) TransferReplica(ctx context.Context, req *milvuspb.TransferReplicaRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.TransferReplicaRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.TransferReplicaRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -4516,6 +4006,7 @@ func (_m *MockProxy) TransferReplica(ctx context.Context, req *milvuspb.Transfer } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.TransferReplicaRequest) error); ok { r1 = rf(ctx, req) } else { @@ -4531,8 +4022,8 @@ type MockProxy_TransferReplica_Call struct { } // TransferReplica is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.TransferReplicaRequest +// - ctx context.Context +// - req *milvuspb.TransferReplicaRequest func (_e *MockProxy_Expecter) TransferReplica(ctx interface{}, req interface{}) *MockProxy_TransferReplica_Call { return &MockProxy_TransferReplica_Call{Call: _e.mock.On("TransferReplica", ctx, req)} } @@ -4549,20 +4040,11 @@ func (_c *MockProxy_TransferReplica_Call) Return(_a0 *commonpb.Status, _a1 error return _c } -func (_c *MockProxy_TransferReplica_Call) RunAndReturn(run func(context.Context, *milvuspb.TransferReplicaRequest) (*commonpb.Status, error)) *MockProxy_TransferReplica_Call { - _c.Call.Return(run) - return _c -} - // UpdateCredential provides a mock function with given fields: ctx, req func (_m *MockProxy) UpdateCredential(ctx context.Context, req *milvuspb.UpdateCredentialRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, req) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.UpdateCredentialRequest) (*commonpb.Status, error)); ok { - return rf(ctx, req) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.UpdateCredentialRequest) *commonpb.Status); ok { r0 = rf(ctx, req) } else { @@ -4571,6 +4053,7 @@ func (_m *MockProxy) UpdateCredential(ctx context.Context, req *milvuspb.UpdateC } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.UpdateCredentialRequest) error); ok { r1 = rf(ctx, req) } else { @@ -4586,8 +4069,8 @@ type MockProxy_UpdateCredential_Call struct { } // UpdateCredential is a helper method to define mock.On call -// - ctx context.Context -// - req *milvuspb.UpdateCredentialRequest +// - ctx context.Context +// - req *milvuspb.UpdateCredentialRequest func (_e *MockProxy_Expecter) UpdateCredential(ctx interface{}, req interface{}) *MockProxy_UpdateCredential_Call { return &MockProxy_UpdateCredential_Call{Call: _e.mock.On("UpdateCredential", ctx, req)} } @@ -4604,20 +4087,11 @@ func (_c *MockProxy_UpdateCredential_Call) Return(_a0 *commonpb.Status, _a1 erro return _c } -func (_c *MockProxy_UpdateCredential_Call) RunAndReturn(run func(context.Context, *milvuspb.UpdateCredentialRequest) (*commonpb.Status, error)) *MockProxy_UpdateCredential_Call { - _c.Call.Return(run) - return _c -} - // UpdateCredentialCache provides a mock function with given fields: ctx, request func (_m *MockProxy) UpdateCredentialCache(ctx context.Context, request *proxypb.UpdateCredCacheRequest) (*commonpb.Status, error) { ret := _m.Called(ctx, request) var r0 *commonpb.Status - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *proxypb.UpdateCredCacheRequest) (*commonpb.Status, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *proxypb.UpdateCredCacheRequest) *commonpb.Status); ok { r0 = rf(ctx, request) } else { @@ -4626,6 +4100,7 @@ func (_m *MockProxy) UpdateCredentialCache(ctx context.Context, request *proxypb } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *proxypb.UpdateCredCacheRequest) error); ok { r1 = rf(ctx, request) } else { @@ -4641,8 +4116,8 @@ type MockProxy_UpdateCredentialCache_Call struct { } // UpdateCredentialCache is a helper method to define mock.On call -// - ctx context.Context -// - request *proxypb.UpdateCredCacheRequest +// - ctx context.Context +// - request *proxypb.UpdateCredCacheRequest func (_e *MockProxy_Expecter) UpdateCredentialCache(ctx interface{}, request interface{}) *MockProxy_UpdateCredentialCache_Call { return &MockProxy_UpdateCredentialCache_Call{Call: _e.mock.On("UpdateCredentialCache", ctx, request)} } @@ -4659,11 +4134,6 @@ func (_c *MockProxy_UpdateCredentialCache_Call) Return(_a0 *commonpb.Status, _a1 return _c } -func (_c *MockProxy_UpdateCredentialCache_Call) RunAndReturn(run func(context.Context, *proxypb.UpdateCredCacheRequest) (*commonpb.Status, error)) *MockProxy_UpdateCredentialCache_Call { - _c.Call.Return(run) - return _c -} - // UpdateStateCode provides a mock function with given fields: stateCode func (_m *MockProxy) UpdateStateCode(stateCode commonpb.StateCode) { _m.Called(stateCode) @@ -4675,7 +4145,7 @@ type MockProxy_UpdateStateCode_Call struct { } // UpdateStateCode is a helper method to define mock.On call -// - stateCode commonpb.StateCode +// - stateCode commonpb.StateCode func (_e *MockProxy_Expecter) UpdateStateCode(stateCode interface{}) *MockProxy_UpdateStateCode_Call { return &MockProxy_UpdateStateCode_Call{Call: _e.mock.On("UpdateStateCode", stateCode)} } @@ -4692,20 +4162,11 @@ func (_c *MockProxy_UpdateStateCode_Call) Return() *MockProxy_UpdateStateCode_Ca return _c } -func (_c *MockProxy_UpdateStateCode_Call) RunAndReturn(run func(commonpb.StateCode)) *MockProxy_UpdateStateCode_Call { - _c.Call.Return(run) - return _c -} - // Upsert provides a mock function with given fields: ctx, request func (_m *MockProxy) Upsert(ctx context.Context, request *milvuspb.UpsertRequest) (*milvuspb.MutationResult, error) { ret := _m.Called(ctx, request) var r0 *milvuspb.MutationResult - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.UpsertRequest) (*milvuspb.MutationResult, error)); ok { - return rf(ctx, request) - } if rf, ok := ret.Get(0).(func(context.Context, *milvuspb.UpsertRequest) *milvuspb.MutationResult); ok { r0 = rf(ctx, request) } else { @@ -4714,6 +4175,7 @@ func (_m *MockProxy) Upsert(ctx context.Context, request *milvuspb.UpsertRequest } } + var r1 error if rf, ok := ret.Get(1).(func(context.Context, *milvuspb.UpsertRequest) error); ok { r1 = rf(ctx, request) } else { @@ -4729,8 +4191,8 @@ type MockProxy_Upsert_Call struct { } // Upsert is a helper method to define mock.On call -// - ctx context.Context -// - request *milvuspb.UpsertRequest +// - ctx context.Context +// - request *milvuspb.UpsertRequest func (_e *MockProxy_Expecter) Upsert(ctx interface{}, request interface{}) *MockProxy_Upsert_Call { return &MockProxy_Upsert_Call{Call: _e.mock.On("Upsert", ctx, request)} } @@ -4747,11 +4209,6 @@ func (_c *MockProxy_Upsert_Call) Return(_a0 *milvuspb.MutationResult, _a1 error) return _c } -func (_c *MockProxy_Upsert_Call) RunAndReturn(run func(context.Context, *milvuspb.UpsertRequest) (*milvuspb.MutationResult, error)) *MockProxy_Upsert_Call { - _c.Call.Return(run) - return _c -} - type mockConstructorTestingTNewMockProxy interface { mock.TestingT Cleanup(func()) diff --git a/internal/types/types.go b/internal/types/types.go index 2496f32f8d788..452d5bf8ca9e4 100644 --- a/internal/types/types.go +++ b/internal/types/types.go @@ -848,6 +848,8 @@ type Proxy interface { // because it only obtains the metrics of Proxy, not including the topological metrics of Query cluster and Data cluster. GetProxyMetrics(ctx context.Context, request *milvuspb.GetMetricsRequest) (*milvuspb.GetMetricsResponse, error) RefreshPolicyInfoCache(ctx context.Context, req *proxypb.RefreshPolicyInfoCacheRequest) (*commonpb.Status, error) + + ListClientInfos(ctx context.Context, req *proxypb.ListClientInfosRequest) (*proxypb.ListClientInfosResponse, error) } // ProxyComponent defines the interface of proxy component. @@ -1347,6 +1349,8 @@ type ProxyComponent interface { TransferReplica(ctx context.Context, req *milvuspb.TransferReplicaRequest) (*commonpb.Status, error) ListResourceGroups(ctx context.Context, req *milvuspb.ListResourceGroupsRequest) (*milvuspb.ListResourceGroupsResponse, error) DescribeResourceGroup(ctx context.Context, req *milvuspb.DescribeResourceGroupRequest) (*milvuspb.DescribeResourceGroupResponse, error) + + Connect(ctx context.Context, req *milvuspb.ConnectRequest) (*milvuspb.ConnectResponse, error) } // QueryNode is the interface `querynode` package implements diff --git a/internal/util/mock/grpc_proxy_client.go b/internal/util/mock/grpc_proxy_client.go index 86365fdf4e376..ab14e93f55366 100644 --- a/internal/util/mock/grpc_proxy_client.go +++ b/internal/util/mock/grpc_proxy_client.go @@ -68,3 +68,7 @@ func (m *GrpcProxyClient) GetProxyMetrics(ctx context.Context, in *milvuspb.GetM func (m *GrpcProxyClient) SetRates(ctx context.Context, in *proxypb.SetRatesRequest, opts ...grpc.CallOption) (*commonpb.Status, error) { return &commonpb.Status{}, m.Err } + +func (m *GrpcProxyClient) ListClientInfos(ctx context.Context, in *proxypb.ListClientInfosRequest, opts ...grpc.CallOption) (*proxypb.ListClientInfosResponse, error) { + return &proxypb.ListClientInfosResponse{}, m.Err +} diff --git a/pkg/go.mod b/pkg/go.mod index cff6abae6dc53..816446adc94c1 100644 --- a/pkg/go.mod +++ b/pkg/go.mod @@ -12,7 +12,7 @@ require ( github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 github.com/klauspost/compress v1.14.4 github.com/lingdor/stackerror v0.0.0-20191119040541-976d8885ed76 - github.com/milvus-io/milvus-proto/go-api v0.0.0-20230515081521-d963c95b041f + github.com/milvus-io/milvus-proto/go-api v0.0.0-20230517025117-8ba62a3f3a63 github.com/panjf2000/ants/v2 v2.4.8 github.com/prometheus/client_golang v1.11.1 github.com/samber/lo v1.27.0 diff --git a/pkg/go.sum b/pkg/go.sum index e8db2f1f60d53..ff2fa6396ab04 100644 --- a/pkg/go.sum +++ b/pkg/go.sum @@ -469,6 +469,8 @@ github.com/milvus-io/milvus-proto/go-api v0.0.0-20230416064425-aec3e83865b2 h1:G github.com/milvus-io/milvus-proto/go-api v0.0.0-20230416064425-aec3e83865b2/go.mod h1:148qnlmZ0Fdm1Fq+Mj/OW2uDoEP25g3mjh0vMGtkgmk= github.com/milvus-io/milvus-proto/go-api v0.0.0-20230515081521-d963c95b041f h1:uZzVaSbUtxMdEix9By6z+M/H/XNkXRQJdZQ9HP/wHtc= github.com/milvus-io/milvus-proto/go-api v0.0.0-20230515081521-d963c95b041f/go.mod h1:148qnlmZ0Fdm1Fq+Mj/OW2uDoEP25g3mjh0vMGtkgmk= +github.com/milvus-io/milvus-proto/go-api v0.0.0-20230517025117-8ba62a3f3a63 h1:V962mSHjOFUbuMgAXziBdbYPOCVZmN1MkqEeKpME+MA= +github.com/milvus-io/milvus-proto/go-api v0.0.0-20230517025117-8ba62a3f3a63/go.mod h1:148qnlmZ0Fdm1Fq+Mj/OW2uDoEP25g3mjh0vMGtkgmk= github.com/milvus-io/pulsar-client-go v0.6.10 h1:eqpJjU+/QX0iIhEo3nhOqMNXL+TyInAs1IAHZCrCM/A= github.com/milvus-io/pulsar-client-go v0.6.10/go.mod h1:lQqCkgwDF8YFYjKA+zOheTk1tev2B+bKj5j7+nm8M1w= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= diff --git a/pkg/util/constant.go b/pkg/util/constant.go index c4ce49a9407d0..bf13a6045be6c 100644 --- a/pkg/util/constant.go +++ b/pkg/util/constant.go @@ -55,6 +55,8 @@ const ( PrivilegeWord = "Privilege" AnyWord = "*" + + IdentifierKey = "identifier" ) const (