# Is proxy\_cache\_bypass recaching?

**URL:** <https://www.ruby-forum.com/t/is-proxy-cache-bypass-recaching/214111>\
**Category:** NGINX\
**Created:** [November 22, 2011, 4:25am UTC](https://www.ruby-forum.com/t/is-proxy-cache-bypass-recaching/214111 "2011-11-22T04:25:03Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dubstep](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/cdc98d/32.png) [@dubstep](https://www.ruby-forum.com/u/dubstep)\
**Post date:** [November 22, 2011, 4:25am UTC](https://www.ruby-forum.com/t/is-proxy-cache-bypass-recaching/214111/1 "2011-11-22T04:25:03Z")

</div>

Hi all,

I have this in my location directive

```
                proxy_cache_bypass $http_soon;

```

now I do a curl call to invalidate

[user@ip-10-111 ~]$ curl “[Custom Application Development Software for Business - Salesforce.com](http://www.site.com/teaser)” -I -H “soon:true”

HTTP/1.1 200 OK

Server: nginx

Date: Tue, 22 Nov 2011 03:07:20 GMT

Content-Type: text/html; charset=utf-8

Connection: keep-alive

Keep-Alive: timeout=60

Vary: Accept-Encoding

Vary: Cookie

X-Mod-Pagespeed: 0.9.17.7-716

Cache-Control: max-age=0, no-cache, no-store

X-Cache-Status: BYPASS

[user@ip-10-111 ~]$ curl “[Custom Application Development Software for Business - Salesforce.com](http://www.site.com/teaser)” -I

HTTP/1.1 200 OK

Server: nginx

Date: Tue, 22 Nov 2011 03:07:37 GMT

Content-Type: text/html; charset=utf-8

Connection: keep-alive

Keep-Alive: timeout=60

Vary: Accept-Encoding

Vary: Cookie

X-Mod-Pagespeed: 0.9.17.7-716

Cache-Control: max-age=0, no-cache, no-store

X-Cache-Status: HIT

Does this mean that the curl call with the header is\* recaching the page  
and the subsequent hits are cache hits?\*

-Quintin

---

<div class="post-metadata">

**Author:** ![Quintin\_P](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/q/13edae/32.png) [@Quintin\_P](https://www.ruby-forum.com/u/Quintin_P)\
**Post date:** [November 23, 2011, 4:32am UTC](https://www.ruby-forum.com/t/is-proxy-cache-bypass-recaching/214111/2 "2011-11-23T04:32:23Z")

</div>

Can someone help me if this please?

---

<div class="post-metadata">

**Author:** ![Quintin\_P](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/q/13edae/32.png) [@Quintin\_P](https://www.ruby-forum.com/u/Quintin_P)\
**Post date:** [November 23, 2011, 12:31pm UTC](https://www.ruby-forum.com/t/is-proxy-cache-bypass-recaching/214111/3 "2011-11-23T12:31:42Z")

</div>

Yes. But be aware of Cache-Control header sent by your backend. (  
[Module ngx\_http\_proxy\_module](http://wiki.nginx.org/HttpProxyModule#proxy_cache) : The cache honors  
backend’s “Expires”, “Cache-Control: no-cache”, and “Cache-Control:  
max-age=XXX” headers since version 0.7.48. Since version 7.66, “private”  
and “no-store” are also honored.)
