gpt4 book ai didi

ruby-on-rails - 为什么 Puma 在 WSL 这么慢?

转载 作者:太空宇宙 更新时间:2023-11-03 16:17:00 29 4
gpt4 key购买 nike

我在适用于 Linux 的 Windows 子系统中运行 Puma,安装起来轻而易举,并且可以立即运行,但提供静态文件的速度非常慢。服务他们需要超过 8 秒:

enter image description here

知道发生了什么事或如何解决它吗?应用程序本身运行速度很快。

我通过执行来运行 puma:

rails s Puma

除了将 gem 添加到我的 Gemfile 之外,我还没有为 Puma 做任何特定的配置。

最佳答案

根据 WSL I/O performance issue ,目前看来根本原因是WSL本身。希望微软尽快完善WSL。

Webrick 在 WSL 中运行良好,在开发环境中,您可以运行 rails s webrick 来快速启动 webrick 服务器

关于ruby-on-rails - 为什么 Puma 在 WSL 这么慢?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41513199/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com