Giter Site home page Giter Site logo

Comments (11)

mattiasgeniar avatar mattiasgeniar commented on June 18, 2024

The "no-cache" request header is Pingdom requesting an uncached version, but Varnish will happily ignore that header.

If a request from cache was available, Varnish will have server that. Have you modified the VCL config in any way? That might influence the way headers are added/removed in the response.

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

Yes, I modified it, I would like u to have a look into it if you please, I will email u with the link.

from varnish-5.0-configuration-templates.

mattiasgeniar avatar mattiasgeniar commented on June 18, 2024

Sorry @aelsharawi , I can't offer individual support on VCLs, feel free to copy your code here and if time permits, I'll have a look.

Thanks,

M.

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

Ok thanks a lot

here is the link

https://pastebin.com/ngs8qErQ

best.

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

is this the correct syntax for hashing this kind of cookie?
learn_press_user_guest_id=12343232123e98998989

    if (req.http.cookie ~ "learn_press_user_guest_id=*") {
       return(hash);
    }

from varnish-5.0-configuration-templates.

mattiasgeniar avatar mattiasgeniar commented on June 18, 2024

Remove line 199 until 208, it adds logic to allow client-based cache flushing. Try again after, should improve cache hit rate.

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

Thanks a lot for offering such immediate help :)

Can U please advise on the best way to hash this cookie

learn_press_user_guest_id=12343232123e98998989

  if (req.http.cookie ~ "learn_press_user_guest_id=*") {
      return(hash);
   }

--- I will test the new modification now

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

fo r the cookie I figured it out,it shall be:

  if (req.http.cookie ~ "learn_press_user_guest_id") {
      return(hash);
   }

thanks again for help, I will test the nocache and report back

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

this is the new pingom
https://www.dropbox.com/s/a21276k34dg3fff/Screenshot%202017-05-15%2011.54.35.png?dl=0
it dose not show hit

however
http://www.isvarnishworking.com/ (on refresh, looks like the varnish creats a hash for the cookies)

shows

HTTP/1.1 200 OK
Date:	Mon, 15 May 2017 09:56:05 GMT
Content-Type:	text/html; charset=UTF-8
Last-Modified:	Thu, 01 Jan 1970 00:00:00 GMT
Expires:	Mon, 15 May 2017 10:56:05 GMT
ETag:	"648a710cc579a2d2097c4ec7a49ccd56"
Content-Encoding:	gzip
Vary:	Accept-Encoding
X-Varnish:	32800 32
Age:	3
X-Cache:	HIT
X-Cache-Hits:	1
Accept-Ranges:	bytes
Connection:	keep-alive

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

why I'm not getting like this website?

https://www.dropbox.com/s/2ipnl54m7qhvdm5/Screenshot%202017-05-15%2015.26.44.png?dl=0

from varnish-5.0-configuration-templates.

aelsharawi avatar aelsharawi commented on June 18, 2024

it was nginx mis-config which prevented js css caching, however I need to make sure Im using the hashing of the cookie correctly ? as I stated above to has the learn-press cookie ? as this plugin sets it for each guest!

from varnish-5.0-configuration-templates.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.