The actor model has gained increasing popularity. However, it lacks support for complex state management tasks, such as enforcing foreign key constraints and ensuring data replication consistency across actors. These are crucial properties in partitioned application designs, such as microservices. To fill this gap, we start by analyzing the key impediments in state-of-the-art actor systems. We find it difficult for developers to express complex data relationships across actors and reason about the impact of state updates on performance due to opaque state management abstractions. To solve this conundrum, we develop SmSa, a novel data management layer for actor systems, allowing developers to declare data dependencies that cut across actors, including foreign keys, data replications, and other dependencies. SmSa can transparently enforce the declared dependencies, reducing the burden on developers. Furthermore, SmSa employs novel logging and concurrency control algorithms to support transactional maintenance of data dependencies. We demonstrate SmSa can support core data management tasks where dependencies across components appear frequently without jeopardizing application logic expressiveness and performance. Our experiments show SmSa significantly reduces the logging overhead and leads to increased concurrency level, improving by up to 2X the performance of state-of-the-art deterministic scheduling approaches. As a result, SmSa will make it easier to design and implement highly partitioned and distributed applications.
翻译:Actor模型日益受到欢迎,然而其缺乏对复杂状态管理任务的支持,例如强制执行外键约束和确保跨Actor的数据复制一致性。这些特性在分区化应用设计(如微服务)中至关重要。为填补这一空白,我们首先分析了现有先进Actor系统中的关键障碍。研究发现,由于不透明的状态管理抽象,开发者难以表达跨Actor的复杂数据关系,也难以推断状态更新对性能的影响。为解决这一难题,我们开发了SmSa——一种用于Actor系统的新型数据管理层,允许开发者声明跨Actor的数据依赖关系,包括外键、数据复制及其他依赖类型。SmSa能够透明地强制执行已声明的依赖关系,从而减轻开发者的负担。此外,SmSa采用创新的日志记录与并发控制算法,以支持数据依赖关系的事务性维护。我们证明SmSa能够支持跨组件依赖频繁出现的核心数据管理任务,且不会损害应用逻辑的表达能力与性能。实验表明,SmSa显著降低了日志记录开销,提升了并发水平,较现有确定性调度方法的性能提升最高达2倍。因此,SmSa将使高度分区化与分布式应用的设计与实现更为便捷。