forked from 0xWheatyz/SPARC
Expose SERP cache TTL as SERP_CACHE_TTL_HOURS environment variable #743
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?
Context
Roadmap reference: P2 - SERP cache TTL is hardcoded
The SERP cache TTL is hardcoded to 24 hours. This cannot be tuned per deployment without a code change.
What to do
SERP_CACHE_TTL_HOURStoconfig.pywith a default of24serp_api.py) to read the TTL from config.env.exampleAcceptance criteria
SERP_CACHE_TTL_HOURS=1causes the cache to expire after 1 hourserp_api.pyResolved.
config.pyreadsSERP_CACHE_TTL_HOURSenv var with default 24.analyzer.pypassesconfig.serp_cache_ttl_hourstodb.store_serp_query(). No hardcoded TTL inserp_api.py.