本地优先软件的 behavioral 类型
Behavioural Types for Local-First Software
AI总结:
本文提出 swarm 协议,从全局视角指定点对点系统,通过事件通知机制实现本地优先协作,并在良构条件下保证一致性恢复,为推理此类系统提供基础。
摘要:
点对点系统是分布式计算中最具弹性的形式,但为其协调设计健壮的协议是困难的。这使得难以指定和推理此类系统的全局行为。本文提出了 swarm 协议,从全局视角来指定此类系统。Swarm 协议被投影到机器上,即对等方的本地规范。我们借鉴了 behavioral 类型,但有一个关键区别:对等方通过事件通知机制通信,而非通过点对点消息传递。我们的目标是遵循本地优先软件的原则,即网络设备在协作完成共同任务的同时保持完全自主性:每台参与设备始终可以在本地取得进展,不受其他设备或网络连接不可用的阻碍。这种免协调的方法会导致计算过程中可能出现的矛盾。我们的主要结果表明,在 swarm 协议的适当良构条件下,一致性最终得以恢复,且符合规范的机器在本地可观察的行为最终将与全局规范匹配。我们提出的模型基于现有的工业平台进行阐述,并为工具支持(此处概述,并在配套工件论文中完整描述)提供了基础,因此我们认为这项工作朝着推理本地优先和点对点软件系统迈出了可行的一步。
英文摘要:
Peer-to-peer systems are the most resilient form of distributed computing, but the design of robust protocols for their coordination is difficult. This makes it hard to specify and reason about global behaviour of such systems. This paper presents swarm protocols to specify such systems from a global viewpoint. Swarm protocols are projected to machines, that is local specifications of peers. We take inspiration from behavioural types with a key difference: peers communicate through an event notification mechanism rather than through point-to-point message passing. Our goal is to adhere to the principles of local-first software where network devices collaborate on a common task while retaining full autonomy: every participating device can locally make progress at all times, not encumbered by unavailability of other devices or network connections. This coordination-free approach leads to inconsistencies that may emerge during computations. Our main result shows that under suitable well-formedness conditions for swarm protocols consistency is eventually recovered and the locally observable behaviour of conforming machines will eventually match the global specification. The model we propose elaborates on an existing industrial platform and provides the basis for tool support (sketched here and fully described in a companion artifact paper), wherefore we consider this work to be a viable step towards reasoning about local-first and peer-to-peer software systems.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。