• Marko Mäkelä's avatar
    Follow-up to MDEV-16328: ALTER TABLE…page_compression_level should not rebuild table · 90b292ce
    Marko Mäkelä authored
    Allow combination of non-instant, non-rebuilding operations with
    changes of table options that do not require a rebuild.
    
    For example, DROP INDEX or ADD INDEX can be performed with
    ALGORITHM=NOCOPY together with changing such table options.
    Changing the table options alone would be allowed with ALGORITHM=INSTANT.
    
    INNOBASE_ALTER_NOCREATE: A new set of flags, for operations that
    are refused for ALGORITHM=INSTANT and do not involve creating
    index trees.
    
    Move ALTER_RENAME_INDEX to the proper place (INNOBASE_ALTER_INSTANT).
    
    innobase_need_rebuild(): Do not require a rebuild if
    INNOBASE_ALTER_NOREBUILD operations are combined with ALTER_OPTIONS.
    
    ha_innobase::prepare_inplace_alter_table(),
    ha_innobase::inplace_alter_table(): Use the fast path if
    ALTER_OPTIONS is combined with INNOBASE_ALTER_NOCREATE.
    In this case, the actual changes would be deferred to
    ha_innobase::commit_inplace_alter_table().
    90b292ce
alter_algorithm,INPLACE.rdiff 3.21 KB