!14291 use no cache for hqf

Merge pull request !14291 from amao/cache
This commit is contained in:
openharmony_ci
2025-05-14 12:30:46 +00:00
committed by Gitee
3 changed files with 15 additions and 1 deletions
@@ -426,6 +426,19 @@ ErrCode BundleMgrHelper::GetBundleInfoForSelf(int32_t flags, BundleInfo &bundleI
return bundleMgr->GetBundleInfoForSelf(flags, bundleInfo);
}
ErrCode BundleMgrHelper::GetBundleInfoForSelfWithOutCache(int32_t flags, BundleInfo &bundleInfo)
{
TAG_LOGD(AAFwkTag::BUNDLEMGRHELPER, "called");
auto bundleMgr = Connect();
if (bundleMgr == nullptr) {
TAG_LOGE(AAFwkTag::BUNDLEMGRHELPER, "null bundleMgr");
return ERR_APPEXECFWK_SERVICE_INTERNAL_ERROR;
}
HITRACE_METER_NAME(HITRACE_TAG_ABILITY_MANAGER, __PRETTY_FUNCTION__);
return bundleMgr->GetBundleInfoForSelfWithOutCache(flags, bundleInfo);
}
ErrCode BundleMgrHelper::GetDependentBundleInfo(const std::string &sharedBundleName, BundleInfo &sharedBundleInfo,
GetDependentBundleInfoFlag flag)
{
+1 -1
View File
@@ -3349,7 +3349,7 @@ bool MainThread::GetHqfFileAndHapPath(const std::string &bundleName,
}
BundleInfo bundleInfo;
if (bundleMgrHelper->GetBundleInfoForSelf(
if (bundleMgrHelper->GetBundleInfoForSelfWithOutCache(
(static_cast<int32_t>(AppExecFwk::GetBundleInfoFlag::GET_BUNDLE_INFO_WITH_HAP_MODULE) +
static_cast<int32_t>(AppExecFwk::GetBundleInfoFlag::GET_BUNDLE_INFO_WITH_ABILITY) +
static_cast<int32_t>(AppExecFwk::GetBundleInfoFlag::GET_BUNDLE_INFO_WITH_APPLICATION) +
@@ -56,6 +56,7 @@ public:
const std::string &bundleName, std::vector<BaseSharedBundleInfo> &baseSharedBundleInfos,
GetDependentBundleInfoFlag flag = GetDependentBundleInfoFlag::GET_APP_CROSS_HSP_BUNDLE_INFO);
ErrCode GetBundleInfoForSelf(int32_t flags, BundleInfo &bundleInfo);
ErrCode GetBundleInfoForSelfWithOutCache(int32_t flags, BundleInfo &bundleInfo);
ErrCode GetDependentBundleInfo(const std::string &sharedBundleName, BundleInfo &sharedBundleInfo,
GetDependentBundleInfoFlag flag = GetDependentBundleInfoFlag::GET_APP_CROSS_HSP_BUNDLE_INFO);
bool GetGroupDir(const std::string &dataGroupId, std::string &dir);