summaryrefslogtreecommitdiff
path: root/sql/ha_myisam.h
diff options
context:
space:
mode:
authorthek@adventure.(none) <>2007-07-12 13:29:51 +0200
committerthek@adventure.(none) <>2007-07-12 13:29:51 +0200
commit8ee7e48de8a12e506496278d79daa053f3a354cd (patch)
treeb4d8f7213751b0b2364435ee6f6c011d652235e7 /sql/ha_myisam.h
parent6d6674e71f8060ab396a5b56cdb505acf93f6c32 (diff)
downloadmariadb-git-8ee7e48de8a12e506496278d79daa053f3a354cd.tar.gz
Bug#28249 Query Cache returns wrong result with concurrent insert / certain lock
A race condition in the integration between MyISAM and the query cache code caused the query cache to fail to invalidate itself on concurrently inserted data. This patch fix this problem by using the existing handler interface which, upon each statement cache attempt, compare the size of the table as viewed from the cache writing thread and with any snap shot of the global table state. If the two sizes are different the global table size is unknown and the current statement can't be cached.
Diffstat (limited to 'sql/ha_myisam.h')
-rw-r--r--sql/ha_myisam.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/sql/ha_myisam.h b/sql/ha_myisam.h
index b186d9c7bb8..536ea211820 100644
--- a/sql/ha_myisam.h
+++ b/sql/ha_myisam.h
@@ -127,4 +127,11 @@ class ha_myisam: public handler
int dump(THD* thd, int fd);
int net_read_dump(NET* net);
#endif
+#ifdef HAVE_QUERY_CACHE
+ my_bool register_query_cache_table(THD *thd, char *table_key,
+ uint key_length,
+ qc_engine_callback
+ *engine_callback,
+ ulonglong *engine_data);
+#endif
};