A rack-supporting webserver that runs in JRuby and supports SSL and streaming

I'm having issues looking for a rack supporting webserver in Ruby that meets our requirements. What we've coded already is using Sinatra, so that's what we're aiming to run.

The webservice must:

  • Run in JRuby
  • Support SSL
  • support streaming of files. It's much more important to be memory-efficient than performant.
  • Be Multiplatform (Windows and Linux flavours)
  • As lightweight as possible - links back to memory efficiency

We're currently using WEBrick, but it can't handle streaming, so we're looking for alternatives. I've been looking around myself, but I'm having real difficulty finding documentation about what various rack webservers can and can't do. The services I've looked at are:

  • WEBrick - doesn't support streaming
  • Thin - depends on C code, so doesn't run in JRuby
  • Passenger - ditto Thin (C Code)
  • Unicorn - ditto Thin (C Code)

We're aware that it could be deployed J2EE container, but as that would require distributing the container around with it, we'd rather not go down that approach if we can avoid it (as it would be a heavier weight solution).

Thanks in advance for any help people can give.


Does Puma meet your requirements? It supports JRuby, SSL, Windows + Linux, and advertises itself as lightweight. I'm afraid I haven't tried it out, nor do I know if it streams files.

For anyone who finds this question and wants to know what we used in the end: we went with Trinidad as it met all the requirements we needed.

It was quite a simple job to strip out the original WEBrick server we were using and replace it with Trinidad, while still using Sinatra. We then used JRuby to wrap it all up into a Jar and run it in the JVM as a self contained web-service package.

Need Your Help

Localized resources in database?

asp.net resources localization

my web application uses a menu for the user navigation, and I need to store the menu in the database. among other properties, each menu item has a text title. But I do not want to store title strin...