Search code examples
ruby-on-railsruby-on-rails-3webrick

Why do I always have to restart the Rails server?


Every time I change anything, I have to restart the server for it to take effect. But that wasn't always the case, it used to work normally before, when I changed anything, it used to get updated automatically.. what happened?


Solution

  • Rails uses config.cache_classes to determine whether it should or should not reload your application classes on each request.

    You should ensure it is set to false in your development.rb file (or whatever environment you actually use).