48 typedef std::vector<Datafile, ut::allocator<Datafile>>
files_t;
148 for (files_t::const_iterator it =
m_files.begin(); it !=
m_files.end();
uint32_t space_id_t
Tablespace identifier.
Definition: api0api.h:50
uint32_t page_no_t
Page number.
Definition: api0api.h:48
Data file control information.
Definition: fsp0file.h:71
static void normalize(std::string &path)
Normalize a directory path for the current OS: On Windows, we convert '/' to '\', else we convert '\'...
Definition: fil0fil.h:878
Data structure that contains the information about shared tablespaces.
Definition: fsp0space.h:46
uint32_t flags() const
Get the tablespace flags.
Definition: fsp0space.h:133
uint64_t get_autoextend_size() const
Definition: fsp0space.h:185
Datafile * first_datafile()
Definition: fsp0space.h:176
virtual ~Tablespace()
Definition: fsp0space.h:64
void delete_files()
Delete all the data files.
Definition: fsp0space.cc:97
char * m_name
Name of the tablespace.
Definition: fsp0space.h:200
void set_path(const char *path, size_t len)
Set tablespace path and filename members.
Definition: fsp0space.h:97
page_no_t get_sum_of_sizes() const
Definition: fsp0space.h:145
bool m_ignore_read_only
Ignore server read only configuration for this tablespace.
Definition: fsp0space.h:216
Tablespace()
Definition: fsp0space.h:53
void set_ignore_read_only(bool read_only_status)
Set Ignore Read Only Status for tablespace.
Definition: fsp0space.h:137
uint64_t m_autoextend_size
Autoextend size.
Definition: fsp0space.h:212
bool intersection(const Tablespace *other_space)
Check if two tablespaces have common data file names.
Definition: fsp0space.cc:45
void set_autoextend_size(uint64_t size)
Definition: fsp0space.h:182
const char * path() const
Get tablespace path.
Definition: fsp0space.h:111
space_id_t m_space_id
Tablespace ID.
Definition: fsp0space.h:203
Tablespace(const Tablespace &)
void file_found(Datafile &file)
Note that the data file was found.
Definition: fsp0space.cc:73
const char * name() const
Get tablespace name.
Definition: fsp0space.h:92
void set_space_id(space_id_t space_id)
Set the space id of the tablespace.
Definition: fsp0space.h:115
void shutdown()
Free the memory allocated by the Tablespace object.
Definition: fsp0space.cc:59
void set_name(const char *name)
Set tablespace name.
Definition: fsp0space.h:84
uint32_t m_flags
Tablespace flags.
Definition: fsp0space.h:209
space_id_t space_id() const
Get the space id of the tablespace.
Definition: fsp0space.h:122
std::vector< Datafile, ut::allocator< Datafile > > files_t
Definition: fsp0space.h:48
dberr_t add_datafile(const char *datafile_added)
Use the ADD DATAFILE path to create a Datafile object and add it to the front of m_files.
Definition: fsp0space.cc:123
char * m_path
Path where tablespace files will reside, not including a filename.
Definition: fsp0space.h:206
void set_flags(uint32_t fsp_flags)
Set the tablespace flags.
Definition: fsp0space.h:126
Tablespace & operator=(const Tablespace &)
bool find(const char *filename)
Find a filename in the list of Datafiles for a tablespace.
Definition: fsp0space.cc:84
void set_path(const char *path)
Set tablespace path and filename members.
Definition: fsp0space.h:107
files_t m_files
Data file information - each Datafile can be accessed globally.
Definition: fsp0space.h:51
dberr_t
Definition: db0err.h:38
constexpr space_id_t SPACE_UNKNOWN
Unknown space id.
Definition: fil0fil.h:1152
Tablespace data file implementation.
bool fsp_flags_is_valid(uint32_t flags)
Validate the tablespace flags.
Definition: fsp0fsp.ic:316
static char * mem_strdup(const char *str)
Duplicates a NUL-terminated string.
static char * mem_strdupl(const char *str, ulint len)
Makes a NUL-terminated copy of a nonterminated string.
void free(void *ptr) noexcept
Releases storage which has been dynamically allocated through any of the ut::malloc*(),...
Definition: ut0new.h:716
const char * filename
Definition: pfs_example_component_population.cc:66
Version control for database, common definitions, and include files.
#define ut_ad(EXPR)
Debug assertion.
Definition: ut0dbg.h:68
#define ut_a(EXPR)
Abort execution if EXPR does not evaluate to nonzero.
Definition: ut0dbg.h:56
Dynamic memory allocation routines and custom allocators specifically crafted to support memory instr...