Jump to content

sql_query_cache ... does IPB use it?


Purple Turnip

Recommended Posts

Posted

No, IPB does not make use of this.

Looking at the docs it would require select statements to be rewritten as "SELECT SQL_CACHE" instead, which IPB does not do.

Posted

Wont MySQL use the cache automatically? Think I read somewhere that if the query is exactly the same as a previous query, it will use the results from the old one instead.

Posted

The mySQL query cache has three states: OFF, ON, ON DEMAND

m4rtin, only if it is set to "ON" will it cache all queries. Mine is set to "on demand" which means you have to tell it which queries to cache.

It would be a bad idea to cache all the queries on IPB anyways.

Posted

Well, you're partially right. With it "on", all queries with result sets that fit within the defined query cache limit will be cached, until you fill the query cache up. So, it's not like every query result set will necessarily be cached. A typical query to pull all posts on a page, for instance, will frequently be larger than the default 1MB limit.

http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html#sysvar_query_cache_limit

  • 2 months later...
Posted

I'd prefer if it was on DEMAND so that IPB can decide which queries are better for SQL caching and which ones aren't.

This sounds like a fairly useful thing that can really help out with the server load.

Posted

Problem is, we support more than just MySQL, so it's a little trickier to implement query-specific caching. Besides, MySQL generally does a good enough job caching the query results with it's default settings.

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...