Implement optimal caching hierarchy for both movies and TV shows #43

Merged
sbcrumb merged 1 commits from sonarrissues into dev 2025-10-10 16:18:34 -04:00
Owner

Perfect the caching strategy as requested:

  1. Database check first (fastest lookup)
  2. NFO file extraction with database caching
  3. API calls only when absolutely necessary

Movies: Fixed order from NFO->DB->API to DB->NFO->API
TV Shows: Added missing NFO extraction tier between database and API

Benefits:

  • First scan: Extract existing NFOGuard data from NFOs and cache in DB
  • Subsequent scans: ~99% database cache hits, minimal API calls
  • NFO recovery: Rebuild database from existing NFO files
  • Webhook processing: Cache webhook dates in database immediately

Expected performance: Manual scans now use 3-tier optimization

Perfect the caching strategy as requested: 1. Database check first (fastest lookup) 2. NFO file extraction with database caching 3. API calls only when absolutely necessary Movies: Fixed order from NFO->DB->API to DB->NFO->API TV Shows: Added missing NFO extraction tier between database and API Benefits: - First scan: Extract existing NFOGuard data from NFOs and cache in DB - Subsequent scans: ~99% database cache hits, minimal API calls - NFO recovery: Rebuild database from existing NFO files - Webhook processing: Cache webhook dates in database immediately Expected performance: Manual scans now use 3-tier optimization
sbcrumb added 1 commit 2025-10-10 16:18:28 -04:00
Implement optimal caching hierarchy for both movies and TV shows
Local Docker Build (Dev) / build-dev (pull_request) Successful in 4s
7e56ac1601
Perfect the caching strategy as requested:
1. Database check first (fastest lookup)
2. NFO file extraction with database caching
3. API calls only when absolutely necessary

Movies: Fixed order from NFO->DB->API to DB->NFO->API
TV Shows: Added missing NFO extraction tier between database and API

Benefits:
- First scan: Extract existing NFOGuard data from NFOs and cache in DB
- Subsequent scans: ~99% database cache hits, minimal API calls
- NFO recovery: Rebuild database from existing NFO files
- Webhook processing: Cache webhook dates in database immediately

Expected performance: Manual scans now use 3-tier optimization
sbcrumb merged commit be075f884e into dev 2025-10-10 16:18:34 -04:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sbcrumb/nfoguard#43