Backport keycache to bring bugfixes made in 5.1.
Backport keycache to 5.0
Here is instructions of how to repeat this if needed: - Copy the following files from the latest MySQL 5.1 to MySQL 5.0: include/keycache.h include/my_bit.h mysys/mf_keycache.c mysys/mf_keycaches.c mysys/my_bit.c Apply the following change in mysys/mf_keycaches.c 81c81 < static uchar *safe_hash_entry_get(SAFE_HASH_ENTRY *entry, size_t *length, --- > static uchar *safe_hash_entry_get(SAFE_HASH_ENTRY *entry, uint *length, recompile everything. Simple test to verify that this is working: cd mysql-test mysql-test-run --valgrind key_cache (the --valgrind argument can be left out if you don't have valgrind installed)
testing Monty's patch
Low Level Design modified. --- /tmp/wklog.52.old.16945 2009-08-28 10:55:40.000000000 +0300 +++ /tmp/wklog.52.new.16945 2009-08-28 10:55:40.000000000 +0300 @@ -1 +1,22 @@ -Just copy files (mf_keycache.c & key=cache.h) and fix what should be fixed. +Here is instructions of how to repeat this if needed: + +- Copy the following files from the latest MySQL 5.1 to MySQL 5.0: + +include/keycache.h +include/my_bit.h +mysys/mf_keycache.c +mysys/mf_keycaches.c +mysys/my_bit.c + +Apply the following change in mysys/mf_keycaches.c +81c81 +< static uchar *safe_hash_entry_get(SAFE_HASH_ENTRY *entry, size_t *length, +--- +> static uchar *safe_hash_entry_get(SAFE_HASH_ENTRY *entry, uint *length, + +recompile everything. + +Simple test to verify that this is working: +cd mysql-test +mysql-test-run --valgrind key_cache +(the --valgrind argument can be left out if you don't have valgrind installed)
- Planning code (Email dicussions & discussions with Sanja): 2 hours. - Backport of code (2 hours). Notice that mysys/mf_keycaches.c::safe_hash_entry_get() is different from the code in MySQL 5.1 - Testing code with mysql-test-run (especially running the key_cache.test with valgrind) - Tested the server with sql-bench
High-Level Specification modified. --- /tmp/wklog.52.old.20094 2009-08-27 09:56:05.000000000 +0300 +++ /tmp/wklog.52.new.20094 2009-08-27 09:56:05.000000000 +0300 @@ -1 +1 @@ - +Backport keycache to 5.0
Low Level Design modified. --- /tmp/wklog.52.old.20035 2009-08-27 09:55:25.000000000 +0300 +++ /tmp/wklog.52.new.20035 2009-08-27 09:55:25.000000000 +0300 @@ -1 +1 @@ - +Just copy files (mf_keycache.c & key=cache.h) and fix what should be fixed.