1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

replace HTON_AUTOMATIC_DELETE_TABLE with return -1 from drop_table()

This commit is contained in:
Sergei Golubchik
2020-06-22 22:14:25 +02:00
parent 4876651e0f
commit 6c52931680
11 changed files with 30 additions and 50 deletions

View File

@ -1484,6 +1484,11 @@ struct handlerton
void (*close_cursor_read_view)(handlerton *hton, THD *thd, void *read_view);
handler *(*create)(handlerton *hton, TABLE_SHARE *table, MEM_ROOT *mem_root);
void (*drop_database)(handlerton *hton, char* path);
/*
return 0 if dropped successfully,
-1 if nothing was done by design (as in e.g. blackhole)
an error code (e.g. HA_ERR_NO_SUCH_TABLE) otherwise
*/
int (*drop_table)(handlerton *hton, const char* path);
int (*panic)(handlerton *hton, enum ha_panic_function flag);
int (*start_consistent_snapshot)(handlerton *hton, THD *thd);
@ -1791,13 +1796,6 @@ handlerton *ha_default_tmp_handlerton(THD *thd);
*/
#define HTON_TRANSACTIONAL_AND_NON_TRANSACTIONAL (1 << 17)
/*
The engine doesn't keep track of tables, delete_table() is not
needed and delete_table() always returns 0 (table deleted). This flag
mainly used to skip storage engines in case of ha_delete_table_force()
*/
#define HTON_AUTOMATIC_DELETE_TABLE (1 << 18)
class Ha_trx_info;
struct THD_TRANS