The popular isolation level Multiversion Read Committed (RC) trades some of the strong guarantees of serializability for increased transaction throughput. Sometimes, transaction workloads can be safely executed under RC obtaining serializability at the lower cost of RC. Such workloads are said to be robust against RC. Previous work has yielded a tractable procedure for deciding robustness against RC for workloads generated by transaction programs modeled as transaction templates. An important insight of that work is that, by more accurately modeling transaction programs, we are able to recognize larger sets of workloads as robust. In this work, we increase the modeling power of transaction templates by extending them with functional constraints, which are useful for capturing data dependencies like foreign keys. We show that the incorporation of functional constraints can identify more workloads as robust that otherwise would not be. Even though we establish that the robustness problem becomes undecidable in its most general form, we show that various restrictions on functional constraints lead to decidable and even tractable fragments that can be used to model and test for robustness against RC for realistic scenarios.
翻译:流行的隔离级别多版本读已提交(RC)以牺牲部分可串行化的强保证为代价,换取更高的事务吞吐量。在某些情况下,事务工作负载可以在RC下安全执行,以更低的成本获得可串行化,此类工作负载被称为对RC具有鲁棒性。已有研究提出了一种可判定过程,用于判定由事务程序(建模为事务模板)生成的工作负载对RC的鲁棒性。该研究的一个重要洞见是:通过更精确地建模事务程序,能识别出更多具有鲁棒性的工作负载。本研究通过引入函数约束来增强事务模板的建模能力,此类约束可有效捕获外键等数据依赖关系。我们证明,函数约束的引入能够识别原本无法被归为鲁棒的更多工作负载。尽管我们发现最一般形式的鲁棒性问题不可判定,但通过施加不同限制条件,函数约束可形成可判定甚至可高效求解的片段,这些片段适用于建模和检验现实场景中对RC的鲁棒性。