-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
Added notes for cache request hostnames #18634
base: production
Are you sure you want to change the base?
Conversation
Deploying cloudflare-docs with Cloudflare Pages
|
Files with changes (up to 15)
|
@@ -109,6 +109,10 @@ The `stale-while-revalidate` and `stale-if-error` directives are not supported w | |||
|
|||
::: | |||
|
|||
:::note | |||
Do not use dynamic or invalid hostnames in cache requests. This can cause DNS cache failures and latency. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should be more explicit. We should say that the hostname used in the cache request should match your hostname.
And then instead of "DNS cache failures" I'd say "a DNS lookup" which will significantly increase latency.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think if they use "request.headers.host" that'd be the correct hostname to use in all cases? I could be wrong about this though
EDIT: Err... we don't need to specify this since they'll just be passing the whole request object in.
I might say "Do not override the hostname in the request or use a hostname that differs from your own"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs more context — show vs. just tell
@mikenomitch @irvinebroque Thank you for the feedback! I updated the note with the details from Mike. An example could also be included if you think that's necessary to show it more explicitly? Let me know your thoughts. |
Added notes - Do not use dynamic or invalid hostnames in cache requests. This can cause DNS cache failures and latency.