Uploaded image for project: 'Percona Server for MySQL'
  1. Percona Server for MySQL
  2. PS-4946

Add option to prevent implicit creation of column family in MyRocks

Details

    Description

      Column Families in MyRocks maintain their own mem-table and are always open. Mem-tables consume a fair amount of memory outside of the block cache. Since the creation of a Column Family has a direct impact on the memory footprint of the mysqld process, users should not always have unrestricted, free-reign to implicitly create column families at will. Consider the following example:

      CREATE TABLE t1(
        a INT,
        b INT,
        c INT,
        d INT,
        PRIMARY KEY(a) COMMENT 'the primary key',
        KEY ab(a,b) COMMENT 'key ab',
        KEY bc(b,c) COMMENT 'key bc',
        KEY cd(c,d) COMMENT 'key cd',
        KEY abcd(a,b,c,d) COMMENT 'key abcd') ENGINE=ROCKSDB;
      

      This will result in MyRocks creating Column Families by the names of:

      • 'the primary key'
      • 'key ab'
      • 'key bc'
      • 'key cd'
      • 'key abcd'

      The fact that any index comment will result in a new column family is a different problem unto itself (see PS-4947), but, this now can not be changed in 5.7.  Regardless, even if the intention was to create a new column family, due to the impact on the required resources, it should be a managed/privileged option at the minimum controlled by a read only server variable.

      Attachments

        Activity

          People

            george.lorch George Lorch (Inactive)
            george.lorch George Lorch (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - Not Specified
                Not Specified
                Logged:
                Time Spent - 7 hours, 30 minutes
                7h 30m

                Smart Checklist