OutputCache and ModelCacheEventConsumer.....???

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
12 năm cách đây
Hi.....

I'm using Nop 2.30...

Can anyone tell me what is  OutputCache   and  ModelCacheEventConsumer....????

why is outputcache commented....??? and why is modelcacheeventconsumer used in some method......???

Thank You...
12 năm cách đây
Output caching has some limitations, that's why it's not used. nopCommerce caches presentation layer models, and ModelCacheEventConsumer helps with it.
12 năm cách đây
a.m. wrote:
Output caching has some limitations, that's why it's not used. nopCommerce caches presentation layer models, and ModelCacheEventConsumer helps with it.


Hello Andrei,
Can you tell us what was these limitations?
I'm having new performance issue while google tells me that average loading page time is 3s, and I'm looking for solutions.
I would like to improve perfs on homepage and category pages, and use OutputCache for example on :
public ActionResult HomepageProducts()
Do you think it's possible?

nop 2.3 on dedicated server
12 năm cách đây
nicolas.muniere wrote:
Can you tell us what was these limitations?

Here are some of them:
1. You'll be limited to only one theme. And you'll not be able to use mobile device support because it's also a new theme (nopCommerce 2.40).
2. If you have several currencies or languages, then you have to cache a view for each currency or language
3. Customers could specify distinct timezones (if enabled). Hence distinct views should be cached for each timezone (view where dates are rendered)
4. Other settings which could vary per customer and could affect views (for example, some customer could see "add to cart" buttons, and other could not)
12 năm cách đây
a.m. wrote:
Here are some of them:
1. You'll be limited to only one theme. And you'll not be able to use mobile device support because it's also a new theme (nopCommerce 2.40).
2. If you have several currencies or languages, then you have to cache a view for each currency or language
3. Customers could specify distinct timezones (if enabled). Hence distinct views should be cached for each timezone (view where dates are rendered)
4. Other settings which could vary per customer and could affect views (for example, some customer could see "add to cart" buttons, and other could not)


Thanks for you answer!
- I think I can resolve 1;2;3 points using by using VaryByCustom param, even if I have many versions of the same views in the cache, if it takes 10 or 100Mo, it's still a good solution in my situation.

- I understand there is no caching solution for thoses who are using customer specific prices etc. I can try to disable cache for thoses specific customers using a filter (http://forums.asp.net/p/1544447/3773034.aspx) or extending OutputCacheAttribute class

I will tell you If I find something I can share.
12 năm cách đây
nicolas.muniere wrote:

- I think I can resolve 1;2;3 points using by using VaryByCustom param, even if I have many versions of the same views in the cache, if it takes 10 or 100Mo, it's still a good solution in my situation.

- I understand there is no caching solution for thoses who are using customer specific prices etc. I can try to disable cache for thoses specific customers using a filter (http://forums.asp.net/p/1544447/3773034.aspx) or extending OutputCacheAttribute class

I will tell you If I find something I can share.


Hi Nicolas, So is there any update from your side? How about performance optimization. I would like to use output cache and I agree with you on your points completely.

Actually its a trade off between features & performance.. so if someone wants high performance then he can decide how should he do it?

@andrie

What do you suggest for cache for improving performance in high traffic large ecommerce portals based on nop commerce?
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.