diff options
author | unknown <sanja@montyprogram.com> | 2012-07-13 22:17:32 +0300 |
---|---|---|
committer | unknown <sanja@montyprogram.com> | 2012-07-13 22:17:32 +0300 |
commit | 9f6a1c5842fc8f71463d48e4da4ec692aadeacc1 (patch) | |
tree | fd7a7367d091702d3081ef719125c038ddc4cfb0 /sql/handler.h | |
parent | 718bbcbfd0dd1aa858e4e3ba0583e85d81414df0 (diff) | |
download | mariadb-git-9f6a1c5842fc8f71463d48e4da4ec692aadeacc1.tar.gz |
fixed MySQL bug#53775:
Now partition engine adds underlying tables to the QC and ask underlying tables engine permittion to cache the query and return result of the query.
Incorrect QC cleanup in case of table registration failure fixe.
Unified interface for myisammrg & partitioned engnes for QC.
Diffstat (limited to 'sql/handler.h')
-rw-r--r-- | sql/handler.h | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/sql/handler.h b/sql/handler.h index ee1731af563..217c8103cd7 100644 --- a/sql/handler.h +++ b/sql/handler.h @@ -1689,6 +1689,8 @@ public: virtual ~handler_add_index() {} }; +class Query_cache; +class Query_cache_block_table; /** The handler class is the interface for dynamically loadable storage engines. Do not add ifdefs and take care when adding or @@ -2522,6 +2524,46 @@ public: return TRUE; } + /* + Count tables invisible from all tables list on which current one built + (like myisammrg and partitioned tables) + + tables_type mask for the tables should be added herdde + + returns number of such tables + */ + + virtual uint count_query_cache_dependant_tables(uint8 *tables_type + __attribute__((unused))) + { + return 0; + } + + /* + register tables invisible from all tables list on which current one built + (like myisammrg and partitioned tables). + + @note they should be counted by method above + + cache Query cache pointer + block Query cache block to write the table + n Number of the table + + @retval FALSE - OK + @retval TRUE - Error + */ + + virtual my_bool + register_query_cache_dependant_tables(THD *thd + __attribute__((unused)), + Query_cache *cache + __attribute__((unused)), + Query_cache_block_table **block + __attribute__((unused)), + uint *n __attribute__((unused))) + { + return FALSE; + } /* Check if the primary key (if there is one) is a clustered and a |