Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-4588

QUERY CACHE - Per table/database max queries in cache (using ALTER TABLE to set per table information)

    Details

      Description

      MAX QUERIES IN CACHE per table/database
      some schemas/tables are log schemas, i don't need query cache there

      1) a per database solution using alter table or 'black_list' variable per schema
      add a black list per schema, maybe a variable could do this job:

      SET GLOBAL query_cache_no_cache_db=xxxx,yyyy,zzzz
      ALTER DATABASE xxxx 
          QUERY_CACHE_MAX_QUERIES=0 (maybe -1 or NULL = infinity?), 
          QUERY_CACHE_FULL=REMOVE/CANT_CACHE
      

      2) a per table solution, maybe using alter table, or a global variable

      SET GLOBAL query_cache_max_queries_per_table=0 - 9999999999999999 (maybe -1 or NULL = infity?)
      ALTER TABLE all_tables_in_schema_xxx 
          QUERY_CACHE_MAX_QUERIES=0 - 999999999999999 (maybe -1 or NULL = infinity?), 
          QUERY_CACHE_FULL=REMOVE/CANT_CACHE
      
      QUERY_CACHE_FULL
          REMOVE works like table cache (remove old table and add new one), 
          CANT_CACHE return "can't cache" and don't cache query
      

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              There are no comments yet on this issue.

                People

                • Assignee:
                  Unassigned
                  Reporter:
                  rspadim roberto spadim
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:

                    Time Tracking

                    Estimated:
                    Original Estimate - 10 weeks
                    10w
                    Remaining:
                    Remaining Estimate - 10 weeks
                    10w
                    Logged:
                    Time Spent - Not Specified
                    Not Specified