MySQL 9.1.0
Source Code Documentation
Storage operations for SDIs in tablespaces.

Called from functions in sdi.cc if the dd object resides in an SE supporting SDI storage in tablespaces. More...

Collaboration diagram for Storage operations for SDIs in tablespaces.:

Functions

bool dd::sdi_tablespace::store_tbl_sdi (THD *thd, handlerton *hton, const Sdi_type &sdi, const Table &table, const dd::Schema &schema)
 Looks up the relevant tablespaces for the table and stores the table SDI in each. More...
 
bool dd::sdi_tablespace::store_tsp_sdi (handlerton *hton, const Sdi_type &sdi, const Tablespace &tablespace)
 Stores the tablespace SDI in the tablespace. More...
 
bool dd::sdi_tablespace::drop_tbl_sdi (THD *thd, const handlerton &hton, const Table &table, const Schema &schema)
 Looks up the relevant tablespaces for the table and drops the table SDI in each. More...
 
bool dd::sdi_tablespace::drop_all_sdi (THD *, const handlerton &, const Table &)
 Deletes all SDIs with SDI_TYPE_TABLE from the table tablespace. More...
 
bool dd::sdi_tablespace::drop_all_sdi (THD *, const handlerton &, const Partition &)
 Deletes all SDIs with SDI_TYPE_TABLE from the partition tablespace, or sub-partition tablespaces in case of a sub-partitioned table. More...
 

Detailed Description

Called from functions in sdi.cc if the dd object resides in an SE supporting SDI storage in tablespaces.

Note
There is no function for dropping the Tablespace SDI. Dropping a tablespace implies that all SDIs in it are dropped also.

Function Documentation

◆ drop_all_sdi() [1/2]

bool dd::sdi_tablespace::drop_all_sdi ( THD ,
const handlerton ,
const Partition  
)

Deletes all SDIs with SDI_TYPE_TABLE from the partition tablespace, or sub-partition tablespaces in case of a sub-partitioned table.

SDIs with SDI_TYPE_TABLESPACE are only deleted if their tablespace id does not match the current tablespace id of the tablespace being deleted from.

◆ drop_all_sdi() [2/2]

bool dd::sdi_tablespace::drop_all_sdi ( THD ,
const handlerton ,
const Table  
)

Deletes all SDIs with SDI_TYPE_TABLE from the table tablespace.

In case of a partitioned table, SDIs are deleted from all partition tablespaces. SDIs with SDI_TYPE_TABLESPACE are only deleted if their tablespace id does not match the current tablespace id of the tablespace being deleted from.

◆ drop_tbl_sdi()

bool dd::sdi_tablespace::drop_tbl_sdi ( THD thd,
const handlerton hton,
const Table table,
const Schema schema 
)

Looks up the relevant tablespaces for the table and drops the table SDI in each.

Note
When the last table in a schema is dropped from a tablespace the schema SDI should also be dropped. But leaving them is not a big problem as the schema SDIs are small (they only contain the default charset for the schema).

◆ store_tbl_sdi()

bool dd::sdi_tablespace::store_tbl_sdi ( THD thd,
handlerton hton,
const dd::Sdi_type sdi,
const dd::Table table,
const dd::Schema schema 
)

Looks up the relevant tablespaces for the table and stores the table SDI in each.

◆ store_tsp_sdi()

bool dd::sdi_tablespace::store_tsp_sdi ( handlerton hton,
const Sdi_type sdi,
const Tablespace tblspc 
)

Stores the tablespace SDI in the tablespace.