innodb 回滚段内存结构
来源:互联网 发布:电脑办公软件分类 编辑:程序博客网 时间:2024/05/16 18:06
/* The rollback segment memory object */struct trx_rseg_t{/**********************************************************/ ulintid;/*!rollback segment id == the index of its slot in the trx system file copy */ ulintspace;/*!space where the rollback segment is header is placed */ ulintpage_no;/* page number of the rollback segment header ,即slot所在页页号*//*--------------------------------------------------------*//* Fields for update undo logs */UT_LIST_BASE_NODE_T(trx_undo_t) update_undo_list;/* List of update undo logs */UT_LIST_BASE_NODE_T(trx_undo_t) update_undo_cached;/* List of update undo log segmentscached for fast reuse *//*--------------------------------------------------------*//* Fields for insert undo logs */UT_LIST_BASE_NODE_T(trx_undo_t) insert_undo_list;/* List of insert undo logs */UT_LIST_BASE_NODE_T(trx_undo_t) insert_undo_cached;/* List of insert undo log segmentscached for fast reuse *//*--------------------------------------------------------*/ //undo log 页ulintlast_page_no;/*!< Page number of the last not yetpurged log header in the history list; FIL_NULL if all list purged */ulintlast_offset;/*!< Byte offset of the last not yet purged log header */trx_id_tlast_trx_no;/*!< Transaction number of the last not yet purged log */iboollast_del_marks;/*!< TRUE if the last not yet purged log needs purging */};
1、将undo页插入historylist时,如果是第一次插入,即该回滚段最早的事务,将相关信息保存到回滚段的内存结构中,即下面几个成员保存的是回滚段中最老事务的信息:
trx_commit->trx_commit_low->trx_write_serialisation_history->trx_undo_update_cleanup->trx_purge_add_update_undo_to_history: if (rseg->last_page_no ==FIL_NULL) { rseg->last_page_no= undo->hdr_page_no;//undo页的页号 rseg->last_offset= undo->hdr_offset;//undo log header的偏移 rseg->last_trx_no= trx->no;//最大事务ID,commit in memory之前的所有事务 rseg->last_del_marks= undo->del_marks;//只在update中 }
0 0
- innodb 回滚段内存结构
- INNODB内存结构
- InnoDB页结构浅析
- InnoDB记录结构浅析
- 关于innodb文件结构
- Innodb 索引结构了解
- InnoDB页结构浅析
- InnoDB记录结构浅析
- Innodb 表结构学习
- InnoDB 页管理结构
- InnoDB INODE 页结构
- myisam、innodb物理结构
- InnoDB 基本存储结构
- InnoDB数据页结构
- InnoDB 的表结构
- MySQL InnoDB存储结构
- mysql innodb 内存
- Innodb 索引结构了解 - Innodb Index Structure
- Golang 中的 panic 与 recover 理解
- 【PHP】操作图片函数实例
- Java8新特性
- ssh连接树莓派
- Java Web服务收到请求时线程的情况
- innodb 回滚段内存结构
- 安装nodejs遇到2503问题解决方法
- docker安装
- Druid WebStatFilter配置 关联监控数据
- 浅谈前端性能优化(七)——图像优化
- bzoj1027 合金 Floyd求最小环 + 计算几何
- UML九种图之用例图
- LeetCode Algorithms 128. Longest Consecutive Sequence 题解
- 按键扫描与状态机结合