Skip to content

Add SetCacheDir API to customize disk cache directory.#3194

Closed
fengdyli wants to merge 6 commits intomainfrom
feature/fengdyli_setCacheDir
Closed

Add SetCacheDir API to customize disk cache directory.#3194
fengdyli wants to merge 6 commits intomainfrom
feature/fengdyli_setCacheDir

Conversation

@fengdyli
Copy link
Collaborator

@fengdyli fengdyli commented Jan 8, 2026

Add SetCacheDir API to customize disk cache directory.

@codecov-commenter
Copy link

codecov-commenter commented Jan 8, 2026

Codecov Report

❌ Patch coverage is 60.86957% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.97%. Comparing base (18befa6) to head (b5c16c3).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/rendering/caches/DiskCache.cpp 60.86% 8 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3194   +/-   ##
=======================================
  Coverage   76.97%   76.97%           
=======================================
  Files         413      413           
  Lines       21910    21930   +20     
  Branches     6291     6302   +11     
=======================================
+ Hits        16865    16881   +16     
- Misses       3819     3824    +5     
+ Partials     1226     1225    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@fengdyli fengdyli changed the title Feature/fengdyli set cache dir Add SetCacheDir API to customize disk cache directory. Jan 8, 2026
auto cacheDir = Platform::Current()->getCacheDir();
}

void DiskCache::checkInitialized() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

看了下checkInitialized方法应该没必要,缓存路径初始化的逻辑放在构造方法中就行,这样就不用每个函数调用前都需要去调用一下checkInitialized方法了,后续增加新的方法可能会漏了调用,增加维护成本。

@fengdyli fengdyli closed this Jan 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants