MySQL 9.1.0
Source Code Documentation
|
Used to insert a single blob into InnoDB. More...
Public Member Functions | |
Blob_handle (Blob_inserter &inserter) | |
Constructor. More... | |
dberr_t | open (lob::ref_t &ref) |
Open a blob. More... | |
dberr_t | write (lob::ref_t &ref, const byte *data, size_t len) |
Write data into a blob. More... | |
dberr_t | close (lob::ref_t &ref) |
Close the blob. More... | |
Private Member Functions | |
dberr_t | extend () |
Page_load * | alloc_first_page () |
Member of Blob_handle. More... | |
Page_load * | alloc_data_page () |
Page_load * | alloc_index_page () |
trx_id_t | get_trx_id () const |
Get the current transaction id. More... | |
Private Attributes | |
lob::bulk::first_page_t | m_first_page |
The first page of the blob. More... | |
lob::bulk::node_page_t | m_node_page |
The LOB index page. More... | |
lob::bulk::data_page_t | m_data_page |
The LOB data page. More... | |
Page_load * | m_first_page_load {nullptr} |
Contains the BUF_BLOCK_MEMORY for the first blob page. More... | |
Page_load * | m_node_page_load {nullptr} |
Contains the BUF_BLOCK_MEMORY for the current index page. More... | |
Page_load * | m_data_page_load {nullptr} |
Contains the BUF_BLOCK_MEMORY for the current data page. More... | |
bool | is_first_page {true} |
True if m_ptr points within first page. More... | |
byte * | m_ptr |
Location where blob data needs to be written. More... | |
size_t | m_len |
Space available at m_ptr for writing blob data. More... | |
size_t | m_blob_length {0} |
Total length of the blob. More... | |
lob::bulk::index_entry_t * | m_index_entry {nullptr} |
byte | m_ref [lob::ref_t::SIZE] |
This is the blob reference. More... | |
Blob_inserter & | m_blob_inserter |
A reference to the Blob_inserter, through which extents would be allocated. More... | |
Used to insert a single blob into InnoDB.
The plan is to keep this private to this module.
|
inline |
Constructor.
Initialize a blob handle.
[in] | inserter | a Blob_inserter object that is inserting the blob. |
|
private |
|
inlineprivate |
Member of Blob_handle.
Allocate the first page of the blob. The returned Page_load object needs to contain a valid page_no and an associated buf_block_t of type BUF_BLOCK_MEMORY. The returned Page_load object is part of an extent that is managed by the m_blob_inserter.
|
private |
dberr_t Btree_multi::bulk::Blob_handle::close | ( | lob::ref_t & | ref | ) |
Close the blob.
[in,out] | ref | blob reference object. |
|
private |
|
inlineprivate |
Get the current transaction id.
dberr_t Btree_multi::bulk::Blob_handle::open | ( | lob::ref_t & | ref | ) |
Open a blob.
[out] | ref | reference of the blob created. It must have lob::ref_t::SIZE bytes to hold a blob reference. |
dberr_t Btree_multi::bulk::Blob_handle::write | ( | lob::ref_t & | ref, |
const byte * | data, | ||
size_t | len | ||
) |
Write data into a blob.
The write is done at the end of the blob.
[in,out] | ref | blob reference object. |
[in] | data | pointer to blob data |
[in] | len | number of bytes to write. |
|
private |
True if m_ptr points within first page.
|
private |
A reference to the Blob_inserter, through which extents would be allocated.
|
private |
Total length of the blob.
|
private |
The LOB data page.
Contains the BUF_BLOCK_MEMORY for the current data page.
|
private |
The first page of the blob.
Contains the BUF_BLOCK_MEMORY for the first blob page.
Once initialized this will not change.
|
private |
|
private |
Space available at m_ptr for writing blob data.
|
private |
The LOB index page.
Contains the BUF_BLOCK_MEMORY for the current index page.
|
private |
Location where blob data needs to be written.
|
private |
This is the blob reference.
Valid after create() call.