Skip to content

[Feature] 重构模组读取的线程模型 #6568

Description

@Lokins577

概述 | Summary

重新梳理 HMCL 读取模组内容时的线程模型,用 每实例单写执行器 + UI 消费不可变快照 替代当前散落各处的 ReentrantLock / ConcurrentHashMap / volatile,使 ModManager 回到单线程的干净状态。

原因 | Reason

#6230 的 review 中,Glavo 指出:

感觉这个 PR 实现的很奇怪。我们可能需要先好好思考一下 HMCL 读取这些内容时的线程模型,而不是像这个 PR 搞得到处是锁,到处上 ConcurrentHashMap

详情 | Description

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions