Commit 09249eb9 authored by Marko Mäkelä's avatar Marko Mäkelä

MDEV-14180 fixup: Avoid unnecessary dirtying of pages

fil_crypt_rotate_page(): If a page is already marked as dirty,
do not move it in buf_pool.flush_list. Actual re-encryption
will happen in buf_flush_page(), and moving the page in
buf_pool.flush_list may only postpone the operation.
parent 4dfec8b2
......@@ -1820,6 +1820,9 @@ fil_crypt_rotate_page(
if (block->page.status == buf_page_t::FREED) {
/* Do not modify freed pages to avoid an assertion
failure on recovery.*/
} else if (block->page.oldest_modification()) {
/* Do not unnecessarily touch pages that are
already dirty. */
} else if (space->is_stopping()) {
/* The tablespace is closing (in DROP TABLE or
TRUNCATE TABLE or similar): avoid further access */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment