Skip to content

Commit 595ede0

Browse files
committed
fix(es): review comments
1 parent 1208623 commit 595ede0

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

pages/edge-services/troubleshooting/cache-problems.mdx

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ You may experience unexpected behavior with caching on your Edge Services pipeli
1111

1212
This page helps you resolve common problems.
1313

14+
<Message type="tip">
15+
Before diving into this troubleshooting guide, ensure you are correctly using `curl` for your testing. `curl -I` uses the HEAD method by default, which does not always trigger the same logic as a real `GET` request. This can mislead you during cache tests, as cache checks might be skipped entirely, and responses main contain different headers. Use `curl -X GET -I` for more better testing and accurate `X-Cache` header information in responses.
16+
</Message>
17+
1418
## Some assets are not being correctly cached by Edge Services.
1519

1620
You may find that even though your application includes proper cache headers (e.g., `Cache-Control: max-age=...`) and is configured behind a Load Balancer with an Edge Services pipeline, static assets like images are not being cached. This can result in repeated `X-Cache: miss` responses, occasional `502` errors, and a weak cache hit:miss ratio, despite the assets being successfully served.
@@ -36,8 +40,8 @@ Check the X-Cache header in the response:
3640
- `X-Cache: hit-fresh`: the cache is working.
3741
- `X-Cache: miss`: the cache was bypassed.
3842

39-
<Message type="tip">
40-
Be cautious when using `curl` to test. `curl -I` uses the HEAD method by default, which can mislead you during troubleshooting. Use `curl -X GET -I` for more accurate testing.
41-
</Message>
43+
Use a cookie-free subdomain for static assets. This prevents cookies from being sent with requests for images, CSS, or JS.
4244

43-
Use a cookie-free subdomain for static assets. This prevents cookies from being sent with requests for images, CSS, or JS.
45+
<Message type="important">
46+
If your cookies contain authentication data, be cautious when enabling caching with cookies. Without proper `Cache-Control` headers, sensitive content may be cached and exposed to other users. Evaluate security risks before overriding the default behavior.
47+
</Message>

0 commit comments

Comments
 (0)