From 7e3bd5cd995e3ae6de27e2d077346f365973173a Mon Sep 17 00:00:00 2001 From: Cuiziyuan Date: Thu, 21 Aug 2025 17:27:35 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=9A=E6=97=B6=E5=99=A8=E6=A8=A1=E5=9D=97?= =?UTF-8?q?=E5=A2=9E=E5=BC=BADFX?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Cuiziyuan --- .../service/data_share/common/scheduler_manager.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/services/distributeddataservice/service/data_share/common/scheduler_manager.cpp b/services/distributeddataservice/service/data_share/common/scheduler_manager.cpp index fa7ec6a96..bb75aa2c5 100644 --- a/services/distributeddataservice/service/data_share/common/scheduler_manager.cpp +++ b/services/distributeddataservice/service/data_share/common/scheduler_manager.cpp @@ -175,16 +175,15 @@ bool SchedulerManager::GetSchedulerStatus(const Key &key) std::lock_guard lock(mutex_); uint32_t lastSize = lastStatusCacheSize_; uint32_t nowSize = schedulerStatusCache_.size(); - if (nowSize != lastSize) { - lastStatusCacheSize_ = nowSize; - ZLOGI("size changed last %{public}d, now %{public}d", lastSize, nowSize); - } auto it = schedulerStatusCache_.find(key); if (it != schedulerStatusCache_.end()) { enabled = it->second; } else { - ZLOGW("key not found, %{public}s, %{public}" PRId64 ", %{public}s", - URIUtils::Anonymous(key.uri).c_str(), key.subscriberId, key.bundleName.c_str()); + ZLOGW("key not found, %{public}s, %{public}" PRId64 ", %{public}s, size last %{public}d, now %{public}d", + URIUtils::Anonymous(key.uri).c_str(), key.subscriberId, key.bundleName.c_str(), lastSize, nowSize); + } + if (nowSize != lastSize) { + lastStatusCacheSize_ = nowSize; } return enabled; } -- Gitee