Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rails-dev-boost in Rails 3.2.8 #36

Closed
nozpheratu opened this issue Nov 8, 2012 · 5 comments
Closed

rails-dev-boost in Rails 3.2.8 #36

nozpheratu opened this issue Nov 8, 2012 · 5 comments

Comments

@nozpheratu
Copy link

I recently upgraded to rails 3.2.8 which seems to use the thin server by default, from my understanding rails-dev-boost only speeds up WEBrick as opposed to the thin server.

Is there any way I can switch back over to WEBrick to get the speed boost offered by this gem?

@thedarkone
Copy link
Owner

rails-dev-boost should be completely server agnostic. The best way to determine if rails-dev-boost is running correctly is to enable the debug mode. This is easiest done by adding a RailsDevelopmentBoost.debug! into a Rails initializer file (these are to be found in config/initializers folder). After restarting the server you should check out your log/development.log file to see if there are [DEV-BOOST] debug messages in there. Try changing a file and then reload a web page to see that rails-dev-boost is indeed unloading relevant constants and files.

@thedarkone
Copy link
Owner

@12eebok any news?

@nozpheratu
Copy link
Author

@thedarkone Sorry I didn't get your first comment notification.

I can confirm that dev boost is indeed running. Perhaps Thin web server is simply slower than WEBrick in general hence the performance drop. I recall when I was running Thin server on Rails 3.1.3 along with rails-dev-boost in development mode I didn't notice any performance gain, but switching over to the default WEBrick yielded a dramatic speed boost in comparison.

The performance difference is fairly negligible on 3.2.8 with Thin server compared to WEBrick on 3.1.3, but only once the website is fully up and running and my browser has everything cached, however. For instance if I was to completely clear my cache in FireFox it can take up to a minute for a page to load and I don't remember having this issue with WEBrick.

@thedarkone
Copy link
Owner

What you are describing (browser cache etc.) probably has to do with the speed of the assets compilation on 3.1 vs 3.2 or something, I don't think rails-dev-boost can be of any help here...

The correctly running rails-dev-boost in debug mode should look like something like this:

  • [DEV-BOOST] [LOAD] and [DEV-BOOST] [ADD_CONSTANTS] messages as the application is booting or server is processing the first request for the given controller/page,
  • [DEV-BOOST] [CHANGED] and gradually indented [DEV-BOOST] [REMOVING] messages if an .rb has been changed and related constants are being unloaded, followed by [DEV-BOOST] [LOAD] and [DEV-BOOST] [ADD_CONSTANTS] on the next request,
  • no [DEV-BOOST] messages if no .rb files have been changed (except maybe an occasional [DEV-BOOST] --- START --- and [DEV-BOOST] --- END --- if rails-dev-boost is not running in an async mode).

@thedarkone
Copy link
Owner

I'm closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants