MySQL 9.1.0
Source Code Documentation
|
handlerton is a singleton structure - one instance per storage engine - to provide access to storage engine functionality that works on the "global" level (unlike handler class that works on a per-table basis). More...
#include <handler.h>
handlerton is a singleton structure - one instance per storage engine - to provide access to storage engine functionality that works on the "global" level (unlike handler class that works on a per-table basis).
usually handlerton instance is defined statically in ha_xxx.cc as
static handlerton { ... } xxx_hton;
savepoint_*, prepare, recover, and *_by_xid pointers can be 0.
acl_notify_t handlerton::acl_notify |
alter_tablespace_t handlerton::alter_tablespace |
binlog_func_t handlerton::binlog_func |
binlog_log_query_t handlerton::binlog_log_query |
check_fk_column_compat_t handlerton::check_fk_column_compat |
Clone_interface_t handlerton::clone_interface |
Clone data transfer interfaces.
close_connection_t handlerton::close_connection |
collect_hton_log_info_t handlerton::collect_hton_log_info |
commit_t handlerton::commit |
commit_by_xid_t handlerton::commit_by_xid |
compare_secondary_engine_cost_t handlerton::compare_secondary_engine_cost |
Pointer to a function that estimates the cost of executing a join in a secondary storage engine.
create_t handlerton::create |
void* handlerton::data |
Location for engines to keep personal structures.
enum legacy_db_type handlerton::db_type |
Historical number used for frm file to determine the correct storage engine.
This is going away and new engines will just use "name" for this.
ddse_dict_init_t handlerton::ddse_dict_init |
dict_cache_reset_t handlerton::dict_cache_reset |
dict_cache_reset_tables_and_tablespaces_t handlerton::dict_cache_reset_tables_and_tablespaces |
dict_get_server_version_t handlerton::dict_get_server_version |
dict_init_t handlerton::dict_init |
dict_recover_t handlerton::dict_recover |
dict_register_dd_table_id_t handlerton::dict_register_dd_table_id |
dict_set_server_version_t handlerton::dict_set_server_version |
discover_t handlerton::discover |
drop_database_t handlerton::drop_database |
external_engine_explain_check_t handlerton::external_engine_explain_check |
Pointer to a function that checks if the table is loaded in the secondary engine in the case of an explain statement.
const char** handlerton::file_extensions |
Null-ended array of file extensions that exist for the storage engine.
Used by frm_error() and the default handler::rename_table and delete_table methods in handler.cc.
For engines that have two file name extensions (separate meta/index file and data file), the order of elements is relevant. First element of engine file name extensions array should be meta/index file extension. Second element - data file extension. This order is assumed by prepare_for_repair() when REPAIR TABLE ... USE_FRM is issued.
For engines that don't have files, file_extensions is NULL.
Currently, the following alternatives are used:
fill_is_table_t handlerton::fill_is_table |
find_files_t handlerton::find_files |
find_secondary_engine_offload_fail_reason_t handlerton::find_secondary_engine_offload_fail_reason |
Pointer to a function that finds and returns the query offload failure reason as a string given a thread context (representing the query) when get_secondary_engine_offload_or_exec_fail_reason returns an empty reason.
finish_upgrade_t handlerton::finish_upgrade |
LEX_CSTRING handlerton::fk_name_suffix |
Suffix for auto-generated foreign key names for tables using this storage engine.
If such suffix is specified by SE then its generated foreign key names follow (table name)(SE-specific FK name suffix)(FK number) pattern. Length of such suffix should not exceed MAX_FK_NAME_SUFFIX_LENGTH bytes. If no suffix is specified then FK_NAME_DEFAULT_SUFFIX is used as default.
uint32 handlerton::flags {0} |
Global handler flags.
flush_logs_t handlerton::flush_logs |
uint32 handlerton::foreign_keys_flags |
Flags describing details of foreign key support by storage engine.
get_cost_constants_t handlerton::get_cost_constants |
get_index_column_cardinality_t handlerton::get_index_column_cardinality |
get_secondary_engine_offload_or_exec_fail_reason_t handlerton::get_secondary_engine_offload_or_exec_fail_reason |
Pointer to a function that returns the query offload or exec failure reason as a string given a thread context (representing the query) when the offloaded query failed in a secondary storage engine.
get_table_statistics_t handlerton::get_table_statistics |
get_tablespace_t handlerton::get_tablespace |
get_tablespace_filename_ext_t handlerton::get_tablespace_filename_ext |
get_tablespace_statistics_t handlerton::get_tablespace_statistics |
get_tablespace_type_t handlerton::get_tablespace_type |
get_tablespace_type_by_name_t handlerton::get_tablespace_type_by_name |
is_dict_readonly_t handlerton::is_dict_readonly |
is_reserved_db_name_t handlerton::is_reserved_db_name |
is_supported_system_table_t handlerton::is_supported_system_table |
is_valid_tablespace_name_t handlerton::is_valid_tablespace_name |
kill_connection_t handlerton::kill_connection |
uint32 handlerton::license |
Flag for Engine License.
lock_hton_log_t handlerton::lock_hton_log |
log_ddl_create_schema_t handlerton::log_ddl_create_schema |
log_ddl_drop_schema_t handlerton::log_ddl_drop_schema |
notify_after_select_t handlerton::notify_after_select |
notify_alter_table_t handlerton::notify_alter_table |
notify_create_table_t handlerton::notify_create_table |
notify_drop_table_t handlerton::notify_drop_table |
notify_exclusive_mdl_t handlerton::notify_exclusive_mdl |
notify_rename_table_t handlerton::notify_rename_table |
notify_truncate_table_t handlerton::notify_truncate_table |
optimize_secondary_engine_t handlerton::optimize_secondary_engine |
Pointer to a function that optimizes the current statement for execution on the secondary storage engine represented by this handlerton.
Page_track_t handlerton::page_track |
Page tracking interface.
panic_t handlerton::panic |
partition_flags_t handlerton::partition_flags |
post_ddl_t handlerton::post_ddl |
post_recover_t handlerton::post_recover |
pre_dd_shutdown_t handlerton::pre_dd_shutdown |
prepare_t handlerton::prepare |
prepare_secondary_engine_t handlerton::prepare_secondary_engine |
Pointer to a function that prepares a secondary engine for executing a statement.
push_to_engine_t handlerton::push_to_engine |
recover_t handlerton::recover |
recover_prepared_in_tc_t handlerton::recover_prepared_in_tc |
redo_log_set_state_t handlerton::redo_log_set_state |
replace_native_transaction_in_thd_t handlerton::replace_native_transaction_in_thd |
reset_plugin_vars_t handlerton::reset_plugin_vars |
rm_tmp_tables_t handlerton::rm_tmp_tables |
rollback_t handlerton::rollback |
rollback_by_xid_t handlerton::rollback_by_xid |
rotate_encryption_master_key_t handlerton::rotate_encryption_master_key |
uint handlerton::savepoint_offset |
To store per-savepoint data storage engine is provided with an area of a requested size (0 is ok here).
savepoint_offset must be initialized statically to the size of the needed memory to store per-savepoint information. After xxx_init it is changed to be an offset to savepoint storage area and need not be used by storage engine. see binlog_hton and binlog_savepoint_set/rollback for an example.
savepoint_release_t handlerton::savepoint_release |
savepoint_rollback_t handlerton::savepoint_rollback |
savepoint_rollback_can_release_mdl_t handlerton::savepoint_rollback_can_release_mdl |
savepoint_set_t handlerton::savepoint_set |
sdi_create_t handlerton::sdi_create |
sdi_delete_t handlerton::sdi_delete |
sdi_drop_t handlerton::sdi_drop |
sdi_get_t handlerton::sdi_get |
sdi_get_keys_t handlerton::sdi_get_keys |
sdi_set_t handlerton::sdi_set |
se_after_commit_t handlerton::se_after_commit |
se_before_commit_t handlerton::se_before_commit |
se_before_rollback_t handlerton::se_before_rollback |
secondary_engine_check_optimizer_request_t handlerton::secondary_engine_check_optimizer_request |
Pointer to function that checks secondary engine request for updating hypergraph join optimization.
SecondaryEngineFlags handlerton::secondary_engine_flags |
Bitmap which contains the supported join types and other flags for a secondary storage engine when used with the hypergraph join optimizer.
If it is empty, it means that the secondary engine does not support the hypergraph join optimizer.
secondary_engine_modify_access_path_cost_t handlerton::secondary_engine_modify_access_path_cost |
Pointer to a function that evaluates the cost of executing an access path in a secondary storage engine.
secondary_engine_pre_prepare_hook_t handlerton::secondary_engine_pre_prepare_hook |
set_prepared_in_tc_t handlerton::set_prepared_in_tc |
set_prepared_in_tc_by_xid_t handlerton::set_prepared_in_tc_by_xid |
set_secondary_engine_offload_fail_reason_t handlerton::set_secondary_engine_offload_fail_reason |
Pointer to a function that sets the offload failure reason as a string for a thread context (representing the query) when the offloaded query failed in a secondary storage engine.
show_status_t handlerton::show_status |
uint handlerton::slot |
Each storage engine has it's own memory area (actually a pointer) in the thd, for storing per-connection information.
It is accessed as
thd->ha_data[xxx_hton.slot]
slot number is initialized by MySQL after xxx_init() is called.
start_consistent_snapshot_t handlerton::start_consistent_snapshot |
SHOW_COMP_OPTION handlerton::state |
Historical marker for if the engine is available or not.
table_exists_in_engine_t handlerton::table_exists_in_engine |
unlock_hton_log_t handlerton::unlock_hton_log |
upgrade_logs_t handlerton::upgrade_logs |
upgrade_space_version_t handlerton::upgrade_space_version |
upgrade_tablespace_t handlerton::upgrade_tablespace |