已开启
fix(deployment): explain supervisor connection failures #59
庄昭雄创建于 15 天前
fix(deployment): explain supervisor connection failures #59
已开启
合并受阻
atomgit-bot
15 天前 评论:
15 天前 评论:
变更摘要
本次变更聚焦于 platform/deployment/src/supervisor.rs 中 request 函数的连接诊断能力,在连接 supervisor.sock 失败或超时时给出更明确的错误提示,帮助定位 supervisor 未运行或 state_dir 与运行实例不一致的问题;同时在 platform/deployment/tests/process.rs 中补充了对应的测试用例。
主要改动
- 补充缺失 supervisor 的诊断信息: 在
request函数中新增socket变量(root.join("supervisor.sock")),并将UnixStream::connect的错误包装为提示连接失败原因(supervisor 未运行或deployment state_dir与运行实例不同)的信息。 - 补充超时未响应的诊断信息: 将超时结果由直接
?传递改为map_err,返回包含超时时间与 socket 路径、说明 supervisor 可能已停止或state_dir不一致的错误信息。 - 新增缺失 supervisor 的测试: 在
process.rs中新增request_explains_a_missing_supervisor测试,验证连接不存在的 socket 时错误中包含supervisor与state_dir。 - 新增陈旧 socket 的测试: 新增
request_explains_a_stale_supervisor_socket测试,通过绑定后立即释放监听器模拟陈旧 socket,验证错误提示同样包含supervisor与state_dir。


不准确?
atomgit-bot
15 天前 评论:
15 天前 评论:
openJiuwen-bot
15 天前 评论:
15 天前 评论:
欢迎来到 openJiuwen 社区
Hey @grandocean , 感谢你对社区的贡献.
机器人使用手册
有关指令的使用,可以点击 此处 查看详情。开发人员可以在每个PR或Issue下方评论特定指令来触发机器人任务。


atomgit-bot
15 天前 评论:
15 天前 评论:
15 天前 添加了label:openJiuwen-cla/yes
openJiuwen-bot
15 天前 评论:
15 天前 评论:
15 天前 修改了pull request 的描述
15 天前 修改了pull request 的描述
openJiuwen-bot
15 天前 评论:
15 天前 评论:
The pipeline(pipeline number:59) is running. Please wait a moment...


15 天前 添加了label:ci-running
15 天前 删除了label:ci-running
15 天前 添加了label:ci-successful
Paired: GitHub #48 ↔ GitCode !59
probe