From 28a90f9e7a27d730baa9878bf277726a7c6f9ad1 Mon Sep 17 00:00:00 2001 From: dragondriver Date: Sat, 9 Oct 2021 16:08:56 +0800 Subject: [PATCH] Store index parameters to descriptor event (#9451) Signed-off-by: dragondriver --- internal/storage/data_codec.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/internal/storage/data_codec.go b/internal/storage/data_codec.go index b44da2c9aa..dbe0a7c616 100644 --- a/internal/storage/data_codec.go +++ b/internal/storage/data_codec.go @@ -823,6 +823,11 @@ func (codec *IndexFileBinlogCodec) Serialize( for pos := range datas { writer := NewIndexFileBinlogWriter(indexBuildID, version, collectionID, partitionID, segmentID, fieldID, indexName, indexID, datas[pos].Key) + // https://github.com/milvus-io/milvus/issues/9449 + // store index parameters to extra, in bytes format. + params, _ := json.Marshal(indexParams) + writer.descriptorEvent.AddExtra(IndexParamsFile, params) + eventWriter, err := writer.NextIndexFileEventWriter() if err != nil { return nil, err