mirror of https://github.com/milvus-io/milvus.git
Update the organization form of the stored prefix key
Signed-off-by: become-nice <995581097@qq.com>pull/4973/head^2
parent
18a56c9b5d
commit
18cf816e56
2
go.sum
2
go.sum
|
@ -617,4 +617,4 @@ rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8
|
|||
rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0=
|
||||
rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA=
|
||||
sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
|
||||
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
|
||||
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
|
|
@ -28,4 +28,4 @@ func NewStore(ctx context.Context, driver types.DriverType) (types.Store, error)
|
|||
return store, nil
|
||||
}
|
||||
return nil, errors.New("unsupported driver")
|
||||
}
|
||||
}
|
|
@ -44,8 +44,8 @@ func (wn *WriteNode) InsertBatchData(ctx context.Context, data []*schema.InsertM
|
|||
var timeStamp []uint64
|
||||
|
||||
for i := 0; i < len(data); i++ {
|
||||
prefixKey = data[i].CollectionName + "_" + strconv.FormatInt(data[i].EntityId, 10)
|
||||
suffixKey = data[i].PartitionTag + "_" + strconv.FormatUint(data[i].SegmentId, 10)
|
||||
prefixKey = data[i].CollectionName + "-" + strconv.FormatUint(data[i].EntityId, 10)
|
||||
suffixKey = strconv.FormatUint(data[i].SegmentId, 10)
|
||||
prefixKeys = append(prefixKeys, []byte(prefixKey))
|
||||
suffixKeys = append(suffixKeys, []byte(suffixKey))
|
||||
binaryData = append(binaryData, data[i].Serialization())
|
||||
|
@ -68,7 +68,7 @@ func (wn *WriteNode) DeleteBatchData(ctx context.Context, data []*schema.DeleteM
|
|||
var timeStamps []uint64
|
||||
|
||||
for i := 0; i < len(data); i++ {
|
||||
prefixKey = data[i].CollectionName + "_" + strconv.FormatInt(data[i].EntityId, 10) + "_"
|
||||
prefixKey = data[i].CollectionName + "-" + strconv.FormatUint(data[i].EntityId, 10)
|
||||
prefixKeys = append(prefixKeys, []byte(prefixKey))
|
||||
timeStamps = append(timeStamps, data[i].Timestamp)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue