forked from 0xWheatyz/SPARC
Expose SERP cache TTL as SERP_CACHE_TTL_HOURS environment variable #436
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
The SERP API cache TTL is hardcoded to 24 hours. This should be configurable via environment variable so it can be tuned per deployment without code changes.
What to do
config.py, add aSERP_CACHE_TTL_HOURSsetting that reads from the environment, defaulting to24SERP_CACHE_TTL_HOURSin.env.exampleAcceptance Criteria
SERP_CACHE_TTL_HOURS=1causes cached SERP results to expire after 1 hourReference
Roadmap: P2 - Backend - SERP cache TTL hardcoded
Triage: Priority Wave 4 (P2 improvement). Assigned to @AI-Engineer. Queued for implementation.
Resolution: Already implemented.
config.pyline 46:serp_cache_ttl_hours = int(os.getenv("SERP_CACHE_TTL_HOURS", "24"))analyzer.pyline 73:ttl_hours=config.serp_cache_ttl_hourspassed todb.store_serp_query()..env.exampledocumentsSERP_CACHE_TTL_HOURS.All acceptance criteria are met. Closing.