34#define DEFAULT_CHAIN_LENGTH 512
133 return (
double)(
stats.records +
stats.deleted) / 20.0 + 10;
146 int close(
void)
override;
150 int rnd_init(
bool scan =
true)
override;
167 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:168
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:34
Definition: transparent_file.h:35
int delete_row(const uchar *buf) override
Definition: ha_tina.cc:1036
ha_tina(handlerton *hton, TABLE_SHARE *table_arg)
Definition: ha_tina.cc:510
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:1378
bool get_write_pos(my_off_t *end_pos, tina_set *closest_hole)
Definition: ha_tina.cc:1224
int write_row(uchar *buf) override
Write a row.
Definition: ha_tina.cc:935
int chain_append()
Definition: ha_tina.cc:604
tina_set * chain_ptr
Definition: ha_tina.h:93
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:1624
my_off_t local_saved_data_file_length
Definition: ha_tina.h:79
bool is_crashed() const override
Check if the table is crashed.
Definition: ha_tina.cc:406
int init_tina_writer()
Definition: ha_tina.cc:384
int open_update_temp_file_if_needed()
Definition: ha_tina.cc:968
int rnd_pos(uchar *buf, uchar *pos) override
Definition: ha_tina.cc:1183
uchar byte_buffer[IO_SIZE]
Definition: ha_tina.h:81
THR_LOCK_DATA lock
Definition: ha_tina.h:74
const char * table_type() const override
The following can be called without an open handler.
Definition: ha_tina.h:113
MEM_ROOT blobroot
Definition: ha_tina.h:98
int close(void) override
Definition: ha_tina.cc:923
bool records_is_known
Definition: ha_tina.h:97
int info(uint) override
General method to gather info from handler.
Definition: ha_tina.cc:1197
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:1109
int create(const char *name, TABLE *form, HA_CREATE_INFO *create_info, dd::Table *table_def) override
Create table (implementation).
Definition: ha_tina.cc:1542
int encode_quote(uchar *buf)
Definition: ha_tina.cc:535
my_off_t next_position
Definition: ha_tina.h:78
int find_current_row(uchar *buf)
Definition: ha_tina.cc:639
double scan_time() override
Definition: ha_tina.h:132
TINA_SHARE * share
Definition: ha_tina.h:75
bool auto_repair() const override
Check if the table can be automatically repaired.
Definition: ha_tina.h:159
String buffer
Definition: ha_tina.h:85
void get_status()
Definition: ha_tina.cc:842
tina_set * chain
Definition: ha_tina.h:92
int rnd_next(uchar *buf) override
Definition: ha_tina.cc:1137
int rnd_end() override
Definition: ha_tina.cc:1238
int delete_all_rows(void) override
Delete all rows in a table.
Definition: ha_tina.cc:1502
int open(const char *name, int mode, uint open_options, const dd::Table *table_def) override
Definition: ha_tina.cc:887
int update_row(const uchar *old_data, uchar *new_data) override
Update a single row.
Definition: ha_tina.cc:992
my_off_t current_position
Definition: ha_tina.h:77
File update_temp_file
Definition: ha_tina.h:84
virtual bool fast_key_read()
Definition: ha_tina.h:136
~ha_tina() override
Definition: ha_tina.h:108
uint max_key_length() const
Definition: ha_tina.h:128
tina_set chain_buffer[DEFAULT_CHAIN_LENGTH]
Definition: ha_tina.h:91
uint max_keys() const
Definition: ha_tina.h:126
int check(THD *thd, HA_CHECK_OPT *check_opt) override
Definition: ha_tina.cc:1580
Transparent_file * file_buff
Definition: ha_tina.h:82
ha_rows estimate_rows_upper_bound() override
Return upper bound of current number of records in the table (max.
Definition: ha_tina.h:142
uint32 chain_size
Definition: ha_tina.h:95
ulong index_flags(uint, uint, bool) const override
Definition: ha_tina.h:118
uint max_key_parts() const
Definition: ha_tina.h:127
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:1530
File data_file
Definition: ha_tina.h:83
int init_data_file()
Initialize the data file.
Definition: ha_tina.cc:1068
void position(const uchar *record) override
Definition: ha_tina.cc:1173
uint max_record_length() const
Definition: ha_tina.h:125
uint local_data_file_version
Definition: ha_tina.h:96
my_off_t temp_file_length
Definition: ha_tina.h:80
ulonglong table_flags() const override
Definition: ha_tina.h:114
void update_status()
Definition: ha_tina.cc:877
int extra(enum ha_extra_function operation) override
Storage engine specific implementation of ha_extra()
Definition: ha_tina.cc:1209
uchar chain_alloced
Definition: ha_tina.h:94
bool check_and_repair(THD *thd) override
Check and repair the table if necessary.
Definition: ha_tina.cc:377
The handler class is the interface for dynamically loadable storage engines.
Definition: handler.h:4414
A table definition from the master.
Definition: rpl_utility.h:248
#define DEFAULT_CHAIN_LENGTH
Definition: ha_tina.h:34
my_off_t ha_rows
Definition: my_base.h:1140
ha_extra_function
Definition: my_base.h:184
#define HA_POS_ERROR
Definition: my_base.h:1142
Some integer typedefs for easier portability.
unsigned long long int ulonglong
Definition: my_inttypes.h:56
ulonglong my_off_t
Definition: my_inttypes.h:72
unsigned char uchar
Definition: my_inttypes.h:52
uint32_t uint32
Definition: my_inttypes.h:67
Common #defines and includes for file and socket I/O.
#define FN_REFLEN
Definition: my_io.h:83
constexpr const size_t IO_SIZE
Definition: my_io.h:159
int File
Definition: my_io_bits.h:51
void my_free(void *ptr)
Frees the memory pointed by the ptr.
Definition: my_memory.cc:81
static int record
Definition: mysqltest.cc:188
Definition: buf0block_hint.cc:30
mode
Definition: file_handle.h:60
#define HA_BINLOG_ROW_CAPABLE
Definition: handler.h:339
#define HA_MAX_REC_LENGTH
Definition: handler.h:617
#define HA_CAN_REPAIR
Definition: handler.h:369
#define HA_BINLOG_STMT_CAPABLE
Definition: handler.h:340
#define HA_NO_TRANSACTIONS
Definition: handler.h:210
#define HA_NO_AUTO_INCREMENT
Definition: handler.h:314
Our own string classes, used pervasively throughout the executor.
case opt name
Definition: sslopt-case.h:33
Definition: handler.h:3632
Struct to hold information about the table that should be created.
Definition: handler.h:3045
The MEM_ROOT is a simple arena, where allocations are carved out of larger blocks.
Definition: my_alloc.h:83
void Clear()
Deallocate all the RAM used.
Definition: my_alloc.cc:171
This structure is shared between different table objects.
Definition: table.h:690
Definition: thr_lock.h:124
Definition: thr_lock.h:139
bool crashed
Definition: ha_tina.h:63
bool is_log_table
Definition: ha_tina.h:50
File meta_file
Definition: ha_tina.h:61
mysql_mutex_t mutex
Definition: ha_tina.h:57
File tina_write_filedes
Definition: ha_tina.h:62
THR_LOCK lock
Definition: ha_tina.h:58
char * table_name
Definition: ha_tina.h:43
bool tina_write_opened
Definition: ha_tina.h:60
uint table_name_length
Definition: ha_tina.h:45
char data_file_name[FN_REFLEN]
Definition: ha_tina.h:44
bool update_file_opened
Definition: ha_tina.h:59
my_off_t saved_data_file_length
Definition: ha_tina.h:56
uint use_count
Definition: ha_tina.h:45
uint data_file_version
Definition: ha_tina.h:65
ha_rows rows_recorded
Definition: ha_tina.h:64
handlerton is a singleton structure - one instance per storage engine - to provide access to storage ...
Definition: handler.h:2622
An instrumented mutex structure.
Definition: mysql_mutex_bits.h:50
Definition: mysqlslap.cc:238
my_off_t begin
Definition: ha_tina.h:69
my_off_t end
Definition: ha_tina.h:70
thr_lock_type
Definition: thr_lock.h:51
unsigned int uint
Definition: uca9-dump.cc:75