13

Is Mojolicious' morbo (development web server) good enough for production? Also, is morbo good enough to handle many http requests?

Or, must I use Apache's mod_perl for production instead of morbo?

LeppyR64
  • 4,830
  • 1
  • 26
  • 33
dns
  • 2,564
  • 1
  • 22
  • 30

2 Answers2

31

morbo is the development server which comes with Mojolicious, its key feature is that it reloads the app when source files change. The production server is hypnotoad and that is recommended (even for high-ish loads) for *nix servers. If you aren't using *nix, then the basic daemon should be used, which is the underlying server that runs both morbo and hypnotoad. Read more here: http://mojolicio.us/perldoc/Mojolicious/Guides/Cookbook#DEPLOYMENT

You may deploy behind a Nginx or Apache reverse proxy if you would like, proxying to hypnotoad or the daemon.

Mojolicious apps can be deployed using PSGI servers like Starman or under mod_perl or even CGI environments, but they will not be able to take advantage of several of the real-time features that Mojolicious is especially useful for, like websockets.

TL;DR, use hypnotoad or daemon for your production server.

Joel Berger
  • 19,816
  • 5
  • 47
  • 101
  • just tried hypnotoad, but unfortunately hypnotoad is not available for Windows. But I accept as the answer because you mention about http://mojolicio.us/perldoc/Mojolicious/Guides/Cookbook#DEPLOYMENT ^^ thanks – dns Apr 28 '13 at 16:28
  • 1
    remember that daemon is just a non-dev version of morbo, or really morbo is just daemon with an autorestart feature. Since you are correct, hypnotoad doen't work on windows, if you were considering deploying with morbo, just use daemon. Enjoy :-) – Joel Berger Apr 28 '13 at 20:48
  • yes, I use CGI (with Apache) just for development purpose. But now I'm thinking about deployment – dns Apr 29 '13 at 12:23
5

i do recommend starman for mojolicious apps in production.

http://metacpan.org/pod/Starman

szabgab
  • 5,884
  • 9
  • 45
  • 61
jacktrade
  • 2,838
  • 2
  • 32
  • 42
  • 5
    Real-time mojolicious features will not work when using a PSGI server. This means things like non-blocking requests and websockets will not work. – Joel Berger Apr 27 '13 at 20:31