- Optimize settings retrieval with runtime and per-class config caching.#132
Closed
djabdou50 wants to merge 2 commits intoglorand:masterfrom
Closed
- Optimize settings retrieval with runtime and per-class config caching.#132djabdou50 wants to merge 2 commits intoglorand:masterfrom
djabdou50 wants to merge 2 commits intoglorand:masterfrom
Conversation
- Add `clearSettingsCache` method to handle clearing runtime and Redis cache. - Update README with Redis request counting instructions.
Owner
|
@djabdou50 Seems like the pipeline is red :( |
- Add `clearSettingsCache` method to handle clearing runtime and Redis cache. - Update README with Redis request counting instructions.
Owner
|
🎉 Thank you for this excellent contribution! First, I want to express my appreciation for the time and effort you've put into this PR. The performance optimizations you've identified—particularly the runtime caching, config optimization, and N+1 query prevention—are exactly the kind of improvements this package needs. 🚀 Exciting News: Major Refactor Coming
📋 Next Steps
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Optimize Settings Performance with Enhanced Caching Strategy
Overview
This PR implements significant performance optimizations for the
HasSettingsTabletrait by introducing a multi-layered caching strategy that reduces Redis calls and improves runtime efficiency.✨ Key Changes
Performance Improvements
$settingsRuntimeCache) that eliminates redundant Redis calls within the same requestconfig()calls across instances__getSettingsValue()to useselect()for targeted column retrieval and support eager loading to prevent N+1 queriesNew Features
clearSettingsCache()method to handle both runtime and Redis cache clearingDeveloper Experience
Performance Impact
Technical Details