diff options
Diffstat (limited to 'storage/innobase/include')
-rw-r--r-- | storage/innobase/include/buf0buf.h | 24 | ||||
-rw-r--r-- | storage/innobase/include/log0recv.h | 18 |
2 files changed, 42 insertions, 0 deletions
diff --git a/storage/innobase/include/buf0buf.h b/storage/innobase/include/buf0buf.h index a04936a19cf..d120dc36091 100644 --- a/storage/innobase/include/buf0buf.h +++ b/storage/innobase/include/buf0buf.h @@ -436,6 +436,7 @@ buf_page_get_zip( const page_size_t& page_size); /** This is the general function used to get access to a database page. +It does page initialization and applies the buffered redo logs. @param[in] page_id page id @param[in] rw_latch RW_S_LATCH, RW_X_LATCH, RW_NO_LATCH @param[in] guess guessed block or NULL @@ -458,6 +459,29 @@ buf_page_get_gen( mtr_t* mtr, dberr_t* err); +/** This is the low level function used to get access to a database page. +@param[in] page_id page id +@param[in] rw_latch RW_S_LATCH, RW_X_LATCH, RW_NO_LATCH +@param[in] guess guessed block or NULL +@param[in] mode BUF_GET, BUF_GET_IF_IN_POOL, +BUF_PEEK_IF_IN_POOL, BUF_GET_NO_LATCH, or BUF_GET_IF_IN_POOL_OR_WATCH +@param[in] file file name +@param[in] line line where called +@param[in] mtr mini-transaction +@param[out] err DB_SUCCESS or error code +@return pointer to the block or NULL */ +buf_block_t* +buf_page_get_low( + const page_id_t page_id, + const page_size_t& page_size, + ulint rw_latch, + buf_block_t* guess, + ulint mode, + const char* file, + unsigned line, + mtr_t* mtr, + dberr_t* err); + /** Initializes a page to the buffer buf_pool. The page is usually not read from a file even if it cannot be found in the buffer buf_pool. This is one of the functions which perform to a block a state transition NOT_USED => diff --git a/storage/innobase/include/log0recv.h b/storage/innobase/include/log0recv.h index 068d7813c20..b91312e81e2 100644 --- a/storage/innobase/include/log0recv.h +++ b/storage/innobase/include/log0recv.h @@ -342,4 +342,22 @@ times! */ roll-forward */ #define RECV_SCAN_SIZE (4 * UNIV_PAGE_SIZE) +/** This is a low level function for the recovery system +to create a page which has buffered intialized redo log records. +@param[in] page_id page to be created using redo logs +@return whether the page creation successfully */ +buf_block_t* recv_recovery_create_page_low(const page_id_t page_id); + +/** Recovery system creates a page which has buffered intialized +redo log records. +@param[in] page_id page to be created using redo logs +@return block which contains page was initialized */ +inline buf_block_t* recv_recovery_create_page(const page_id_t page_id) +{ + if (UNIV_LIKELY(!recv_recovery_on)) + return NULL; + + return recv_recovery_create_page_low(page_id); +} + #endif |