Details
-
Type:
Technical task
-
Status: Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:
Description
Possibly LevelDB is not supposed to work with query cache, but then it should be taken care of, since now it returns incorrect results;
Please note that the test case below needs to be run with query-cache-type=1 (I couldn't find a suitable include file to set it automatically).
The same test without query cache returns 'updated' in all selects after update, as expected. Same is true for the test case with query cache if it's run for InnoDB.
Test output:
create table t1 (pk int primary key, c char(8)) engine=LevelDB; insert into t1 values (1,'new'),(2,'new'); select * from t1; pk c 1 new 2 new connect con1,localhost,root,,; update t1 set c = 'updated'; connection default; flush status; show status like 'Qcache_hits'; Variable_name Value Qcache_hits 0 show global status like 'Qcache_hits'; Variable_name Value Qcache_hits 0 select * from t1; pk c 1 new 2 new select sql_no_cache * from t1; pk c 1 new 2 new select * from t1 where pk = 1; pk c 1 new show status like 'Qcache_hits'; Variable_name Value Qcache_hits 0 show global status like 'Qcache_hits'; Variable_name Value Qcache_hits 0
Test case:
# Important: # The test needs to be run with --mysqld=--query-cache-type=1 --enable_connect_log create table t1 (pk int primary key, c char(8)) engine=LevelDB; insert into t1 values (1,'new'),(2,'new'); select * from t1; --connect (con1,localhost,root,,) update t1 set c = 'updated'; #select * from t1; --connection default flush status; show status like 'Qcache_hits'; show global status like 'Qcache_hits'; select * from t1; select sql_no_cache * from t1; select * from t1 where pk = 1; show status like 'Qcache_hits'; show global status like 'Qcache_hits';
revision-id: psergey@askmonty.org-20130115181447-1jfr200qcuqzp1sr revno: 4495 branch-nick: mysql-5.6-leveldb
Gliffy Diagrams
Attachments
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions
For now, I've just disabled query cache for LevelDB tables. In the future, we can add support for it