Visitar URL original
Catch non HEAD GET events and cache them by Naramsim · Pull Request #95 · PokeAPI/deploy · GitHub
Skip to content

Catch non HEAD GET events and cache them - #95

Open
Naramsim wants to merge 2 commits into
masterfrom
staging
Open

Naramsim wants to merge 2 commits into
masterfrom
staging

Conversation

@Naramsim

@Naramsim Naramsim commented Oct 4, 2026

Copy link
Copy Markdown
Member

This sets a cache control header so we can cache POST, PUT, ent for a longer time on Cloudflare.

@FallenDeity Should we add the X-PokeAPI-Hash and X-PokeAPI-Deploy-Date headers as well?

@Naramsim
Naramsim requested a review from FallenDeity October 4, 2026 10:38
@FallenDeity

Copy link
Copy Markdown
Contributor

i thought cf cdn dosent cache anything other than get? https://developers.cloudflare.com/cache/concepts/default-cache-behavior/

and this still wastes compute wouldnt a better option be google cloud armor or cf waf? we could set a policy/rule preventing them from reaching the function at all

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants