33#define DEFAULT_CHAIN_LENGTH 512
132 return (
double)(
stats.records +
stats.deleted) / 20.0 + 10;
145 int close(
void)
override;
149 int rnd_init(
bool scan =
true)
override;
166 uint table_changes)
override;
app_data_ptr new_data(u_int n, char *val, cons_type consensus)
Using this class is fraught with peril, and you need to be very careful when doing so.
Definition: sql_string.h:166
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:33
Definition: transparent_file.h:34
int delete_row(const uchar *buf) override
Definition: ha_tina.cc:1035
ha_tina(handlerton *hton, TABLE_SHARE *table_arg)
Definition: ha_tina.cc:509
int repair(THD *thd, HA_CHECK_OPT *check_opt) override
In this method check_opt can be modified to specify CHECK option to use to call check() upon the tabl...
Definition: ha_tina.cc:1377
bool get_write_pos(my_off_t *end_pos, tina_set *closest_hole)
Definition: ha_tina.cc:1223
int write_row(uchar *buf) override
Write a row.
Definition: ha_tina.cc:934
int chain_append()
Definition: ha_tina.cc:603
tina_set * chain_ptr
Definition: ha_tina.h:92
bool check_if_incompatible_data(HA_CREATE_INFO *info, uint table_changes) override
Part of old, deprecated in-place ALTER API.
Definition: ha_tina.cc:1623
my_off_t local_saved_data_file_length
Definition: ha_tina.h:78
bool is_crashed() const override
Check if the table is crashed.
Definition: ha_tina.cc:405
int init_tina_writer()
Definition: ha_tina.cc:383
int open_update_temp_file_if_needed()
Definition: ha_tina.cc:967
int rnd_pos(uchar *buf, uchar *pos) override
Definition: ha_tina.cc:1182
uchar byte_buffer[IO_SIZE]
Definition: ha_tina.h:80
THR_LOCK_DATA lock
Definition: ha_tina.h:73
const char * table_type() const override
The following can be called without an open handler.
Definition: ha_tina.h:112
MEM_ROOT blobroot
Definition: ha_tina.h:97
int close(void) override
Definition: ha_tina.cc:922
bool records_is_known
Definition: ha_tina.h:96
int info(uint) override
General method to gather info from handler.
Definition: ha_tina.cc:1196
int rnd_init(bool scan=true) override
rnd_init() can be called two times without rnd_end() in between (it only makes sense if scan=1).
Definition: ha_tina.cc:1108
int create(const char *name, TABLE *form, HA_CREATE_INFO *create_info, dd::Table *table_def) override
Create table (implementation).
Definition: ha_tina.cc:1541
int encode_quote(uchar *buf)
Definition: ha_tina.cc:534
my_off_t next_position
Definition: ha_tina.h:77
int find_current_row(uchar *buf)
Definition: ha_tina.cc:638
double scan_time() override
Definition: ha_tina.h:131
TINA_SHARE * share
Definition: ha_tina.h:74
bool auto_repair() const override
Check if the table can be automatically repaired.
Definition: ha_tina.h:158
String buffer
Definition: ha_tina.h:84
void get_status()
Definition: ha_tina.cc:841
tina_set * chain
Definition: ha_tina.h:91
int rnd_next(uchar *buf) override
Definition: ha_tina.cc:1136
int rnd_end() override
Definition: ha_tina.cc:1237
int delete_all_rows(void) override
Delete all rows in a table.
Definition: ha_tina.cc:1501
int open(const char *name, int mode, uint open_options, const dd::Table *table_def) override
Definition: ha_tina.cc:886
int update_row(const uchar *old_data, uchar *new_data) override
Update a single row.
Definition: ha_tina.cc:991
my_off_t current_position
Definition: ha_tina.h:76
File update_temp_file
Definition: ha_tina.h:83
virtual bool fast_key_read()
Definition: ha_tina.h:135
~ha_tina() override
Definition: ha_tina.h:107
uint max_key_length() const
Definition: ha_tina.h:127
tina_set chain_buffer[DEFAULT_CHAIN_LENGTH]
Definition: ha_tina.h:90
uint max_keys() const
Definition: ha_tina.h:125
int check(THD *thd, HA_CHECK_OPT *check_opt) override
Definition: ha_tina.cc:1579
Transparent_file * file_buff
Definition: ha_tina.h:81
ha_rows estimate_rows_upper_bound() override
Return upper bound of current number of records in the table (max.
Definition: ha_tina.h:141
uint32 chain_size
Definition: ha_tina.h:94
ulong index_flags(uint, uint, bool) const override
Definition: ha_tina.h:117
uint max_key_parts() const
Definition: ha_tina.h:126
THR_LOCK_DATA ** store_lock(THD *thd, THR_LOCK_DATA **to, enum thr_lock_type lock_type) override
Is not invoked for non-transactional temporary tables.
Definition: ha_tina.cc:1529
File data_file
Definition: ha_tina.h:82
int init_data_file()
Initialize the data file.
Definition: ha_tina.cc:1067
void position(const uchar *record) override
Definition: ha_tina.cc:1172
uint max_record_length() const
Definition: ha_tina.h:124
uint local_data_file_version
Definition: ha_tina.h:95
my_off_t temp_file_length
Definition: ha_tina.h:79
ulonglong table_flags() const override
Definition: ha_tina.h:113
void update_status()
Definition: ha_tina.cc:876
int extra(enum ha_extra_function operation) override
Storage engine specific implementation of ha_extra()
Definition: ha_tina.cc:1208
uchar chain_alloced
Definition: ha_tina.h:93
bool check_and_repair(THD *thd) override
Check and repair the table if necessary.
Definition: ha_tina.cc:376
The handler class is the interface for dynamically loadable storage engines.
Definition: handler.h:4365
A table definition from the master.
Definition: rpl_utility.h:247
#define DEFAULT_CHAIN_LENGTH
Definition: ha_tina.h:33
my_off_t ha_rows
Definition: my_base.h:1139
ha_extra_function
Definition: my_base.h:183
#define HA_POS_ERROR
Definition: my_base.h:1141
Some integer typedefs for easier portability.
unsigned long long int ulonglong
Definition: my_inttypes.h:55
ulonglong my_off_t
Definition: my_inttypes.h:71
unsigned char uchar
Definition: my_inttypes.h:51
uint32_t uint32
Definition: my_inttypes.h:66
Common #defines and includes for file and socket I/O.
#define FN_REFLEN
Definition: my_io.h:82
constexpr const size_t IO_SIZE
Definition: my_io.h:158
int File
Definition: my_io_bits.h:50
void my_free(void *ptr)
Frees the memory pointed by the ptr.
Definition: my_memory.cc:80
static int record
Definition: mysqltest.cc:187
Definition: buf0block_hint.cc:29
mode
Definition: file_handle.h:59
#define HA_BINLOG_ROW_CAPABLE
Definition: handler.h:338
#define HA_MAX_REC_LENGTH
Definition: handler.h:616
#define HA_CAN_REPAIR
Definition: handler.h:368
#define HA_BINLOG_STMT_CAPABLE
Definition: handler.h:339
#define HA_NO_TRANSACTIONS
Definition: handler.h:209
#define HA_NO_AUTO_INCREMENT
Definition: handler.h:313
Our own string classes, used pervasively throughout the executor.
case opt name
Definition: sslopt-case.h:32
Definition: handler.h:3583
Definition: handler.h:2998
The MEM_ROOT is a simple arena, where allocations are carved out of larger blocks.
Definition: my_alloc.h:82
void Clear()
Deallocate all the RAM used.
Definition: my_alloc.cc:168
This structure is shared between different table objects.
Definition: table.h:688
Definition: thr_lock.h:123
Definition: thr_lock.h:138
bool crashed
Definition: ha_tina.h:62
bool is_log_table
Definition: ha_tina.h:49
File meta_file
Definition: ha_tina.h:60
mysql_mutex_t mutex
Definition: ha_tina.h:56
File tina_write_filedes
Definition: ha_tina.h:61
THR_LOCK lock
Definition: ha_tina.h:57
char * table_name
Definition: ha_tina.h:42
bool tina_write_opened
Definition: ha_tina.h:59
uint table_name_length
Definition: ha_tina.h:44
char data_file_name[FN_REFLEN]
Definition: ha_tina.h:43
bool update_file_opened
Definition: ha_tina.h:58
my_off_t saved_data_file_length
Definition: ha_tina.h:55
uint use_count
Definition: ha_tina.h:44
uint data_file_version
Definition: ha_tina.h:64
ha_rows rows_recorded
Definition: ha_tina.h:63
handlerton is a singleton structure - one instance per storage engine - to provide access to storage ...
Definition: handler.h:2594
An instrumented mutex structure.
Definition: mysql_mutex_bits.h:49
Definition: mysqlslap.cc:237
my_off_t begin
Definition: ha_tina.h:68
my_off_t end
Definition: ha_tina.h:69
thr_lock_type
Definition: thr_lock.h:50
unsigned int uint
Definition: uca9-dump.cc:74