| 1 | /***************************************************************************** |
| 2 | |
| 3 | Copyright (c) 2012, 2016, Oracle and/or its affiliates. All Rights Reserved. |
| 4 | Copyright (c) 2017, MariaDB Corporation. |
| 5 | |
| 6 | This program is free software; you can redistribute it and/or modify it under |
| 7 | the terms of the GNU General Public License as published by the Free Software |
| 8 | Foundation; version 2 of the License. |
| 9 | |
| 10 | This program is distributed in the hope that it will be useful, but WITHOUT |
| 11 | ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
| 12 | FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. |
| 13 | |
| 14 | You should have received a copy of the GNU General Public License along with |
| 15 | this program; if not, write to the Free Software Foundation, Inc., |
| 16 | 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA |
| 17 | |
| 18 | *****************************************************************************/ |
| 19 | |
| 20 | /**************************************************//** |
| 21 | @file include/row0quiesce.h |
| 22 | |
| 23 | Header file for tablespace quiesce functions. |
| 24 | |
| 25 | Created 2012-02-08 by Sunny Bains |
| 26 | *******************************************************/ |
| 27 | |
| 28 | #ifndef row0quiesce_h |
| 29 | #define row0quiesce_h |
| 30 | |
| 31 | #include "univ.i" |
| 32 | #include "dict0types.h" |
| 33 | |
| 34 | struct trx_t; |
| 35 | |
| 36 | /** The version number of the export meta-data text file. */ |
| 37 | #define IB_EXPORT_CFG_VERSION_V1 0x1UL |
| 38 | |
| 39 | /*********************************************************************//** |
| 40 | Quiesce the tablespace that the table resides in. */ |
| 41 | void |
| 42 | row_quiesce_table_start( |
| 43 | /*====================*/ |
| 44 | dict_table_t* table, /*!< in: quiesce this table */ |
| 45 | trx_t* trx) /*!< in/out: transaction/session */ |
| 46 | MY_ATTRIBUTE((nonnull)); |
| 47 | |
| 48 | /*********************************************************************//** |
| 49 | Set a table's quiesce state. |
| 50 | @return DB_SUCCESS or errro code. */ |
| 51 | dberr_t |
| 52 | row_quiesce_set_state( |
| 53 | /*==================*/ |
| 54 | dict_table_t* table, /*!< in: quiesce this table */ |
| 55 | ib_quiesce_t state, /*!< in: quiesce state to set */ |
| 56 | trx_t* trx) /*!< in/out: transaction */ |
| 57 | MY_ATTRIBUTE((nonnull, warn_unused_result)); |
| 58 | |
| 59 | /*********************************************************************//** |
| 60 | Cleanup after table quiesce. */ |
| 61 | void |
| 62 | row_quiesce_table_complete( |
| 63 | /*=======================*/ |
| 64 | dict_table_t* table, /*!< in: quiesce this table */ |
| 65 | trx_t* trx) /*!< in/out: transaction/session */ |
| 66 | MY_ATTRIBUTE((nonnull)); |
| 67 | |
| 68 | #endif /* row0quiesce_h */ |
| 69 | |