From b89e5a324061ec02f073d89a439d8cc5b981e29a Mon Sep 17 00:00:00 2001
From: "zhenshan.cao" <zhenshan.cao@zilliz.com>
Date: Thu, 4 Feb 2021 14:37:12 +0800
Subject: [PATCH] Add GetQuerySegmentInfo

Signed-off-by: zhenshan.cao <zhenshan.cao@zilliz.com>
---
 internal/core/src/pb/milvus.pb.cc             | 1699 +++++++++++++++--
 internal/core/src/pb/milvus.pb.h              |  877 ++++++++-
 internal/datanode/data_sync_service_test.go   |   14 +-
 .../datanode/flow_graph_insert_buffer_node.go |   17 +-
 .../flow_graph_msg_stream_input_node.go       |   15 +-
 internal/dataservice/meta.go                  |    2 +-
 internal/dataservice/segment_allocator.go     |    4 +-
 .../dataservice/segment_allocator_test.go     |    9 +-
 internal/dataservice/server.go                |   45 +-
 internal/dataservice/watcher_test.go          |    2 +-
 internal/distributed/proxynode/service.go     |    5 +
 internal/masterservice/master_service.go      |   23 +-
 internal/masterservice/master_service_test.go |   34 +-
 internal/msgstream/msgstream.go               |   10 +
 internal/msgstream/pulsarms/factory.go        |   32 +
 internal/msgstream/pulsarms/msg_test.go       |   12 +-
 .../msgstream/pulsarms/pulsar_msgstream.go    |   37 +-
 .../pulsarms/pulsar_msgstream_test.go         |   50 +-
 internal/proto/milvus.proto                   |   22 +
 internal/proto/milvuspb/milvus.pb.go          |  471 +++--
 internal/proxynode/impl.go                    |   53 +-
 internal/proxynode/insert_channels.go         |    8 +-
 internal/proxynode/interface.go               |    5 +
 internal/proxynode/proxy_node.go              |   18 +-
 internal/proxynode/task.go                    |  101 +-
 internal/proxynode/task_scheduler.go          |    7 +-
 internal/proxynode/timetick.go                |   11 +-
 internal/proxyservice/impl.go                 |   18 +-
 internal/querynode/data_sync_service_test.go  |   14 +-
 .../flow_graph_msg_stream_input_nodes.go      |   22 +-
 .../querynode/flow_graph_service_time_node.go |    9 +-
 internal/querynode/load_service_test.go       |   48 +-
 internal/querynode/query_node.go              |   10 +-
 internal/querynode/search_service.go          |   12 +-
 internal/querynode/search_service_test.go     |   34 +-
 internal/querynode/stats_service.go           |    9 +-
 internal/querynode/stats_service_test.go      |   10 +-
 internal/queryservice/load_test.go            |    6 +-
 38 files changed, 3206 insertions(+), 569 deletions(-)
 create mode 100644 internal/msgstream/pulsarms/factory.go

diff --git a/internal/core/src/pb/milvus.pb.cc b/internal/core/src/pb/milvus.pb.cc
index 6564f4607..0a8ff050b 100644
--- a/internal/core/src/pb/milvus.pb.cc
+++ b/internal/core/src/pb/milvus.pb.cc
@@ -23,6 +23,7 @@ extern PROTOBUF_INTERNAL_EXPORT_common_2eproto ::PROTOBUF_NAMESPACE_ID::internal
 extern PROTOBUF_INTERNAL_EXPORT_milvus_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_IndexDescription_milvus_2eproto;
 extern PROTOBUF_INTERNAL_EXPORT_milvus_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_PersistentSegmentInfo_milvus_2eproto;
 extern PROTOBUF_INTERNAL_EXPORT_milvus_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_PlaceholderValue_milvus_2eproto;
+extern PROTOBUF_INTERNAL_EXPORT_milvus_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_QuerySegmentInfo_milvus_2eproto;
 extern PROTOBUF_INTERNAL_EXPORT_schema_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_CollectionSchema_schema_2eproto;
 namespace milvus {
 namespace proto {
@@ -199,6 +200,18 @@ class PersistentSegmentInfoResponseDefaultTypeInternal {
  public:
   ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<PersistentSegmentInfoResponse> _instance;
 } _PersistentSegmentInfoResponse_default_instance_;
+class QuerySegmentInfoDefaultTypeInternal {
+ public:
+  ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<QuerySegmentInfo> _instance;
+} _QuerySegmentInfo_default_instance_;
+class QuerySegmentInfoRequestDefaultTypeInternal {
+ public:
+  ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<QuerySegmentInfoRequest> _instance;
+} _QuerySegmentInfoRequest_default_instance_;
+class QuerySegmentInfoResponseDefaultTypeInternal {
+ public:
+  ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<QuerySegmentInfoResponse> _instance;
+} _QuerySegmentInfoResponse_default_instance_;
 class RegisterLinkResponseDefaultTypeInternal {
  public:
   ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<RegisterLinkResponse> _instance;
@@ -690,6 +703,51 @@ static void InitDefaultsscc_info_PlaceholderValue_milvus_2eproto() {
 ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_PlaceholderValue_milvus_2eproto =
     {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_PlaceholderValue_milvus_2eproto}, {}};
 
+static void InitDefaultsscc_info_QuerySegmentInfo_milvus_2eproto() {
+  GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+  {
+    void* ptr = &::milvus::proto::milvus::_QuerySegmentInfo_default_instance_;
+    new (ptr) ::milvus::proto::milvus::QuerySegmentInfo();
+    ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr);
+  }
+  ::milvus::proto::milvus::QuerySegmentInfo::InitAsDefaultInstance();
+}
+
+::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_QuerySegmentInfo_milvus_2eproto =
+    {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_QuerySegmentInfo_milvus_2eproto}, {}};
+
+static void InitDefaultsscc_info_QuerySegmentInfoRequest_milvus_2eproto() {
+  GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+  {
+    void* ptr = &::milvus::proto::milvus::_QuerySegmentInfoRequest_default_instance_;
+    new (ptr) ::milvus::proto::milvus::QuerySegmentInfoRequest();
+    ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr);
+  }
+  ::milvus::proto::milvus::QuerySegmentInfoRequest::InitAsDefaultInstance();
+}
+
+::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_QuerySegmentInfoRequest_milvus_2eproto =
+    {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsscc_info_QuerySegmentInfoRequest_milvus_2eproto}, {
+      &scc_info_MsgBase_common_2eproto.base,}};
+
+static void InitDefaultsscc_info_QuerySegmentInfoResponse_milvus_2eproto() {
+  GOOGLE_PROTOBUF_VERIFY_VERSION;
+
+  {
+    void* ptr = &::milvus::proto::milvus::_QuerySegmentInfoResponse_default_instance_;
+    new (ptr) ::milvus::proto::milvus::QuerySegmentInfoResponse();
+    ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr);
+  }
+  ::milvus::proto::milvus::QuerySegmentInfoResponse::InitAsDefaultInstance();
+}
+
+::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<2> scc_info_QuerySegmentInfoResponse_milvus_2eproto =
+    {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 2, InitDefaultsscc_info_QuerySegmentInfoResponse_milvus_2eproto}, {
+      &scc_info_Status_common_2eproto.base,
+      &scc_info_QuerySegmentInfo_milvus_2eproto.base,}};
+
 static void InitDefaultsscc_info_RegisterLinkResponse_milvus_2eproto() {
   GOOGLE_PROTOBUF_VERIFY_VERSION;
 
@@ -871,7 +929,7 @@ static void InitDefaultsscc_info_StringResponse_milvus_2eproto() {
     {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsscc_info_StringResponse_milvus_2eproto}, {
       &scc_info_Status_common_2eproto.base,}};
 
-static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_milvus_2eproto[44];
+static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_milvus_2eproto[47];
 static const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* file_level_enum_descriptors_milvus_2eproto[1];
 static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_milvus_2eproto = nullptr;
 
@@ -1233,6 +1291,33 @@ const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_milvus_2eproto::offsets[] PROT
   PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::PersistentSegmentInfoResponse, status_),
   PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::PersistentSegmentInfoResponse, infos_),
   ~0u,  // no _has_bits_
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, _internal_metadata_),
+  ~0u,  // no _extensions_
+  ~0u,  // no _oneof_case_
+  ~0u,  // no _weak_field_map_
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, segmentid_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, collectionid_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, partitionid_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, mem_size_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, num_rows_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, index_name_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfo, indexid_),
+  ~0u,  // no _has_bits_
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoRequest, _internal_metadata_),
+  ~0u,  // no _extensions_
+  ~0u,  // no _oneof_case_
+  ~0u,  // no _weak_field_map_
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoRequest, base_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoRequest, dbname_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoRequest, collectionname_),
+  ~0u,  // no _has_bits_
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoResponse, _internal_metadata_),
+  ~0u,  // no _extensions_
+  ~0u,  // no _oneof_case_
+  ~0u,  // no _weak_field_map_
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoResponse, status_),
+  PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::QuerySegmentInfoResponse, infos_),
+  ~0u,  // no _has_bits_
   PROTOBUF_FIELD_OFFSET(::milvus::proto::milvus::RegisterLinkResponse, _internal_metadata_),
   ~0u,  // no _extensions_
   ~0u,  // no _oneof_case_
@@ -1284,7 +1369,10 @@ static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOB
   { 327, -1, sizeof(::milvus::proto::milvus::PersistentSegmentInfo)},
   { 341, -1, sizeof(::milvus::proto::milvus::PersistentSegmentInfoRequest)},
   { 349, -1, sizeof(::milvus::proto::milvus::PersistentSegmentInfoResponse)},
-  { 356, -1, sizeof(::milvus::proto::milvus::RegisterLinkResponse)},
+  { 356, -1, sizeof(::milvus::proto::milvus::QuerySegmentInfo)},
+  { 368, -1, sizeof(::milvus::proto::milvus::QuerySegmentInfoRequest)},
+  { 376, -1, sizeof(::milvus::proto::milvus::QuerySegmentInfoResponse)},
+  { 383, -1, sizeof(::milvus::proto::milvus::RegisterLinkResponse)},
 };
 
 static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = {
@@ -1331,6 +1419,9 @@ static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] =
   reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_PersistentSegmentInfo_default_instance_),
   reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_PersistentSegmentInfoRequest_default_instance_),
   reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_PersistentSegmentInfoResponse_default_instance_),
+  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_QuerySegmentInfo_default_instance_),
+  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_QuerySegmentInfoRequest_default_instance_),
+  reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_QuerySegmentInfoResponse_default_instance_),
   reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::milvus::proto::milvus::_RegisterLinkResponse_default_instance_),
 };
 
@@ -1466,80 +1557,93 @@ const char descriptor_table_protodef_milvus_2eproto[] PROTOBUF_SECTION_VARIABLE(
   "ollectionName\030\003 \001(\t\"\207\001\n\035PersistentSegmen"
   "tInfoResponse\022+\n\006status\030\001 \001(\0132\033.milvus.p"
   "roto.common.Status\0229\n\005infos\030\002 \003(\0132*.milv"
-  "us.proto.milvus.PersistentSegmentInfo\"r\n"
-  "\024RegisterLinkResponse\022-\n\007address\030\001 \001(\0132\034"
-  ".milvus.proto.common.Address\022+\n\006status\030\002"
-  " \001(\0132\033.milvus.proto.common.Status*@\n\017Pla"
-  "ceholderType\022\010\n\004NONE\020\000\022\021\n\rVECTOR_BINARY\020"
-  "d\022\020\n\014VECTOR_FLOAT\020e2\365\021\n\rMilvusService\022_\n"
-  "\020CreateCollection\022,.milvus.proto.milvus."
-  "CreateCollectionRequest\032\033.milvus.proto.c"
-  "ommon.Status\"\000\022[\n\016DropCollection\022*.milvu"
-  "s.proto.milvus.DropCollectionRequest\032\033.m"
-  "ilvus.proto.common.Status\"\000\022_\n\rHasCollec"
-  "tion\022).milvus.proto.milvus.HasCollection"
-  "Request\032!.milvus.proto.milvus.BoolRespon"
-  "se\"\000\022[\n\016LoadCollection\022*.milvus.proto.mi"
-  "lvus.LoadCollectionRequest\032\033.milvus.prot"
-  "o.common.Status\"\000\022a\n\021ReleaseCollection\022-"
-  ".milvus.proto.milvus.ReleaseCollectionRe"
-  "quest\032\033.milvus.proto.common.Status\"\000\022w\n\022"
-  "DescribeCollection\022..milvus.proto.milvus"
-  ".DescribeCollectionRequest\032/.milvus.prot"
-  "o.milvus.DescribeCollectionResponse\"\000\022v\n"
-  "\027GetCollectionStatistics\022+.milvus.proto."
-  "milvus.CollectionStatsRequest\032,.milvus.p"
-  "roto.milvus.CollectionStatsResponse\"\000\022l\n"
-  "\017ShowCollections\022*.milvus.proto.milvus.S"
-  "howCollectionRequest\032+.milvus.proto.milv"
-  "us.ShowCollectionResponse\"\000\022]\n\017CreatePar"
-  "tition\022+.milvus.proto.milvus.CreateParti"
-  "tionRequest\032\033.milvus.proto.common.Status"
-  "\"\000\022Y\n\rDropPartition\022).milvus.proto.milvu"
-  "s.DropPartitionRequest\032\033.milvus.proto.co"
-  "mmon.Status\"\000\022]\n\014HasPartition\022(.milvus.p"
-  "roto.milvus.HasPartitionRequest\032!.milvus"
-  ".proto.milvus.BoolResponse\"\000\022Y\n\016LoadPart"
-  "itions\022(.milvus.proto.milvus.LoadPartito"
-  "nRequest\032\033.milvus.proto.common.Status\"\000\022"
-  "`\n\021ReleasePartitions\022,.milvus.proto.milv"
-  "us.ReleasePartitionRequest\032\033.milvus.prot"
-  "o.common.Status\"\000\022s\n\026GetPartitionStatist"
-  "ics\022*.milvus.proto.milvus.PartitionStats"
-  "Request\032+.milvus.proto.milvus.PartitionS"
-  "tatsResponse\"\000\022i\n\016ShowPartitions\022).milvu"
-  "s.proto.milvus.ShowPartitionRequest\032*.mi"
-  "lvus.proto.milvus.ShowPartitionResponse\""
-  "\000\022U\n\013CreateIndex\022\'.milvus.proto.milvus.C"
-  "reateIndexRequest\032\033.milvus.proto.common."
-  "Status\"\000\022h\n\rDescribeIndex\022).milvus.proto"
-  ".milvus.DescribeIndexRequest\032*.milvus.pr"
-  "oto.milvus.DescribeIndexResponse\"\000\022b\n\rGe"
-  "tIndexState\022&.milvus.proto.milvus.IndexS"
-  "tateRequest\032\'.milvus.proto.milvus.IndexS"
-  "tateResponse\"\000\022S\n\006Insert\022\".milvus.proto."
-  "milvus.InsertRequest\032#.milvus.proto.milv"
-  "us.InsertResponse\"\000\022R\n\006Search\022\".milvus.p"
-  "roto.milvus.SearchRequest\032\".milvus.proto"
-  ".milvus.SearchResults\"\000\022I\n\005Flush\022!.milvu"
-  "s.proto.milvus.FlushRequest\032\033.milvus.pro"
-  "to.common.Status\"\000\022Q\n\014GetDdChannel\022\032.mil"
-  "vus.proto.common.Empty\032#.milvus.proto.mi"
-  "lvus.StringResponse\"\000\022\203\001\n\030GetPersistentS"
-  "egmentInfo\0221.milvus.proto.milvus.Persist"
-  "entSegmentInfoRequest\0322.milvus.proto.mil"
-  "vus.PersistentSegmentInfoResponse\"\0002g\n\014P"
-  "roxyService\022W\n\014RegisterLink\022\032.milvus.pro"
-  "to.common.Empty\032).milvus.proto.milvus.Re"
-  "gisterLinkResponse\"\000BBZ@github.com/zilli"
-  "ztech/milvus-distributed/internal/proto/"
-  "milvuspbb\006proto3"
+  "us.proto.milvus.PersistentSegmentInfo\"\231\001"
+  "\n\020QuerySegmentInfo\022\021\n\tsegmentID\030\001 \001(\003\022\024\n"
+  "\014collectionID\030\002 \001(\003\022\023\n\013partitionID\030\003 \001(\003"
+  "\022\020\n\010mem_size\030\004 \001(\003\022\020\n\010num_rows\030\005 \001(\003\022\022\n\n"
+  "index_name\030\006 \001(\t\022\017\n\007indexID\030\007 \001(\003\"m\n\027Que"
+  "rySegmentInfoRequest\022*\n\004base\030\001 \001(\0132\034.mil"
+  "vus.proto.common.MsgBase\022\016\n\006dbName\030\002 \001(\t"
+  "\022\026\n\016collectionName\030\003 \001(\t\"}\n\030QuerySegment"
+  "InfoResponse\022+\n\006status\030\001 \001(\0132\033.milvus.pr"
+  "oto.common.Status\0224\n\005infos\030\002 \003(\0132%.milvu"
+  "s.proto.milvus.QuerySegmentInfo\"r\n\024Regis"
+  "terLinkResponse\022-\n\007address\030\001 \001(\0132\034.milvu"
+  "s.proto.common.Address\022+\n\006status\030\002 \001(\0132\033"
+  ".milvus.proto.common.Status*@\n\017Placehold"
+  "erType\022\010\n\004NONE\020\000\022\021\n\rVECTOR_BINARY\020d\022\020\n\014V"
+  "ECTOR_FLOAT\020e2\353\022\n\rMilvusService\022_\n\020Creat"
+  "eCollection\022,.milvus.proto.milvus.Create"
+  "CollectionRequest\032\033.milvus.proto.common."
+  "Status\"\000\022[\n\016DropCollection\022*.milvus.prot"
+  "o.milvus.DropCollectionRequest\032\033.milvus."
+  "proto.common.Status\"\000\022_\n\rHasCollection\022)"
+  ".milvus.proto.milvus.HasCollectionReques"
+  "t\032!.milvus.proto.milvus.BoolResponse\"\000\022["
+  "\n\016LoadCollection\022*.milvus.proto.milvus.L"
+  "oadCollectionRequest\032\033.milvus.proto.comm"
+  "on.Status\"\000\022a\n\021ReleaseCollection\022-.milvu"
+  "s.proto.milvus.ReleaseCollectionRequest\032"
+  "\033.milvus.proto.common.Status\"\000\022w\n\022Descri"
+  "beCollection\022..milvus.proto.milvus.Descr"
+  "ibeCollectionRequest\032/.milvus.proto.milv"
+  "us.DescribeCollectionResponse\"\000\022v\n\027GetCo"
+  "llectionStatistics\022+.milvus.proto.milvus"
+  ".CollectionStatsRequest\032,.milvus.proto.m"
+  "ilvus.CollectionStatsResponse\"\000\022l\n\017ShowC"
+  "ollections\022*.milvus.proto.milvus.ShowCol"
+  "lectionRequest\032+.milvus.proto.milvus.Sho"
+  "wCollectionResponse\"\000\022]\n\017CreatePartition"
+  "\022+.milvus.proto.milvus.CreatePartitionRe"
+  "quest\032\033.milvus.proto.common.Status\"\000\022Y\n\r"
+  "DropPartition\022).milvus.proto.milvus.Drop"
+  "PartitionRequest\032\033.milvus.proto.common.S"
+  "tatus\"\000\022]\n\014HasPartition\022(.milvus.proto.m"
+  "ilvus.HasPartitionRequest\032!.milvus.proto"
+  ".milvus.BoolResponse\"\000\022Y\n\016LoadPartitions"
+  "\022(.milvus.proto.milvus.LoadPartitonReque"
+  "st\032\033.milvus.proto.common.Status\"\000\022`\n\021Rel"
+  "easePartitions\022,.milvus.proto.milvus.Rel"
+  "easePartitionRequest\032\033.milvus.proto.comm"
+  "on.Status\"\000\022s\n\026GetPartitionStatistics\022*."
+  "milvus.proto.milvus.PartitionStatsReques"
+  "t\032+.milvus.proto.milvus.PartitionStatsRe"
+  "sponse\"\000\022i\n\016ShowPartitions\022).milvus.prot"
+  "o.milvus.ShowPartitionRequest\032*.milvus.p"
+  "roto.milvus.ShowPartitionResponse\"\000\022U\n\013C"
+  "reateIndex\022\'.milvus.proto.milvus.CreateI"
+  "ndexRequest\032\033.milvus.proto.common.Status"
+  "\"\000\022h\n\rDescribeIndex\022).milvus.proto.milvu"
+  "s.DescribeIndexRequest\032*.milvus.proto.mi"
+  "lvus.DescribeIndexResponse\"\000\022b\n\rGetIndex"
+  "State\022&.milvus.proto.milvus.IndexStateRe"
+  "quest\032\'.milvus.proto.milvus.IndexStateRe"
+  "sponse\"\000\022S\n\006Insert\022\".milvus.proto.milvus"
+  ".InsertRequest\032#.milvus.proto.milvus.Ins"
+  "ertResponse\"\000\022R\n\006Search\022\".milvus.proto.m"
+  "ilvus.SearchRequest\032\".milvus.proto.milvu"
+  "s.SearchResults\"\000\022I\n\005Flush\022!.milvus.prot"
+  "o.milvus.FlushRequest\032\033.milvus.proto.com"
+  "mon.Status\"\000\022Q\n\014GetDdChannel\022\032.milvus.pr"
+  "oto.common.Empty\032#.milvus.proto.milvus.S"
+  "tringResponse\"\000\022\203\001\n\030GetPersistentSegment"
+  "Info\0221.milvus.proto.milvus.PersistentSeg"
+  "mentInfoRequest\0322.milvus.proto.milvus.Pe"
+  "rsistentSegmentInfoResponse\"\000\022t\n\023GetQuer"
+  "ySegmentInfo\022,.milvus.proto.milvus.Query"
+  "SegmentInfoRequest\032-.milvus.proto.milvus"
+  ".QuerySegmentInfoResponse\"\0002g\n\014ProxyServ"
+  "ice\022W\n\014RegisterLink\022\032.milvus.proto.commo"
+  "n.Empty\032).milvus.proto.milvus.RegisterLi"
+  "nkResponse\"\000BBZ@github.com/zilliztech/mi"
+  "lvus-distributed/internal/proto/milvuspb"
+  "b\006proto3"
   ;
 static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_milvus_2eproto_deps[2] = {
   &::descriptor_table_common_2eproto,
   &::descriptor_table_schema_2eproto,
 };
-static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_milvus_2eproto_sccs[44] = {
+static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_milvus_2eproto_sccs[47] = {
   &scc_info_BoolResponse_milvus_2eproto.base,
   &scc_info_CollectionStatsRequest_milvus_2eproto.base,
   &scc_info_CollectionStatsResponse_milvus_2eproto.base,
@@ -1572,6 +1676,9 @@ static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_mil
   &scc_info_PersistentSegmentInfoResponse_milvus_2eproto.base,
   &scc_info_PlaceholderGroup_milvus_2eproto.base,
   &scc_info_PlaceholderValue_milvus_2eproto.base,
+  &scc_info_QuerySegmentInfo_milvus_2eproto.base,
+  &scc_info_QuerySegmentInfoRequest_milvus_2eproto.base,
+  &scc_info_QuerySegmentInfoResponse_milvus_2eproto.base,
   &scc_info_RegisterLinkResponse_milvus_2eproto.base,
   &scc_info_ReleaseCollectionRequest_milvus_2eproto.base,
   &scc_info_ReleasePartitionRequest_milvus_2eproto.base,
@@ -1588,10 +1695,10 @@ static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_mil
 static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_milvus_2eproto_once;
 static bool descriptor_table_milvus_2eproto_initialized = false;
 const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_milvus_2eproto = {
-  &descriptor_table_milvus_2eproto_initialized, descriptor_table_protodef_milvus_2eproto, "milvus.proto", 7936,
-  &descriptor_table_milvus_2eproto_once, descriptor_table_milvus_2eproto_sccs, descriptor_table_milvus_2eproto_deps, 44, 2,
+  &descriptor_table_milvus_2eproto_initialized, descriptor_table_protodef_milvus_2eproto, "milvus.proto", 8448,
+  &descriptor_table_milvus_2eproto_once, descriptor_table_milvus_2eproto_sccs, descriptor_table_milvus_2eproto_deps, 47, 2,
   schemas, file_default_instances, TableStruct_milvus_2eproto::offsets,
-  file_level_metadata_milvus_2eproto, 44, file_level_enum_descriptors_milvus_2eproto, file_level_service_descriptors_milvus_2eproto,
+  file_level_metadata_milvus_2eproto, 47, file_level_enum_descriptors_milvus_2eproto, file_level_service_descriptors_milvus_2eproto,
 };
 
 // Force running AddDescriptors() at dynamic initialization time.
@@ -18945,122 +19052,124 @@ void PersistentSegmentInfoResponse::InternalSwap(PersistentSegmentInfoResponse*
 
 // ===================================================================
 
-void RegisterLinkResponse::InitAsDefaultInstance() {
-  ::milvus::proto::milvus::_RegisterLinkResponse_default_instance_._instance.get_mutable()->address_ = const_cast< ::milvus::proto::common::Address*>(
-      ::milvus::proto::common::Address::internal_default_instance());
-  ::milvus::proto::milvus::_RegisterLinkResponse_default_instance_._instance.get_mutable()->status_ = const_cast< ::milvus::proto::common::Status*>(
-      ::milvus::proto::common::Status::internal_default_instance());
+void QuerySegmentInfo::InitAsDefaultInstance() {
 }
-class RegisterLinkResponse::_Internal {
+class QuerySegmentInfo::_Internal {
  public:
-  static const ::milvus::proto::common::Address& address(const RegisterLinkResponse* msg);
-  static const ::milvus::proto::common::Status& status(const RegisterLinkResponse* msg);
 };
 
-const ::milvus::proto::common::Address&
-RegisterLinkResponse::_Internal::address(const RegisterLinkResponse* msg) {
-  return *msg->address_;
-}
-const ::milvus::proto::common::Status&
-RegisterLinkResponse::_Internal::status(const RegisterLinkResponse* msg) {
-  return *msg->status_;
-}
-void RegisterLinkResponse::clear_address() {
-  if (GetArenaNoVirtual() == nullptr && address_ != nullptr) {
-    delete address_;
-  }
-  address_ = nullptr;
-}
-void RegisterLinkResponse::clear_status() {
-  if (GetArenaNoVirtual() == nullptr && status_ != nullptr) {
-    delete status_;
-  }
-  status_ = nullptr;
-}
-RegisterLinkResponse::RegisterLinkResponse()
+QuerySegmentInfo::QuerySegmentInfo()
   : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) {
   SharedCtor();
-  // @@protoc_insertion_point(constructor:milvus.proto.milvus.RegisterLinkResponse)
+  // @@protoc_insertion_point(constructor:milvus.proto.milvus.QuerySegmentInfo)
 }
-RegisterLinkResponse::RegisterLinkResponse(const RegisterLinkResponse& from)
+QuerySegmentInfo::QuerySegmentInfo(const QuerySegmentInfo& from)
   : ::PROTOBUF_NAMESPACE_ID::Message(),
       _internal_metadata_(nullptr) {
   _internal_metadata_.MergeFrom(from._internal_metadata_);
-  if (from.has_address()) {
-    address_ = new ::milvus::proto::common::Address(*from.address_);
-  } else {
-    address_ = nullptr;
-  }
-  if (from.has_status()) {
-    status_ = new ::milvus::proto::common::Status(*from.status_);
-  } else {
-    status_ = nullptr;
+  index_name_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  if (!from.index_name().empty()) {
+    index_name_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.index_name_);
   }
-  // @@protoc_insertion_point(copy_constructor:milvus.proto.milvus.RegisterLinkResponse)
+  ::memcpy(&segmentid_, &from.segmentid_,
+    static_cast<size_t>(reinterpret_cast<char*>(&indexid_) -
+    reinterpret_cast<char*>(&segmentid_)) + sizeof(indexid_));
+  // @@protoc_insertion_point(copy_constructor:milvus.proto.milvus.QuerySegmentInfo)
 }
 
-void RegisterLinkResponse::SharedCtor() {
-  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_RegisterLinkResponse_milvus_2eproto.base);
-  ::memset(&address_, 0, static_cast<size_t>(
-      reinterpret_cast<char*>(&status_) -
-      reinterpret_cast<char*>(&address_)) + sizeof(status_));
+void QuerySegmentInfo::SharedCtor() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_QuerySegmentInfo_milvus_2eproto.base);
+  index_name_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  ::memset(&segmentid_, 0, static_cast<size_t>(
+      reinterpret_cast<char*>(&indexid_) -
+      reinterpret_cast<char*>(&segmentid_)) + sizeof(indexid_));
 }
 
-RegisterLinkResponse::~RegisterLinkResponse() {
-  // @@protoc_insertion_point(destructor:milvus.proto.milvus.RegisterLinkResponse)
+QuerySegmentInfo::~QuerySegmentInfo() {
+  // @@protoc_insertion_point(destructor:milvus.proto.milvus.QuerySegmentInfo)
   SharedDtor();
 }
 
-void RegisterLinkResponse::SharedDtor() {
-  if (this != internal_default_instance()) delete address_;
-  if (this != internal_default_instance()) delete status_;
+void QuerySegmentInfo::SharedDtor() {
+  index_name_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
 }
 
-void RegisterLinkResponse::SetCachedSize(int size) const {
+void QuerySegmentInfo::SetCachedSize(int size) const {
   _cached_size_.Set(size);
 }
-const RegisterLinkResponse& RegisterLinkResponse::default_instance() {
-  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_RegisterLinkResponse_milvus_2eproto.base);
+const QuerySegmentInfo& QuerySegmentInfo::default_instance() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_QuerySegmentInfo_milvus_2eproto.base);
   return *internal_default_instance();
 }
 
 
-void RegisterLinkResponse::Clear() {
-// @@protoc_insertion_point(message_clear_start:milvus.proto.milvus.RegisterLinkResponse)
+void QuerySegmentInfo::Clear() {
+// @@protoc_insertion_point(message_clear_start:milvus.proto.milvus.QuerySegmentInfo)
   ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
   // Prevent compiler warnings about cached_has_bits being unused
   (void) cached_has_bits;
 
-  if (GetArenaNoVirtual() == nullptr && address_ != nullptr) {
-    delete address_;
-  }
-  address_ = nullptr;
-  if (GetArenaNoVirtual() == nullptr && status_ != nullptr) {
-    delete status_;
-  }
-  status_ = nullptr;
+  index_name_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  ::memset(&segmentid_, 0, static_cast<size_t>(
+      reinterpret_cast<char*>(&indexid_) -
+      reinterpret_cast<char*>(&segmentid_)) + sizeof(indexid_));
   _internal_metadata_.Clear();
 }
 
 #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
-const char* RegisterLinkResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) {
+const char* QuerySegmentInfo::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) {
 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
   while (!ctx->Done(&ptr)) {
     ::PROTOBUF_NAMESPACE_ID::uint32 tag;
     ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag);
     CHK_(ptr);
     switch (tag >> 3) {
-      // .milvus.proto.common.Address address = 1;
+      // int64 segmentID = 1;
       case 1:
-        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
-          ptr = ctx->ParseMessage(mutable_address(), ptr);
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 8)) {
+          segmentid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr);
           CHK_(ptr);
         } else goto handle_unusual;
         continue;
-      // .milvus.proto.common.Status status = 2;
+      // int64 collectionID = 2;
       case 2:
-        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
-          ptr = ctx->ParseMessage(mutable_status(), ptr);
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 16)) {
+          collectionid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // int64 partitionID = 3;
+      case 3:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 24)) {
+          partitionid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // int64 mem_size = 4;
+      case 4:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 32)) {
+          mem_size_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // int64 num_rows = 5;
+      case 5:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 40)) {
+          num_rows_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // string index_name = 6;
+      case 6:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 50)) {
+          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_index_name(), ptr, ctx, "milvus.proto.milvus.QuerySegmentInfo.index_name");
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // int64 indexID = 7;
+      case 7:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 56)) {
+          indexid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr);
           CHK_(ptr);
         } else goto handle_unusual;
         continue;
@@ -19084,32 +19193,103 @@ failure:
 #undef CHK_
 }
 #else  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
-bool RegisterLinkResponse::MergePartialFromCodedStream(
+bool QuerySegmentInfo::MergePartialFromCodedStream(
     ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) {
 #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
   ::PROTOBUF_NAMESPACE_ID::uint32 tag;
-  // @@protoc_insertion_point(parse_start:milvus.proto.milvus.RegisterLinkResponse)
+  // @@protoc_insertion_point(parse_start:milvus.proto.milvus.QuerySegmentInfo)
   for (;;) {
     ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
     tag = p.first;
     if (!p.second) goto handle_unusual;
     switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) {
-      // .milvus.proto.common.Address address = 1;
+      // int64 segmentID = 1;
       case 1: {
-        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) {
-          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
-               input, mutable_address()));
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (8 & 0xFF)) {
+
+          DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive<
+                   ::PROTOBUF_NAMESPACE_ID::int64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT64>(
+                 input, &segmentid_)));
         } else {
           goto handle_unusual;
         }
         break;
       }
 
-      // .milvus.proto.common.Status status = 2;
+      // int64 collectionID = 2;
       case 2: {
-        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (18 & 0xFF)) {
-          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
-               input, mutable_status()));
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (16 & 0xFF)) {
+
+          DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive<
+                   ::PROTOBUF_NAMESPACE_ID::int64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT64>(
+                 input, &collectionid_)));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // int64 partitionID = 3;
+      case 3: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (24 & 0xFF)) {
+
+          DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive<
+                   ::PROTOBUF_NAMESPACE_ID::int64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT64>(
+                 input, &partitionid_)));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // int64 mem_size = 4;
+      case 4: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (32 & 0xFF)) {
+
+          DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive<
+                   ::PROTOBUF_NAMESPACE_ID::int64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT64>(
+                 input, &mem_size_)));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // int64 num_rows = 5;
+      case 5: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (40 & 0xFF)) {
+
+          DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive<
+                   ::PROTOBUF_NAMESPACE_ID::int64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT64>(
+                 input, &num_rows_)));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // string index_name = 6;
+      case 6: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (50 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString(
+                input, this->mutable_index_name()));
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+            this->index_name().data(), static_cast<int>(this->index_name().length()),
+            ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE,
+            "milvus.proto.milvus.QuerySegmentInfo.index_name"));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // int64 indexID = 7;
+      case 7: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (56 & 0xFF)) {
+
+          DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive<
+                   ::PROTOBUF_NAMESPACE_ID::int64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT64>(
+                 input, &indexid_)));
         } else {
           goto handle_unusual;
         }
@@ -19128,31 +19308,1207 @@ bool RegisterLinkResponse::MergePartialFromCodedStream(
     }
   }
 success:
-  // @@protoc_insertion_point(parse_success:milvus.proto.milvus.RegisterLinkResponse)
+  // @@protoc_insertion_point(parse_success:milvus.proto.milvus.QuerySegmentInfo)
   return true;
 failure:
-  // @@protoc_insertion_point(parse_failure:milvus.proto.milvus.RegisterLinkResponse)
+  // @@protoc_insertion_point(parse_failure:milvus.proto.milvus.QuerySegmentInfo)
   return false;
 #undef DO_
 }
 #endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
 
-void RegisterLinkResponse::SerializeWithCachedSizes(
+void QuerySegmentInfo::SerializeWithCachedSizes(
     ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const {
-  // @@protoc_insertion_point(serialize_start:milvus.proto.milvus.RegisterLinkResponse)
+  // @@protoc_insertion_point(serialize_start:milvus.proto.milvus.QuerySegmentInfo)
   ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
   (void) cached_has_bits;
 
-  // .milvus.proto.common.Address address = 1;
-  if (this->has_address()) {
-    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
-      1, _Internal::address(this), output);
+  // int64 segmentID = 1;
+  if (this->segmentid() != 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64(1, this->segmentid(), output);
   }
 
-  // .milvus.proto.common.Status status = 2;
-  if (this->has_status()) {
-    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
-      2, _Internal::status(this), output);
+  // int64 collectionID = 2;
+  if (this->collectionid() != 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64(2, this->collectionid(), output);
+  }
+
+  // int64 partitionID = 3;
+  if (this->partitionid() != 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64(3, this->partitionid(), output);
+  }
+
+  // int64 mem_size = 4;
+  if (this->mem_size() != 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64(4, this->mem_size(), output);
+  }
+
+  // int64 num_rows = 5;
+  if (this->num_rows() != 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64(5, this->num_rows(), output);
+  }
+
+  // string index_name = 6;
+  if (this->index_name().size() > 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+      this->index_name().data(), static_cast<int>(this->index_name().length()),
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
+      "milvus.proto.milvus.QuerySegmentInfo.index_name");
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased(
+      6, this->index_name(), output);
+  }
+
+  // int64 indexID = 7;
+  if (this->indexid() != 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64(7, this->indexid(), output);
+  }
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields(
+        _internal_metadata_.unknown_fields(), output);
+  }
+  // @@protoc_insertion_point(serialize_end:milvus.proto.milvus.QuerySegmentInfo)
+}
+
+::PROTOBUF_NAMESPACE_ID::uint8* QuerySegmentInfo::InternalSerializeWithCachedSizesToArray(
+    ::PROTOBUF_NAMESPACE_ID::uint8* target) const {
+  // @@protoc_insertion_point(serialize_to_array_start:milvus.proto.milvus.QuerySegmentInfo)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  // int64 segmentID = 1;
+  if (this->segmentid() != 0) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64ToArray(1, this->segmentid(), target);
+  }
+
+  // int64 collectionID = 2;
+  if (this->collectionid() != 0) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64ToArray(2, this->collectionid(), target);
+  }
+
+  // int64 partitionID = 3;
+  if (this->partitionid() != 0) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64ToArray(3, this->partitionid(), target);
+  }
+
+  // int64 mem_size = 4;
+  if (this->mem_size() != 0) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64ToArray(4, this->mem_size(), target);
+  }
+
+  // int64 num_rows = 5;
+  if (this->num_rows() != 0) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64ToArray(5, this->num_rows(), target);
+  }
+
+  // string index_name = 6;
+  if (this->index_name().size() > 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+      this->index_name().data(), static_cast<int>(this->index_name().length()),
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
+      "milvus.proto.milvus.QuerySegmentInfo.index_name");
+    target =
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray(
+        6, this->index_name(), target);
+  }
+
+  // int64 indexID = 7;
+  if (this->indexid() != 0) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt64ToArray(7, this->indexid(), target);
+  }
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray(
+        _internal_metadata_.unknown_fields(), target);
+  }
+  // @@protoc_insertion_point(serialize_to_array_end:milvus.proto.milvus.QuerySegmentInfo)
+  return target;
+}
+
+size_t QuerySegmentInfo::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:milvus.proto.milvus.QuerySegmentInfo)
+  size_t total_size = 0;
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    total_size +=
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize(
+        _internal_metadata_.unknown_fields());
+  }
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  // Prevent compiler warnings about cached_has_bits being unused
+  (void) cached_has_bits;
+
+  // string index_name = 6;
+  if (this->index_name().size() > 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
+        this->index_name());
+  }
+
+  // int64 segmentID = 1;
+  if (this->segmentid() != 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int64Size(
+        this->segmentid());
+  }
+
+  // int64 collectionID = 2;
+  if (this->collectionid() != 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int64Size(
+        this->collectionid());
+  }
+
+  // int64 partitionID = 3;
+  if (this->partitionid() != 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int64Size(
+        this->partitionid());
+  }
+
+  // int64 mem_size = 4;
+  if (this->mem_size() != 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int64Size(
+        this->mem_size());
+  }
+
+  // int64 num_rows = 5;
+  if (this->num_rows() != 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int64Size(
+        this->num_rows());
+  }
+
+  // int64 indexID = 7;
+  if (this->indexid() != 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int64Size(
+        this->indexid());
+  }
+
+  int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size);
+  SetCachedSize(cached_size);
+  return total_size;
+}
+
+void QuerySegmentInfo::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:milvus.proto.milvus.QuerySegmentInfo)
+  GOOGLE_DCHECK_NE(&from, this);
+  const QuerySegmentInfo* source =
+      ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<QuerySegmentInfo>(
+          &from);
+  if (source == nullptr) {
+  // @@protoc_insertion_point(generalized_merge_from_cast_fail:milvus.proto.milvus.QuerySegmentInfo)
+    ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
+  } else {
+  // @@protoc_insertion_point(generalized_merge_from_cast_success:milvus.proto.milvus.QuerySegmentInfo)
+    MergeFrom(*source);
+  }
+}
+
+void QuerySegmentInfo::MergeFrom(const QuerySegmentInfo& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:milvus.proto.milvus.QuerySegmentInfo)
+  GOOGLE_DCHECK_NE(&from, this);
+  _internal_metadata_.MergeFrom(from._internal_metadata_);
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  if (from.index_name().size() > 0) {
+
+    index_name_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.index_name_);
+  }
+  if (from.segmentid() != 0) {
+    set_segmentid(from.segmentid());
+  }
+  if (from.collectionid() != 0) {
+    set_collectionid(from.collectionid());
+  }
+  if (from.partitionid() != 0) {
+    set_partitionid(from.partitionid());
+  }
+  if (from.mem_size() != 0) {
+    set_mem_size(from.mem_size());
+  }
+  if (from.num_rows() != 0) {
+    set_num_rows(from.num_rows());
+  }
+  if (from.indexid() != 0) {
+    set_indexid(from.indexid());
+  }
+}
+
+void QuerySegmentInfo::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:milvus.proto.milvus.QuerySegmentInfo)
+  if (&from == this) return;
+  Clear();
+  MergeFrom(from);
+}
+
+void QuerySegmentInfo::CopyFrom(const QuerySegmentInfo& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:milvus.proto.milvus.QuerySegmentInfo)
+  if (&from == this) return;
+  Clear();
+  MergeFrom(from);
+}
+
+bool QuerySegmentInfo::IsInitialized() const {
+  return true;
+}
+
+void QuerySegmentInfo::InternalSwap(QuerySegmentInfo* other) {
+  using std::swap;
+  _internal_metadata_.Swap(&other->_internal_metadata_);
+  index_name_.Swap(&other->index_name_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
+    GetArenaNoVirtual());
+  swap(segmentid_, other->segmentid_);
+  swap(collectionid_, other->collectionid_);
+  swap(partitionid_, other->partitionid_);
+  swap(mem_size_, other->mem_size_);
+  swap(num_rows_, other->num_rows_);
+  swap(indexid_, other->indexid_);
+}
+
+::PROTOBUF_NAMESPACE_ID::Metadata QuerySegmentInfo::GetMetadata() const {
+  return GetMetadataStatic();
+}
+
+
+// ===================================================================
+
+void QuerySegmentInfoRequest::InitAsDefaultInstance() {
+  ::milvus::proto::milvus::_QuerySegmentInfoRequest_default_instance_._instance.get_mutable()->base_ = const_cast< ::milvus::proto::common::MsgBase*>(
+      ::milvus::proto::common::MsgBase::internal_default_instance());
+}
+class QuerySegmentInfoRequest::_Internal {
+ public:
+  static const ::milvus::proto::common::MsgBase& base(const QuerySegmentInfoRequest* msg);
+};
+
+const ::milvus::proto::common::MsgBase&
+QuerySegmentInfoRequest::_Internal::base(const QuerySegmentInfoRequest* msg) {
+  return *msg->base_;
+}
+void QuerySegmentInfoRequest::clear_base() {
+  if (GetArenaNoVirtual() == nullptr && base_ != nullptr) {
+    delete base_;
+  }
+  base_ = nullptr;
+}
+QuerySegmentInfoRequest::QuerySegmentInfoRequest()
+  : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) {
+  SharedCtor();
+  // @@protoc_insertion_point(constructor:milvus.proto.milvus.QuerySegmentInfoRequest)
+}
+QuerySegmentInfoRequest::QuerySegmentInfoRequest(const QuerySegmentInfoRequest& from)
+  : ::PROTOBUF_NAMESPACE_ID::Message(),
+      _internal_metadata_(nullptr) {
+  _internal_metadata_.MergeFrom(from._internal_metadata_);
+  dbname_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  if (!from.dbname().empty()) {
+    dbname_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.dbname_);
+  }
+  collectionname_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  if (!from.collectionname().empty()) {
+    collectionname_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.collectionname_);
+  }
+  if (from.has_base()) {
+    base_ = new ::milvus::proto::common::MsgBase(*from.base_);
+  } else {
+    base_ = nullptr;
+  }
+  // @@protoc_insertion_point(copy_constructor:milvus.proto.milvus.QuerySegmentInfoRequest)
+}
+
+void QuerySegmentInfoRequest::SharedCtor() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_QuerySegmentInfoRequest_milvus_2eproto.base);
+  dbname_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  collectionname_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  base_ = nullptr;
+}
+
+QuerySegmentInfoRequest::~QuerySegmentInfoRequest() {
+  // @@protoc_insertion_point(destructor:milvus.proto.milvus.QuerySegmentInfoRequest)
+  SharedDtor();
+}
+
+void QuerySegmentInfoRequest::SharedDtor() {
+  dbname_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  collectionname_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  if (this != internal_default_instance()) delete base_;
+}
+
+void QuerySegmentInfoRequest::SetCachedSize(int size) const {
+  _cached_size_.Set(size);
+}
+const QuerySegmentInfoRequest& QuerySegmentInfoRequest::default_instance() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_QuerySegmentInfoRequest_milvus_2eproto.base);
+  return *internal_default_instance();
+}
+
+
+void QuerySegmentInfoRequest::Clear() {
+// @@protoc_insertion_point(message_clear_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  // Prevent compiler warnings about cached_has_bits being unused
+  (void) cached_has_bits;
+
+  dbname_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  collectionname_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+  if (GetArenaNoVirtual() == nullptr && base_ != nullptr) {
+    delete base_;
+  }
+  base_ = nullptr;
+  _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* QuerySegmentInfoRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) {
+#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
+  while (!ctx->Done(&ptr)) {
+    ::PROTOBUF_NAMESPACE_ID::uint32 tag;
+    ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag);
+    CHK_(ptr);
+    switch (tag >> 3) {
+      // .milvus.proto.common.MsgBase base = 1;
+      case 1:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
+          ptr = ctx->ParseMessage(mutable_base(), ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // string dbName = 2;
+      case 2:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
+          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_dbname(), ptr, ctx, "milvus.proto.milvus.QuerySegmentInfoRequest.dbName");
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // string collectionName = 3;
+      case 3:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 26)) {
+          ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_collectionname(), ptr, ctx, "milvus.proto.milvus.QuerySegmentInfoRequest.collectionName");
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      default: {
+      handle_unusual:
+        if ((tag & 7) == 4 || tag == 0) {
+          ctx->SetLastTag(tag);
+          goto success;
+        }
+        ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx);
+        CHK_(ptr != nullptr);
+        continue;
+      }
+    }  // switch
+  }  // while
+success:
+  return ptr;
+failure:
+  ptr = nullptr;
+  goto success;
+#undef CHK_
+}
+#else  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool QuerySegmentInfoRequest::MergePartialFromCodedStream(
+    ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+  ::PROTOBUF_NAMESPACE_ID::uint32 tag;
+  // @@protoc_insertion_point(parse_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  for (;;) {
+    ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    tag = p.first;
+    if (!p.second) goto handle_unusual;
+    switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) {
+      // .milvus.proto.common.MsgBase base = 1;
+      case 1: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
+               input, mutable_base()));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // string dbName = 2;
+      case 2: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (18 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString(
+                input, this->mutable_dbname()));
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+            this->dbname().data(), static_cast<int>(this->dbname().length()),
+            ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE,
+            "milvus.proto.milvus.QuerySegmentInfoRequest.dbName"));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // string collectionName = 3;
+      case 3: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (26 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString(
+                input, this->mutable_collectionname()));
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+            this->collectionname().data(), static_cast<int>(this->collectionname().length()),
+            ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE,
+            "milvus.proto.milvus.QuerySegmentInfoRequest.collectionName"));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      default: {
+      handle_unusual:
+        if (tag == 0) {
+          goto success;
+        }
+        DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField(
+              input, tag, _internal_metadata_.mutable_unknown_fields()));
+        break;
+      }
+    }
+  }
+success:
+  // @@protoc_insertion_point(parse_success:milvus.proto.milvus.QuerySegmentInfoRequest)
+  return true;
+failure:
+  // @@protoc_insertion_point(parse_failure:milvus.proto.milvus.QuerySegmentInfoRequest)
+  return false;
+#undef DO_
+}
+#endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void QuerySegmentInfoRequest::SerializeWithCachedSizes(
+    ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const {
+  // @@protoc_insertion_point(serialize_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  // .milvus.proto.common.MsgBase base = 1;
+  if (this->has_base()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
+      1, _Internal::base(this), output);
+  }
+
+  // string dbName = 2;
+  if (this->dbname().size() > 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+      this->dbname().data(), static_cast<int>(this->dbname().length()),
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
+      "milvus.proto.milvus.QuerySegmentInfoRequest.dbName");
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased(
+      2, this->dbname(), output);
+  }
+
+  // string collectionName = 3;
+  if (this->collectionname().size() > 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+      this->collectionname().data(), static_cast<int>(this->collectionname().length()),
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
+      "milvus.proto.milvus.QuerySegmentInfoRequest.collectionName");
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased(
+      3, this->collectionname(), output);
+  }
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields(
+        _internal_metadata_.unknown_fields(), output);
+  }
+  // @@protoc_insertion_point(serialize_end:milvus.proto.milvus.QuerySegmentInfoRequest)
+}
+
+::PROTOBUF_NAMESPACE_ID::uint8* QuerySegmentInfoRequest::InternalSerializeWithCachedSizesToArray(
+    ::PROTOBUF_NAMESPACE_ID::uint8* target) const {
+  // @@protoc_insertion_point(serialize_to_array_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  // .milvus.proto.common.MsgBase base = 1;
+  if (this->has_base()) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
+      InternalWriteMessageToArray(
+        1, _Internal::base(this), target);
+  }
+
+  // string dbName = 2;
+  if (this->dbname().size() > 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+      this->dbname().data(), static_cast<int>(this->dbname().length()),
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
+      "milvus.proto.milvus.QuerySegmentInfoRequest.dbName");
+    target =
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray(
+        2, this->dbname(), target);
+  }
+
+  // string collectionName = 3;
+  if (this->collectionname().size() > 0) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String(
+      this->collectionname().data(), static_cast<int>(this->collectionname().length()),
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE,
+      "milvus.proto.milvus.QuerySegmentInfoRequest.collectionName");
+    target =
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray(
+        3, this->collectionname(), target);
+  }
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray(
+        _internal_metadata_.unknown_fields(), target);
+  }
+  // @@protoc_insertion_point(serialize_to_array_end:milvus.proto.milvus.QuerySegmentInfoRequest)
+  return target;
+}
+
+size_t QuerySegmentInfoRequest::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  size_t total_size = 0;
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    total_size +=
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize(
+        _internal_metadata_.unknown_fields());
+  }
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  // Prevent compiler warnings about cached_has_bits being unused
+  (void) cached_has_bits;
+
+  // string dbName = 2;
+  if (this->dbname().size() > 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
+        this->dbname());
+  }
+
+  // string collectionName = 3;
+  if (this->collectionname().size() > 0) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
+        this->collectionname());
+  }
+
+  // .milvus.proto.common.MsgBase base = 1;
+  if (this->has_base()) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
+        *base_);
+  }
+
+  int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size);
+  SetCachedSize(cached_size);
+  return total_size;
+}
+
+void QuerySegmentInfoRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  GOOGLE_DCHECK_NE(&from, this);
+  const QuerySegmentInfoRequest* source =
+      ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<QuerySegmentInfoRequest>(
+          &from);
+  if (source == nullptr) {
+  // @@protoc_insertion_point(generalized_merge_from_cast_fail:milvus.proto.milvus.QuerySegmentInfoRequest)
+    ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
+  } else {
+  // @@protoc_insertion_point(generalized_merge_from_cast_success:milvus.proto.milvus.QuerySegmentInfoRequest)
+    MergeFrom(*source);
+  }
+}
+
+void QuerySegmentInfoRequest::MergeFrom(const QuerySegmentInfoRequest& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  GOOGLE_DCHECK_NE(&from, this);
+  _internal_metadata_.MergeFrom(from._internal_metadata_);
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  if (from.dbname().size() > 0) {
+
+    dbname_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.dbname_);
+  }
+  if (from.collectionname().size() > 0) {
+
+    collectionname_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.collectionname_);
+  }
+  if (from.has_base()) {
+    mutable_base()->::milvus::proto::common::MsgBase::MergeFrom(from.base());
+  }
+}
+
+void QuerySegmentInfoRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  if (&from == this) return;
+  Clear();
+  MergeFrom(from);
+}
+
+void QuerySegmentInfoRequest::CopyFrom(const QuerySegmentInfoRequest& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:milvus.proto.milvus.QuerySegmentInfoRequest)
+  if (&from == this) return;
+  Clear();
+  MergeFrom(from);
+}
+
+bool QuerySegmentInfoRequest::IsInitialized() const {
+  return true;
+}
+
+void QuerySegmentInfoRequest::InternalSwap(QuerySegmentInfoRequest* other) {
+  using std::swap;
+  _internal_metadata_.Swap(&other->_internal_metadata_);
+  dbname_.Swap(&other->dbname_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
+    GetArenaNoVirtual());
+  collectionname_.Swap(&other->collectionname_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
+    GetArenaNoVirtual());
+  swap(base_, other->base_);
+}
+
+::PROTOBUF_NAMESPACE_ID::Metadata QuerySegmentInfoRequest::GetMetadata() const {
+  return GetMetadataStatic();
+}
+
+
+// ===================================================================
+
+void QuerySegmentInfoResponse::InitAsDefaultInstance() {
+  ::milvus::proto::milvus::_QuerySegmentInfoResponse_default_instance_._instance.get_mutable()->status_ = const_cast< ::milvus::proto::common::Status*>(
+      ::milvus::proto::common::Status::internal_default_instance());
+}
+class QuerySegmentInfoResponse::_Internal {
+ public:
+  static const ::milvus::proto::common::Status& status(const QuerySegmentInfoResponse* msg);
+};
+
+const ::milvus::proto::common::Status&
+QuerySegmentInfoResponse::_Internal::status(const QuerySegmentInfoResponse* msg) {
+  return *msg->status_;
+}
+void QuerySegmentInfoResponse::clear_status() {
+  if (GetArenaNoVirtual() == nullptr && status_ != nullptr) {
+    delete status_;
+  }
+  status_ = nullptr;
+}
+QuerySegmentInfoResponse::QuerySegmentInfoResponse()
+  : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) {
+  SharedCtor();
+  // @@protoc_insertion_point(constructor:milvus.proto.milvus.QuerySegmentInfoResponse)
+}
+QuerySegmentInfoResponse::QuerySegmentInfoResponse(const QuerySegmentInfoResponse& from)
+  : ::PROTOBUF_NAMESPACE_ID::Message(),
+      _internal_metadata_(nullptr),
+      infos_(from.infos_) {
+  _internal_metadata_.MergeFrom(from._internal_metadata_);
+  if (from.has_status()) {
+    status_ = new ::milvus::proto::common::Status(*from.status_);
+  } else {
+    status_ = nullptr;
+  }
+  // @@protoc_insertion_point(copy_constructor:milvus.proto.milvus.QuerySegmentInfoResponse)
+}
+
+void QuerySegmentInfoResponse::SharedCtor() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_QuerySegmentInfoResponse_milvus_2eproto.base);
+  status_ = nullptr;
+}
+
+QuerySegmentInfoResponse::~QuerySegmentInfoResponse() {
+  // @@protoc_insertion_point(destructor:milvus.proto.milvus.QuerySegmentInfoResponse)
+  SharedDtor();
+}
+
+void QuerySegmentInfoResponse::SharedDtor() {
+  if (this != internal_default_instance()) delete status_;
+}
+
+void QuerySegmentInfoResponse::SetCachedSize(int size) const {
+  _cached_size_.Set(size);
+}
+const QuerySegmentInfoResponse& QuerySegmentInfoResponse::default_instance() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_QuerySegmentInfoResponse_milvus_2eproto.base);
+  return *internal_default_instance();
+}
+
+
+void QuerySegmentInfoResponse::Clear() {
+// @@protoc_insertion_point(message_clear_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  // Prevent compiler warnings about cached_has_bits being unused
+  (void) cached_has_bits;
+
+  infos_.Clear();
+  if (GetArenaNoVirtual() == nullptr && status_ != nullptr) {
+    delete status_;
+  }
+  status_ = nullptr;
+  _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* QuerySegmentInfoResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) {
+#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
+  while (!ctx->Done(&ptr)) {
+    ::PROTOBUF_NAMESPACE_ID::uint32 tag;
+    ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag);
+    CHK_(ptr);
+    switch (tag >> 3) {
+      // .milvus.proto.common.Status status = 1;
+      case 1:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
+          ptr = ctx->ParseMessage(mutable_status(), ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+      case 2:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
+          ptr -= 1;
+          do {
+            ptr += 1;
+            ptr = ctx->ParseMessage(add_infos(), ptr);
+            CHK_(ptr);
+            if (!ctx->DataAvailable(ptr)) break;
+          } while (::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<::PROTOBUF_NAMESPACE_ID::uint8>(ptr) == 18);
+        } else goto handle_unusual;
+        continue;
+      default: {
+      handle_unusual:
+        if ((tag & 7) == 4 || tag == 0) {
+          ctx->SetLastTag(tag);
+          goto success;
+        }
+        ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx);
+        CHK_(ptr != nullptr);
+        continue;
+      }
+    }  // switch
+  }  // while
+success:
+  return ptr;
+failure:
+  ptr = nullptr;
+  goto success;
+#undef CHK_
+}
+#else  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool QuerySegmentInfoResponse::MergePartialFromCodedStream(
+    ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+  ::PROTOBUF_NAMESPACE_ID::uint32 tag;
+  // @@protoc_insertion_point(parse_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  for (;;) {
+    ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    tag = p.first;
+    if (!p.second) goto handle_unusual;
+    switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) {
+      // .milvus.proto.common.Status status = 1;
+      case 1: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
+               input, mutable_status()));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+      case 2: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (18 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
+                input, add_infos()));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      default: {
+      handle_unusual:
+        if (tag == 0) {
+          goto success;
+        }
+        DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField(
+              input, tag, _internal_metadata_.mutable_unknown_fields()));
+        break;
+      }
+    }
+  }
+success:
+  // @@protoc_insertion_point(parse_success:milvus.proto.milvus.QuerySegmentInfoResponse)
+  return true;
+failure:
+  // @@protoc_insertion_point(parse_failure:milvus.proto.milvus.QuerySegmentInfoResponse)
+  return false;
+#undef DO_
+}
+#endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void QuerySegmentInfoResponse::SerializeWithCachedSizes(
+    ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const {
+  // @@protoc_insertion_point(serialize_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  // .milvus.proto.common.Status status = 1;
+  if (this->has_status()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
+      1, _Internal::status(this), output);
+  }
+
+  // repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+  for (unsigned int i = 0,
+      n = static_cast<unsigned int>(this->infos_size()); i < n; i++) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
+      2,
+      this->infos(static_cast<int>(i)),
+      output);
+  }
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields(
+        _internal_metadata_.unknown_fields(), output);
+  }
+  // @@protoc_insertion_point(serialize_end:milvus.proto.milvus.QuerySegmentInfoResponse)
+}
+
+::PROTOBUF_NAMESPACE_ID::uint8* QuerySegmentInfoResponse::InternalSerializeWithCachedSizesToArray(
+    ::PROTOBUF_NAMESPACE_ID::uint8* target) const {
+  // @@protoc_insertion_point(serialize_to_array_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  // .milvus.proto.common.Status status = 1;
+  if (this->has_status()) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
+      InternalWriteMessageToArray(
+        1, _Internal::status(this), target);
+  }
+
+  // repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+  for (unsigned int i = 0,
+      n = static_cast<unsigned int>(this->infos_size()); i < n; i++) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
+      InternalWriteMessageToArray(
+        2, this->infos(static_cast<int>(i)), target);
+  }
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray(
+        _internal_metadata_.unknown_fields(), target);
+  }
+  // @@protoc_insertion_point(serialize_to_array_end:milvus.proto.milvus.QuerySegmentInfoResponse)
+  return target;
+}
+
+size_t QuerySegmentInfoResponse::ByteSizeLong() const {
+// @@protoc_insertion_point(message_byte_size_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  size_t total_size = 0;
+
+  if (_internal_metadata_.have_unknown_fields()) {
+    total_size +=
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize(
+        _internal_metadata_.unknown_fields());
+  }
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  // Prevent compiler warnings about cached_has_bits being unused
+  (void) cached_has_bits;
+
+  // repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+  {
+    unsigned int count = static_cast<unsigned int>(this->infos_size());
+    total_size += 1UL * count;
+    for (unsigned int i = 0; i < count; i++) {
+      total_size +=
+        ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
+          this->infos(static_cast<int>(i)));
+    }
+  }
+
+  // .milvus.proto.common.Status status = 1;
+  if (this->has_status()) {
+    total_size += 1 +
+      ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
+        *status_);
+  }
+
+  int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size);
+  SetCachedSize(cached_size);
+  return total_size;
+}
+
+void QuerySegmentInfoResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
+// @@protoc_insertion_point(generalized_merge_from_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  GOOGLE_DCHECK_NE(&from, this);
+  const QuerySegmentInfoResponse* source =
+      ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<QuerySegmentInfoResponse>(
+          &from);
+  if (source == nullptr) {
+  // @@protoc_insertion_point(generalized_merge_from_cast_fail:milvus.proto.milvus.QuerySegmentInfoResponse)
+    ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this);
+  } else {
+  // @@protoc_insertion_point(generalized_merge_from_cast_success:milvus.proto.milvus.QuerySegmentInfoResponse)
+    MergeFrom(*source);
+  }
+}
+
+void QuerySegmentInfoResponse::MergeFrom(const QuerySegmentInfoResponse& from) {
+// @@protoc_insertion_point(class_specific_merge_from_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  GOOGLE_DCHECK_NE(&from, this);
+  _internal_metadata_.MergeFrom(from._internal_metadata_);
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  infos_.MergeFrom(from.infos_);
+  if (from.has_status()) {
+    mutable_status()->::milvus::proto::common::Status::MergeFrom(from.status());
+  }
+}
+
+void QuerySegmentInfoResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) {
+// @@protoc_insertion_point(generalized_copy_from_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  if (&from == this) return;
+  Clear();
+  MergeFrom(from);
+}
+
+void QuerySegmentInfoResponse::CopyFrom(const QuerySegmentInfoResponse& from) {
+// @@protoc_insertion_point(class_specific_copy_from_start:milvus.proto.milvus.QuerySegmentInfoResponse)
+  if (&from == this) return;
+  Clear();
+  MergeFrom(from);
+}
+
+bool QuerySegmentInfoResponse::IsInitialized() const {
+  return true;
+}
+
+void QuerySegmentInfoResponse::InternalSwap(QuerySegmentInfoResponse* other) {
+  using std::swap;
+  _internal_metadata_.Swap(&other->_internal_metadata_);
+  CastToBase(&infos_)->InternalSwap(CastToBase(&other->infos_));
+  swap(status_, other->status_);
+}
+
+::PROTOBUF_NAMESPACE_ID::Metadata QuerySegmentInfoResponse::GetMetadata() const {
+  return GetMetadataStatic();
+}
+
+
+// ===================================================================
+
+void RegisterLinkResponse::InitAsDefaultInstance() {
+  ::milvus::proto::milvus::_RegisterLinkResponse_default_instance_._instance.get_mutable()->address_ = const_cast< ::milvus::proto::common::Address*>(
+      ::milvus::proto::common::Address::internal_default_instance());
+  ::milvus::proto::milvus::_RegisterLinkResponse_default_instance_._instance.get_mutable()->status_ = const_cast< ::milvus::proto::common::Status*>(
+      ::milvus::proto::common::Status::internal_default_instance());
+}
+class RegisterLinkResponse::_Internal {
+ public:
+  static const ::milvus::proto::common::Address& address(const RegisterLinkResponse* msg);
+  static const ::milvus::proto::common::Status& status(const RegisterLinkResponse* msg);
+};
+
+const ::milvus::proto::common::Address&
+RegisterLinkResponse::_Internal::address(const RegisterLinkResponse* msg) {
+  return *msg->address_;
+}
+const ::milvus::proto::common::Status&
+RegisterLinkResponse::_Internal::status(const RegisterLinkResponse* msg) {
+  return *msg->status_;
+}
+void RegisterLinkResponse::clear_address() {
+  if (GetArenaNoVirtual() == nullptr && address_ != nullptr) {
+    delete address_;
+  }
+  address_ = nullptr;
+}
+void RegisterLinkResponse::clear_status() {
+  if (GetArenaNoVirtual() == nullptr && status_ != nullptr) {
+    delete status_;
+  }
+  status_ = nullptr;
+}
+RegisterLinkResponse::RegisterLinkResponse()
+  : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) {
+  SharedCtor();
+  // @@protoc_insertion_point(constructor:milvus.proto.milvus.RegisterLinkResponse)
+}
+RegisterLinkResponse::RegisterLinkResponse(const RegisterLinkResponse& from)
+  : ::PROTOBUF_NAMESPACE_ID::Message(),
+      _internal_metadata_(nullptr) {
+  _internal_metadata_.MergeFrom(from._internal_metadata_);
+  if (from.has_address()) {
+    address_ = new ::milvus::proto::common::Address(*from.address_);
+  } else {
+    address_ = nullptr;
+  }
+  if (from.has_status()) {
+    status_ = new ::milvus::proto::common::Status(*from.status_);
+  } else {
+    status_ = nullptr;
+  }
+  // @@protoc_insertion_point(copy_constructor:milvus.proto.milvus.RegisterLinkResponse)
+}
+
+void RegisterLinkResponse::SharedCtor() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_RegisterLinkResponse_milvus_2eproto.base);
+  ::memset(&address_, 0, static_cast<size_t>(
+      reinterpret_cast<char*>(&status_) -
+      reinterpret_cast<char*>(&address_)) + sizeof(status_));
+}
+
+RegisterLinkResponse::~RegisterLinkResponse() {
+  // @@protoc_insertion_point(destructor:milvus.proto.milvus.RegisterLinkResponse)
+  SharedDtor();
+}
+
+void RegisterLinkResponse::SharedDtor() {
+  if (this != internal_default_instance()) delete address_;
+  if (this != internal_default_instance()) delete status_;
+}
+
+void RegisterLinkResponse::SetCachedSize(int size) const {
+  _cached_size_.Set(size);
+}
+const RegisterLinkResponse& RegisterLinkResponse::default_instance() {
+  ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_RegisterLinkResponse_milvus_2eproto.base);
+  return *internal_default_instance();
+}
+
+
+void RegisterLinkResponse::Clear() {
+// @@protoc_insertion_point(message_clear_start:milvus.proto.milvus.RegisterLinkResponse)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  // Prevent compiler warnings about cached_has_bits being unused
+  (void) cached_has_bits;
+
+  if (GetArenaNoVirtual() == nullptr && address_ != nullptr) {
+    delete address_;
+  }
+  address_ = nullptr;
+  if (GetArenaNoVirtual() == nullptr && status_ != nullptr) {
+    delete status_;
+  }
+  status_ = nullptr;
+  _internal_metadata_.Clear();
+}
+
+#if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+const char* RegisterLinkResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) {
+#define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
+  while (!ctx->Done(&ptr)) {
+    ::PROTOBUF_NAMESPACE_ID::uint32 tag;
+    ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag);
+    CHK_(ptr);
+    switch (tag >> 3) {
+      // .milvus.proto.common.Address address = 1;
+      case 1:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) {
+          ptr = ctx->ParseMessage(mutable_address(), ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      // .milvus.proto.common.Status status = 2;
+      case 2:
+        if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) {
+          ptr = ctx->ParseMessage(mutable_status(), ptr);
+          CHK_(ptr);
+        } else goto handle_unusual;
+        continue;
+      default: {
+      handle_unusual:
+        if ((tag & 7) == 4 || tag == 0) {
+          ctx->SetLastTag(tag);
+          goto success;
+        }
+        ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx);
+        CHK_(ptr != nullptr);
+        continue;
+      }
+    }  // switch
+  }  // while
+success:
+  return ptr;
+failure:
+  ptr = nullptr;
+  goto success;
+#undef CHK_
+}
+#else  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+bool RegisterLinkResponse::MergePartialFromCodedStream(
+    ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) {
+#define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure
+  ::PROTOBUF_NAMESPACE_ID::uint32 tag;
+  // @@protoc_insertion_point(parse_start:milvus.proto.milvus.RegisterLinkResponse)
+  for (;;) {
+    ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
+    tag = p.first;
+    if (!p.second) goto handle_unusual;
+    switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) {
+      // .milvus.proto.common.Address address = 1;
+      case 1: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
+               input, mutable_address()));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      // .milvus.proto.common.Status status = 2;
+      case 2: {
+        if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (18 & 0xFF)) {
+          DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage(
+               input, mutable_status()));
+        } else {
+          goto handle_unusual;
+        }
+        break;
+      }
+
+      default: {
+      handle_unusual:
+        if (tag == 0) {
+          goto success;
+        }
+        DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField(
+              input, tag, _internal_metadata_.mutable_unknown_fields()));
+        break;
+      }
+    }
+  }
+success:
+  // @@protoc_insertion_point(parse_success:milvus.proto.milvus.RegisterLinkResponse)
+  return true;
+failure:
+  // @@protoc_insertion_point(parse_failure:milvus.proto.milvus.RegisterLinkResponse)
+  return false;
+#undef DO_
+}
+#endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+
+void RegisterLinkResponse::SerializeWithCachedSizes(
+    ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const {
+  // @@protoc_insertion_point(serialize_start:milvus.proto.milvus.RegisterLinkResponse)
+  ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0;
+  (void) cached_has_bits;
+
+  // .milvus.proto.common.Address address = 1;
+  if (this->has_address()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
+      1, _Internal::address(this), output);
+  }
+
+  // .milvus.proto.common.Status status = 2;
+  if (this->has_status()) {
+    ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray(
+      2, _Internal::status(this), output);
   }
 
   if (_internal_metadata_.have_unknown_fields()) {
@@ -19416,6 +20772,15 @@ template<> PROTOBUF_NOINLINE ::milvus::proto::milvus::PersistentSegmentInfoReque
 template<> PROTOBUF_NOINLINE ::milvus::proto::milvus::PersistentSegmentInfoResponse* Arena::CreateMaybeMessage< ::milvus::proto::milvus::PersistentSegmentInfoResponse >(Arena* arena) {
   return Arena::CreateInternal< ::milvus::proto::milvus::PersistentSegmentInfoResponse >(arena);
 }
+template<> PROTOBUF_NOINLINE ::milvus::proto::milvus::QuerySegmentInfo* Arena::CreateMaybeMessage< ::milvus::proto::milvus::QuerySegmentInfo >(Arena* arena) {
+  return Arena::CreateInternal< ::milvus::proto::milvus::QuerySegmentInfo >(arena);
+}
+template<> PROTOBUF_NOINLINE ::milvus::proto::milvus::QuerySegmentInfoRequest* Arena::CreateMaybeMessage< ::milvus::proto::milvus::QuerySegmentInfoRequest >(Arena* arena) {
+  return Arena::CreateInternal< ::milvus::proto::milvus::QuerySegmentInfoRequest >(arena);
+}
+template<> PROTOBUF_NOINLINE ::milvus::proto::milvus::QuerySegmentInfoResponse* Arena::CreateMaybeMessage< ::milvus::proto::milvus::QuerySegmentInfoResponse >(Arena* arena) {
+  return Arena::CreateInternal< ::milvus::proto::milvus::QuerySegmentInfoResponse >(arena);
+}
 template<> PROTOBUF_NOINLINE ::milvus::proto::milvus::RegisterLinkResponse* Arena::CreateMaybeMessage< ::milvus::proto::milvus::RegisterLinkResponse >(Arena* arena) {
   return Arena::CreateInternal< ::milvus::proto::milvus::RegisterLinkResponse >(arena);
 }
diff --git a/internal/core/src/pb/milvus.pb.h b/internal/core/src/pb/milvus.pb.h
index 6c38da3da..502256c4d 100644
--- a/internal/core/src/pb/milvus.pb.h
+++ b/internal/core/src/pb/milvus.pb.h
@@ -50,7 +50,7 @@ struct TableStruct_milvus_2eproto {
     PROTOBUF_SECTION_VARIABLE(protodesc_cold);
   static const ::PROTOBUF_NAMESPACE_ID::internal::AuxillaryParseTableField aux[]
     PROTOBUF_SECTION_VARIABLE(protodesc_cold);
-  static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTable schema[44]
+  static const ::PROTOBUF_NAMESPACE_ID::internal::ParseTable schema[47]
     PROTOBUF_SECTION_VARIABLE(protodesc_cold);
   static const ::PROTOBUF_NAMESPACE_ID::internal::FieldMetadata field_metadata[];
   static const ::PROTOBUF_NAMESPACE_ID::internal::SerializationTable serialization_table[];
@@ -156,6 +156,15 @@ extern PlaceholderGroupDefaultTypeInternal _PlaceholderGroup_default_instance_;
 class PlaceholderValue;
 class PlaceholderValueDefaultTypeInternal;
 extern PlaceholderValueDefaultTypeInternal _PlaceholderValue_default_instance_;
+class QuerySegmentInfo;
+class QuerySegmentInfoDefaultTypeInternal;
+extern QuerySegmentInfoDefaultTypeInternal _QuerySegmentInfo_default_instance_;
+class QuerySegmentInfoRequest;
+class QuerySegmentInfoRequestDefaultTypeInternal;
+extern QuerySegmentInfoRequestDefaultTypeInternal _QuerySegmentInfoRequest_default_instance_;
+class QuerySegmentInfoResponse;
+class QuerySegmentInfoResponseDefaultTypeInternal;
+extern QuerySegmentInfoResponseDefaultTypeInternal _QuerySegmentInfoResponse_default_instance_;
 class RegisterLinkResponse;
 class RegisterLinkResponseDefaultTypeInternal;
 extern RegisterLinkResponseDefaultTypeInternal _RegisterLinkResponse_default_instance_;
@@ -228,6 +237,9 @@ template<> ::milvus::proto::milvus::PersistentSegmentInfoRequest* Arena::CreateM
 template<> ::milvus::proto::milvus::PersistentSegmentInfoResponse* Arena::CreateMaybeMessage<::milvus::proto::milvus::PersistentSegmentInfoResponse>(Arena*);
 template<> ::milvus::proto::milvus::PlaceholderGroup* Arena::CreateMaybeMessage<::milvus::proto::milvus::PlaceholderGroup>(Arena*);
 template<> ::milvus::proto::milvus::PlaceholderValue* Arena::CreateMaybeMessage<::milvus::proto::milvus::PlaceholderValue>(Arena*);
+template<> ::milvus::proto::milvus::QuerySegmentInfo* Arena::CreateMaybeMessage<::milvus::proto::milvus::QuerySegmentInfo>(Arena*);
+template<> ::milvus::proto::milvus::QuerySegmentInfoRequest* Arena::CreateMaybeMessage<::milvus::proto::milvus::QuerySegmentInfoRequest>(Arena*);
+template<> ::milvus::proto::milvus::QuerySegmentInfoResponse* Arena::CreateMaybeMessage<::milvus::proto::milvus::QuerySegmentInfoResponse>(Arena*);
 template<> ::milvus::proto::milvus::RegisterLinkResponse* Arena::CreateMaybeMessage<::milvus::proto::milvus::RegisterLinkResponse>(Arena*);
 template<> ::milvus::proto::milvus::ReleaseCollectionRequest* Arena::CreateMaybeMessage<::milvus::proto::milvus::ReleaseCollectionRequest>(Arena*);
 template<> ::milvus::proto::milvus::ReleasePartitionRequest* Arena::CreateMaybeMessage<::milvus::proto::milvus::ReleasePartitionRequest>(Arena*);
@@ -7248,6 +7260,492 @@ class PersistentSegmentInfoResponse :
 };
 // -------------------------------------------------------------------
 
+class QuerySegmentInfo :
+    public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:milvus.proto.milvus.QuerySegmentInfo) */ {
+ public:
+  QuerySegmentInfo();
+  virtual ~QuerySegmentInfo();
+
+  QuerySegmentInfo(const QuerySegmentInfo& from);
+  QuerySegmentInfo(QuerySegmentInfo&& from) noexcept
+    : QuerySegmentInfo() {
+    *this = ::std::move(from);
+  }
+
+  inline QuerySegmentInfo& operator=(const QuerySegmentInfo& from) {
+    CopyFrom(from);
+    return *this;
+  }
+  inline QuerySegmentInfo& operator=(QuerySegmentInfo&& from) noexcept {
+    if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+      if (this != &from) InternalSwap(&from);
+    } else {
+      CopyFrom(from);
+    }
+    return *this;
+  }
+
+  static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
+    return GetDescriptor();
+  }
+  static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
+    return GetMetadataStatic().descriptor;
+  }
+  static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
+    return GetMetadataStatic().reflection;
+  }
+  static const QuerySegmentInfo& default_instance();
+
+  static void InitAsDefaultInstance();  // FOR INTERNAL USE ONLY
+  static inline const QuerySegmentInfo* internal_default_instance() {
+    return reinterpret_cast<const QuerySegmentInfo*>(
+               &_QuerySegmentInfo_default_instance_);
+  }
+  static constexpr int kIndexInFileMessages =
+    43;
+
+  friend void swap(QuerySegmentInfo& a, QuerySegmentInfo& b) {
+    a.Swap(&b);
+  }
+  inline void Swap(QuerySegmentInfo* other) {
+    if (other == this) return;
+    InternalSwap(other);
+  }
+
+  // implements Message ----------------------------------------------
+
+  inline QuerySegmentInfo* New() const final {
+    return CreateMaybeMessage<QuerySegmentInfo>(nullptr);
+  }
+
+  QuerySegmentInfo* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
+    return CreateMaybeMessage<QuerySegmentInfo>(arena);
+  }
+  void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
+  void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
+  void CopyFrom(const QuerySegmentInfo& from);
+  void MergeFrom(const QuerySegmentInfo& from);
+  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+  bool IsInitialized() const final;
+
+  size_t ByteSizeLong() const final;
+  #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
+  #else
+  bool MergePartialFromCodedStream(
+      ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) final;
+  #endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+  void SerializeWithCachedSizes(
+      ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const final;
+  ::PROTOBUF_NAMESPACE_ID::uint8* InternalSerializeWithCachedSizesToArray(
+      ::PROTOBUF_NAMESPACE_ID::uint8* target) const final;
+  int GetCachedSize() const final { return _cached_size_.Get(); }
+
+  private:
+  inline void SharedCtor();
+  inline void SharedDtor();
+  void SetCachedSize(int size) const final;
+  void InternalSwap(QuerySegmentInfo* other);
+  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
+  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
+    return "milvus.proto.milvus.QuerySegmentInfo";
+  }
+  private:
+  inline ::PROTOBUF_NAMESPACE_ID::Arena* GetArenaNoVirtual() const {
+    return nullptr;
+  }
+  inline void* MaybeArenaPtr() const {
+    return nullptr;
+  }
+  public:
+
+  ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
+  private:
+  static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
+    ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_milvus_2eproto);
+    return ::descriptor_table_milvus_2eproto.file_level_metadata[kIndexInFileMessages];
+  }
+
+  public:
+
+  // nested types ----------------------------------------------------
+
+  // accessors -------------------------------------------------------
+
+  enum : int {
+    kIndexNameFieldNumber = 6,
+    kSegmentIDFieldNumber = 1,
+    kCollectionIDFieldNumber = 2,
+    kPartitionIDFieldNumber = 3,
+    kMemSizeFieldNumber = 4,
+    kNumRowsFieldNumber = 5,
+    kIndexIDFieldNumber = 7,
+  };
+  // string index_name = 6;
+  void clear_index_name();
+  const std::string& index_name() const;
+  void set_index_name(const std::string& value);
+  void set_index_name(std::string&& value);
+  void set_index_name(const char* value);
+  void set_index_name(const char* value, size_t size);
+  std::string* mutable_index_name();
+  std::string* release_index_name();
+  void set_allocated_index_name(std::string* index_name);
+
+  // int64 segmentID = 1;
+  void clear_segmentid();
+  ::PROTOBUF_NAMESPACE_ID::int64 segmentid() const;
+  void set_segmentid(::PROTOBUF_NAMESPACE_ID::int64 value);
+
+  // int64 collectionID = 2;
+  void clear_collectionid();
+  ::PROTOBUF_NAMESPACE_ID::int64 collectionid() const;
+  void set_collectionid(::PROTOBUF_NAMESPACE_ID::int64 value);
+
+  // int64 partitionID = 3;
+  void clear_partitionid();
+  ::PROTOBUF_NAMESPACE_ID::int64 partitionid() const;
+  void set_partitionid(::PROTOBUF_NAMESPACE_ID::int64 value);
+
+  // int64 mem_size = 4;
+  void clear_mem_size();
+  ::PROTOBUF_NAMESPACE_ID::int64 mem_size() const;
+  void set_mem_size(::PROTOBUF_NAMESPACE_ID::int64 value);
+
+  // int64 num_rows = 5;
+  void clear_num_rows();
+  ::PROTOBUF_NAMESPACE_ID::int64 num_rows() const;
+  void set_num_rows(::PROTOBUF_NAMESPACE_ID::int64 value);
+
+  // int64 indexID = 7;
+  void clear_indexid();
+  ::PROTOBUF_NAMESPACE_ID::int64 indexid() const;
+  void set_indexid(::PROTOBUF_NAMESPACE_ID::int64 value);
+
+  // @@protoc_insertion_point(class_scope:milvus.proto.milvus.QuerySegmentInfo)
+ private:
+  class _Internal;
+
+  ::PROTOBUF_NAMESPACE_ID::internal::InternalMetadataWithArena _internal_metadata_;
+  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr index_name_;
+  ::PROTOBUF_NAMESPACE_ID::int64 segmentid_;
+  ::PROTOBUF_NAMESPACE_ID::int64 collectionid_;
+  ::PROTOBUF_NAMESPACE_ID::int64 partitionid_;
+  ::PROTOBUF_NAMESPACE_ID::int64 mem_size_;
+  ::PROTOBUF_NAMESPACE_ID::int64 num_rows_;
+  ::PROTOBUF_NAMESPACE_ID::int64 indexid_;
+  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
+  friend struct ::TableStruct_milvus_2eproto;
+};
+// -------------------------------------------------------------------
+
+class QuerySegmentInfoRequest :
+    public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:milvus.proto.milvus.QuerySegmentInfoRequest) */ {
+ public:
+  QuerySegmentInfoRequest();
+  virtual ~QuerySegmentInfoRequest();
+
+  QuerySegmentInfoRequest(const QuerySegmentInfoRequest& from);
+  QuerySegmentInfoRequest(QuerySegmentInfoRequest&& from) noexcept
+    : QuerySegmentInfoRequest() {
+    *this = ::std::move(from);
+  }
+
+  inline QuerySegmentInfoRequest& operator=(const QuerySegmentInfoRequest& from) {
+    CopyFrom(from);
+    return *this;
+  }
+  inline QuerySegmentInfoRequest& operator=(QuerySegmentInfoRequest&& from) noexcept {
+    if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+      if (this != &from) InternalSwap(&from);
+    } else {
+      CopyFrom(from);
+    }
+    return *this;
+  }
+
+  static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
+    return GetDescriptor();
+  }
+  static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
+    return GetMetadataStatic().descriptor;
+  }
+  static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
+    return GetMetadataStatic().reflection;
+  }
+  static const QuerySegmentInfoRequest& default_instance();
+
+  static void InitAsDefaultInstance();  // FOR INTERNAL USE ONLY
+  static inline const QuerySegmentInfoRequest* internal_default_instance() {
+    return reinterpret_cast<const QuerySegmentInfoRequest*>(
+               &_QuerySegmentInfoRequest_default_instance_);
+  }
+  static constexpr int kIndexInFileMessages =
+    44;
+
+  friend void swap(QuerySegmentInfoRequest& a, QuerySegmentInfoRequest& b) {
+    a.Swap(&b);
+  }
+  inline void Swap(QuerySegmentInfoRequest* other) {
+    if (other == this) return;
+    InternalSwap(other);
+  }
+
+  // implements Message ----------------------------------------------
+
+  inline QuerySegmentInfoRequest* New() const final {
+    return CreateMaybeMessage<QuerySegmentInfoRequest>(nullptr);
+  }
+
+  QuerySegmentInfoRequest* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
+    return CreateMaybeMessage<QuerySegmentInfoRequest>(arena);
+  }
+  void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
+  void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
+  void CopyFrom(const QuerySegmentInfoRequest& from);
+  void MergeFrom(const QuerySegmentInfoRequest& from);
+  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+  bool IsInitialized() const final;
+
+  size_t ByteSizeLong() const final;
+  #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
+  #else
+  bool MergePartialFromCodedStream(
+      ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) final;
+  #endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+  void SerializeWithCachedSizes(
+      ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const final;
+  ::PROTOBUF_NAMESPACE_ID::uint8* InternalSerializeWithCachedSizesToArray(
+      ::PROTOBUF_NAMESPACE_ID::uint8* target) const final;
+  int GetCachedSize() const final { return _cached_size_.Get(); }
+
+  private:
+  inline void SharedCtor();
+  inline void SharedDtor();
+  void SetCachedSize(int size) const final;
+  void InternalSwap(QuerySegmentInfoRequest* other);
+  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
+  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
+    return "milvus.proto.milvus.QuerySegmentInfoRequest";
+  }
+  private:
+  inline ::PROTOBUF_NAMESPACE_ID::Arena* GetArenaNoVirtual() const {
+    return nullptr;
+  }
+  inline void* MaybeArenaPtr() const {
+    return nullptr;
+  }
+  public:
+
+  ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
+  private:
+  static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
+    ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_milvus_2eproto);
+    return ::descriptor_table_milvus_2eproto.file_level_metadata[kIndexInFileMessages];
+  }
+
+  public:
+
+  // nested types ----------------------------------------------------
+
+  // accessors -------------------------------------------------------
+
+  enum : int {
+    kDbNameFieldNumber = 2,
+    kCollectionNameFieldNumber = 3,
+    kBaseFieldNumber = 1,
+  };
+  // string dbName = 2;
+  void clear_dbname();
+  const std::string& dbname() const;
+  void set_dbname(const std::string& value);
+  void set_dbname(std::string&& value);
+  void set_dbname(const char* value);
+  void set_dbname(const char* value, size_t size);
+  std::string* mutable_dbname();
+  std::string* release_dbname();
+  void set_allocated_dbname(std::string* dbname);
+
+  // string collectionName = 3;
+  void clear_collectionname();
+  const std::string& collectionname() const;
+  void set_collectionname(const std::string& value);
+  void set_collectionname(std::string&& value);
+  void set_collectionname(const char* value);
+  void set_collectionname(const char* value, size_t size);
+  std::string* mutable_collectionname();
+  std::string* release_collectionname();
+  void set_allocated_collectionname(std::string* collectionname);
+
+  // .milvus.proto.common.MsgBase base = 1;
+  bool has_base() const;
+  void clear_base();
+  const ::milvus::proto::common::MsgBase& base() const;
+  ::milvus::proto::common::MsgBase* release_base();
+  ::milvus::proto::common::MsgBase* mutable_base();
+  void set_allocated_base(::milvus::proto::common::MsgBase* base);
+
+  // @@protoc_insertion_point(class_scope:milvus.proto.milvus.QuerySegmentInfoRequest)
+ private:
+  class _Internal;
+
+  ::PROTOBUF_NAMESPACE_ID::internal::InternalMetadataWithArena _internal_metadata_;
+  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr dbname_;
+  ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr collectionname_;
+  ::milvus::proto::common::MsgBase* base_;
+  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
+  friend struct ::TableStruct_milvus_2eproto;
+};
+// -------------------------------------------------------------------
+
+class QuerySegmentInfoResponse :
+    public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:milvus.proto.milvus.QuerySegmentInfoResponse) */ {
+ public:
+  QuerySegmentInfoResponse();
+  virtual ~QuerySegmentInfoResponse();
+
+  QuerySegmentInfoResponse(const QuerySegmentInfoResponse& from);
+  QuerySegmentInfoResponse(QuerySegmentInfoResponse&& from) noexcept
+    : QuerySegmentInfoResponse() {
+    *this = ::std::move(from);
+  }
+
+  inline QuerySegmentInfoResponse& operator=(const QuerySegmentInfoResponse& from) {
+    CopyFrom(from);
+    return *this;
+  }
+  inline QuerySegmentInfoResponse& operator=(QuerySegmentInfoResponse&& from) noexcept {
+    if (GetArenaNoVirtual() == from.GetArenaNoVirtual()) {
+      if (this != &from) InternalSwap(&from);
+    } else {
+      CopyFrom(from);
+    }
+    return *this;
+  }
+
+  static const ::PROTOBUF_NAMESPACE_ID::Descriptor* descriptor() {
+    return GetDescriptor();
+  }
+  static const ::PROTOBUF_NAMESPACE_ID::Descriptor* GetDescriptor() {
+    return GetMetadataStatic().descriptor;
+  }
+  static const ::PROTOBUF_NAMESPACE_ID::Reflection* GetReflection() {
+    return GetMetadataStatic().reflection;
+  }
+  static const QuerySegmentInfoResponse& default_instance();
+
+  static void InitAsDefaultInstance();  // FOR INTERNAL USE ONLY
+  static inline const QuerySegmentInfoResponse* internal_default_instance() {
+    return reinterpret_cast<const QuerySegmentInfoResponse*>(
+               &_QuerySegmentInfoResponse_default_instance_);
+  }
+  static constexpr int kIndexInFileMessages =
+    45;
+
+  friend void swap(QuerySegmentInfoResponse& a, QuerySegmentInfoResponse& b) {
+    a.Swap(&b);
+  }
+  inline void Swap(QuerySegmentInfoResponse* other) {
+    if (other == this) return;
+    InternalSwap(other);
+  }
+
+  // implements Message ----------------------------------------------
+
+  inline QuerySegmentInfoResponse* New() const final {
+    return CreateMaybeMessage<QuerySegmentInfoResponse>(nullptr);
+  }
+
+  QuerySegmentInfoResponse* New(::PROTOBUF_NAMESPACE_ID::Arena* arena) const final {
+    return CreateMaybeMessage<QuerySegmentInfoResponse>(arena);
+  }
+  void CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
+  void MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) final;
+  void CopyFrom(const QuerySegmentInfoResponse& from);
+  void MergeFrom(const QuerySegmentInfoResponse& from);
+  PROTOBUF_ATTRIBUTE_REINITIALIZES void Clear() final;
+  bool IsInitialized() const final;
+
+  size_t ByteSizeLong() const final;
+  #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+  const char* _InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) final;
+  #else
+  bool MergePartialFromCodedStream(
+      ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) final;
+  #endif  // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER
+  void SerializeWithCachedSizes(
+      ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const final;
+  ::PROTOBUF_NAMESPACE_ID::uint8* InternalSerializeWithCachedSizesToArray(
+      ::PROTOBUF_NAMESPACE_ID::uint8* target) const final;
+  int GetCachedSize() const final { return _cached_size_.Get(); }
+
+  private:
+  inline void SharedCtor();
+  inline void SharedDtor();
+  void SetCachedSize(int size) const final;
+  void InternalSwap(QuerySegmentInfoResponse* other);
+  friend class ::PROTOBUF_NAMESPACE_ID::internal::AnyMetadata;
+  static ::PROTOBUF_NAMESPACE_ID::StringPiece FullMessageName() {
+    return "milvus.proto.milvus.QuerySegmentInfoResponse";
+  }
+  private:
+  inline ::PROTOBUF_NAMESPACE_ID::Arena* GetArenaNoVirtual() const {
+    return nullptr;
+  }
+  inline void* MaybeArenaPtr() const {
+    return nullptr;
+  }
+  public:
+
+  ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadata() const final;
+  private:
+  static ::PROTOBUF_NAMESPACE_ID::Metadata GetMetadataStatic() {
+    ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&::descriptor_table_milvus_2eproto);
+    return ::descriptor_table_milvus_2eproto.file_level_metadata[kIndexInFileMessages];
+  }
+
+  public:
+
+  // nested types ----------------------------------------------------
+
+  // accessors -------------------------------------------------------
+
+  enum : int {
+    kInfosFieldNumber = 2,
+    kStatusFieldNumber = 1,
+  };
+  // repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+  int infos_size() const;
+  void clear_infos();
+  ::milvus::proto::milvus::QuerySegmentInfo* mutable_infos(int index);
+  ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::milvus::QuerySegmentInfo >*
+      mutable_infos();
+  const ::milvus::proto::milvus::QuerySegmentInfo& infos(int index) const;
+  ::milvus::proto::milvus::QuerySegmentInfo* add_infos();
+  const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::milvus::QuerySegmentInfo >&
+      infos() const;
+
+  // .milvus.proto.common.Status status = 1;
+  bool has_status() const;
+  void clear_status();
+  const ::milvus::proto::common::Status& status() const;
+  ::milvus::proto::common::Status* release_status();
+  ::milvus::proto::common::Status* mutable_status();
+  void set_allocated_status(::milvus::proto::common::Status* status);
+
+  // @@protoc_insertion_point(class_scope:milvus.proto.milvus.QuerySegmentInfoResponse)
+ private:
+  class _Internal;
+
+  ::PROTOBUF_NAMESPACE_ID::internal::InternalMetadataWithArena _internal_metadata_;
+  ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::milvus::QuerySegmentInfo > infos_;
+  ::milvus::proto::common::Status* status_;
+  mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_;
+  friend struct ::TableStruct_milvus_2eproto;
+};
+// -------------------------------------------------------------------
+
 class RegisterLinkResponse :
     public ::PROTOBUF_NAMESPACE_ID::Message /* @@protoc_insertion_point(class_definition:milvus.proto.milvus.RegisterLinkResponse) */ {
  public:
@@ -7290,7 +7788,7 @@ class RegisterLinkResponse :
                &_RegisterLinkResponse_default_instance_);
   }
   static constexpr int kIndexInFileMessages =
-    43;
+    46;
 
   friend void swap(RegisterLinkResponse& a, RegisterLinkResponse& b) {
     a.Swap(&b);
@@ -13552,6 +14050,375 @@ PersistentSegmentInfoResponse::infos() const {
 
 // -------------------------------------------------------------------
 
+// QuerySegmentInfo
+
+// int64 segmentID = 1;
+inline void QuerySegmentInfo::clear_segmentid() {
+  segmentid_ = PROTOBUF_LONGLONG(0);
+}
+inline ::PROTOBUF_NAMESPACE_ID::int64 QuerySegmentInfo::segmentid() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.segmentID)
+  return segmentid_;
+}
+inline void QuerySegmentInfo::set_segmentid(::PROTOBUF_NAMESPACE_ID::int64 value) {
+  
+  segmentid_ = value;
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.segmentID)
+}
+
+// int64 collectionID = 2;
+inline void QuerySegmentInfo::clear_collectionid() {
+  collectionid_ = PROTOBUF_LONGLONG(0);
+}
+inline ::PROTOBUF_NAMESPACE_ID::int64 QuerySegmentInfo::collectionid() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.collectionID)
+  return collectionid_;
+}
+inline void QuerySegmentInfo::set_collectionid(::PROTOBUF_NAMESPACE_ID::int64 value) {
+  
+  collectionid_ = value;
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.collectionID)
+}
+
+// int64 partitionID = 3;
+inline void QuerySegmentInfo::clear_partitionid() {
+  partitionid_ = PROTOBUF_LONGLONG(0);
+}
+inline ::PROTOBUF_NAMESPACE_ID::int64 QuerySegmentInfo::partitionid() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.partitionID)
+  return partitionid_;
+}
+inline void QuerySegmentInfo::set_partitionid(::PROTOBUF_NAMESPACE_ID::int64 value) {
+  
+  partitionid_ = value;
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.partitionID)
+}
+
+// int64 mem_size = 4;
+inline void QuerySegmentInfo::clear_mem_size() {
+  mem_size_ = PROTOBUF_LONGLONG(0);
+}
+inline ::PROTOBUF_NAMESPACE_ID::int64 QuerySegmentInfo::mem_size() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.mem_size)
+  return mem_size_;
+}
+inline void QuerySegmentInfo::set_mem_size(::PROTOBUF_NAMESPACE_ID::int64 value) {
+  
+  mem_size_ = value;
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.mem_size)
+}
+
+// int64 num_rows = 5;
+inline void QuerySegmentInfo::clear_num_rows() {
+  num_rows_ = PROTOBUF_LONGLONG(0);
+}
+inline ::PROTOBUF_NAMESPACE_ID::int64 QuerySegmentInfo::num_rows() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.num_rows)
+  return num_rows_;
+}
+inline void QuerySegmentInfo::set_num_rows(::PROTOBUF_NAMESPACE_ID::int64 value) {
+  
+  num_rows_ = value;
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.num_rows)
+}
+
+// string index_name = 6;
+inline void QuerySegmentInfo::clear_index_name() {
+  index_name_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline const std::string& QuerySegmentInfo::index_name() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.index_name)
+  return index_name_.GetNoArena();
+}
+inline void QuerySegmentInfo::set_index_name(const std::string& value) {
+  
+  index_name_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value);
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.index_name)
+}
+inline void QuerySegmentInfo::set_index_name(std::string&& value) {
+  
+  index_name_.SetNoArena(
+    &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+  // @@protoc_insertion_point(field_set_rvalue:milvus.proto.milvus.QuerySegmentInfo.index_name)
+}
+inline void QuerySegmentInfo::set_index_name(const char* value) {
+  GOOGLE_DCHECK(value != nullptr);
+  
+  index_name_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+  // @@protoc_insertion_point(field_set_char:milvus.proto.milvus.QuerySegmentInfo.index_name)
+}
+inline void QuerySegmentInfo::set_index_name(const char* value, size_t size) {
+  
+  index_name_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
+      ::std::string(reinterpret_cast<const char*>(value), size));
+  // @@protoc_insertion_point(field_set_pointer:milvus.proto.milvus.QuerySegmentInfo.index_name)
+}
+inline std::string* QuerySegmentInfo::mutable_index_name() {
+  
+  // @@protoc_insertion_point(field_mutable:milvus.proto.milvus.QuerySegmentInfo.index_name)
+  return index_name_.MutableNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline std::string* QuerySegmentInfo::release_index_name() {
+  // @@protoc_insertion_point(field_release:milvus.proto.milvus.QuerySegmentInfo.index_name)
+  
+  return index_name_.ReleaseNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline void QuerySegmentInfo::set_allocated_index_name(std::string* index_name) {
+  if (index_name != nullptr) {
+    
+  } else {
+    
+  }
+  index_name_.SetAllocatedNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), index_name);
+  // @@protoc_insertion_point(field_set_allocated:milvus.proto.milvus.QuerySegmentInfo.index_name)
+}
+
+// int64 indexID = 7;
+inline void QuerySegmentInfo::clear_indexid() {
+  indexid_ = PROTOBUF_LONGLONG(0);
+}
+inline ::PROTOBUF_NAMESPACE_ID::int64 QuerySegmentInfo::indexid() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfo.indexID)
+  return indexid_;
+}
+inline void QuerySegmentInfo::set_indexid(::PROTOBUF_NAMESPACE_ID::int64 value) {
+  
+  indexid_ = value;
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfo.indexID)
+}
+
+// -------------------------------------------------------------------
+
+// QuerySegmentInfoRequest
+
+// .milvus.proto.common.MsgBase base = 1;
+inline bool QuerySegmentInfoRequest::has_base() const {
+  return this != internal_default_instance() && base_ != nullptr;
+}
+inline const ::milvus::proto::common::MsgBase& QuerySegmentInfoRequest::base() const {
+  const ::milvus::proto::common::MsgBase* p = base_;
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfoRequest.base)
+  return p != nullptr ? *p : *reinterpret_cast<const ::milvus::proto::common::MsgBase*>(
+      &::milvus::proto::common::_MsgBase_default_instance_);
+}
+inline ::milvus::proto::common::MsgBase* QuerySegmentInfoRequest::release_base() {
+  // @@protoc_insertion_point(field_release:milvus.proto.milvus.QuerySegmentInfoRequest.base)
+  
+  ::milvus::proto::common::MsgBase* temp = base_;
+  base_ = nullptr;
+  return temp;
+}
+inline ::milvus::proto::common::MsgBase* QuerySegmentInfoRequest::mutable_base() {
+  
+  if (base_ == nullptr) {
+    auto* p = CreateMaybeMessage<::milvus::proto::common::MsgBase>(GetArenaNoVirtual());
+    base_ = p;
+  }
+  // @@protoc_insertion_point(field_mutable:milvus.proto.milvus.QuerySegmentInfoRequest.base)
+  return base_;
+}
+inline void QuerySegmentInfoRequest::set_allocated_base(::milvus::proto::common::MsgBase* base) {
+  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaNoVirtual();
+  if (message_arena == nullptr) {
+    delete reinterpret_cast< ::PROTOBUF_NAMESPACE_ID::MessageLite*>(base_);
+  }
+  if (base) {
+    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = nullptr;
+    if (message_arena != submessage_arena) {
+      base = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
+          message_arena, base, submessage_arena);
+    }
+    
+  } else {
+    
+  }
+  base_ = base;
+  // @@protoc_insertion_point(field_set_allocated:milvus.proto.milvus.QuerySegmentInfoRequest.base)
+}
+
+// string dbName = 2;
+inline void QuerySegmentInfoRequest::clear_dbname() {
+  dbname_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline const std::string& QuerySegmentInfoRequest::dbname() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+  return dbname_.GetNoArena();
+}
+inline void QuerySegmentInfoRequest::set_dbname(const std::string& value) {
+  
+  dbname_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value);
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+}
+inline void QuerySegmentInfoRequest::set_dbname(std::string&& value) {
+  
+  dbname_.SetNoArena(
+    &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+  // @@protoc_insertion_point(field_set_rvalue:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+}
+inline void QuerySegmentInfoRequest::set_dbname(const char* value) {
+  GOOGLE_DCHECK(value != nullptr);
+  
+  dbname_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+  // @@protoc_insertion_point(field_set_char:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+}
+inline void QuerySegmentInfoRequest::set_dbname(const char* value, size_t size) {
+  
+  dbname_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
+      ::std::string(reinterpret_cast<const char*>(value), size));
+  // @@protoc_insertion_point(field_set_pointer:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+}
+inline std::string* QuerySegmentInfoRequest::mutable_dbname() {
+  
+  // @@protoc_insertion_point(field_mutable:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+  return dbname_.MutableNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline std::string* QuerySegmentInfoRequest::release_dbname() {
+  // @@protoc_insertion_point(field_release:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+  
+  return dbname_.ReleaseNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline void QuerySegmentInfoRequest::set_allocated_dbname(std::string* dbname) {
+  if (dbname != nullptr) {
+    
+  } else {
+    
+  }
+  dbname_.SetAllocatedNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), dbname);
+  // @@protoc_insertion_point(field_set_allocated:milvus.proto.milvus.QuerySegmentInfoRequest.dbName)
+}
+
+// string collectionName = 3;
+inline void QuerySegmentInfoRequest::clear_collectionname() {
+  collectionname_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline const std::string& QuerySegmentInfoRequest::collectionname() const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+  return collectionname_.GetNoArena();
+}
+inline void QuerySegmentInfoRequest::set_collectionname(const std::string& value) {
+  
+  collectionname_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), value);
+  // @@protoc_insertion_point(field_set:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+}
+inline void QuerySegmentInfoRequest::set_collectionname(std::string&& value) {
+  
+  collectionname_.SetNoArena(
+    &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
+  // @@protoc_insertion_point(field_set_rvalue:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+}
+inline void QuerySegmentInfoRequest::set_collectionname(const char* value) {
+  GOOGLE_DCHECK(value != nullptr);
+  
+  collectionname_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
+  // @@protoc_insertion_point(field_set_char:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+}
+inline void QuerySegmentInfoRequest::set_collectionname(const char* value, size_t size) {
+  
+  collectionname_.SetNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(),
+      ::std::string(reinterpret_cast<const char*>(value), size));
+  // @@protoc_insertion_point(field_set_pointer:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+}
+inline std::string* QuerySegmentInfoRequest::mutable_collectionname() {
+  
+  // @@protoc_insertion_point(field_mutable:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+  return collectionname_.MutableNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline std::string* QuerySegmentInfoRequest::release_collectionname() {
+  // @@protoc_insertion_point(field_release:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+  
+  return collectionname_.ReleaseNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited());
+}
+inline void QuerySegmentInfoRequest::set_allocated_collectionname(std::string* collectionname) {
+  if (collectionname != nullptr) {
+    
+  } else {
+    
+  }
+  collectionname_.SetAllocatedNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), collectionname);
+  // @@protoc_insertion_point(field_set_allocated:milvus.proto.milvus.QuerySegmentInfoRequest.collectionName)
+}
+
+// -------------------------------------------------------------------
+
+// QuerySegmentInfoResponse
+
+// .milvus.proto.common.Status status = 1;
+inline bool QuerySegmentInfoResponse::has_status() const {
+  return this != internal_default_instance() && status_ != nullptr;
+}
+inline const ::milvus::proto::common::Status& QuerySegmentInfoResponse::status() const {
+  const ::milvus::proto::common::Status* p = status_;
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfoResponse.status)
+  return p != nullptr ? *p : *reinterpret_cast<const ::milvus::proto::common::Status*>(
+      &::milvus::proto::common::_Status_default_instance_);
+}
+inline ::milvus::proto::common::Status* QuerySegmentInfoResponse::release_status() {
+  // @@protoc_insertion_point(field_release:milvus.proto.milvus.QuerySegmentInfoResponse.status)
+  
+  ::milvus::proto::common::Status* temp = status_;
+  status_ = nullptr;
+  return temp;
+}
+inline ::milvus::proto::common::Status* QuerySegmentInfoResponse::mutable_status() {
+  
+  if (status_ == nullptr) {
+    auto* p = CreateMaybeMessage<::milvus::proto::common::Status>(GetArenaNoVirtual());
+    status_ = p;
+  }
+  // @@protoc_insertion_point(field_mutable:milvus.proto.milvus.QuerySegmentInfoResponse.status)
+  return status_;
+}
+inline void QuerySegmentInfoResponse::set_allocated_status(::milvus::proto::common::Status* status) {
+  ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaNoVirtual();
+  if (message_arena == nullptr) {
+    delete reinterpret_cast< ::PROTOBUF_NAMESPACE_ID::MessageLite*>(status_);
+  }
+  if (status) {
+    ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena = nullptr;
+    if (message_arena != submessage_arena) {
+      status = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
+          message_arena, status, submessage_arena);
+    }
+    
+  } else {
+    
+  }
+  status_ = status;
+  // @@protoc_insertion_point(field_set_allocated:milvus.proto.milvus.QuerySegmentInfoResponse.status)
+}
+
+// repeated .milvus.proto.milvus.QuerySegmentInfo infos = 2;
+inline int QuerySegmentInfoResponse::infos_size() const {
+  return infos_.size();
+}
+inline void QuerySegmentInfoResponse::clear_infos() {
+  infos_.Clear();
+}
+inline ::milvus::proto::milvus::QuerySegmentInfo* QuerySegmentInfoResponse::mutable_infos(int index) {
+  // @@protoc_insertion_point(field_mutable:milvus.proto.milvus.QuerySegmentInfoResponse.infos)
+  return infos_.Mutable(index);
+}
+inline ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::milvus::QuerySegmentInfo >*
+QuerySegmentInfoResponse::mutable_infos() {
+  // @@protoc_insertion_point(field_mutable_list:milvus.proto.milvus.QuerySegmentInfoResponse.infos)
+  return &infos_;
+}
+inline const ::milvus::proto::milvus::QuerySegmentInfo& QuerySegmentInfoResponse::infos(int index) const {
+  // @@protoc_insertion_point(field_get:milvus.proto.milvus.QuerySegmentInfoResponse.infos)
+  return infos_.Get(index);
+}
+inline ::milvus::proto::milvus::QuerySegmentInfo* QuerySegmentInfoResponse::add_infos() {
+  // @@protoc_insertion_point(field_add:milvus.proto.milvus.QuerySegmentInfoResponse.infos)
+  return infos_.Add();
+}
+inline const ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::milvus::proto::milvus::QuerySegmentInfo >&
+QuerySegmentInfoResponse::infos() const {
+  // @@protoc_insertion_point(field_list:milvus.proto.milvus.QuerySegmentInfoResponse.infos)
+  return infos_;
+}
+
+// -------------------------------------------------------------------
+
 // RegisterLinkResponse
 
 // .milvus.proto.common.Address address = 1;
@@ -13733,6 +14600,12 @@ inline void RegisterLinkResponse::set_allocated_status(::milvus::proto::common::
 
 // -------------------------------------------------------------------
 
+// -------------------------------------------------------------------
+
+// -------------------------------------------------------------------
+
+// -------------------------------------------------------------------
+
 
 // @@protoc_insertion_point(namespace_scope)
 
diff --git a/internal/datanode/data_sync_service_test.go b/internal/datanode/data_sync_service_test.go
index e5aa64d1e..7973aecb7 100644
--- a/internal/datanode/data_sync_service_test.go
+++ b/internal/datanode/data_sync_service_test.go
@@ -82,14 +82,12 @@ func TestDataSyncService_Start(t *testing.T) {
 	insertChannels := Params.InsertChannelNames
 	ddChannels := Params.DDChannelNames
 
-	factory := msgstream.ProtoUDFactory{}
-	insertStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(pulsarURL)
-	insertStream.CreatePulsarProducers(insertChannels)
-
-	ddStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(pulsarURL)
-	ddStream.CreatePulsarProducers(ddChannels)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	insertStream, _ := factory.NewMsgStream(ctx)
+	insertStream.AsProducer(insertChannels)
+
+	ddStream, _ := factory.NewMsgStream(ctx)
+	ddStream.AsProducer(ddChannels)
 
 	var insertMsgStream msgstream.MsgStream = insertStream
 	insertMsgStream.Start()
diff --git a/internal/datanode/flow_graph_insert_buffer_node.go b/internal/datanode/flow_graph_insert_buffer_node.go
index 96b96814c..1b5336926 100644
--- a/internal/datanode/flow_graph_insert_buffer_node.go
+++ b/internal/datanode/flow_graph_insert_buffer_node.go
@@ -664,26 +664,23 @@ func newInsertBufferNode(ctx context.Context, flushMeta *metaTable,
 	}
 	minioPrefix := Params.InsertBinlogRootPath
 
-	factory := msgstream.ProtoUDFactory{}
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
 
 	//input stream, data node time tick
-	wTt := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	wTt.SetPulsarClient(Params.PulsarAddress)
-	wTt.CreatePulsarProducers([]string{Params.TimeTickChannelName})
+	wTt, _ := factory.NewMsgStream(ctx)
+	wTt.AsProducer([]string{Params.TimeTickChannelName})
 	var wTtMsgStream msgstream.MsgStream = wTt
 	wTtMsgStream.Start()
 
 	// update statistics channel
-	segS := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	segS.SetPulsarClient(Params.PulsarAddress)
-	segS.CreatePulsarProducers([]string{Params.SegmentStatisticsChannelName})
+	segS, _ := factory.NewMsgStream(ctx)
+	segS.AsProducer([]string{Params.SegmentStatisticsChannelName})
 	var segStatisticsMsgStream msgstream.MsgStream = segS
 	segStatisticsMsgStream.Start()
 
 	// segment flush completed channel
-	cf := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	cf.SetPulsarClient(Params.PulsarAddress)
-	cf.CreatePulsarProducers([]string{Params.CompleteFlushChannelName})
+	cf, _ := factory.NewMsgStream(ctx)
+	cf.AsProducer([]string{Params.CompleteFlushChannelName})
 	var completeFlushStream msgstream.MsgStream = cf
 	completeFlushStream.Start()
 
diff --git a/internal/datanode/flow_graph_msg_stream_input_node.go b/internal/datanode/flow_graph_msg_stream_input_node.go
index 649f6e5d2..0476ce4d6 100644
--- a/internal/datanode/flow_graph_msg_stream_input_node.go
+++ b/internal/datanode/flow_graph_msg_stream_input_node.go
@@ -15,11 +15,9 @@ func newDmInputNode(ctx context.Context) *flowgraph.InputNode {
 	consumeChannels := Params.InsertChannelNames
 	consumeSubName := Params.MsgChannelSubName
 
-	factory := msgstream.ProtoUDFactory{}
-	insertStream := pulsarms.NewPulsarTtMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(Params.PulsarAddress)
-
-	insertStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	insertStream, _ := factory.NewTtMsgStream(ctx)
+	insertStream.AsConsumer(consumeChannels, consumeSubName)
 
 	var stream msgstream.MsgStream = insertStream
 	node := flowgraph.NewInputNode(&stream, "dmInputNode", maxQueueLength, maxParallelism)
@@ -32,10 +30,9 @@ func newDDInputNode(ctx context.Context) *flowgraph.InputNode {
 	maxParallelism := Params.FlowGraphMaxParallelism
 	consumeSubName := Params.MsgChannelSubName
 
-	factory := msgstream.ProtoUDFactory{}
-	tmpStream := pulsarms.NewPulsarTtMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	tmpStream.SetPulsarClient(Params.PulsarAddress)
-	tmpStream.CreatePulsarConsumers(Params.DDChannelNames, consumeSubName)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	tmpStream, _ := factory.NewTtMsgStream(ctx)
+	tmpStream.AsConsumer(Params.DDChannelNames, consumeSubName)
 
 	var stream msgstream.MsgStream = tmpStream
 	node := flowgraph.NewInputNode(&stream, "ddInputNode", maxQueueLength, maxParallelism)
diff --git a/internal/dataservice/meta.go b/internal/dataservice/meta.go
index 61b67842b..b69cc746e 100644
--- a/internal/dataservice/meta.go
+++ b/internal/dataservice/meta.go
@@ -183,7 +183,7 @@ func (meta *meta) UpdateSegment(segmentInfo *datapb.SegmentInfo) error {
 
 func (meta *meta) DropSegment(segmentID UniqueID) error {
 	meta.ddLock.Lock()
-	defer meta.ddLock.Unlock()
+	meta.ddLock.Unlock()
 
 	if _, ok := meta.segID2Info[segmentID]; !ok {
 		return newErrSegmentNotFound(segmentID)
diff --git a/internal/dataservice/segment_allocator.go b/internal/dataservice/segment_allocator.go
index a85dd4111..d15d3b66a 100644
--- a/internal/dataservice/segment_allocator.go
+++ b/internal/dataservice/segment_allocator.go
@@ -71,7 +71,7 @@ type (
 	}
 )
 
-func newSegmentAllocator(meta *meta, allocator allocator) *segmentAllocatorImpl {
+func newSegmentAllocator(meta *meta, allocator allocator) (*segmentAllocatorImpl, error) {
 	segmentAllocator := &segmentAllocatorImpl{
 		mt:                     meta,
 		segments:               make(map[UniqueID]*segmentStatus),
@@ -80,7 +80,7 @@ func newSegmentAllocator(meta *meta, allocator allocator) *segmentAllocatorImpl
 		segmentThresholdFactor: Params.SegmentSizeFactor,
 		allocator:              allocator,
 	}
-	return segmentAllocator
+	return segmentAllocator, nil
 }
 
 func (allocator *segmentAllocatorImpl) OpenSegment(segmentInfo *datapb.SegmentInfo) error {
diff --git a/internal/dataservice/segment_allocator_test.go b/internal/dataservice/segment_allocator_test.go
index 9f81783ef..d0e248edc 100644
--- a/internal/dataservice/segment_allocator_test.go
+++ b/internal/dataservice/segment_allocator_test.go
@@ -17,7 +17,8 @@ func TestAllocSegment(t *testing.T) {
 	mockAllocator := newMockAllocator()
 	meta, err := newMemoryMeta(mockAllocator)
 	assert.Nil(t, err)
-	segAllocator := newSegmentAllocator(meta, mockAllocator)
+	segAllocator, err := newSegmentAllocator(meta, mockAllocator)
+	assert.Nil(t, err)
 
 	schema := newTestSchema()
 	collID, err := mockAllocator.allocID()
@@ -67,7 +68,8 @@ func TestSealSegment(t *testing.T) {
 	mockAllocator := newMockAllocator()
 	meta, err := newMemoryMeta(mockAllocator)
 	assert.Nil(t, err)
-	segAllocator := newSegmentAllocator(meta, mockAllocator)
+	segAllocator, err := newSegmentAllocator(meta, mockAllocator)
+	assert.Nil(t, err)
 
 	schema := newTestSchema()
 	collID, err := mockAllocator.allocID()
@@ -103,7 +105,8 @@ func TestExpireSegment(t *testing.T) {
 	mockAllocator := newMockAllocator()
 	meta, err := newMemoryMeta(mockAllocator)
 	assert.Nil(t, err)
-	segAllocator := newSegmentAllocator(meta, mockAllocator)
+	segAllocator, err := newSegmentAllocator(meta, mockAllocator)
+	assert.Nil(t, err)
 
 	schema := newTestSchema()
 	collID, err := mockAllocator.allocID()
diff --git a/internal/dataservice/server.go b/internal/dataservice/server.go
index afbbdfd24..a5537e11c 100644
--- a/internal/dataservice/server.go
+++ b/internal/dataservice/server.go
@@ -134,7 +134,10 @@ func (s *Server) Start() error {
 		return err
 	}
 	s.statsHandler = newStatsHandler(s.meta)
-	s.segAllocator = newSegmentAllocator(s.meta, s.allocator)
+	s.segAllocator, err = newSegmentAllocator(s.meta, s.allocator)
+	if err != nil {
+		return err
+	}
 	s.ddHandler = newDDHandler(s.meta, s.segAllocator)
 	s.initSegmentInfoChannel()
 	if err = s.loadMetaFromMaster(); err != nil {
@@ -170,25 +173,22 @@ func (s *Server) initMeta() error {
 }
 
 func (s *Server) initSegmentInfoChannel() {
-	factory := msgstream.ProtoUDFactory{}
-	segmentInfoStream := pulsarms.NewPulsarMsgStream(s.ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	segmentInfoStream.SetPulsarClient(Params.PulsarAddress)
-	segmentInfoStream.CreatePulsarProducers([]string{Params.SegmentInfoChannelName})
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	segmentInfoStream, _ := factory.NewMsgStream(s.ctx)
+	segmentInfoStream.AsProducer([]string{Params.SegmentInfoChannelName})
 	s.segmentInfoStream = segmentInfoStream
 	s.segmentInfoStream.Start()
 }
 func (s *Server) initMsgProducer() error {
-	factory := msgstream.ProtoUDFactory{}
-	ttMsgStream := pulsarms.NewPulsarMsgStream(s.ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	ttMsgStream.SetPulsarClient(Params.PulsarAddress)
-	ttMsgStream.CreatePulsarConsumers([]string{Params.TimeTickChannelName}, Params.DataServiceSubscriptionName)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	ttMsgStream, _ := factory.NewMsgStream(s.ctx)
+	ttMsgStream.AsConsumer([]string{Params.TimeTickChannelName}, Params.DataServiceSubscriptionName)
 	s.ttMsgStream = ttMsgStream
 	s.ttMsgStream.Start()
 	timeTickBarrier := timesync.NewHardTimeTickBarrier(s.ttMsgStream, s.cluster.GetNodeIDs())
 	dataNodeTTWatcher := newDataNodeTimeTickWatcher(s.meta, s.segAllocator, s.cluster)
-	k2sStream := pulsarms.NewPulsarMsgStream(s.ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	k2sStream.SetPulsarClient(Params.PulsarAddress)
-	k2sStream.CreatePulsarProducers(Params.K2SChannelNames)
+	k2sStream, _ := factory.NewMsgStream(s.ctx)
+	k2sStream.AsProducer(Params.K2SChannelNames)
 	s.k2sMsgStream = k2sStream
 	s.k2sMsgStream.Start()
 	k2sMsgWatcher := timesync.NewMsgTimeTickWatcher(s.k2sMsgStream)
@@ -308,10 +308,9 @@ func (s *Server) startServerLoop() {
 
 func (s *Server) startStatsChannel(ctx context.Context) {
 	defer s.serverLoopWg.Done()
-	factory := msgstream.ProtoUDFactory{}
-	statsStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	statsStream.SetPulsarClient(Params.PulsarAddress)
-	statsStream.CreatePulsarConsumers([]string{Params.StatisticsChannelName}, Params.DataServiceSubscriptionName)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	statsStream, _ := factory.NewMsgStream(ctx)
+	statsStream.AsConsumer([]string{Params.StatisticsChannelName}, Params.DataServiceSubscriptionName)
 	statsStream.Start()
 	defer statsStream.Close()
 	for {
@@ -335,10 +334,9 @@ func (s *Server) startStatsChannel(ctx context.Context) {
 
 func (s *Server) startSegmentFlushChannel(ctx context.Context) {
 	defer s.serverLoopWg.Done()
-	factory := msgstream.ProtoUDFactory{}
-	flushStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	flushStream.SetPulsarClient(Params.PulsarAddress)
-	flushStream.CreatePulsarConsumers([]string{Params.SegmentInfoChannelName}, Params.DataServiceSubscriptionName)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	flushStream, _ := factory.NewMsgStream(ctx)
+	flushStream.AsConsumer([]string{Params.SegmentInfoChannelName}, Params.DataServiceSubscriptionName)
 	flushStream.Start()
 	defer flushStream.Close()
 	for {
@@ -371,10 +369,9 @@ func (s *Server) startSegmentFlushChannel(ctx context.Context) {
 
 func (s *Server) startDDChannel(ctx context.Context) {
 	defer s.serverLoopWg.Done()
-	factory := msgstream.ProtoUDFactory{}
-	ddStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(Params.PulsarAddress)
-	ddStream.CreatePulsarConsumers([]string{s.ddChannelName}, Params.DataServiceSubscriptionName)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	ddStream, _ := factory.NewMsgStream(ctx)
+	ddStream.AsConsumer([]string{s.ddChannelName}, Params.DataServiceSubscriptionName)
 	ddStream.Start()
 	defer ddStream.Close()
 	for {
diff --git a/internal/dataservice/watcher_test.go b/internal/dataservice/watcher_test.go
index 11e8fbe5f..e476f9f02 100644
--- a/internal/dataservice/watcher_test.go
+++ b/internal/dataservice/watcher_test.go
@@ -21,7 +21,7 @@ func TestDataNodeTTWatcher(t *testing.T) {
 	allocator := newMockAllocator()
 	meta, err := newMemoryMeta(allocator)
 	assert.Nil(t, err)
-	segAllocator := newSegmentAllocator(meta, allocator)
+	segAllocator, err := newSegmentAllocator(meta, allocator)
 	assert.Nil(t, err)
 	watcher := newDataNodeTimeTickWatcher(meta, segAllocator, cluster)
 
diff --git a/internal/distributed/proxynode/service.go b/internal/distributed/proxynode/service.go
index 9c325d1dc..b933d3330 100644
--- a/internal/distributed/proxynode/service.go
+++ b/internal/distributed/proxynode/service.go
@@ -324,3 +324,8 @@ func (s *Server) GetDdChannel(ctx context.Context, request *commonpb.Empty) (*mi
 func (s *Server) GetPersistentSegmentInfo(ctx context.Context, request *milvuspb.PersistentSegmentInfoRequest) (*milvuspb.PersistentSegmentInfoResponse, error) {
 	return s.impl.GetPersistentSegmentInfo(request)
 }
+
+func (s *Server) GetQuerySegmentInfo(ctx context.Context, request *milvuspb.QuerySegmentInfoRequest) (*milvuspb.QuerySegmentInfoResponse, error) {
+	return s.impl.GetQuerySegmentInfo(request)
+
+}
diff --git a/internal/masterservice/master_service.go b/internal/masterservice/master_service.go
index 53040b408..545c0c401 100644
--- a/internal/masterservice/master_service.go
+++ b/internal/masterservice/master_service.go
@@ -402,7 +402,6 @@ func (c *Core) tsLoop() {
 	}
 }
 func (c *Core) setMsgStreams() error {
-	dispatcherFactory := ms.ProtoUDFactory{}
 
 	if Params.PulsarAddress == "" {
 		return errors.Errorf("PulsarAddress is empty")
@@ -415,26 +414,25 @@ func (c *Core) setMsgStreams() error {
 	if Params.ProxyTimeTickChannel == "" {
 		return errors.Errorf("ProxyTimeTickChannel is empty")
 	}
-	proxyTimeTickStream := pulsarms.NewPulsarMsgStream(c.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	proxyTimeTickStream.SetPulsarClient(Params.PulsarAddress)
-	proxyTimeTickStream.CreatePulsarConsumers([]string{Params.ProxyTimeTickChannel}, Params.MsgChannelSubName)
+
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	proxyTimeTickStream, _ := factory.NewMsgStream(c.ctx)
+	proxyTimeTickStream.AsConsumer([]string{Params.ProxyTimeTickChannel}, Params.MsgChannelSubName)
 	proxyTimeTickStream.Start()
 
 	// master time tick channel
 	if Params.TimeTickChannel == "" {
 		return errors.Errorf("TimeTickChannel is empty")
 	}
-	timeTickStream := pulsarms.NewPulsarMsgStream(c.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	timeTickStream.SetPulsarClient(Params.PulsarAddress)
-	timeTickStream.CreatePulsarProducers([]string{Params.TimeTickChannel})
+	timeTickStream, _ := factory.NewMsgStream(c.ctx)
+	timeTickStream.AsProducer([]string{Params.TimeTickChannel})
 
 	// master dd channel
 	if Params.DdChannel == "" {
 		return errors.Errorf("DdChannel is empty")
 	}
-	ddStream := pulsarms.NewPulsarMsgStream(c.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(Params.PulsarAddress)
-	ddStream.CreatePulsarProducers([]string{Params.DdChannel})
+	ddStream, _ := factory.NewMsgStream(c.ctx)
+	ddStream.AsProducer([]string{Params.DdChannel})
 
 	c.SendTimeTick = func(t typeutil.Timestamp) error {
 		msgPack := ms.MsgPack{}
@@ -567,9 +565,8 @@ func (c *Core) setMsgStreams() error {
 	if Params.DataServiceSegmentChannel == "" {
 		return errors.Errorf("DataServiceSegmentChannel is empty")
 	}
-	dataServiceStream := pulsarms.NewPulsarMsgStream(c.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	dataServiceStream.SetPulsarClient(Params.PulsarAddress)
-	dataServiceStream.CreatePulsarConsumers([]string{Params.DataServiceSegmentChannel}, Params.MsgChannelSubName)
+	dataServiceStream, _ := factory.NewMsgStream(c.ctx)
+	dataServiceStream.AsConsumer([]string{Params.DataServiceSegmentChannel}, Params.MsgChannelSubName)
 	dataServiceStream.Start()
 	c.DataServiceSegmentChan = make(chan *datapb.SegmentInfo, 1024)
 	c.DataNodeSegmentFlushCompletedChan = make(chan typeutil.UniqueID, 1024)
diff --git a/internal/masterservice/master_service_test.go b/internal/masterservice/master_service_test.go
index a5584e643..5333dbf45 100644
--- a/internal/masterservice/master_service_test.go
+++ b/internal/masterservice/master_service_test.go
@@ -105,6 +105,17 @@ func (idx *indexMock) getFileArray() []string {
 	return ret
 }
 
+func consumeMsgChan(timeout time.Duration, targetChan <-chan *ms.MsgPack) {
+	for {
+		select {
+		case <-time.After(timeout):
+			return
+		case <-targetChan:
+
+		}
+	}
+}
+
 func TestMasterService(t *testing.T) {
 	ctx, cancel := context.WithCancel(context.Background())
 	defer cancel()
@@ -146,23 +157,19 @@ func TestMasterService(t *testing.T) {
 	err = core.Start()
 	assert.Nil(t, err)
 
-	factory := ms.ProtoUDFactory{}
-	proxyTimeTickStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	proxyTimeTickStream.SetPulsarClient(Params.PulsarAddress)
-	proxyTimeTickStream.CreatePulsarProducers([]string{Params.ProxyTimeTickChannel})
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
+	proxyTimeTickStream, _ := factory.NewMsgStream(ctx)
+	proxyTimeTickStream.AsProducer([]string{Params.ProxyTimeTickChannel})
 
-	dataServiceSegmentStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	dataServiceSegmentStream.SetPulsarClient(Params.PulsarAddress)
-	dataServiceSegmentStream.CreatePulsarProducers([]string{Params.DataServiceSegmentChannel})
+	dataServiceSegmentStream, _ := factory.NewMsgStream(ctx)
+	dataServiceSegmentStream.AsProducer([]string{Params.DataServiceSegmentChannel})
 
-	timeTickStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	timeTickStream.SetPulsarClient(Params.PulsarAddress)
-	timeTickStream.CreatePulsarConsumers([]string{Params.TimeTickChannel}, Params.MsgChannelSubName)
+	timeTickStream, _ := factory.NewMsgStream(ctx)
+	timeTickStream.AsConsumer([]string{Params.TimeTickChannel}, Params.MsgChannelSubName)
 	timeTickStream.Start()
 
-	ddStream := pulsarms.NewPulsarMsgStream(ctx, 1024, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(Params.PulsarAddress)
-	ddStream.CreatePulsarConsumers([]string{Params.DdChannel}, Params.MsgChannelSubName)
+	ddStream, _ := factory.NewMsgStream(ctx)
+	ddStream.AsConsumer([]string{Params.DdChannel}, Params.MsgChannelSubName)
 	ddStream.Start()
 
 	time.Sleep(time.Second)
@@ -405,6 +412,7 @@ func TestMasterService(t *testing.T) {
 			CollectionName: "testColl",
 			PartitionName:  "testPartition",
 		}
+		consumeMsgChan(time.Second, ddStream.Chan())
 		status, err := core.CreatePartition(req)
 		assert.Nil(t, err)
 		assert.Equal(t, status.ErrorCode, commonpb.ErrorCode_SUCCESS)
diff --git a/internal/msgstream/msgstream.go b/internal/msgstream/msgstream.go
index dd11dba3b..e62e00595 100644
--- a/internal/msgstream/msgstream.go
+++ b/internal/msgstream/msgstream.go
@@ -1,6 +1,8 @@
 package msgstream
 
 import (
+	"context"
+
 	"github.com/zilliztech/milvus-distributed/internal/proto/internalpb2"
 	"github.com/zilliztech/milvus-distributed/internal/util/typeutil"
 )
@@ -24,9 +26,17 @@ type MsgStream interface {
 	Start()
 	Close()
 	Chan() <-chan *MsgPack
+	AsProducer(channels []string)
+	AsConsumer(channels []string, subName string)
+	SetRepackFunc(repackFunc RepackFunc)
 
 	Produce(*MsgPack) error
 	Broadcast(*MsgPack) error
 	Consume() *MsgPack
 	Seek(offset *MsgPosition) error
 }
+
+type Factory interface {
+	NewMsgStream(ctx context.Context) (MsgStream, error)
+	NewTtMsgStream(ctx context.Context) (MsgStream, error)
+}
diff --git a/internal/msgstream/pulsarms/factory.go b/internal/msgstream/pulsarms/factory.go
new file mode 100644
index 000000000..8e10c2e3f
--- /dev/null
+++ b/internal/msgstream/pulsarms/factory.go
@@ -0,0 +1,32 @@
+package pulsarms
+
+import (
+	"context"
+
+	"github.com/zilliztech/milvus-distributed/internal/msgstream"
+)
+
+type Factory struct {
+	dispatcherFactory msgstream.ProtoUDFactory
+	address           string
+	receiveBufSize    int64
+	pulsarBufSize     int64
+}
+
+func (f *Factory) NewMsgStream(ctx context.Context) (msgstream.MsgStream, error) {
+	return newPulsarMsgStream(ctx, f.address, f.receiveBufSize, f.pulsarBufSize, f.dispatcherFactory.NewUnmarshalDispatcher())
+}
+
+func (f *Factory) NewTtMsgStream(ctx context.Context) (msgstream.MsgStream, error) {
+	return NewPulsarTtMsgStream(ctx, f.address, f.receiveBufSize, f.pulsarBufSize, f.dispatcherFactory.NewUnmarshalDispatcher())
+}
+
+func NewFactory(address string, receiveBufSize int64, pulsarBufSize int64) *Factory {
+	f := &Factory{
+		dispatcherFactory: msgstream.ProtoUDFactory{},
+		address:           address,
+		receiveBufSize:    receiveBufSize,
+		pulsarBufSize:     pulsarBufSize,
+	}
+	return f
+}
diff --git a/internal/msgstream/pulsarms/msg_test.go b/internal/msgstream/pulsarms/msg_test.go
index a1051e231..51d999c4d 100644
--- a/internal/msgstream/pulsarms/msg_test.go
+++ b/internal/msgstream/pulsarms/msg_test.go
@@ -141,18 +141,16 @@ func TestStream_task_Insert(t *testing.T) {
 	msgPack.Msgs = append(msgPack.Msgs, getInsertTask(3, 3))
 
 	factory := msgstream.ProtoUDFactory{}
-	inputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	inputStream.SetPulsarClient(pulsarAddress)
-	inputStream.CreatePulsarProducers(producerChannels)
+	inputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	inputStream.AsProducer(producerChannels)
 	inputStream.SetRepackFunc(newRepackFunc)
 	inputStream.Start()
 
 	dispatcher := factory.NewUnmarshalDispatcher()
-	outputStream := NewPulsarMsgStream(context.Background(), 100, 100, dispatcher)
-	outputStream.SetPulsarClient(pulsarAddress)
+	outputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, dispatcher)
 	testTask := InsertTask{}
 	dispatcher.AddMsgTemplate(commonpb.MsgType_kInsert, testTask.Unmarshal)
-	outputStream.CreatePulsarConsumers(consumerChannels, consumerSubName)
+	outputStream.AsConsumer(consumerChannels, consumerSubName)
 	outputStream.Start()
 
 	err := inputStream.Produce(&msgPack)
@@ -161,7 +159,7 @@ func TestStream_task_Insert(t *testing.T) {
 	}
 	receiveCount := 0
 	for {
-		result := (*outputStream).Consume()
+		result := outputStream.Consume()
 		if len(result.Msgs) > 0 {
 			msgs := result.Msgs
 			for _, v := range msgs {
diff --git a/internal/msgstream/pulsarms/pulsar_msgstream.go b/internal/msgstream/pulsarms/pulsar_msgstream.go
index 523426669..5f9986861 100644
--- a/internal/msgstream/pulsarms/pulsar_msgstream.go
+++ b/internal/msgstream/pulsarms/pulsar_msgstream.go
@@ -52,7 +52,12 @@ type PulsarMsgStream struct {
 	pulsarBufSize    int64
 }
 
-func NewPulsarMsgStream(ctx context.Context, receiveBufSize int64, pulsarBufSize int64, unmarshal UnmarshalDispatcher) *PulsarMsgStream {
+func newPulsarMsgStream(ctx context.Context,
+	address string,
+	receiveBufSize int64,
+	pulsarBufSize int64,
+	unmarshal UnmarshalDispatcher) (*PulsarMsgStream, error) {
+
 	streamCtx, streamCancel := context.WithCancel(ctx)
 	producers := make([]Producer, 0)
 	consumers := make([]Consumer, 0)
@@ -66,19 +71,17 @@ func NewPulsarMsgStream(ctx context.Context, receiveBufSize int64, pulsarBufSize
 		unmarshal:        unmarshal,
 		pulsarBufSize:    pulsarBufSize,
 	}
-	stream.receiveBuf = make(chan *MsgPack, receiveBufSize)
-	return stream
-}
-
-func (ms *PulsarMsgStream) SetPulsarClient(address string) {
 	client, err := pulsar.NewClient(pulsar.ClientOptions{URL: address})
 	if err != nil {
 		log.Printf("Set pulsar client failed, error = %v", err)
+		return nil, err
 	}
-	ms.client = client
+	stream.client = client
+	stream.receiveBuf = make(chan *MsgPack, receiveBufSize)
+	return stream, nil
 }
 
-func (ms *PulsarMsgStream) CreatePulsarProducers(channels []string) {
+func (ms *PulsarMsgStream) AsProducer(channels []string) {
 	for i := 0; i < len(channels); i++ {
 		fn := func() error {
 			pp, err := ms.client.CreateProducer(pulsar.ProducerOptions{Topic: channels[i]})
@@ -100,7 +103,7 @@ func (ms *PulsarMsgStream) CreatePulsarProducers(channels []string) {
 	}
 }
 
-func (ms *PulsarMsgStream) CreatePulsarConsumers(channels []string,
+func (ms *PulsarMsgStream) AsConsumer(channels []string,
 	subName string) {
 	for i := 0; i < len(channels); i++ {
 		fn := func() error {
@@ -479,7 +482,12 @@ type PulsarTtMsgStream struct {
 	lastTimeStamp Timestamp
 }
 
-func NewPulsarTtMsgStream(ctx context.Context, receiveBufSize int64, pulsarBufSize int64, unmarshal msgstream.UnmarshalDispatcher) *PulsarTtMsgStream {
+func NewPulsarTtMsgStream(ctx context.Context,
+	address string,
+	receiveBufSize int64,
+	pulsarBufSize int64,
+	unmarshal msgstream.UnmarshalDispatcher) (*PulsarTtMsgStream, error) {
+
 	streamCtx, streamCancel := context.WithCancel(ctx)
 	pulsarMsgStream := PulsarMsgStream{
 		ctx:           streamCtx,
@@ -487,10 +495,17 @@ func NewPulsarTtMsgStream(ctx context.Context, receiveBufSize int64, pulsarBufSi
 		pulsarBufSize: pulsarBufSize,
 		unmarshal:     unmarshal,
 	}
+
+	client, err := pulsar.NewClient(pulsar.ClientOptions{URL: address})
+	if err != nil {
+		log.Printf("Set pulsar client failed, error = %v", err)
+		return nil, err
+	}
+	pulsarMsgStream.client = client
 	pulsarMsgStream.receiveBuf = make(chan *MsgPack, receiveBufSize)
 	return &PulsarTtMsgStream{
 		PulsarMsgStream: pulsarMsgStream,
-	}
+	}, nil
 }
 
 func (ms *PulsarTtMsgStream) Start() {
diff --git a/internal/msgstream/pulsarms/pulsar_msgstream_test.go b/internal/msgstream/pulsarms/pulsar_msgstream_test.go
index f9e9bb309..2fcfad927 100644
--- a/internal/msgstream/pulsarms/pulsar_msgstream_test.go
+++ b/internal/msgstream/pulsarms/pulsar_msgstream_test.go
@@ -176,9 +176,8 @@ func initPulsarStream(pulsarAddress string,
 	factory := msgstream.ProtoUDFactory{}
 
 	// set input stream
-	inputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	inputStream.SetPulsarClient(pulsarAddress)
-	inputStream.CreatePulsarProducers(producerChannels)
+	inputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	inputStream.AsProducer(producerChannels)
 	for _, opt := range opts {
 		inputStream.SetRepackFunc(opt)
 	}
@@ -186,9 +185,8 @@ func initPulsarStream(pulsarAddress string,
 	var input msgstream.MsgStream = inputStream
 
 	// set output stream
-	outputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	outputStream.SetPulsarClient(pulsarAddress)
-	outputStream.CreatePulsarConsumers(consumerChannels, consumerSubName)
+	outputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	outputStream.AsConsumer(consumerChannels, consumerSubName)
 	outputStream.Start()
 	var output msgstream.MsgStream = outputStream
 
@@ -203,9 +201,8 @@ func initPulsarTtStream(pulsarAddress string,
 	factory := msgstream.ProtoUDFactory{}
 
 	// set input stream
-	inputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	inputStream.SetPulsarClient(pulsarAddress)
-	inputStream.CreatePulsarProducers(producerChannels)
+	inputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	inputStream.AsProducer(producerChannels)
 	for _, opt := range opts {
 		inputStream.SetRepackFunc(opt)
 	}
@@ -213,9 +210,8 @@ func initPulsarTtStream(pulsarAddress string,
 	var input msgstream.MsgStream = inputStream
 
 	// set output stream
-	outputStream := NewPulsarTtMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	outputStream.SetPulsarClient(pulsarAddress)
-	outputStream.CreatePulsarConsumers(consumerChannels, consumerSubName)
+	outputStream, _ := NewPulsarTtMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	outputStream.AsConsumer(consumerChannels, consumerSubName)
 	outputStream.Start()
 	var output msgstream.MsgStream = outputStream
 
@@ -417,14 +413,12 @@ func TestStream_PulsarMsgStream_InsertRepackFunc(t *testing.T) {
 	msgPack.Msgs = append(msgPack.Msgs, insertMsg)
 
 	factory := msgstream.ProtoUDFactory{}
-	inputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	inputStream.SetPulsarClient(pulsarAddress)
-	inputStream.CreatePulsarProducers(producerChannels)
+	inputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	inputStream.AsProducer(producerChannels)
 	inputStream.Start()
 
-	outputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	outputStream.SetPulsarClient(pulsarAddress)
-	outputStream.CreatePulsarConsumers(consumerChannels, consumerSubName)
+	outputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	outputStream.AsConsumer(consumerChannels, consumerSubName)
 	outputStream.Start()
 	var output msgstream.MsgStream = outputStream
 
@@ -470,14 +464,12 @@ func TestStream_PulsarMsgStream_DeleteRepackFunc(t *testing.T) {
 	msgPack.Msgs = append(msgPack.Msgs, deleteMsg)
 
 	factory := msgstream.ProtoUDFactory{}
-	inputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	inputStream.SetPulsarClient(pulsarAddress)
-	inputStream.CreatePulsarProducers(producerChannels)
+	inputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	inputStream.AsProducer(producerChannels)
 	inputStream.Start()
 
-	outputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	outputStream.SetPulsarClient(pulsarAddress)
-	outputStream.CreatePulsarConsumers(consumerChannels, consumerSubName)
+	outputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	outputStream.AsConsumer(consumerChannels, consumerSubName)
 	outputStream.Start()
 	var output msgstream.MsgStream = outputStream
 
@@ -503,14 +495,12 @@ func TestStream_PulsarMsgStream_DefaultRepackFunc(t *testing.T) {
 	msgPack.Msgs = append(msgPack.Msgs, getTsMsg(commonpb.MsgType_kQueryNodeStats, 4, 4))
 
 	factory := msgstream.ProtoUDFactory{}
-	inputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	inputStream.SetPulsarClient(pulsarAddress)
-	inputStream.CreatePulsarProducers(producerChannels)
+	inputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	inputStream.AsProducer(producerChannels)
 	inputStream.Start()
 
-	outputStream := NewPulsarMsgStream(context.Background(), 100, 100, factory.NewUnmarshalDispatcher())
-	outputStream.SetPulsarClient(pulsarAddress)
-	outputStream.CreatePulsarConsumers(consumerChannels, consumerSubName)
+	outputStream, _ := newPulsarMsgStream(context.Background(), pulsarAddress, 100, 100, factory.NewUnmarshalDispatcher())
+	outputStream.AsConsumer(consumerChannels, consumerSubName)
 	outputStream.Start()
 	var output msgstream.MsgStream = outputStream
 
diff --git a/internal/proto/milvus.proto b/internal/proto/milvus.proto
index 9077a8a86..7869ae060 100644
--- a/internal/proto/milvus.proto
+++ b/internal/proto/milvus.proto
@@ -290,6 +290,27 @@ message PersistentSegmentInfoResponse {
   repeated PersistentSegmentInfo infos = 2;
 }
 
+message QuerySegmentInfo {
+  int64 segmentID = 1;
+  int64 collectionID = 2;
+  int64 partitionID = 3;
+  int64 mem_size = 4;
+  int64 num_rows = 5;
+  string index_name = 6;
+  int64 indexID = 7;
+}
+
+message QuerySegmentInfoRequest {
+  common.MsgBase base = 1;
+  string dbName = 2;
+  string collectionName = 3;
+}
+
+message QuerySegmentInfoResponse {
+  common.Status status = 1;
+  repeated QuerySegmentInfo infos = 2;
+}
+
 service MilvusService {
   rpc CreateCollection(CreateCollectionRequest) returns (common.Status) {}
   rpc DropCollection(DropCollectionRequest) returns (common.Status) {}
@@ -319,6 +340,7 @@ service MilvusService {
   rpc GetDdChannel(common.Empty) returns (StringResponse) {}
 
   rpc GetPersistentSegmentInfo(PersistentSegmentInfoRequest) returns (PersistentSegmentInfoResponse) {}
+  rpc GetQuerySegmentInfo(QuerySegmentInfoRequest) returns (QuerySegmentInfoResponse) {}
 
 }
 
diff --git a/internal/proto/milvuspb/milvus.pb.go b/internal/proto/milvuspb/milvus.pb.go
index 3dec54bc2..7a8343037 100644
--- a/internal/proto/milvuspb/milvus.pb.go
+++ b/internal/proto/milvuspb/milvus.pb.go
@@ -2518,6 +2518,195 @@ func (m *PersistentSegmentInfoResponse) GetInfos() []*PersistentSegmentInfo {
 	return nil
 }
 
+type QuerySegmentInfo struct {
+	SegmentID            int64    `protobuf:"varint,1,opt,name=segmentID,proto3" json:"segmentID,omitempty"`
+	CollectionID         int64    `protobuf:"varint,2,opt,name=collectionID,proto3" json:"collectionID,omitempty"`
+	PartitionID          int64    `protobuf:"varint,3,opt,name=partitionID,proto3" json:"partitionID,omitempty"`
+	MemSize              int64    `protobuf:"varint,4,opt,name=mem_size,json=memSize,proto3" json:"mem_size,omitempty"`
+	NumRows              int64    `protobuf:"varint,5,opt,name=num_rows,json=numRows,proto3" json:"num_rows,omitempty"`
+	IndexName            string   `protobuf:"bytes,6,opt,name=index_name,json=indexName,proto3" json:"index_name,omitempty"`
+	IndexID              int64    `protobuf:"varint,7,opt,name=indexID,proto3" json:"indexID,omitempty"`
+	XXX_NoUnkeyedLiteral struct{} `json:"-"`
+	XXX_unrecognized     []byte   `json:"-"`
+	XXX_sizecache        int32    `json:"-"`
+}
+
+func (m *QuerySegmentInfo) Reset()         { *m = QuerySegmentInfo{} }
+func (m *QuerySegmentInfo) String() string { return proto.CompactTextString(m) }
+func (*QuerySegmentInfo) ProtoMessage()    {}
+func (*QuerySegmentInfo) Descriptor() ([]byte, []int) {
+	return fileDescriptor_02345ba45cc0e303, []int{43}
+}
+
+func (m *QuerySegmentInfo) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_QuerySegmentInfo.Unmarshal(m, b)
+}
+func (m *QuerySegmentInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_QuerySegmentInfo.Marshal(b, m, deterministic)
+}
+func (m *QuerySegmentInfo) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_QuerySegmentInfo.Merge(m, src)
+}
+func (m *QuerySegmentInfo) XXX_Size() int {
+	return xxx_messageInfo_QuerySegmentInfo.Size(m)
+}
+func (m *QuerySegmentInfo) XXX_DiscardUnknown() {
+	xxx_messageInfo_QuerySegmentInfo.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_QuerySegmentInfo proto.InternalMessageInfo
+
+func (m *QuerySegmentInfo) GetSegmentID() int64 {
+	if m != nil {
+		return m.SegmentID
+	}
+	return 0
+}
+
+func (m *QuerySegmentInfo) GetCollectionID() int64 {
+	if m != nil {
+		return m.CollectionID
+	}
+	return 0
+}
+
+func (m *QuerySegmentInfo) GetPartitionID() int64 {
+	if m != nil {
+		return m.PartitionID
+	}
+	return 0
+}
+
+func (m *QuerySegmentInfo) GetMemSize() int64 {
+	if m != nil {
+		return m.MemSize
+	}
+	return 0
+}
+
+func (m *QuerySegmentInfo) GetNumRows() int64 {
+	if m != nil {
+		return m.NumRows
+	}
+	return 0
+}
+
+func (m *QuerySegmentInfo) GetIndexName() string {
+	if m != nil {
+		return m.IndexName
+	}
+	return ""
+}
+
+func (m *QuerySegmentInfo) GetIndexID() int64 {
+	if m != nil {
+		return m.IndexID
+	}
+	return 0
+}
+
+type QuerySegmentInfoRequest struct {
+	Base                 *commonpb.MsgBase `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"`
+	DbName               string            `protobuf:"bytes,2,opt,name=dbName,proto3" json:"dbName,omitempty"`
+	CollectionName       string            `protobuf:"bytes,3,opt,name=collectionName,proto3" json:"collectionName,omitempty"`
+	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
+	XXX_unrecognized     []byte            `json:"-"`
+	XXX_sizecache        int32             `json:"-"`
+}
+
+func (m *QuerySegmentInfoRequest) Reset()         { *m = QuerySegmentInfoRequest{} }
+func (m *QuerySegmentInfoRequest) String() string { return proto.CompactTextString(m) }
+func (*QuerySegmentInfoRequest) ProtoMessage()    {}
+func (*QuerySegmentInfoRequest) Descriptor() ([]byte, []int) {
+	return fileDescriptor_02345ba45cc0e303, []int{44}
+}
+
+func (m *QuerySegmentInfoRequest) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_QuerySegmentInfoRequest.Unmarshal(m, b)
+}
+func (m *QuerySegmentInfoRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_QuerySegmentInfoRequest.Marshal(b, m, deterministic)
+}
+func (m *QuerySegmentInfoRequest) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_QuerySegmentInfoRequest.Merge(m, src)
+}
+func (m *QuerySegmentInfoRequest) XXX_Size() int {
+	return xxx_messageInfo_QuerySegmentInfoRequest.Size(m)
+}
+func (m *QuerySegmentInfoRequest) XXX_DiscardUnknown() {
+	xxx_messageInfo_QuerySegmentInfoRequest.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_QuerySegmentInfoRequest proto.InternalMessageInfo
+
+func (m *QuerySegmentInfoRequest) GetBase() *commonpb.MsgBase {
+	if m != nil {
+		return m.Base
+	}
+	return nil
+}
+
+func (m *QuerySegmentInfoRequest) GetDbName() string {
+	if m != nil {
+		return m.DbName
+	}
+	return ""
+}
+
+func (m *QuerySegmentInfoRequest) GetCollectionName() string {
+	if m != nil {
+		return m.CollectionName
+	}
+	return ""
+}
+
+type QuerySegmentInfoResponse struct {
+	Status               *commonpb.Status    `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"`
+	Infos                []*QuerySegmentInfo `protobuf:"bytes,2,rep,name=infos,proto3" json:"infos,omitempty"`
+	XXX_NoUnkeyedLiteral struct{}            `json:"-"`
+	XXX_unrecognized     []byte              `json:"-"`
+	XXX_sizecache        int32               `json:"-"`
+}
+
+func (m *QuerySegmentInfoResponse) Reset()         { *m = QuerySegmentInfoResponse{} }
+func (m *QuerySegmentInfoResponse) String() string { return proto.CompactTextString(m) }
+func (*QuerySegmentInfoResponse) ProtoMessage()    {}
+func (*QuerySegmentInfoResponse) Descriptor() ([]byte, []int) {
+	return fileDescriptor_02345ba45cc0e303, []int{45}
+}
+
+func (m *QuerySegmentInfoResponse) XXX_Unmarshal(b []byte) error {
+	return xxx_messageInfo_QuerySegmentInfoResponse.Unmarshal(m, b)
+}
+func (m *QuerySegmentInfoResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+	return xxx_messageInfo_QuerySegmentInfoResponse.Marshal(b, m, deterministic)
+}
+func (m *QuerySegmentInfoResponse) XXX_Merge(src proto.Message) {
+	xxx_messageInfo_QuerySegmentInfoResponse.Merge(m, src)
+}
+func (m *QuerySegmentInfoResponse) XXX_Size() int {
+	return xxx_messageInfo_QuerySegmentInfoResponse.Size(m)
+}
+func (m *QuerySegmentInfoResponse) XXX_DiscardUnknown() {
+	xxx_messageInfo_QuerySegmentInfoResponse.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_QuerySegmentInfoResponse proto.InternalMessageInfo
+
+func (m *QuerySegmentInfoResponse) GetStatus() *commonpb.Status {
+	if m != nil {
+		return m.Status
+	}
+	return nil
+}
+
+func (m *QuerySegmentInfoResponse) GetInfos() []*QuerySegmentInfo {
+	if m != nil {
+		return m.Infos
+	}
+	return nil
+}
+
 type RegisterLinkResponse struct {
 	Address              *commonpb.Address `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
 	Status               *commonpb.Status  `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"`
@@ -2530,7 +2719,7 @@ func (m *RegisterLinkResponse) Reset()         { *m = RegisterLinkResponse{} }
 func (m *RegisterLinkResponse) String() string { return proto.CompactTextString(m) }
 func (*RegisterLinkResponse) ProtoMessage()    {}
 func (*RegisterLinkResponse) Descriptor() ([]byte, []int) {
-	return fileDescriptor_02345ba45cc0e303, []int{43}
+	return fileDescriptor_02345ba45cc0e303, []int{46}
 }
 
 func (m *RegisterLinkResponse) XXX_Unmarshal(b []byte) error {
@@ -2610,131 +2799,139 @@ func init() {
 	proto.RegisterType((*PersistentSegmentInfo)(nil), "milvus.proto.milvus.PersistentSegmentInfo")
 	proto.RegisterType((*PersistentSegmentInfoRequest)(nil), "milvus.proto.milvus.PersistentSegmentInfoRequest")
 	proto.RegisterType((*PersistentSegmentInfoResponse)(nil), "milvus.proto.milvus.PersistentSegmentInfoResponse")
+	proto.RegisterType((*QuerySegmentInfo)(nil), "milvus.proto.milvus.QuerySegmentInfo")
+	proto.RegisterType((*QuerySegmentInfoRequest)(nil), "milvus.proto.milvus.QuerySegmentInfoRequest")
+	proto.RegisterType((*QuerySegmentInfoResponse)(nil), "milvus.proto.milvus.QuerySegmentInfoResponse")
 	proto.RegisterType((*RegisterLinkResponse)(nil), "milvus.proto.milvus.RegisterLinkResponse")
 }
 
 func init() { proto.RegisterFile("milvus.proto", fileDescriptor_02345ba45cc0e303) }
 
 var fileDescriptor_02345ba45cc0e303 = []byte{
-	// 1879 bytes of a gzipped FileDescriptorProto
+	// 1964 bytes of a gzipped FileDescriptorProto
 	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x5a, 0xed, 0x6f, 0x1b, 0x49,
-	0x19, 0xcf, 0xd8, 0x8e, 0x93, 0x3c, 0x59, 0x3b, 0xce, 0x34, 0x2f, 0xae, 0xaf, 0xe5, 0xd2, 0x85,
-	0xbb, 0xa6, 0x2f, 0xd7, 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 0xff, 0xff, 0x0d, 0xe8, 0xd6, 0x03, 0x3a, 0x27, 0x00, 0x00,
 }
 
 // Reference imports to suppress errors if they are not otherwise used.
@@ -2772,6 +2969,7 @@ type MilvusServiceClient interface {
 	Flush(ctx context.Context, in *FlushRequest, opts ...grpc.CallOption) (*commonpb.Status, error)
 	GetDdChannel(ctx context.Context, in *commonpb.Empty, opts ...grpc.CallOption) (*StringResponse, error)
 	GetPersistentSegmentInfo(ctx context.Context, in *PersistentSegmentInfoRequest, opts ...grpc.CallOption) (*PersistentSegmentInfoResponse, error)
+	GetQuerySegmentInfo(ctx context.Context, in *QuerySegmentInfoRequest, opts ...grpc.CallOption) (*QuerySegmentInfoResponse, error)
 }
 
 type milvusServiceClient struct {
@@ -2989,6 +3187,15 @@ func (c *milvusServiceClient) GetPersistentSegmentInfo(ctx context.Context, in *
 	return out, nil
 }
 
+func (c *milvusServiceClient) GetQuerySegmentInfo(ctx context.Context, in *QuerySegmentInfoRequest, opts ...grpc.CallOption) (*QuerySegmentInfoResponse, error) {
+	out := new(QuerySegmentInfoResponse)
+	err := c.cc.Invoke(ctx, "/milvus.proto.milvus.MilvusService/GetQuerySegmentInfo", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
 // MilvusServiceServer is the server API for MilvusService service.
 type MilvusServiceServer interface {
 	CreateCollection(context.Context, *CreateCollectionRequest) (*commonpb.Status, error)
@@ -3014,6 +3221,7 @@ type MilvusServiceServer interface {
 	Flush(context.Context, *FlushRequest) (*commonpb.Status, error)
 	GetDdChannel(context.Context, *commonpb.Empty) (*StringResponse, error)
 	GetPersistentSegmentInfo(context.Context, *PersistentSegmentInfoRequest) (*PersistentSegmentInfoResponse, error)
+	GetQuerySegmentInfo(context.Context, *QuerySegmentInfoRequest) (*QuerySegmentInfoResponse, error)
 }
 
 // UnimplementedMilvusServiceServer can be embedded to have forward compatible implementations.
@@ -3089,6 +3297,9 @@ func (*UnimplementedMilvusServiceServer) GetDdChannel(ctx context.Context, req *
 func (*UnimplementedMilvusServiceServer) GetPersistentSegmentInfo(ctx context.Context, req *PersistentSegmentInfoRequest) (*PersistentSegmentInfoResponse, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method GetPersistentSegmentInfo not implemented")
 }
+func (*UnimplementedMilvusServiceServer) GetQuerySegmentInfo(ctx context.Context, req *QuerySegmentInfoRequest) (*QuerySegmentInfoResponse, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method GetQuerySegmentInfo not implemented")
+}
 
 func RegisterMilvusServiceServer(s *grpc.Server, srv MilvusServiceServer) {
 	s.RegisterService(&_MilvusService_serviceDesc, srv)
@@ -3508,6 +3719,24 @@ func _MilvusService_GetPersistentSegmentInfo_Handler(srv interface{}, ctx contex
 	return interceptor(ctx, in, info, handler)
 }
 
+func _MilvusService_GetQuerySegmentInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(QuerySegmentInfoRequest)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(MilvusServiceServer).GetQuerySegmentInfo(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/milvus.proto.milvus.MilvusService/GetQuerySegmentInfo",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(MilvusServiceServer).GetQuerySegmentInfo(ctx, req.(*QuerySegmentInfoRequest))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
 var _MilvusService_serviceDesc = grpc.ServiceDesc{
 	ServiceName: "milvus.proto.milvus.MilvusService",
 	HandlerType: (*MilvusServiceServer)(nil),
@@ -3604,6 +3833,10 @@ var _MilvusService_serviceDesc = grpc.ServiceDesc{
 			MethodName: "GetPersistentSegmentInfo",
 			Handler:    _MilvusService_GetPersistentSegmentInfo_Handler,
 		},
+		{
+			MethodName: "GetQuerySegmentInfo",
+			Handler:    _MilvusService_GetQuerySegmentInfo_Handler,
+		},
 	},
 	Streams:  []grpc.StreamDesc{},
 	Metadata: "milvus.proto",
diff --git a/internal/proxynode/impl.go b/internal/proxynode/impl.go
index d0c898e5b..33de45bda 100644
--- a/internal/proxynode/impl.go
+++ b/internal/proxynode/impl.go
@@ -7,6 +7,8 @@ import (
 	"strconv"
 	"time"
 
+	"github.com/zilliztech/milvus-distributed/internal/proto/querypb"
+
 	"github.com/zilliztech/milvus-distributed/internal/proto/datapb"
 
 	"github.com/zilliztech/milvus-distributed/internal/msgstream"
@@ -442,8 +444,10 @@ func (node *NodeImpl) GetIndexState(request *milvuspb.IndexStateRequest) (*milvu
 	ctx, cancel := context.WithTimeout(context.Background(), reqTimeoutInterval)
 	defer cancel()
 	dipt := &GetIndexStateTask{
-		Condition:         NewTaskCondition(ctx),
-		IndexStateRequest: request,
+		Condition:             NewTaskCondition(ctx),
+		IndexStateRequest:     request,
+		indexServiceClient:    node.indexServiceClient,
+		masterClientInterface: node.masterClient,
 	}
 
 	err := node.sched.DdQueue.Enqueue(dipt)
@@ -641,6 +645,51 @@ func (node *NodeImpl) GetPersistentSegmentInfo(req *milvuspb.PersistentSegmentIn
 	return resp, nil
 }
 
+func (node *NodeImpl) GetQuerySegmentInfo(req *milvuspb.QuerySegmentInfoRequest) (*milvuspb.QuerySegmentInfoResponse, error) {
+	resp := &milvuspb.QuerySegmentInfoResponse{
+		Status: &commonpb.Status{
+			ErrorCode: commonpb.ErrorCode_UNEXPECTED_ERROR,
+		},
+	}
+	segments, err := node.getSegmentsOfCollection(req.DbName, req.CollectionName)
+	if err != nil {
+		resp.Status.Reason = err.Error()
+		return resp, nil
+	}
+	infoResp, err := node.queryServiceClient.GetSegmentInfo(&querypb.SegmentInfoRequest{
+		Base: &commonpb.MsgBase{
+			MsgType:   commonpb.MsgType_kSegmentInfo,
+			MsgID:     0,
+			Timestamp: 0,
+			SourceID:  Params.ProxyID,
+		},
+		SegmentIDs: segments,
+	})
+	if err != nil {
+		resp.Status.Reason = err.Error()
+		return resp, nil
+	}
+	if infoResp.Status.ErrorCode != commonpb.ErrorCode_SUCCESS {
+		resp.Status.Reason = infoResp.Status.Reason
+		return resp, nil
+	}
+	queryInfos := make([]*milvuspb.QuerySegmentInfo, len(infoResp.Infos))
+	for i, info := range infoResp.Infos {
+		queryInfos[i] = &milvuspb.QuerySegmentInfo{
+			SegmentID:    info.SegmentID,
+			CollectionID: info.CollectionID,
+			PartitionID:  info.PartitionID,
+			NumRows:      info.NumRows,
+			MemSize:      info.MemSize,
+			IndexName:    info.IndexName,
+			IndexID:      info.IndexID,
+		}
+	}
+	resp.Status.ErrorCode = commonpb.ErrorCode_SUCCESS
+	resp.Infos = queryInfos
+	return resp, nil
+}
+
 func (node *NodeImpl) getSegmentsOfCollection(dbName string, collectionName string) ([]UniqueID, error) {
 	describeCollectionResponse, err := node.masterClient.DescribeCollection(&milvuspb.DescribeCollectionRequest{
 		Base: &commonpb.MsgBase{
diff --git a/internal/proxynode/insert_channels.go b/internal/proxynode/insert_channels.go
index 44b0dce3e..deda7ef03 100644
--- a/internal/proxynode/insert_channels.go
+++ b/internal/proxynode/insert_channels.go
@@ -83,7 +83,6 @@ type InsertChannelsMap struct {
 func (m *InsertChannelsMap) createInsertMsgStream(collID UniqueID, channels []string) error {
 	m.mtx.Lock()
 	defer m.mtx.Unlock()
-	factory := msgstream.ProtoUDFactory{}
 
 	_, ok := m.collectionID2InsertChannels[collID]
 	if ok {
@@ -101,9 +100,10 @@ func (m *InsertChannelsMap) createInsertMsgStream(collID UniqueID, channels []st
 	}
 	m.insertChannels = append(m.insertChannels, channels)
 	m.collectionID2InsertChannels[collID] = len(m.insertChannels) - 1
-	stream := pulsarms.NewPulsarMsgStream(context.Background(), Params.MsgStreamInsertBufSize, 1024, factory.NewUnmarshalDispatcher())
-	stream.SetPulsarClient(Params.PulsarAddress)
-	stream.CreatePulsarProducers(channels)
+
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.MsgStreamInsertBufSize, 1024)
+	stream, _ := factory.NewMsgStream(context.Background())
+	stream.AsProducer(channels)
 	repack := func(tsMsgs []msgstream.TsMsg, hashKeys [][]int32) (map[int32]*msgstream.MsgPack, error) {
 		return insertRepackFunc(tsMsgs, hashKeys, m.nodeInstance.segAssigner, true)
 	}
diff --git a/internal/proxynode/interface.go b/internal/proxynode/interface.go
index d7f8b048b..fcb44aa13 100644
--- a/internal/proxynode/interface.go
+++ b/internal/proxynode/interface.go
@@ -23,6 +23,7 @@ type MasterClient interface {
 	CreateIndex(in *milvuspb.CreateIndexRequest) (*commonpb.Status, error)
 	DescribeIndex(in *milvuspb.DescribeIndexRequest) (*milvuspb.DescribeIndexResponse, error)
 	ShowSegments(in *milvuspb.ShowSegmentRequest) (*milvuspb.ShowSegmentResponse, error)
+	DescribeSegment(in *milvuspb.DescribeSegmentRequest) (*milvuspb.DescribeSegmentResponse, error)
 }
 
 type IndexServiceClient interface {
@@ -43,6 +44,7 @@ type QueryServiceClient interface {
 	//GetSearchChannelNames() ([]string, error)
 	//GetSearchResultChannels() ([]string, error)
 	GetComponentStates() (*internalpb2.ComponentStates, error)
+	GetSegmentInfo(req *querypb.SegmentInfoRequest) (*querypb.SegmentInfoResponse, error)
 }
 
 type DataServiceClient interface {
@@ -94,4 +96,7 @@ type ProxyNode interface {
 	Flush(request *milvuspb.FlushRequest) (*commonpb.Status, error)
 
 	GetDdChannel(request *commonpb.Empty) (*milvuspb.StringResponse, error)
+
+	GetQuerySegmentInfo(req *milvuspb.QuerySegmentInfoRequest) (*milvuspb.QuerySegmentInfoResponse, error)
+	GetPersistentSegmentInfo(req *milvuspb.PersistentSegmentInfoRequest) (*milvuspb.PersistentSegmentInfoResponse, error)
 }
diff --git a/internal/proxynode/proxy_node.go b/internal/proxynode/proxy_node.go
index 8b00c66c6..ee999d4d2 100644
--- a/internal/proxynode/proxy_node.go
+++ b/internal/proxynode/proxy_node.go
@@ -54,8 +54,8 @@ type NodeImpl struct {
 	tsoAllocator *allocator.TimestampAllocator
 	segAssigner  *SegIDAssigner
 
-	manipulationMsgStream *pulsarms.PulsarMsgStream
-	queryMsgStream        *pulsarms.PulsarMsgStream
+	manipulationMsgStream msgstream.MsgStream
+	queryMsgStream        msgstream.MsgStream
 
 	tracer opentracing.Tracer
 	closer io.Closer
@@ -106,7 +106,7 @@ func (node *NodeImpl) waitForServiceReady(service Component, serviceName string)
 }
 
 func (node *NodeImpl) Init() error {
-	factory := msgstream.ProtoUDFactory{}
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.MsgStreamSearchBufSize, 1024)
 
 	// todo wait for proxyservice state changed to Healthy
 
@@ -195,11 +195,8 @@ func (node *NodeImpl) Init() error {
 	}
 	opentracing.SetGlobalTracer(node.tracer)
 
-	pulsarAddress := Params.PulsarAddress
-
-	node.queryMsgStream = pulsarms.NewPulsarMsgStream(node.ctx, Params.MsgStreamSearchBufSize, 1024, factory.NewUnmarshalDispatcher())
-	node.queryMsgStream.SetPulsarClient(pulsarAddress)
-	node.queryMsgStream.CreatePulsarProducers(Params.SearchChannelNames)
+	node.queryMsgStream, _ = factory.NewMsgStream(node.ctx)
+	node.queryMsgStream.AsProducer(Params.SearchChannelNames)
 	log.Println("create query message stream ...")
 
 	masterAddr := Params.MasterAddress
@@ -225,9 +222,8 @@ func (node *NodeImpl) Init() error {
 	node.segAssigner = segAssigner
 	node.segAssigner.PeerID = Params.ProxyID
 
-	node.manipulationMsgStream = pulsarms.NewPulsarMsgStream(node.ctx, Params.MsgStreamInsertBufSize, 1024, factory.NewUnmarshalDispatcher())
-	node.manipulationMsgStream.SetPulsarClient(pulsarAddress)
-	node.manipulationMsgStream.CreatePulsarProducers(Params.InsertChannelNames)
+	node.manipulationMsgStream, _ = factory.NewMsgStream(node.ctx)
+	node.manipulationMsgStream.AsProducer(Params.InsertChannelNames)
 	repackFuncImpl := func(tsMsgs []msgstream.TsMsg, hashKeys [][]int32) (map[int32]*msgstream.MsgPack, error) {
 		return insertRepackFunc(tsMsgs, hashKeys, node.segAssigner, true)
 	}
diff --git a/internal/proxynode/task.go b/internal/proxynode/task.go
index f29de8e2c..5ef991f8f 100644
--- a/internal/proxynode/task.go
+++ b/internal/proxynode/task.go
@@ -6,12 +6,13 @@ import (
 	"math"
 	"strconv"
 
+	"github.com/zilliztech/milvus-distributed/internal/proto/indexpb"
+
 	"github.com/zilliztech/milvus-distributed/internal/proto/datapb"
 
 	"github.com/golang/protobuf/proto"
 	"github.com/zilliztech/milvus-distributed/internal/allocator"
 	"github.com/zilliztech/milvus-distributed/internal/msgstream"
-	"github.com/zilliztech/milvus-distributed/internal/msgstream/pulsarms"
 	"github.com/zilliztech/milvus-distributed/internal/proto/commonpb"
 	"github.com/zilliztech/milvus-distributed/internal/proto/internalpb2"
 	"github.com/zilliztech/milvus-distributed/internal/proto/milvuspb"
@@ -410,7 +411,7 @@ func (dct *DropCollectionTask) PostExecute() error {
 type SearchTask struct {
 	Condition
 	internalpb2.SearchRequest
-	queryMsgStream *pulsarms.PulsarMsgStream
+	queryMsgStream msgstream.MsgStream
 	resultBuf      chan []*internalpb2.SearchResults
 	result         *milvuspb.SearchResults
 	query          *milvuspb.SearchRequest
@@ -1285,8 +1286,9 @@ func (dit *DescribeIndexTask) PostExecute() error {
 type GetIndexStateTask struct {
 	Condition
 	*milvuspb.IndexStateRequest
-	indexServiceClient IndexServiceClient
-	result             *milvuspb.IndexStateResponse
+	indexServiceClient    IndexServiceClient
+	masterClientInterface MasterClient
+	result                *milvuspb.IndexStateResponse
 }
 
 func (dipt *GetIndexStateTask) OnEnqueue() error {
@@ -1336,17 +1338,98 @@ func (dipt *GetIndexStateTask) PreExecute() error {
 }
 
 func (dipt *GetIndexStateTask) Execute() error {
-	// TODO: use index service client
-	//var err error
-	//dipt.result, err = dipt.masterClient.GetIndexState(dipt.IndexStateRequest)
-	//return err
+	collectionName := dipt.CollectionName
+	collectionID, err := globalMetaCache.GetCollectionID(collectionName)
+	if err != nil { // err is not nil if collection not exists
+		return err
+	}
+
+	showPartitionRequest := &milvuspb.ShowPartitionRequest{
+		Base: &commonpb.MsgBase{
+			MsgType:   commonpb.MsgType_kShowPartitions,
+			MsgID:     dipt.Base.MsgID,
+			Timestamp: dipt.Base.Timestamp,
+			SourceID:  Params.ProxyID,
+		},
+		DbName:         dipt.DbName,
+		CollectionName: collectionName,
+		CollectionID:   collectionID,
+	}
+	partitions, err := dipt.masterClientInterface.ShowPartitions(showPartitionRequest)
+	if err != nil {
+		return err
+	}
+
+	for _, partitionID := range partitions.PartitionIDs {
+		showSegmentsRequest := &milvuspb.ShowSegmentRequest{
+			Base: &commonpb.MsgBase{
+				MsgType:   commonpb.MsgType_kShowSegment,
+				MsgID:     dipt.Base.MsgID,
+				Timestamp: dipt.Base.Timestamp,
+				SourceID:  Params.ProxyID,
+			},
+			CollectionID: collectionID,
+			PartitionID:  partitionID,
+		}
+		segments, err := dipt.masterClientInterface.ShowSegments(showSegmentsRequest)
+		if err != nil {
+			return err
+		}
+
+		getIndexStatesRequest := &indexpb.IndexStatesRequest{
+			IndexBuildIDs: make([]UniqueID, 0),
+		}
+		for _, segmentID := range segments.SegmentIDs {
+			describeSegmentRequest := &milvuspb.DescribeSegmentRequest{
+				Base: &commonpb.MsgBase{
+					MsgType:   commonpb.MsgType_kDescribeSegment,
+					MsgID:     dipt.Base.MsgID,
+					Timestamp: dipt.Base.Timestamp,
+					SourceID:  Params.ProxyID,
+				},
+				CollectionID: collectionID,
+				SegmentID:    segmentID,
+			}
+			segmentDesc, err := dipt.masterClientInterface.DescribeSegment(describeSegmentRequest)
+			if err != nil {
+				return err
+			}
+
+			getIndexStatesRequest.IndexBuildIDs = append(getIndexStatesRequest.IndexBuildIDs, segmentDesc.BuildID)
+		}
+
+		states, err := dipt.indexServiceClient.GetIndexStates(getIndexStatesRequest)
+		if err != nil {
+			return err
+		}
+
+		if states.Status.ErrorCode != commonpb.ErrorCode_SUCCESS {
+			dipt.result = &milvuspb.IndexStateResponse{
+				Status: states.Status,
+				State:  commonpb.IndexState_FAILED,
+			}
+			return nil
+		}
+
+		for _, state := range states.States {
+			if state.State != commonpb.IndexState_FINISHED {
+				dipt.result = &milvuspb.IndexStateResponse{
+					Status: states.Status,
+					State:  state.State,
+				}
+				return nil
+			}
+		}
+	}
+
 	dipt.result = &milvuspb.IndexStateResponse{
 		Status: &commonpb.Status{
-			ErrorCode: 0,
+			ErrorCode: commonpb.ErrorCode_SUCCESS,
 			Reason:    "",
 		},
 		State: commonpb.IndexState_FINISHED,
 	}
+
 	return nil
 }
 
diff --git a/internal/proxynode/task_scheduler.go b/internal/proxynode/task_scheduler.go
index 6a61633cc..24cbc5771 100644
--- a/internal/proxynode/task_scheduler.go
+++ b/internal/proxynode/task_scheduler.go
@@ -371,11 +371,10 @@ func (sched *TaskScheduler) queryLoop() {
 
 func (sched *TaskScheduler) queryResultLoop() {
 	defer sched.wg.Done()
-	factory := msgstream.ProtoUDFactory{}
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.MsgStreamSearchResultBufSize, 1024)
 
-	queryResultMsgStream := pulsarms.NewPulsarMsgStream(sched.ctx, Params.MsgStreamSearchResultBufSize, 1024, factory.NewUnmarshalDispatcher())
-	queryResultMsgStream.SetPulsarClient(Params.PulsarAddress)
-	queryResultMsgStream.CreatePulsarConsumers(Params.SearchResultChannelNames,
+	queryResultMsgStream, _ := factory.NewMsgStream(sched.ctx)
+	queryResultMsgStream.AsConsumer(Params.SearchResultChannelNames,
 		Params.ProxySubName)
 	queryNodeNum := Params.QueryNodeNum
 
diff --git a/internal/proxynode/timetick.go b/internal/proxynode/timetick.go
index 8153c8633..30861feb2 100644
--- a/internal/proxynode/timetick.go
+++ b/internal/proxynode/timetick.go
@@ -26,7 +26,7 @@ type timeTick struct {
 	pulsarProducer pulsar.Producer
 
 	tsoAllocator  *allocator.TimestampAllocator
-	tickMsgStream *pulsarms.PulsarMsgStream
+	tickMsgStream msgstream.MsgStream
 
 	peerID    UniqueID
 	wg        sync.WaitGroup
@@ -51,12 +51,9 @@ func newTimeTick(ctx context.Context,
 		checkFunc:    checkFunc,
 	}
 
-	factory := msgstream.ProtoUDFactory{}
-	t.tickMsgStream = pulsarms.NewPulsarMsgStream(t.ctx, Params.MsgStreamTimeTickBufSize, 1024, factory.NewUnmarshalDispatcher())
-	pulsarAddress := Params.PulsarAddress
-
-	t.tickMsgStream.SetPulsarClient(pulsarAddress)
-	t.tickMsgStream.CreatePulsarProducers(Params.ProxyTimeTickChannelNames)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.MsgStreamTimeTickBufSize, 1024)
+	t.tickMsgStream, _ = factory.NewMsgStream(t.ctx)
+	t.tickMsgStream.AsProducer(Params.ProxyTimeTickChannelNames)
 	return t
 }
 
diff --git a/internal/proxyservice/impl.go b/internal/proxyservice/impl.go
index d4951c28e..f03afa130 100644
--- a/internal/proxyservice/impl.go
+++ b/internal/proxyservice/impl.go
@@ -10,7 +10,6 @@ import (
 	"strconv"
 	"time"
 
-	"github.com/zilliztech/milvus-distributed/internal/msgstream"
 	"github.com/zilliztech/milvus-distributed/internal/msgstream/pulsarms"
 
 	"github.com/zilliztech/milvus-distributed/internal/proto/commonpb"
@@ -96,7 +95,7 @@ func (s *ServiceImpl) fillNodeInitParams() error {
 }
 
 func (s *ServiceImpl) Init() error {
-	dispatcherFactory := msgstream.ProtoUDFactory{}
+	factory := pulsarms.NewFactory(Params.PulsarAddress, 1024, 1024)
 
 	err := s.fillNodeInitParams()
 	if err != nil {
@@ -104,9 +103,8 @@ func (s *ServiceImpl) Init() error {
 	}
 	log.Println("fill node init params ...")
 
-	serviceTimeTickMsgStream := pulsarms.NewPulsarTtMsgStream(s.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	serviceTimeTickMsgStream.SetPulsarClient(Params.PulsarAddress)
-	serviceTimeTickMsgStream.CreatePulsarProducers([]string{Params.ServiceTimeTickChannel})
+	serviceTimeTickMsgStream, _ := factory.NewTtMsgStream(s.ctx)
+	serviceTimeTickMsgStream.AsProducer([]string{Params.ServiceTimeTickChannel})
 	log.Println("create service time tick producer channel: ", []string{Params.ServiceTimeTickChannel})
 
 	channels := make([]string, Params.InsertChannelNum)
@@ -114,14 +112,12 @@ func (s *ServiceImpl) Init() error {
 	for ; i < Params.InsertChannelNum; i++ {
 		channels[i] = Params.InsertChannelPrefixName + strconv.FormatInt(i, 10)
 	}
-	insertTickMsgStream := pulsarms.NewPulsarMsgStream(s.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	insertTickMsgStream.SetPulsarClient(Params.PulsarAddress)
-	insertTickMsgStream.CreatePulsarProducers(channels)
+	insertTickMsgStream, _ := factory.NewMsgStream(s.ctx)
+	insertTickMsgStream.AsProducer(channels)
 	log.Println("create service time tick producer channel: ", channels)
 
-	nodeTimeTickMsgStream := pulsarms.NewPulsarMsgStream(s.ctx, 1024, 1024, dispatcherFactory.NewUnmarshalDispatcher())
-	nodeTimeTickMsgStream.SetPulsarClient(Params.PulsarAddress)
-	nodeTimeTickMsgStream.CreatePulsarConsumers(Params.NodeTimeTickChannel,
+	nodeTimeTickMsgStream, _ := factory.NewMsgStream(s.ctx)
+	nodeTimeTickMsgStream.AsConsumer(Params.NodeTimeTickChannel,
 		"proxyservicesub") // TODO: add config
 	log.Println("create node time tick consumer channel: ", Params.NodeTimeTickChannel)
 
diff --git a/internal/querynode/data_sync_service_test.go b/internal/querynode/data_sync_service_test.go
index b8cd27b7a..dc961aa87 100644
--- a/internal/querynode/data_sync_service_test.go
+++ b/internal/querynode/data_sync_service_test.go
@@ -109,14 +109,12 @@ func TestDataSyncService_Start(t *testing.T) {
 	ddChannels := Params.DDChannelNames
 	pulsarURL := Params.PulsarAddress
 
-	factory := msgstream.ProtoUDFactory{}
-	insertStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(pulsarURL)
-	insertStream.CreatePulsarProducers(insertChannels)
-
-	ddStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(pulsarURL)
-	ddStream.CreatePulsarProducers(ddChannels)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	insertStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	insertStream.AsProducer(insertChannels)
+
+	ddStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	ddStream.AsProducer(ddChannels)
 
 	var insertMsgStream msgstream.MsgStream = insertStream
 	insertMsgStream.Start()
diff --git a/internal/querynode/flow_graph_msg_stream_input_nodes.go b/internal/querynode/flow_graph_msg_stream_input_nodes.go
index 046d411ad..0d229606b 100644
--- a/internal/querynode/flow_graph_msg_stream_input_nodes.go
+++ b/internal/querynode/flow_graph_msg_stream_input_nodes.go
@@ -9,18 +9,13 @@ import (
 )
 
 func (dsService *dataSyncService) newDmInputNode(ctx context.Context) *flowgraph.InputNode {
-	factory := msgstream.ProtoUDFactory{}
-	receiveBufSize := Params.InsertReceiveBufSize
-	pulsarBufSize := Params.InsertPulsarBufSize
-
-	msgStreamURL := Params.PulsarAddress
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.InsertReceiveBufSize, Params.InsertPulsarBufSize)
 
 	consumeChannels := Params.InsertChannelNames
 	consumeSubName := Params.MsgChannelSubName
 
-	insertStream := pulsarms.NewPulsarTtMsgStream(ctx, receiveBufSize, pulsarBufSize, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(msgStreamURL)
-	insertStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	insertStream, _ := factory.NewTtMsgStream(ctx)
+	insertStream.AsConsumer(consumeChannels, consumeSubName)
 
 	var stream msgstream.MsgStream = insertStream
 	dsService.dmStream = stream
@@ -33,18 +28,13 @@ func (dsService *dataSyncService) newDmInputNode(ctx context.Context) *flowgraph
 }
 
 func (dsService *dataSyncService) newDDInputNode(ctx context.Context) *flowgraph.InputNode {
-	factory := msgstream.ProtoUDFactory{}
-	receiveBufSize := Params.DDReceiveBufSize
-	pulsarBufSize := Params.DDPulsarBufSize
-
-	msgStreamURL := Params.PulsarAddress
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.DDReceiveBufSize, Params.DDPulsarBufSize)
 
 	consumeChannels := Params.DDChannelNames
 	consumeSubName := Params.MsgChannelSubName
 
-	ddStream := pulsarms.NewPulsarTtMsgStream(ctx, receiveBufSize, pulsarBufSize, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(msgStreamURL)
-	ddStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	ddStream, _ := factory.NewTtMsgStream(ctx)
+	ddStream.AsConsumer(consumeChannels, consumeSubName)
 
 	var stream msgstream.MsgStream = ddStream
 	dsService.ddStream = stream
diff --git a/internal/querynode/flow_graph_service_time_node.go b/internal/querynode/flow_graph_service_time_node.go
index 4ee39a8d7..651be6fbc 100644
--- a/internal/querynode/flow_graph_service_time_node.go
+++ b/internal/querynode/flow_graph_service_time_node.go
@@ -13,7 +13,7 @@ import (
 type serviceTimeNode struct {
 	baseNode
 	replica           collectionReplica
-	timeTickMsgStream *pulsarms.PulsarMsgStream
+	timeTickMsgStream msgstream.MsgStream
 }
 
 func (stNode *serviceTimeNode) Name() string {
@@ -78,10 +78,9 @@ func newServiceTimeNode(ctx context.Context, replica collectionReplica) *service
 	baseNode.SetMaxQueueLength(maxQueueLength)
 	baseNode.SetMaxParallelism(maxParallelism)
 
-	factory := msgstream.ProtoUDFactory{}
-	timeTimeMsgStream := pulsarms.NewPulsarMsgStream(ctx, Params.SearchReceiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	timeTimeMsgStream.SetPulsarClient(Params.PulsarAddress)
-	timeTimeMsgStream.CreatePulsarProducers([]string{Params.QueryTimeTickChannelName})
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.SearchReceiveBufSize, 1024)
+	timeTimeMsgStream, _ := factory.NewMsgStream(ctx)
+	timeTimeMsgStream.AsProducer([]string{Params.QueryTimeTickChannelName})
 
 	return &serviceTimeNode{
 		baseNode:          baseNode,
diff --git a/internal/querynode/load_service_test.go b/internal/querynode/load_service_test.go
index 5e00e4f09..4bcd10052 100644
--- a/internal/querynode/load_service_test.go
+++ b/internal/querynode/load_service_test.go
@@ -130,10 +130,10 @@ import (
 //
 //	insertStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	insertStream.SetPulsarClient(Params.PulsarAddress)
-//	insertStream.CreatePulsarProducers(insertChannels)
+//	insertStream.AsProducer(insertChannels)
 //	ddStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	ddStream.SetPulsarClient(Params.PulsarAddress)
-//	ddStream.CreatePulsarProducers(ddChannels)
+//	ddStream.AsProducer(ddChannels)
 //
 //	var insertMsgStream msgstream.MsgStream = insertStream
 //	insertMsgStream.Start()
@@ -206,7 +206,7 @@ import (
 //	}
 //	searchStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	searchStream.SetPulsarClient(Params.PulsarAddress)
-//	searchStream.CreatePulsarProducers(newSearchChannelNames)
+//	searchStream.AsProducer(newSearchChannelNames)
 //	searchStream.Start()
 //	err = searchStream.Produce(fn(1))
 //	assert.NoError(t, err)
@@ -215,7 +215,7 @@ import (
 //	searchResultStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	searchResultStream.SetPulsarClient(Params.PulsarAddress)
 //	unmarshalDispatcher := util.NewUnmarshalDispatcher()
-//	searchResultStream.CreatePulsarConsumers(newSearchResultChannelNames, "loadIndexTestSubSearchResult", unmarshalDispatcher, receiveBufSize)
+//	searchResultStream.AsConsumer(newSearchResultChannelNames, "loadIndexTestSubSearchResult", unmarshalDispatcher, receiveBufSize)
 //	searchResultStream.Start()
 //	searchResult := searchResultStream.Consume()
 //	assert.NotNil(t, searchResult)
@@ -295,7 +295,7 @@ import (
 //	// init message stream consumer and do checks
 //	statsMs := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, Params.StatsReceiveBufSize)
 //	statsMs.SetPulsarClient(Params.PulsarAddress)
-//	statsMs.CreatePulsarConsumers([]string{Params.StatsChannelName}, Params.MsgChannelSubName, util.NewUnmarshalDispatcher(), Params.StatsReceiveBufSize)
+//	statsMs.AsConsumer([]string{Params.StatsChannelName}, Params.MsgChannelSubName, util.NewUnmarshalDispatcher(), Params.StatsReceiveBufSize)
 //	statsMs.Start()
 //
 //	findFiledStats := false
@@ -464,10 +464,10 @@ import (
 //
 //	insertStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	insertStream.SetPulsarClient(Params.PulsarAddress)
-//	insertStream.CreatePulsarProducers(insertChannels)
+//	insertStream.AsProducer(insertChannels)
 //	ddStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	ddStream.SetPulsarClient(Params.PulsarAddress)
-//	ddStream.CreatePulsarProducers(ddChannels)
+//	ddStream.AsProducer(ddChannels)
 //
 //	var insertMsgStream msgstream.MsgStream = insertStream
 //	insertMsgStream.Start()
@@ -529,7 +529,7 @@ import (
 //	}
 //	searchStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	searchStream.SetPulsarClient(Params.PulsarAddress)
-//	searchStream.CreatePulsarProducers(newSearchChannelNames)
+//	searchStream.AsProducer(newSearchChannelNames)
 //	searchStream.Start()
 //	err = searchStream.Produce(fn(1))
 //	assert.NoError(t, err)
@@ -538,7 +538,7 @@ import (
 //	searchResultStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize)
 //	searchResultStream.SetPulsarClient(Params.PulsarAddress)
 //	unmarshalDispatcher := util.NewUnmarshalDispatcher()
-//	searchResultStream.CreatePulsarConsumers(newSearchResultChannelNames, "loadIndexTestSubSearchResult2", unmarshalDispatcher, receiveBufSize)
+//	searchResultStream.AsConsumer(newSearchResultChannelNames, "loadIndexTestSubSearchResult2", unmarshalDispatcher, receiveBufSize)
 //	searchResultStream.Start()
 //	searchResult := searchResultStream.Consume()
 //	assert.NotNil(t, searchResult)
@@ -612,7 +612,7 @@ import (
 //	// init message stream consumer and do checks
 //	statsMs := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, Params.StatsReceiveBufSize)
 //	statsMs.SetPulsarClient(Params.PulsarAddress)
-//	statsMs.CreatePulsarConsumers([]string{Params.StatsChannelName}, Params.MsgChannelSubName, util.NewUnmarshalDispatcher(), Params.StatsReceiveBufSize)
+//	statsMs.AsConsumer([]string{Params.StatsChannelName}, Params.MsgChannelSubName, util.NewUnmarshalDispatcher(), Params.StatsReceiveBufSize)
 //	statsMs.Start()
 //
 //	findFiledStats := false
@@ -1016,15 +1016,13 @@ func doInsert(ctx context.Context, collectionID UniqueID, partitionID UniqueID,
 	ddChannels := Params.DDChannelNames
 	pulsarURL := Params.PulsarAddress
 
-	factory := msgstream.ProtoUDFactory{}
-	insertStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(pulsarURL)
-	insertStream.CreatePulsarProducers(insertChannels)
-	insertStream.CreatePulsarConsumers(insertChannels, Params.MsgChannelSubName)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	insertStream, _ := factory.NewMsgStream(ctx)
+	insertStream.AsProducer(insertChannels)
+	insertStream.AsConsumer(insertChannels, Params.MsgChannelSubName)
 
-	ddStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(pulsarURL)
-	ddStream.CreatePulsarProducers(ddChannels)
+	ddStream, _ := factory.NewMsgStream(ctx)
+	ddStream.AsProducer(ddChannels)
 
 	var insertMsgStream msgstream.MsgStream = insertStream
 	insertMsgStream.Start()
@@ -1076,15 +1074,13 @@ func sentTimeTick(ctx context.Context) error {
 	ddChannels := Params.DDChannelNames
 	pulsarURL := Params.PulsarAddress
 
-	factory := msgstream.ProtoUDFactory{}
-	insertStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(pulsarURL)
-	insertStream.CreatePulsarProducers(insertChannels)
-	insertStream.CreatePulsarConsumers(insertChannels, Params.MsgChannelSubName)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	insertStream, _ := factory.NewMsgStream(ctx)
+	insertStream.AsProducer(insertChannels)
+	insertStream.AsConsumer(insertChannels, Params.MsgChannelSubName)
 
-	ddStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(pulsarURL)
-	ddStream.CreatePulsarProducers(ddChannels)
+	ddStream, _ := factory.NewMsgStream(ctx)
+	ddStream.AsProducer(ddChannels)
 
 	var insertMsgStream msgstream.MsgStream = insertStream
 	insertMsgStream.Start()
diff --git a/internal/querynode/query_node.go b/internal/querynode/query_node.go
index 191dab46e..ff9545780 100644
--- a/internal/querynode/query_node.go
+++ b/internal/querynode/query_node.go
@@ -333,11 +333,11 @@ func (node *QueryNode) AddQueryChannel(in *queryPb.AddQueryChannelsRequest) (*co
 	// add request channel
 	consumeChannels := []string{in.RequestChannelID}
 	consumeSubName := Params.MsgChannelSubName
-	searchStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	searchStream.AsConsumer(consumeChannels, consumeSubName)
 
 	// add result channel
 	producerChannels := []string{in.ResultChannelID}
-	resultStream.CreatePulsarProducers(producerChannels)
+	resultStream.AsProducer(producerChannels)
 
 	status := &commonpb.Status{
 		ErrorCode: commonpb.ErrorCode_SUCCESS,
@@ -382,12 +382,12 @@ func (node *QueryNode) RemoveQueryChannel(in *queryPb.RemoveQueryChannelsRequest
 	consumeChannels := []string{in.RequestChannelID}
 	consumeSubName := Params.MsgChannelSubName
 	// TODO: searchStream.RemovePulsarConsumers(producerChannels)
-	searchStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	searchStream.AsConsumer(consumeChannels, consumeSubName)
 
 	// remove result channel
 	producerChannels := []string{in.ResultChannelID}
 	// TODO: resultStream.RemovePulsarProducer(producerChannels)
-	resultStream.CreatePulsarProducers(producerChannels)
+	resultStream.AsProducer(producerChannels)
 
 	status := &commonpb.Status{
 		ErrorCode: commonpb.ErrorCode_SUCCESS,
@@ -420,7 +420,7 @@ func (node *QueryNode) WatchDmChannels(in *queryPb.WatchDmChannelsRequest) (*com
 	// add request channel
 	consumeChannels := in.ChannelIDs
 	consumeSubName := Params.MsgChannelSubName
-	fgDMMsgStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	fgDMMsgStream.AsConsumer(consumeChannels, consumeSubName)
 
 	status := &commonpb.Status{
 		ErrorCode: commonpb.ErrorCode_SUCCESS,
diff --git a/internal/querynode/search_service.go b/internal/querynode/search_service.go
index 217a2c881..c44e9406d 100644
--- a/internal/querynode/search_service.go
+++ b/internal/querynode/search_service.go
@@ -47,19 +47,17 @@ func newSearchService(ctx context.Context, replica collectionReplica) *searchSer
 
 	msgStreamURL := Params.PulsarAddress
 
-	factory := msgstream.ProtoUDFactory{}
+	factory := pulsarms.NewFactory(msgStreamURL, receiveBufSize, pulsarBufSize)
 
 	consumeChannels := Params.SearchChannelNames
 	consumeSubName := Params.MsgChannelSubName
-	searchStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, pulsarBufSize, factory.NewUnmarshalDispatcher())
-	searchStream.SetPulsarClient(msgStreamURL)
-	searchStream.CreatePulsarConsumers(consumeChannels, consumeSubName)
+	searchStream, _ := factory.NewMsgStream(ctx)
+	searchStream.AsConsumer(consumeChannels, consumeSubName)
 	var inputStream msgstream.MsgStream = searchStream
 
 	producerChannels := Params.SearchResultChannelNames
-	searchResultStream := pulsarms.NewPulsarMsgStream(ctx, receiveBufSize, pulsarBufSize, factory.NewUnmarshalDispatcher())
-	searchResultStream.SetPulsarClient(msgStreamURL)
-	searchResultStream.CreatePulsarProducers(producerChannels)
+	searchResultStream, _ := factory.NewMsgStream(ctx)
+	searchResultStream.AsProducer(producerChannels)
 	var outputStream msgstream.MsgStream = searchResultStream
 
 	searchServiceCtx, searchServiceCancel := context.WithCancel(ctx)
diff --git a/internal/querynode/search_service_test.go b/internal/querynode/search_service_test.go
index 759d4e23b..ca33a0ffc 100644
--- a/internal/querynode/search_service_test.go
+++ b/internal/querynode/search_service_test.go
@@ -93,10 +93,9 @@ func TestSearch_Search(t *testing.T) {
 	msgPackSearch := msgstream.MsgPack{}
 	msgPackSearch.Msgs = append(msgPackSearch.Msgs, searchMsg)
 
-	factory := msgstream.ProtoUDFactory{}
-	searchStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	searchStream.SetPulsarClient(pulsarURL)
-	searchStream.CreatePulsarProducers(searchProducerChannels)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	searchStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	searchStream.AsProducer(searchProducerChannels)
 	searchStream.Start()
 	err = searchStream.Produce(&msgPackSearch)
 	assert.NoError(t, err)
@@ -180,13 +179,11 @@ func TestSearch_Search(t *testing.T) {
 	insertChannels := Params.InsertChannelNames
 	ddChannels := Params.DDChannelNames
 
-	insertStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(pulsarURL)
-	insertStream.CreatePulsarProducers(insertChannels)
+	insertStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	insertStream.AsProducer(insertChannels)
 
-	ddStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(pulsarURL)
-	ddStream.CreatePulsarProducers(ddChannels)
+	ddStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	ddStream.AsProducer(ddChannels)
 
 	var insertMsgStream msgstream.MsgStream = insertStream
 	insertMsgStream.Start()
@@ -286,10 +283,9 @@ func TestSearch_SearchMultiSegments(t *testing.T) {
 	msgPackSearch := msgstream.MsgPack{}
 	msgPackSearch.Msgs = append(msgPackSearch.Msgs, searchMsg)
 
-	factory := msgstream.ProtoUDFactory{}
-	searchStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	searchStream.SetPulsarClient(pulsarURL)
-	searchStream.CreatePulsarProducers(searchProducerChannels)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	searchStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	searchStream.AsProducer(searchProducerChannels)
 	searchStream.Start()
 	err = searchStream.Produce(&msgPackSearch)
 	assert.NoError(t, err)
@@ -377,13 +373,11 @@ func TestSearch_SearchMultiSegments(t *testing.T) {
 	insertChannels := Params.InsertChannelNames
 	ddChannels := Params.DDChannelNames
 
-	insertStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	insertStream.SetPulsarClient(pulsarURL)
-	insertStream.CreatePulsarProducers(insertChannels)
+	insertStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	insertStream.AsProducer(insertChannels)
 
-	ddStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	ddStream.SetPulsarClient(pulsarURL)
-	ddStream.CreatePulsarProducers(ddChannels)
+	ddStream, _ := factory.NewMsgStream(node.queryNodeLoopCtx)
+	ddStream.AsProducer(ddChannels)
 
 	var insertMsgStream msgstream.MsgStream = insertStream
 	insertMsgStream.Start()
diff --git a/internal/querynode/stats_service.go b/internal/querynode/stats_service.go
index 872476ae9..9608128e8 100644
--- a/internal/querynode/stats_service.go
+++ b/internal/querynode/stats_service.go
@@ -36,16 +36,13 @@ func newStatsService(ctx context.Context, replica collectionReplica, fieldStatsC
 
 func (sService *statsService) start() {
 	sleepTimeInterval := Params.StatsPublishInterval
-	receiveBufSize := Params.StatsReceiveBufSize
 
 	// start pulsar
-	msgStreamURL := Params.PulsarAddress
 	producerChannels := []string{Params.StatsChannelName}
 
-	factory := msgstream.ProtoUDFactory{}
-	statsStream := pulsarms.NewPulsarMsgStream(sService.ctx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	statsStream.SetPulsarClient(msgStreamURL)
-	statsStream.CreatePulsarProducers(producerChannels)
+	factory := pulsarms.NewFactory(Params.PulsarAddress, Params.StatsReceiveBufSize, 1024)
+	statsStream, _ := factory.NewMsgStream(sService.ctx)
+	statsStream.AsProducer(producerChannels)
 
 	var statsMsgStream msgstream.MsgStream = statsStream
 
diff --git a/internal/querynode/stats_service_test.go b/internal/querynode/stats_service_test.go
index 0ddfef1d5..d21230fd0 100644
--- a/internal/querynode/stats_service_test.go
+++ b/internal/querynode/stats_service_test.go
@@ -3,6 +3,7 @@ package querynode
 import (
 	"testing"
 
+	"github.com/stretchr/testify/assert"
 	"github.com/zilliztech/milvus-distributed/internal/msgstream"
 	"github.com/zilliztech/milvus-distributed/internal/msgstream/pulsarms"
 )
@@ -26,11 +27,10 @@ func TestSegmentManagement_sendSegmentStatistic(t *testing.T) {
 	producerChannels := []string{Params.StatsChannelName}
 
 	pulsarURL := Params.PulsarAddress
-
-	factory := msgstream.ProtoUDFactory{}
-	statsStream := pulsarms.NewPulsarMsgStream(node.queryNodeLoopCtx, receiveBufSize, 1024, factory.NewUnmarshalDispatcher())
-	statsStream.SetPulsarClient(pulsarURL)
-	statsStream.CreatePulsarProducers(producerChannels)
+	factory := pulsarms.NewFactory(pulsarURL, receiveBufSize, 1024)
+	statsStream, err := factory.NewMsgStream(node.queryNodeLoopCtx)
+	assert.Nil(t, err)
+	statsStream.AsProducer(producerChannels)
 
 	var statsMsgStream msgstream.MsgStream = statsStream
 
diff --git a/internal/queryservice/load_test.go b/internal/queryservice/load_test.go
index 9d73d5168..8af9a6289 100644
--- a/internal/queryservice/load_test.go
+++ b/internal/queryservice/load_test.go
@@ -228,10 +228,10 @@ func TestLoadCollection(t *testing.T) {
 	//
 	//insertStream := pulsarms.NewPulsarMsgStream(context.Background(), receiveBufSize)
 	//insertStream.SetPulsarClient(pulsarAddress)
-	//insertStream.CreatePulsarProducers(insertChannels)
+	//insertStream.AsProducer(insertChannels)
 	//ddStream := pulsarms.NewPulsarMsgStream(context.Background(), receiveBufSize)
 	//ddStream.SetPulsarClient(pulsarAddress)
-	//ddStream.CreatePulsarProducers(ddChannels)
+	//ddStream.AsProducer(ddChannels)
 	//
 	//var insertMsgStream msgstream.MsgStream = insertStream
 	//insertMsgStream.Start()
@@ -246,7 +246,7 @@ func TestLoadCollection(t *testing.T) {
 	//consumeStream := pulsarms.NewPulsarTtMsgStream(context.Background(), receiveBufSize)
 	//consumeStream.SetPulsarClient(pulsarAddress)
 	//unmarshalDispatcher := util.NewUnmarshalDispatcher()
-	//consumeStream.CreatePulsarConsumers(insertChannels, "test", unmarshalDispatcher, pulsarBufSize)
+	//consumeStream.AsConsumer(insertChannels, "test", unmarshalDispatcher, pulsarBufSize)
 	//consumeStream.Start()
 	//
 	//for i := 0; i < 10; i++ {
-- 
GitLab