Cache with ecommerce | Community
Skip to main content
francisco_ribei
Level 6
October 16, 2015
Solved

Cache with ecommerce

  • October 16, 2015
  • 4 replies
  • 823 views

Hi,

How does the ecommerce add-on handles caching related to price.

As I read on documentation price is a kind of information that is always retrieved from the PIM. So, how does that works with dispatcher? there is no cache on products page?

Thanks,

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Sham_HC

Product page is cached but not the variants. Price is varient & is not cached in file system.  However it is available through commerceSession api. 

It imports data from PIM & stores under /etc/commerce 

4 replies

Sham_HC
Sham_HCAccepted solution
Level 10
October 16, 2015

Product page is cached but not the variants. Price is varient & is not cached in file system.  However it is available through commerceSession api. 

It imports data from PIM & stores under /etc/commerce 

francisco_ribei
Level 6
October 16, 2015

I see, but for example in this page:

http://localhost:4502/content/geometrixx-outdoors/en/equipment/hiking.html

It has a list of products and their prices.

So, as far as I know, usually this page will be cached by dispatcher. In case the product price is changed, there will be a request for all pages where the product is used to clear the cache? Or those pages where products are displayed usually are not cached?

Thanks.

Sham_HC
Level 10
October 16, 2015

Page will be cached & no need to clear the cache to get latest price. Price will be calculated & internally uses commerce session.

francisco_ribei
Level 6
October 16, 2015

Hi Sham,

I didn't understand. When the page is requested, dispatcher caches the html returned, including the price that was retrieve from ecommerceSession. So, next time the page is requested, it will return this HTML. What if the price was changed? This entire HTML should be generated again, right? So, how does the cache should not be cleared?

Thanks