这是一个小型的服务端模组,当服务器的 Watchdog 系统因服务器死锁或长时间卡住而将其终止时,该模组会使日志显示更多信息。崩溃报告日志现在将显示在服务器死锁时正在运行的所有代码。换句话说,它将显示所有线程的完整堆栈跟踪,而不是通常被截断(缩短)的版本。
从理论上讲,这应该有助于诊断是什么模组代码或 mixin 导致了“非主线程”卡住。当一个线程卡住时,服务器主线程会被阻塞,如果它保持阻塞状态过久,Watchdog 就会终止它,因为一个 tick 花费了太长时间来完成。它并不能解决所有的死锁问题。 但它可能会为你提供足够的信息来追踪导致某些死锁的原因。
下图是该模组安装前后的示例(画廊标签页能更好地展示图片):

是的,你可以在整合包中发布此模组。 客户端也可以安装此模组,但由于 Watchdog 系统仅在服务器上运行,因此它在客户端上不会有任何作用。你也可以仅在服务端安装此模组。未安装此模组的客户端仍然可以连接。
注意 1: NeoForge 20.4.107 及更高版本已合并此模组!对于 MC 1.20.4 或更高版本,你不需要在 NeoForge 中使用此模组!
注意 2: Fabric API 0.104.0+1.21.2 及更高版本已合并此模组!对于 MC 1.21.2 或更高版本,你不需要在 Fabric 中使用此模组!
This is a tiny server-sided mod that makes it so that the logs show more information when the Watchdog system on the server has killed the server due to being deadlocked or stuck so long. The crash report log will now show all of the code that was running at the time of the deadlocked server. In other words, the full stacktrace of all threads instead of the normally truncated (shortened) version.
In theory, this should help with diagnosing what modded code or mixin has caused an "off-thread" to lock up. When a thread locks up, the server thread gets stuck and if it remains stuck for so long, the Watchdog kills it because a tick took too long to complete. It won't help solve all deadlock issues. But it might get you just enough info to track down the cause of a few deadlocks.
Image below is an example of before and after this mod is put on (Gallery tab shows image better):

Yes you may ship this mod in a modpack. The client can also have this mod on but it won't do anything on client since the Watchdog system is only ran on servers. You can also run servers with this mod only on the server. Clients without this mod can still connect.
NOTE 1: NeoForge 20.4.107 and newer already has this mod merged into it! You do not need this mod in NeoForge for 1.20.4 MC or newer!
NOTE 2: Fabric API 0.104.0+1.21.2 and newer already has this mod merged into it! You do not need this mod in Fabric for 1.21.2 MC or newer!
下载 FullStack Watchdog
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 FullStack Watchdog
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 FullStack Watchdog
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 FullStack Watchdog
下载 FullStack Watchdog
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
(V.1.1.0 更新内容) (Minecraft 1.20.2)
主要更新:
已更新至 Minecraft 1.20.2,并适配 Neoforge
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
查看物品与配方
模组
在游戏画面角落显示附近世界地形、玩家、生物和实体的地图。可创建路径点,帮助你找到标记过的位置。
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
添加区块认领和玩家组队功能,并与 Xaero's Minimap 和 World Map 集成
模组
添加全屏世界地图,显示你在世界中已探索的区域。与 Xaero's Minimap 搭配使用效果极佳。
评论 0
登录后参与评分
还没有评论,来抢沙发吧