Skip to main content
QUICK REVIEW

[论文解读] Living in Parallel Realities -- Co-Existing Schema Versions with a Bidirectional Database Evolution Language

Kai Herrmann, Hannes Voigt|arXiv (Cornell University)|Aug 19, 2016
Advanced Database Systems and Queries参考文献 16被引用 28
一句话总结

本文提出 InVerDa,一种通过双向数据库演化语言 BiDEL 实现单一数据库中并存多个模式版本的系统。BiDEL 自动生成增量代码(视图和触发器),以在不同模式版本间同步数据,消除手动维护的需要,实现透明、双向的数据传播,且性能开销极低。

ABSTRACT

We introduce end-to-end support of co-existing schema versions within one database. While it is state of the art to run multiple versions of a continuously developed application concurrently, it is hard to do the same for databases. In order to keep multiple co-existing schema versions alive; which are all accessing the same data set; developers usually employ handwritten delta code (e.g. views and triggers in SQL). This delta code is hard to write and hard to maintain: if a database administrator decides to adapt the physical table schema, all handwritten delta code needs to be adapted as well, which is expensive and error-prone in practice. In this paper, we present InVerDa: developers use the simple bidirectional database evolution language BiDEL, which carries enough information to generate all delta code automatically. Without additional effort, new schema versions become immediately accessible and data changes in any version are visible in all schema versions at the same time. InVerDa also allows for easily changing the physical table design without affecting the availability of co-existing schema versions. This greatly increases robustness (orders of magnitude less lines of code) and allows for significant performance optimization. A main contribution is the formal evaluation that each schema version acts like a common full-fledged database schema independently of the chosen physical table design.

研究动机与目标

  • 解决现代 DBMS 中缺乏对并存模式版本的原生支持的问题,该问题迫使开发人员手动维护复杂的增量代码。
  • 降低敏捷开发和长期系统维护过程中数据库模式演化的成本与出错风险。
  • 使数据库管理员能够自由修改物理表模式,而不会破坏现有模式版本或需要手动更新增量代码。
  • 提供形式化验证的双向转换机制,确保所有模式版本之间的一致性与正确性。
  • 通过自动生�和管理增量代码,实现高性能与高可维护性,与手写 SQL 相比,代码库规模减少 359 倍。

提出的方法

  • 设计 BiDEL,一种双向数据库演化语言,用于定义正向与反向的模式与数据转换。
  • 对双向性进行形式化评估,以保证所有模式版本之间读写传播的正确性。
  • 实现 InVerDa 作为 DBMS 扩展,利用 BiDEL 自动生成视图与触发器,实现跨模式版本的数据同步。
  • 支持完整的访问传播:任一模式版本中的写操作在所有其他版本中均可见,且每个版本均表现如独立、完整的数据库。
  • 将逻辑模式演化与物理模式设计解耦,使 DBA 可在不影响应用层模式版本的前提下优化物理存储。
  • 通过测量多种 SMO 上的传播开销来评估性能,结果显示与理论预期的偏差极小(6.3%)。

实验结果

研究问题

  • RQ1如何在不依赖手动增量代码的前提下,支持单一数据库中的并存模式版本?
  • RQ2为确保模式版本间正确双向数据传播,需要哪些形式化保证?
  • RQ3与手写 SQL 相比,双向数据库演化语言是否能降低模式演化的复杂性与维护成本?
  • RQ4自动生成的增量代码的性能开销在多大程度上影响查询处理?
  • RQ5是否可以独立于逻辑模式版本应用物理模式优化,而不会破坏应用兼容性?

主要发现

  • BiDEL 脚本的长度仅为等效手写 SQL 脚本的 1/359,显著减少了代码库规模与维护负担。
  • 自动生成的增量代码性能开销极低,实测传播时间平均仅比理论预期偏差 6.3%。
  • InVerDa 实现了透明的双向数据传播:任一模式版本中的更改会立即在所有其他版本中可见,且每个版本均表现为功能完整的独立数据库。
  • 数据库管理员可自由修改物理表模式,而不会影响并存的逻辑模式版本的可用性或正确性。
  • 系统通过允许物理模式根据工作负载变化进行自适应调整,支持高效的查询优化,同时保持向后兼容性。
  • 对双向性的形式化验证确保了所有读写操作在所有模式版本之间均被正确传播,提供了强有力的正确性保障。

更好的研究,从现在开始

从论文设计到论文写作,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。