[Hummingbird] Caching issue after upload new product.

I normally upload about 5 products a day. After upload, the products we cannot see them on the website, even if we wait 24 hours and open the website from a different web browser. Due to that, I need to clear the cache every day. The consequences are the entire website get very low to taking so long to load the pages for the first time until caching the pages again. I need your advice on how to proceed. Thank you.

  • Ash

    Hello Sergio Brandao Filho

    If you clear cache, first time it will take some time to load as the page is server by processing the entire website, as well as it will generate the cache again.

    If you have option to set cron job on your cPanel or server admin panel, then you can create a cron job to run the following:
    http://DOMAIN.com/wp-json/hummingbird/v1/clear_cache/(?P<page_cache>\\w-]+)

    Make sure you change DOMAIN.com with original domain.

    You can run this cron daily at one of those times when your site is not busy. This will clear the cache when the cron will run. You can check more about HB API here: https://premium.wpmudev.org/docs/wpmu-dev-plugins/hummingbird-api-docs/

    Hope it helps! Please feel free to ask more questions if you have any.

    Have a nice day!

    Cheers,
    Ash

  • Sergio Brandao Filho

    Hi Ash,

    Thank you for your feedback!

    I still have some questions as following:

    When the cron runs, it will clear the cache, but it will generate cache again only when customers load each page of the website? Or there is any tool running that will recreate the cache by itself?

    My concern is that since I started e-commerce recently and I don't have much traffic yet, in order to build the traffic, the website must be fast. Since I'm doing digital marketing action, any customer that tries to access the website and the page is slow, they go away. Also, a critical situation is the links that takes customers from the products page to the cart's page, then to the checkout page. If I'm not wrong, these links are from each individual product to the cart and checkout pages. In other words, any customer that try to buy, but to load the checkout page takes forever, the also go way.

    is that makes sense for you?

    Best regards,

    Sergio Brandao Filho

  • Nithin

    Hi Sergio Brandao Filho,

    When the cron runs, it will clear the cache, but it will generate cache again only when customers load each page of the website? Or there is any tool running that will recreate the cache by itself?

    Sorry for the delay in getting back to you. By default in Hummingbird, the cache should have automatically cleared once a new product is created out of the box, even without configuring cron job separately it should have worked fine.

    We'll need to give a closer look at why the site is behaving in such a way in Hummingbird side, and check what could be done to make it work in your use case. Seems like support access to your site is disabled at the moment.

    Could you please grant support staff access so I can take a closer look. You can grant access from WPMU DEV > Support > Support Access > Grant Access, or check this manual: https://premium.wpmudev.org/docs/getting-started/getting-support/#chapter-5

    Please let us know once you enable access, so that we could get this sorted. Have a nice day. :slight_smile:

    Kind Regards,
    Nithin

  • Nithin

    Hi Sergio Brandao Filho,

    Hope you are doing good today. :slight_smile:

    Sorry for the delay in getting back to you, I gave a closer look at the Hummingbird settings, and I gave a quick test by adding a test product in your website, and could notice the newly added products not showing up.

    However, what I could notice what that, you had "Clear full cache when post/page is updated" option disabled, under Hummingbird Pro > Caching > Page Caching as shown in the following screenshot:

    What the above option does is, it clears any caches when a product is updated, so that cache gets regenerated by listing the newly added product.

    Also, along with the above mentioned settings, I have also enabled "File Change Detection" to "Automatic", so any changes made in File structure would also reflect immediately.

    I gave a test with the above settings enabled, and I couldn't notice any lag, or website taking time to load in any way. I have kept the above settings enabled at the moment, could you please check, & see whether the existing setting enabled helps with making sure the products added are up to date?

    In general, the above settings enabled should be enough, and cron doesn't need to be configured in such use case. If you still think there is any further changes that you want, or still notice issue, then I'll make sure to check with our developer to see if anything further that could be implemented via cron side too.

    Please let us know if you have any further query after checking the site, so that we could give a closer look, if needed. Have a nice day ahead. :slight_smile:

    Regards,
    Nithin

  • Sergio Brandao Filho

    Hi Nithin,

    Thank you for your message!

    I test it but I figured out that every time I load the product, it comes available, BUT it clears ALL the pages on the website, so when customers try to access the website, it takes too much time to load the pages for the first time. Customers are going away.

    Questions:

    Is there any way not clear the cache for all pages and show the products when I upload?
    Or
    Is there any way to re-load all the pages for the first time automatically after clear the cache?

    Best regards,

    Sergio Brandao Filho

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.