From fdea71d9fe185e96f91597eb854c12a9300dd860 Mon Sep 17 00:00:00 2001 From: fengyang Date: Thu, 15 May 2025 09:28:52 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E6=9F=A5=E8=AF=A2=E8=BF=91?= =?UTF-8?q?=E4=B8=89=E5=8D=81=E5=A4=A9=E6=95=B0=E6=8D=AE=E8=BF=94=E5=9B=9E?= =?UTF-8?q?=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: fengyang --- frameworks/src/bundle_state_common.cpp | 2 +- services/common/include/bundle_active_constant.h | 1 + services/common/include/bundle_active_core.h | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/frameworks/src/bundle_state_common.cpp b/frameworks/src/bundle_state_common.cpp index d69dacd..84c6186 100644 --- a/frameworks/src/bundle_state_common.cpp +++ b/frameworks/src/bundle_state_common.cpp @@ -612,7 +612,7 @@ std::shared_ptr>> Bu std::vector packageStats; if (endTime - beginTime <= INTERVAL_TIME) { errCode = BundleActiveClient::GetInstance().QueryBundleStatsInfoByInterval(packageStats, - BundleStateCondition::IntervalType::BY_DAILY, beginTime, endTime); + BundleStateCondition::IntervalType::BY_MONTHLY, beginTime, endTime); } else { errCode = BundleActiveClient::GetInstance().QueryBundleStatsInfoByInterval(packageStats, BundleStateCondition::IntervalType::BY_OPTIMIZED, beginTime, endTime); diff --git a/services/common/include/bundle_active_constant.h b/services/common/include/bundle_active_constant.h index f4ee663..b588ef5 100644 --- a/services/common/include/bundle_active_constant.h +++ b/services/common/include/bundle_active_constant.h @@ -80,6 +80,7 @@ const int32_t QUERY_CONDITION_VALID = 0; const int32_t QUERY_CONDITION_INVALID = -1; const uint32_t BUNDLE_ACTIVE_DB_NAME_MAX_LENGTH = 100; const int64_t TWO_SECONDS = 2 * 1000LL; +const int64_t TEN_MINUTES = 10 * 60 * 1000LL; const int64_t THIRTY_MINUTE = 30 * 60 * 1000LL; const int64_t SIX_DAY_IN_MILLIS_MAX_DEBUG = 6 * 1 * 10 * 60 * 1000LL; const int64_t SIX_DAY_IN_MILLIS_MAX = 6 * 24 * 60 * 60 * 1000LL; diff --git a/services/common/include/bundle_active_core.h b/services/common/include/bundle_active_core.h index 6d46b1c..43d7640 100644 --- a/services/common/include/bundle_active_core.h +++ b/services/common/include/bundle_active_core.h @@ -253,7 +253,7 @@ private: void AddbundleUninstalledUid(const int32_t uid); void DelayRemoveBundleUninstalledUid(const int32_t uid); int64_t flushInterval_; - static const int64_t TIME_CHANGE_THRESHOLD_MILLIS = TWO_SECONDS; + static const int64_t TIME_CHANGE_THRESHOLD_MILLIS = TEN_MINUTES; const int32_t DEFAULT_USER_ID = -1; std::map visibleActivities_; -- Gitee