• Resolved MarcGuay

    (@marcguay)


    I have added a URI pattern to the Private Cached URIs setting but it always returns a “miss”. To reproduce:

    • I have added the URI “^/acheter-un-arbre/arbres-en-vente” to “Private Cached URIs” in the LiteSpeed Cache Settings.
    • I visit the URL in a browser and see the headers:
      • x-litespeed-cache: miss
      • x-litespeed-cache-control: private,max-age=1800
    • I visit a second time and still see the same headers.

    I tried with the Storefront theme to see if it was my custom theme causing the issue and had the same result. Thanks for your help.

    Report Number: UWOIHXYN

    • This topic was modified 2 months, 1 week ago by MarcGuay.
    • This topic was modified 2 months, 1 week ago by MarcGuay.

    The page I need help with: [log in to see the link]

Viewing 15 replies - 1 through 15 (of 22 total)
  • Plugin Support qtwrk

    (@qtwrk)

    this URL gives me redirection to homepage , pelase check

    https://verdissementlaval.baboonserver.com/acheter-un-arbre/arbres-en-vente

    Thread Starter MarcGuay

    (@marcguay)

    When you visit the URL you’ll be redirected to the homepage and asked to enter an address. Please enter “123 Avenue Laval, Laval, QC, Canada” and click the “Confirmer l’adresse” button. You will then be redirected to the page in question.

    Plugin Support qtwrk

    (@qtwrk)

    it’s because you have a cookie sbjs_session , which is changing in every request, , when you privitize cache , it also checks for cookies value , so when cookie changes, it misses

    Thread Starter MarcGuay

    (@marcguay)

    Thank you. I’ve disabled that cookie but the problem persists.

    Thread Starter MarcGuay

    (@marcguay)

    I notice that there are some google analytics cookies that change on every page load – this is probably causing the same issue. Is it possible that private cached URIs is not compatible with GA?

    Plugin Support qtwrk

    (@qtwrk)

    yes, when you privitize cache , cookies are taken into calculation as well

    and may I know why do you want to private cache this page?

    Thread Starter MarcGuay

    (@marcguay)

    1) User visits homepage and enters and confirms address
    2) A cookie is set with an ID associated with the territory they belong to
    3) Certain pages display different content based on the territory, so I’m using the Vary cookie feature to cache separate pages depending on the user’s territory.
    4) We allow those pages to be open to bots for scraping previews.
    5) If I clear the cache and a bot visits one of those pages without the cookie assigned, a version of the page is publicly cached.
    6) A user can then visit the page and view the cached version without entering an address.

    I was hoping that even if publicly caching is not an option that private caching could be implemented.

    • This reply was modified 2 months, 1 week ago by MarcGuay.
    • This reply was modified 2 months, 1 week ago by MarcGuay.
    Plugin Support qtwrk

    (@qtwrk)

    you should better vary it , Cache -> Advance -> cookie vary , put the name of cookie that your set with address

    Thread Starter MarcGuay

    (@marcguay)

    The same problem happens (a page with no-cookie is cached by the bot’s visit and then served to the user because the logic to check for the cookie doesn’t execute).

    • This reply was modified 2 months, 1 week ago by MarcGuay.
    Plugin Support qtwrk

    (@qtwrk)

    how come ? are you sure you set it correctly ?

    please provide a new report, let me double check

    Thread Starter MarcGuay

    (@marcguay)

    Is there a way to prevent specific user agents from generating page caches?

    Thread Starter MarcGuay

    (@marcguay)

    New report IDELYTAE

    Plugin Support qtwrk

    (@qtwrk)

    you can use Cache -> Exclude -> Do not cache user agent

    Thread Starter MarcGuay

    (@marcguay)

    That is perfect, thank you for your help!

    Thread Starter MarcGuay

    (@marcguay)

    Can you please delete the link to the staging site that you posted above?

Viewing 15 replies - 1 through 15 (of 22 total)
  • You must be logged in to reply to this topic.