线程尝试加入自身
我正在构建 Ruby on Rails v2.3.8 房地产应用程序。我编写了一个 rake 任务来提取房产列表和照片。该应用程序使用 rets4r(特别是 josephholsten-rets4r)与基于 RETS 的服务器进行通信,并使用 Paperclip 来管理房产照片并将其推送到 S3。
我看到的问题是 rake 任务永远不会完成。它总是会在某个时刻崩溃,而且永远不会在同一个地方。有一次它在 45 分钟后崩溃,经过一些小的更改(添加了一些开始/救援块以尝试跟踪错误),它似乎运行了更长的时间(2-12 小时),但仍然崩溃。
我收到的错误始终是“Rake 中止”,然后“线程 [内存地址] 尝试加入自身”。查看日志没有提供任何帮助。只是标准回形针日志消息。我也不是故意尝试在 rake 任务中做任何多线程的事情。
更新:我使用的是rets4r的gem版本1.1.17。然而,我注意到在该项目的 Github 页面上,自从标记该版本以来已经有相当多的提交。 这些提交之一讨论了删除线程的使用。
I am working on building a Ruby on Rails v2.3.8 real estate application. I've written a rake task to pull in the property listings and photos. The app uses rets4r (specifically josephholsten-rets4r) to talk to a RETS-based server and Paperclip is used to manage the property photos and push them up to S3.
The problem I'm seeing is the rake task never completes. It will always crash at some point and it's never the same spot. One time it crashed after 45 min, after some minor changes (added some begin/rescue blocks to try and track down the error), it seems to run longer (2-12 hours), but still crashes.
The error I get is always "Rake aborted" and then "thread [memory address] tried to join itself." Looking into the logs provides nothing helpful. Just the standard Paperclip log messages. I'm also not deliberately trying to do anything multi-threaded in the rake task.
Update: I was using the gem version 1.1.17 of rets4r. However, I notice on the Github page for the project, there have been quite a few commits since that version was tagged. One of those commits talks about removing the use of threads.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论