paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Correct Black-Box Monitors for Distributed Deadlock Detection: Formalisation and Implementation

用于分布式死锁检测的正确黑盒监视器:形式化与实现
OOPSLA 9(OOPSLA2)2025匹配度 2/10 · 论文属于形式化验证与分布式运行时监控(黑盒死锁检测),不涉及 LLM/Agent、静态分析或浮点/贝叶斯程序分析,与研究方向的核心交叉点无关;仅在“形式化+工程实现”的研究风格上略有共鸣。引用 0 inbox
Radosław Jan Rowicki, Adrian Francalanza, Alceste Scalas
crossref: 2026-09-10

AI 速览

一句话:提出并实现首个形式化、可证明正确且完备的分布式黑盒死锁检测监视器,适用于 Erlang/OTP RPC 应用。

并发分布式微服务常通过消息传递和 RPC 交互,一旦部分服务死锁,依赖它们的服务会阻塞,死锁核心被掩盖,诊断困难。本文提出部署在各服务旁的黑盒监视器,仅观察出入消息并与其他监视器交换探测信息来检测死锁。作者建立了可刻画 Erlang/OTP gen_server 等 RPC 应用风格的形式模型,给出分布式黑盒监控算法,并证明其可靠且完备:既无假阳性也无假阴性。结果在 Coq 中机器化验证,并实现为 Erlang/OTP 工具 DDMon,评估其性能。这是首个对分布式黑盒死锁检测进行形式化、正确性证明并实现的工具。

问题
如何在不侵入服务内部、仅凭消息观测与监视器间探测的情况下,准确检测分布式 RPC 应用中的死锁,并避免误报与漏报。
方法
建立刻画 RPC 应用风格的形式模型,设计分布式黑盒监控算法,证明其可靠且完备,并在 Coq 中机器化验证;实现为 Erlang/OTP 工具 DDMon。
评估
在 Erlang/OTP 应用上评估 DDMon 的性能,检验其实现可行性与监控开销。
原文摘要(Abstract)

Many software applications rely on concurrent and distributed (micro)services that interact via message passing and various forms of remote procedure calls (RPC). As these systems organically evolve and grow in scale and complexity, the risk of introducing deadlocks increases and their impact may worsen: even if only a few services deadlock, many other services may block while awaiting responses from the deadlocked ones. As a result, the “core” of the deadlock can be obfuscated by its consequences on the rest of the system, and diagnosing and fixing the problem can be challenging. In this work we tackle the challenge by proposing distributed black-box monitors that are deployed alongside each service and detect deadlocks by only observing the incoming and outgoing messages, and exchanging probes with other monitors. We present a formal model that captures popular RPC-based application styles (e.g., gen_servers in Erlang/OTP), and a distributed black-box monitoring algorithm that we prove sound and complete (i.e., identifies deadlocked services with neither false positives nor false negatives). We implement our results in a tool called DDMon for the monitoring of Erlang/OTP applications, and we evaluate its performance. This is the first work that formalises, proves the correctness, and implements distributed black-box monitors for deadlock detection. Our results are mechanised in Coq. DDMon is the companion artifact of this paper.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot2939,
  title = {Correct Black-Box Monitors for Distributed Deadlock Detection: Formalisation and Implementation},
  author = {Radosław Jan Rowicki and Adrian Francalanza and Alceste Scalas},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {OOPSLA2},
  year = {2025},
  doi = {10.1145/3763069}
}