-
Notifications
You must be signed in to change notification settings - Fork 0
Cache Improvements #29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…zation demo script
… cache - Added comprehensive caching system inspired by VFB_connect to VFBquery. - Implemented memory and disk caching with configurable TTL and size limits. - Enhanced core functions with caching capabilities, including term info and instance retrieval. - Created a demo script to showcase caching functionality and performance improvements. - Developed a test suite to validate caching behavior and performance metrics. - Updated documentation to reflect new caching features and usage examples.
- Added solr_cache_demo.py to demonstrate caching benefits and cold start problem. - Created solr_cache_integration.py to integrate SOLR caching into existing VFBquery functions. - Developed solr_result_cache.py for server-side caching using SOLR, including metadata management and expiration handling. - Introduced test_solr_cache_enhanced.py to validate caching lifecycle, expiration, cleanup, and performance metrics.
… improving data integrity and retrieval efficiency. Add production tests for cache functionality and field preservation.
- Updated README.md to clarify caching features and examples, emphasizing server-side caching. - Removed SOLR_CACHING.md as the content is now integrated into README.md. - Deleted cache optimization demo scripts (cache_optimization_demo.py, native_caching_demo.py, production_cache_test.py, solr_cache_demo.py) as they are no longer needed. - Improved caching examples in README.md to reflect current functionality and usage.
…nd improve clarity
…in get_instances function
…n formatting for thumbnails
…atch expected Neo4j format
…nulls function to improve list filtering; adjust cache_data serialization in SolrResultCache
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR implements comprehensive caching improvements for VFBquery to address cold start performance issues and reduce response times from minutes to seconds. The changes introduce multiple layers of caching including in-memory, disk-based, and SOLR-based caching systems, all enabled by default with production-ready configurations.
Key changes:
- Added SOLR-based result caching with 3-month TTL for server-side optimization
- Implemented multi-layer memory and disk caching with intelligent LRU eviction
- Enhanced
get_instancesfunction with fallback SOLR implementation when Neo4j is unavailable - Added comprehensive performance testing infrastructure and monitoring
Reviewed Changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| src/vfbquery/solr_result_cache.py | New SOLR-based caching system for server-side result storage |
| src/vfbquery/cache_enhancements.py | Multi-layer caching with memory management and disk persistence |
| src/vfbquery/cached_functions.py | Enhanced VFBquery functions with integrated caching support |
| src/vfbquery/vfb_queries.py | Updated get_term_info and get_instances with caching and fallback mechanisms |
| src/vfbquery/init.py | Auto-enable caching on import with configurable environment controls |
| test_parsing.sh | Test script for GitHub Actions workflow parsing validation |
| .github/workflows/performance-test.yml | Automated performance testing and reporting workflow |
| src/test/term_info_queries_test.py | Added performance benchmarking test with timing thresholds |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
No description provided.