【问题标题】:Resque Pool launch failure on macOSmacOS 上的 Resque Pool 启动失败
【发布时间】:2018-12-20 22:52:32
【问题描述】:

resque-pool 无法在 macOS High Sierra 上启动 resque worker

错误信息

bjc[5921]: +[__NSPlaceholderDictionary initialize] 可能在调用 fork() 时正在另一个线程中进行。我们不能在 fork() 子进程中安全地调用它或忽略它。而是崩溃。在 objc_initializeAfterForkError 上设置断点进行调试。

【问题讨论】:

    标签: ruby-on-rails resque macos-high-sierra


    【解决方案1】:

    通过the accepted answer for this Stackexchange question 研究并找到了答案 - 它与独角兽有关,但非常适用于我的问题。

    Apple 在分叉进程方面对 High Sierra 进行了安全相关的更改。

    Holger 的回答提供了一种解决方法,可以通过环境变量禁用 High Sierra 中的新安全功能。

    OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES
    

    这解决了我的问题。我现在可以通过resque-pool 启动 resque 工作人员。

    红宝石

    有关Ruby context is discussed here的问题的更多详细信息

    raised an issue on the resque-pool gem。但可能在 Ruby 中有更多需要解决的问题。我不够专业……

    【讨论】:

      猜你喜欢
      • 2013-07-15
      • 2023-04-08
      • 2022-11-13
      • 1970-01-01
      • 2017-05-07
      • 2021-01-07
      • 1970-01-01
      • 2017-12-01
      • 2015-11-13
      相关资源
      最近更新 更多