There is a fairly straightforward answer in configure.php file contents explained.
A quick web search on the word "cache" provides a number of explanations for what a cache is and why you might use one. Here is one such article from Microsoft.
There is a fairly straightforward answer in configure.php file contents explained.
A quick web search on the word "cache" provides a number of explanations for what a cache is and why you might use one. Here is one such article from Microsoft.
The glass is not half full. The glass is not half empty. The glass is simply too big!
Where are the Zen Cart Debug Logs? Where are the HTTP 500 / Server Error Logs?
Zen Cart related projects maintained by lhûngîl : Plugin / Module Tracker
I already read that configure.php contents page, its doesnt answer my question.
I know what Cache is, and what it is used for, however I want to know what is being cahed to the db or file of the setting in the configure.php file is set.set and for what purpose/benefits/disadvantages.
Phil Rogers
A problem shared is a problem solved.
Some SQL queries for your store may be cached for ... well, for the reasons you said you already understand.
Setting it to 'none' effectively disables the caching.
Setting it to 'file' is ... well ... obsolete since v1.5.0.
Setting it to 'database' causes the preprocessed sql query results to be stored so a single lookup will retrieve the data instead of having to make the database go out and collect all the info for some complex queries again. This gives some performance gain.
While it may seem odd to cache database results to the database, the purpose is mainly for minimizing delays with complex lookups or very high-traffic lookups. But, that's what caching is all about, as you know.
If your server is very well tuned, then you might get a small increase in performance by enabling the caching (as I said earlier, the only valid option is 'none' or 'database').
If your server is already struggling to perform well at the database level, caching to database will not be beneficial and you should really look at improving your server configuration.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Thanks Doc.
is it any queries that are cahed or only ZenCart core file queries. i.e would queires carried out my mods be included?
Also can caching cause issues? is it only caching the look up statements or does it cache the results? if changes are made to the catalougue would cache need to be reset to ensure current results are shown etc?
Phil Rogers
A problem shared is a problem solved.
It only caches a select few core queries. Not addons.
And only reads, not writes.
And the system already does any cache cleanup needed whenever any cached data is changed, so integrity is always preserved.
If your question is still about performance, the addition of the query_cache code in 1.5.1 almost invalidates the need for the older legacy caching. I would venture to say that you would find little gain by enabling SQL_CACHE_METHOD if query_cache is enabled.
And, as I said earlier, if your server's database is sluggish at all, then that's what you should be tuning, not the caching settings in Zen Cart.
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
I dont have any problems and have never needed to enable it.. Just edjamucating myself![]()
Phil Rogers
A problem shared is a problem solved.
Although I did once bring this up before, the only time I ever had a problem is when someone was purposly adding hundreds if not thousends of products in the cart. this seem to create exponetial queries on the database on every page load the more products that were in the cart to the point of the site no longer responding. I guess the only way to tackle that is to put a limit on the max server queries per user?
Phil Rogers
A problem shared is a problem solved.
Can you give an example of how you would know if the server was struggling to perform well at the database level? I'm not a programmer so I don't know what to look for or what I would be seeing/experiencing.
Also, what steps would I take - or what should I be asking my host company - to improve the server configuration?
BTW, the store that lead to this question is using zen cart v1.3.9h and the owner does not want to upgrade. The site is hosted with Hostgator.
I would like to take these actions if I could get more clarity on exactly what to do.
Thanks for anything you can share.