[MCOL-794] query cache not work with all engine with columnstore Created: 2017-06-29 Updated: 2020-08-25 Resolved: 2017-07-13 |
|
| Status: | Closed |
| Project: | MariaDB ColumnStore |
| Component/s: | MariaDB Server |
| Affects Version/s: | 1.0.9 |
| Fix Version/s: | 1.0.10, 1.1.0 |
| Type: | Bug | Priority: | Major |
| Reporter: | Richard Stracke | Assignee: | Daniel Lee (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Docker container with Columnstore 1.09 |
||
| Sprint: | 2017-14 |
| Description |
|
Query cache not work with columnstore regardless the engine.
No query in the query cache
But query cache is active.
|
| Comments |
| Comment by Andrew Hutchings (Inactive) [ 2017-07-12 ] | ||||||
|
The cause appears to be that the lexer adds the database name to the end of the query buffer. The query cache then sees the lengths of the DB names as different so thinks that this is part of a multi-statement query and disables. We overwrite the query buffer in vtable mode but don't add that back again. This is the comment in sql_cache we need to look for, this is the point query cache decides to turn off:
| ||||||
| Comment by Andrew Hutchings (Inactive) [ 2017-07-12 ] | ||||||
|
Two pull requests, one for 1.0, one for 1.1. Note that this only fixes query cache with non-ColumnStore tables. We can't do query cache for ColumnStore tables due to the way vtable works. | ||||||
| Comment by Daniel Lee (Inactive) [ 2017-07-13 ] | ||||||
|
Builds verified: Github source 1.0.10, 1.1.0; 1.0.10-1 [root@localhost mariadb-columnstore-server]# git show [root@localhost mariadb-columnstore-engine]# git show 1.1.0-1 [root@localhost mariadb-columnstore-server]# git show [root@localhost mariadb-columnstore-engine]# git show Note: Need to turn on query cache at session level for this to work. |