<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Xaprb &#187; query cache</title>
	<atom:link href="http://www.xaprb.com/blog/tag/query-cache/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.xaprb.com/blog</link>
	<description>Stay curious!</description>
	<lastBuildDate>Thu, 09 Feb 2012 03:58:56 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Making query cache contention more obvious</title>
		<link>http://www.xaprb.com/blog/2010/09/15/making-query-cache-contention-more-obvious/</link>
		<comments>http://www.xaprb.com/blog/2010/09/15/making-query-cache-contention-more-obvious/#comments</comments>
		<pubDate>Thu, 16 Sep 2010 02:24:40 +0000</pubDate>
		<dc:creator>Xaprb</dc:creator>
				<category><![CDATA[SQL]]></category>
		<category><![CDATA[Percona Server]]></category>
		<category><![CDATA[query cache]]></category>

		<guid isPermaLink="false">http://www.xaprb.com/blog/?p=2016</guid>
		<description><![CDATA[The newest release of Percona Server includes a trivial change that I think will be extremely valuable. This is the addition of a new thread state, &#8220;Waiting on query cache mutex.&#8221; Fixing the query cache to make it scalable is hard. Fixing the server to report when the query cache is a bottleneck is not [...]


<strong>Further Reading:</strong><ul><li><a href='http://www.xaprb.com/blog/2010/03/04/a-growing-trend-innodb-mutex-contention/' rel='bookmark' title='Permanent Link: A growing trend: InnoDB mutex contention'>A growing trend: InnoDB mutex contention</a></li>
<li><a href='http://www.xaprb.com/blog/2009/03/08/making-maatkit-more-open-source-one-step-at-a-time/' rel='bookmark' title='Permanent Link: Making Maatkit more Open Source one step at a time'>Making Maatkit more Open Source one step at a time</a></li>
<li><a href='http://www.xaprb.com/blog/2009/10/29/making-changes-to-many-tables-at-once/' rel='bookmark' title='Permanent Link: Making changes to many tables at once'>Making changes to many tables at once</a></li>
<li><a href='http://www.xaprb.com/blog/2009/06/07/the-cache-oblivious-algorithms-inside-tokuteks-tokudb/' rel='bookmark' title='Permanent Link: The cache-oblivious algorithms inside Tokutek&#8217;s TokuDB'>The cache-oblivious algorithms inside Tokutek&#8217;s TokuDB</a></li>
<li><a href='http://www.xaprb.com/blog/2009/04/01/how-mysql-really-executes-a-query/' rel='bookmark' title='Permanent Link: How MySQL really executes a query'>How MySQL really executes a query</a></li>
</ul>]]></description>
			<content:encoded><![CDATA[<p>The <a href="http://www.mysqlperformanceblog.com/2010/09/15/percona-server-5-1-49-rel12-0/">newest release of Percona Server</a> includes a trivial change that I think will be extremely valuable.  This is the addition of a new thread state, &#8220;Waiting on query cache mutex.&#8221;  Fixing the query cache to make it scalable is hard.  Fixing the server to report when the query cache is a bottleneck is not hard.  It has historically been very difficult for users to diagnose what&#8217;s wrong with their server when the query cache is locking it intermittently.  Now it will be trivial: they will look at SHOW PROCESSLIST and the evidence will be unmistakable.</p>

<p><strong>Further Reading:</strong><ul><li><a href='http://www.xaprb.com/blog/2010/03/04/a-growing-trend-innodb-mutex-contention/' rel='bookmark' title='Permanent Link: A growing trend: InnoDB mutex contention'>A growing trend: InnoDB mutex contention</a></li>
<li><a href='http://www.xaprb.com/blog/2009/03/08/making-maatkit-more-open-source-one-step-at-a-time/' rel='bookmark' title='Permanent Link: Making Maatkit more Open Source one step at a time'>Making Maatkit more Open Source one step at a time</a></li>
<li><a href='http://www.xaprb.com/blog/2009/10/29/making-changes-to-many-tables-at-once/' rel='bookmark' title='Permanent Link: Making changes to many tables at once'>Making changes to many tables at once</a></li>
<li><a href='http://www.xaprb.com/blog/2009/06/07/the-cache-oblivious-algorithms-inside-tokuteks-tokudb/' rel='bookmark' title='Permanent Link: The cache-oblivious algorithms inside Tokutek&#8217;s TokuDB'>The cache-oblivious algorithms inside Tokutek&#8217;s TokuDB</a></li>
<li><a href='http://www.xaprb.com/blog/2009/04/01/how-mysql-really-executes-a-query/' rel='bookmark' title='Permanent Link: How MySQL really executes a query'>How MySQL really executes a query</a></li>
</ul>]]></content:encoded>
			<wfw:commentRss>http://www.xaprb.com/blog/2010/09/15/making-query-cache-contention-more-obvious/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>MySQL Conference and Expo 2008, Day Two</title>
		<link>http://www.xaprb.com/blog/2008/04/17/mysql-conference-and-expo-2008-day-two/</link>
		<comments>http://www.xaprb.com/blog/2008/04/17/mysql-conference-and-expo-2008-day-two/#comments</comments>
		<pubDate>Thu, 17 Apr 2008 17:01:02 +0000</pubDate>
		<dc:creator>Xaprb</dc:creator>
				<category><![CDATA[SQL]]></category>
		<category><![CDATA[Brian Aker]]></category>
		<category><![CDATA[EnterpriseDB]]></category>
		<category><![CDATA[Falcon]]></category>
		<category><![CDATA[Grazr]]></category>
		<category><![CDATA[Maatkit]]></category>
		<category><![CDATA[Maria]]></category>
		<category><![CDATA[mysqluc2008]]></category>
		<category><![CDATA[Patrick Galbraith]]></category>
		<category><![CDATA[Percona]]></category>
		<category><![CDATA[query cache]]></category>
		<category><![CDATA[Tokutek]]></category>

		<guid isPermaLink="false">http://www.xaprb.com/blog/2008/04/17/mysql-conference-and-expo-2008-day-two/</guid>
		<description><![CDATA[Day two of the conference was a little disappointing, as far as sessions went. There were several time blocks where I simply wasn&#8217;t interested in any of the sessions. Instead, I went to the expo hall and tried to pry straight answers out of sly salespeople. Here&#8217;s what I attended. Paying It Forward: Harnessing the [...]


<strong>Further Reading:</strong><ul><li><a href='http://www.xaprb.com/blog/2008/04/19/mysql-conference-and-expo-2008-day-three/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day Three'>MySQL Conference and Expo 2008, Day Three</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/16/mysql-conference-and-expo-2008-day-one/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day One'>MySQL Conference and Expo 2008, Day One</a></li>
<li><a href='http://www.xaprb.com/blog/2008/01/25/my-presentations-at-the-2008-mysql-conference-and-expo/' rel='bookmark' title='Permanent Link: My presentations at the 2008 MySQL Conference and Expo'>My presentations at the 2008 MySQL Conference and Expo</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/25/baron-schwartz-on-a-podcast-at-mysql-conference-and-expo-2008/' rel='bookmark' title='Permanent Link: Baron Schwartz on a podcast at MySQL Conference and Expo 2008'>Baron Schwartz on a podcast at MySQL Conference and Expo 2008</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/23/like-it-or-not-it-is-the-mysql-conference-and-expo/' rel='bookmark' title='Permanent Link: Like it or not, it is the MySQL Conference and Expo'>Like it or not, it is the MySQL Conference and Expo</a></li>
</ul>]]></description>
			<content:encoded><![CDATA[<p>Day two of the conference was a little disappointing, as far as sessions went.  There were several time blocks where I simply wasn&#8217;t interested in any of the sessions.  Instead, I went to the expo hall and tried to pry straight answers out of sly salespeople.  Here&#8217;s what I attended.</p>

<h3>Paying It Forward: Harnessing the MySQL Contributory Resources</h3>

<p>This was a talk focused on how MySQL has made it possible for community members to contribute to MySQL.  There was quite a bit of talk about IRC channels, mailing lists, and the like.  However, the talk gave short shrift to how MySQL plans to become  truly open source (in terms of its development model, not its license).  I think there was basically nothing to talk about there.  I had a good conversation about some of my concerns with the speaker and some others from MySQL right afterwards.</p>

<p>There was basically nobody there &#8212; I didn&#8217;t count, but I&#8217;d say maybe 10 or 12 people.  I think this is a telling sign.</p>

<h3>Architecture of Maria: A New Storage Engine with a Transactional Design</h3>

<p>I was interested in this talk because I&#8217;m interested in the tension between Falcon and Maria (and between Falcon and everything, for that matter) but I left and went to the expo hall again after a bit.  The talk was good but I&#8217;d already seen and/or read it, and the question-and-answer component wasn&#8217;t enough to keep me there.</p>

<h3>The MySQL Query Cache</h3>

<p>This was the second session I gave at the conference, and again it was standing-room-only, with nearly 300 attendees according to the person who was watching the door.  The questions were frequent and added a lot to the discussion.  Slides will be on the conference website when they post them.</p>

<h3>Grazr: Lessons Learned Building a Web 2.0 Application Using MySQL</h3>

<p>I was keenly interested in this talk because a) I am a big fan of Patrick Galbraith&#8217;s work with many different projects, and b) I had heard a lot about <a href="http://www.grazr.com/">Grazr</a> but didn&#8217;t know much about it.  However, I missed most of the talk.  About ten minutes into it, I got a call I couldn&#8217;t refuse: my wife!</p>

<p>However, I did sneak back into the room for the last bit too.  And I gave Grazr a try.  Unfortunately, I got really confused by it; I tried a bunch of different ways to import my Google Reader&#8217;s OPML.  I got that to work, but then I couldn&#8217;t figure out how to read the feeds in the OPML via Grazr.  Then I think I figured that out (I&#8217;m not sure) but it didn&#8217;t strike me as a very handy way to read my feeds.  I&#8217;ll try taking another look at it later if I get time.  (I&#8217;m all ears if there&#8217;s a better way to read feeds).</p>

<h3>Extending MySQL</h3>

<p>This one was mostly for fun.  I knew a lot about UDFs already (I&#8217;ve created some) and I knew about the pluggable storage engine API.  But I didn&#8217;t know about pluggable event daemons.  Holy cow, what a great way to shoot yourself (or your server) in the foot!  All the power of an atomic bomb, with all the safety of SPF 5 sunblock in a nuclear attack.  Or something like that.  But darn, it sure is nifty.  Brian is a great speaker too &#8212; very lively.</p>

<p>You know, there&#8217;s another way to extend MySQL that most people don&#8217;t seem to know about, which Brian didn&#8217;t mention.  That is procedures (not stored procedures).  They are sort of like a post-filter for a result set, and like UDFs they&#8217;ve been around forever.  I have never heard of anyone writing their own, but there&#8217;s an example in the server itself: <a href="http://dev.mysql.com/doc/refman/4.1/en/procedure-analyse.html">PROCEDURE ANALYSE</a>.</p>

<h3>Expo hall</h3>

<p>I went to the expo hall to meet and greet many of the companies that Percona (my employer) is already working with (doing independent benchmarks, performance verification, analysis etc) or will be in the future.  I also wanted to grill some of the vendors on their technology.  Usually I find them very cagey; they claim X times faster this-or-that, but won&#8217;t tell you how, and won&#8217;t tell you what their systems don&#8217;t do well.  I don&#8217;t understand why they take this approach; you can&#8217;t hide your system&#8217;s strong and weak spots.  There is no security through obscurity, and shrewd independent observers are going to get to the bottom of it with or without your permission.</p>

<p>So, for instance, I was talking with <a href="http://www.tokutek.com/">Tokutek,</a> who claimed to be a drop-in replacement for InnoDB with 200x better performance and apparently no downsides.  However, on closer questioning, I did get him to admit that the system has table-level locking.  Thus it won&#8217;t give any concurrency, so saying it&#8217;s a drop-in InnoDB replacement is questionable.  And the comparison against InnoDB seemed contrived to create a worst-case situation with bad tuning and a workload so it would perform terribly. An honest comparison tunes both systems to their highest performance and measures them; you can&#8217;t tune one system as badly as possible and compare it to the other&#8217;s best-case performance.  I pressed on further and asked about range scans in some specific cases (they claim they&#8217;re great at range queries, and equal to InnoDB on everything else).  At last they admitted they can&#8217;t perform well on some very common queries such as real-life queries InnoDB performs very well on for me.  They said these are &#8220;point queries&#8221; but that&#8217;s not true; you can design indexes to support many different ways to range-query a table in InnoDB and get great performance.  So it sounds to me like Tokutek&#8217;s storage format is extremely narrowly focused, and there is indeed a trade-off.  I will be interested to see how their technology develops, though.  It&#8217;s not done yet.</p>

<h3>In general</h3>

<p>There are a lot of Maatkit t-shirts walking around, which makes me happy.  If I&#8217;d printed 200 of them, I probably could have given them all away.  I was wearing a <a href="http://www.postgresql.org/">PostgreSQL</a> t-shirt myself.  Proudly, I might add.  I&#8217;m not the only person here who&#8217;s interested in PostgreSQL.  This morning I met a person from EnterpriseDB.</p>

<p>Yesterday was a bit slow in terms of interesting sessions, but there was a lot going on in the hallways, the expo hall, the meetings over lunch, and so on.</p>

<p><strong>Further Reading:</strong><ul><li><a href='http://www.xaprb.com/blog/2008/04/19/mysql-conference-and-expo-2008-day-three/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day Three'>MySQL Conference and Expo 2008, Day Three</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/16/mysql-conference-and-expo-2008-day-one/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day One'>MySQL Conference and Expo 2008, Day One</a></li>
<li><a href='http://www.xaprb.com/blog/2008/01/25/my-presentations-at-the-2008-mysql-conference-and-expo/' rel='bookmark' title='Permanent Link: My presentations at the 2008 MySQL Conference and Expo'>My presentations at the 2008 MySQL Conference and Expo</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/25/baron-schwartz-on-a-podcast-at-mysql-conference-and-expo-2008/' rel='bookmark' title='Permanent Link: Baron Schwartz on a podcast at MySQL Conference and Expo 2008'>Baron Schwartz on a podcast at MySQL Conference and Expo 2008</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/23/like-it-or-not-it-is-the-mysql-conference-and-expo/' rel='bookmark' title='Permanent Link: Like it or not, it is the MySQL Conference and Expo'>Like it or not, it is the MySQL Conference and Expo</a></li>
</ul>]]></content:encoded>
			<wfw:commentRss>http://www.xaprb.com/blog/2008/04/17/mysql-conference-and-expo-2008-day-two/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My presentations at the 2008 MySQL Conference and Expo</title>
		<link>http://www.xaprb.com/blog/2008/01/25/my-presentations-at-the-2008-mysql-conference-and-expo/</link>
		<comments>http://www.xaprb.com/blog/2008/01/25/my-presentations-at-the-2008-mysql-conference-and-expo/#comments</comments>
		<pubDate>Fri, 25 Jan 2008 18:42:57 +0000</pubDate>
		<dc:creator>Xaprb</dc:creator>
				<category><![CDATA[Beat Vontobel]]></category>
		<category><![CDATA[conference]]></category>
		<category><![CDATA[explain]]></category>
		<category><![CDATA[Jay Pipes]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[mysqlconf2008]]></category>
		<category><![CDATA[mysqluc2008]]></category>
		<category><![CDATA[query cache]]></category>

		<guid isPermaLink="false">http://www.xaprb.com/blog/2008/01/25/my-presentations-at-the-2008-mysql-conference-and-expo/</guid>
		<description><![CDATA[<p>
<a href="http://en.oreilly.com/mysql2008/">
<img src="http://en.oreilly.com/mysql2008/public/asset/asset/561" width="120" height="240"  border="0"  alt="MySQL Conference &#038; Expo 2008" title="MySQL Conference &#038; Expo 2008"  style="float: right" /></a>

I'll be attending the <a href="http://en.oreilly.com/mysql2008/">2008 MySQL Conference and Expo</a> again this year, and I'm looking forward to hearing some great sessions, meeting new and old friends, and giving sessions myself.  As a proposal reviewer, I looked at and voted on 250+ proposals for sessions and tutorials for this conference.  There are going to be some great sessions and tutorials.</p>


<strong>Further Reading:</strong><ul><li><a href='http://www.xaprb.com/blog/2008/04/16/mysql-conference-and-expo-2008-day-one/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day One'>MySQL Conference and Expo 2008, Day One</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/17/mysql-conference-and-expo-2008-day-two/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day Two'>MySQL Conference and Expo 2008, Day Two</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/19/mysql-conference-and-expo-2008-day-three/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day Three'>MySQL Conference and Expo 2008, Day Three</a></li>
<li><a href='http://www.xaprb.com/blog/2008/02/22/remember-to-sign-up-for-mysql-conference-and-expo/' rel='bookmark' title='Permanent Link: Remember to sign up for MySQL Conference and Expo!'>Remember to sign up for MySQL Conference and Expo!</a></li>
<li><a href='http://www.xaprb.com/blog/2007/10/05/how-to-get-your-session-accepted-to-mysql-conference-2008/' rel='bookmark' title='Permanent Link: How to get your session accepted to MySQL Conference 2008'>How to get your session accepted to MySQL Conference 2008</a></li>
</ul>]]></description>
			<content:encoded><![CDATA[<p>
<a href="http://en.oreilly.com/mysql2008/">
<img src="http://en.oreilly.com/mysql2008/public/asset/asset/561" width="120" height="240"  border="0"  alt="MySQL Conference &#038; Expo 2008" title="MySQL Conference &#038; Expo 2008"  style="float: right" /></a>

I&#8217;ll be attending the <a href="http://en.oreilly.com/mysql2008/">2008 MySQL Conference and Expo</a> again this year, and I&#8217;m looking forward to hearing some great sessions, meeting new and old friends, and giving sessions myself.  As a proposal reviewer, I looked at and voted on 250+ proposals for sessions and tutorials for this conference.  There are going to be some great sessions and tutorials.<sup>[1]</sup></p>

<p>If you haven&#8217;t come to the conference previously, it&#8217;s well worth your time and money, in my opinion.</p>

<p>I (Baron Schwartz) am giving <a href="http://en.oreilly.com/mysql2008/public/schedule/speaker/142">two sessions</a> myself, on extremely practical topics.  One is the <a href="http://en.oreilly.com/mysql2008/public/schedule/detail/1763">query cache</a>, and the other is <a href="http://en.oreilly.com/mysql2008/public/schedule/detail/300">EXPLAIN</a>.  Both are the subject of many myths and misunderstandings!  My goal is to remove all the programmer-speak and show you how they really work.  Once you understand that, you can understand the technical terminology.  (But it&#8217;s very hard to go the other direction).</p>

<p>I haven&#8217;t decided yet which sessions I want to attend, but I know this: I&#8217;m not going to miss seeing how <a href="http://en.oreilly.com/mysql2008/public/schedule/detail/794">Beat Vontobel solves a Su Doku puzzle with only self-joins</a>.  His session on views last year was just amazing.</p>

<p>Hopefully there&#8217;ll be plenty of time to sit down for meals and chats with all the people I correspond with throughout the year, but rarely get to see or talk to!</p>

<p><sup>1</sup>And no, I don&#8217;t get any kickback for saying nice things about the conference.  Even reviewing all those proposals was a volunteer job.  And Jay Pipes tricked me into it, the rat!  He told me it would be only a few hours.  Haha, you can&#8217;t review 250 proposals in a few hours&#8230; I have to say though, some of them were really rewarding to read.  One of them was about holding a cosmic prayer circle or something like that.  Without expressing any opinion on my religion/spirituality, I did have to vote NO on that one &#8212; sorry, wrong conference.</p>

<p><strong>Further Reading:</strong><ul><li><a href='http://www.xaprb.com/blog/2008/04/16/mysql-conference-and-expo-2008-day-one/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day One'>MySQL Conference and Expo 2008, Day One</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/17/mysql-conference-and-expo-2008-day-two/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day Two'>MySQL Conference and Expo 2008, Day Two</a></li>
<li><a href='http://www.xaprb.com/blog/2008/04/19/mysql-conference-and-expo-2008-day-three/' rel='bookmark' title='Permanent Link: MySQL Conference and Expo 2008, Day Three'>MySQL Conference and Expo 2008, Day Three</a></li>
<li><a href='http://www.xaprb.com/blog/2008/02/22/remember-to-sign-up-for-mysql-conference-and-expo/' rel='bookmark' title='Permanent Link: Remember to sign up for MySQL Conference and Expo!'>Remember to sign up for MySQL Conference and Expo!</a></li>
<li><a href='http://www.xaprb.com/blog/2007/10/05/how-to-get-your-session-accepted-to-mysql-conference-2008/' rel='bookmark' title='Permanent Link: How to get your session accepted to MySQL Conference 2008'>How to get your session accepted to MySQL Conference 2008</a></li>
</ul>]]></content:encoded>
			<wfw:commentRss>http://www.xaprb.com/blog/2008/01/25/my-presentations-at-the-2008-mysql-conference-and-expo/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

