From b6b06efd38de7edaedf44a67d426b5e328c7014c Mon Sep 17 00:00:00 2001 From: caoxianfei1 Date: Fri, 17 Nov 2023 14:04:14 +0800 Subject: [PATCH] [fix] fix the error that modify diskTrimCheckIntervalSec on the fly Signed-off-by: caoxianfei1 --- curvefs/src/client/s3/disk_cache_manager.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/curvefs/src/client/s3/disk_cache_manager.cpp b/curvefs/src/client/s3/disk_cache_manager.cpp index 235989ca87..33a09e307d 100644 --- a/curvefs/src/client/s3/disk_cache_manager.cpp +++ b/curvefs/src/client/s3/disk_cache_manager.cpp @@ -418,6 +418,7 @@ void DiskCacheManager::TrimCache() { cacheWriteFullDir = GetCacheWriteFullDir(); while (true) { UpdateDiskFsUsedRatio(); + waitIntervalSec_.Init(FLAGS_diskTrimCheckIntervalSec * 1000); waitIntervalSec_.WaitForNextExcution(); if (!isRunning_) { LOG(INFO) << "trim thread end.";