Skip to content
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

Adjust recent vuln cache #246

Merged
merged 1 commit into from
Dec 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion schema/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@
# Prepare the cache key with parameters
cache_key = f"recent_days_{days}_{page}_{per_page}"
# Use the cache key for caching the response
@cache(timeout=1800, key_prefix=cache_key)
@cache(timeout=600, key_prefix=cache_key) # Cache for 10 minutes, 4/12/2024 - Synfinner.
Dismissed Show dismissed Hide dismissed
def fetch_vulnerabilities():
cutoff_date = (datetime.utcnow() - timedelta(days=int(days))).strftime("%Y-%m-%d")
field = (
Expand Down
Loading