From bbb69980acd41ef153c5f7cbf5e8fb0d972dbf52 Mon Sep 17 00:00:00 2001 From: "yihao.dai" Date: Wed, 29 May 2024 12:17:43 +0800 Subject: [PATCH] enhance: Replace 'off' with 'disable' (#33433) YAML will automatically parse "off" as a boolean variable. We should avoid using "off" in the future. issue: https://github.com/milvus-io/milvus/issues/32772 --------- Signed-off-by: bigsheeper --- configs/milvus.yaml | 8 ++++---- pkg/util/paramtable/component_param.go | 8 ++++---- pkg/util/paramtable/component_param_test.go | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/configs/milvus.yaml b/configs/milvus.yaml index 298f152c5f..1f23cd014d 100644 --- a/configs/milvus.yaml +++ b/configs/milvus.yaml @@ -329,13 +329,13 @@ queryNode: enabled: true memoryLimit: 2147483648 # 2 GB, 2 * 1024 *1024 *1024 readAheadPolicy: willneed # The read ahead policy of chunk cache, options: `normal, random, sequential, willneed, dontneed` - # options: async, sync, off. + # options: async, sync, disable. # Specifies the necessity for warming up the chunk cache. - # 1. If set to "sync" or "async," the original vector data will be synchronously/asynchronously loaded into the + # 1. If set to "sync" or "async" the original vector data will be synchronously/asynchronously loaded into the # chunk cache during the load process. This approach has the potential to substantially reduce query/search latency # for a specific duration post-load, albeit accompanied by a concurrent increase in disk usage; - # 2. If set to "off," original vector data will only be loaded into the chunk cache during search/query. - warmup: off + # 2. If set to "disable" original vector data will only be loaded into the chunk cache during search/query. + warmup: disable mmap: mmapEnabled: false # Enable mmap for loading data lazyload: diff --git a/pkg/util/paramtable/component_param.go b/pkg/util/paramtable/component_param.go index c74bbefd35..9d3da19aff 100644 --- a/pkg/util/paramtable/component_param.go +++ b/pkg/util/paramtable/component_param.go @@ -2358,13 +2358,13 @@ func (p *queryNodeConfig) init(base *BaseTable) { p.ChunkCacheWarmingUp = ParamItem{ Key: "queryNode.cache.warmup", Version: "2.3.6", - DefaultValue: "off", - Doc: `options: async, sync, off. + DefaultValue: "disable", + Doc: `options: async, sync, disable. Specifies the necessity for warming up the chunk cache. -1. If set to "sync" or "async," the original vector data will be synchronously/asynchronously loaded into the +1. If set to "sync" or "async" the original vector data will be synchronously/asynchronously loaded into the chunk cache during the load process. This approach has the potential to substantially reduce query/search latency for a specific duration post-load, albeit accompanied by a concurrent increase in disk usage; -2. If set to "off," original vector data will only be loaded into the chunk cache during search/query.`, +2. If set to "disable" original vector data will only be loaded into the chunk cache during search/query.`, Export: true, } p.ChunkCacheWarmingUp.Init(base.mgr) diff --git a/pkg/util/paramtable/component_param_test.go b/pkg/util/paramtable/component_param_test.go index cba13b3893..1b4719efe3 100644 --- a/pkg/util/paramtable/component_param_test.go +++ b/pkg/util/paramtable/component_param_test.go @@ -339,7 +339,7 @@ func TestComponentParam(t *testing.T) { // chunk cache assert.Equal(t, "willneed", Params.ReadAheadPolicy.GetValue()) - assert.Equal(t, "false", Params.ChunkCacheWarmingUp.GetValue()) + assert.Equal(t, "disable", Params.ChunkCacheWarmingUp.GetValue()) // test small indexNlist/NProbe default params.Remove("queryNode.segcore.smallIndex.nlist")