mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-07 19:31:51 +08:00
Add collectonScheam when calling load_collection and load_partition
Signed-off-by: zhenshan.cao <zhenshan.cao@zilliz.com>
This commit is contained in:
parent
a12b184e02
commit
39161cac9a
@ -1625,6 +1625,11 @@ func (lct *LoadCollectionTask) Execute() (err error) {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
collSchema, err := globalMetaCache.GetCollectionSchema(lct.CollectionName)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
request := &querypb.LoadCollectionRequest{
|
||||
Base: &commonpb.MsgBase{
|
||||
MsgType: commonpb.MsgType_kLoadCollection,
|
||||
@ -1634,6 +1639,7 @@ func (lct *LoadCollectionTask) Execute() (err error) {
|
||||
},
|
||||
DbID: 0,
|
||||
CollectionID: collID,
|
||||
Schema: collSchema,
|
||||
}
|
||||
lct.result, err = lct.queryserviceClient.LoadCollection(request)
|
||||
return err
|
||||
@ -1770,6 +1776,10 @@ func (lpt *LoadPartitionTask) Execute() (err error) {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
collSchema, err := globalMetaCache.GetCollectionSchema(lpt.CollectionName)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
for _, partitionName := range lpt.PartitionNames {
|
||||
partitionID, err := globalMetaCache.GetPartitionID(lpt.CollectionName, partitionName)
|
||||
if err != nil {
|
||||
@ -1787,6 +1797,7 @@ func (lpt *LoadPartitionTask) Execute() (err error) {
|
||||
DbID: 0,
|
||||
CollectionID: collID,
|
||||
PartitionIDs: partitionIDs,
|
||||
Schema: collSchema,
|
||||
}
|
||||
lpt.result, err = lpt.queryserviceClient.LoadPartitions(request)
|
||||
return err
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user