Jetty vs Puma: What are the differences?
Jetty: An open-source project providing an HTTP server, HTTP client, and javax.servlet container. Jetty is used in a wide variety of projects and products, both in development and production. Jetty can be easily embedded in devices, tools, frameworks, application servers, and clusters. See the Jetty Powered page for more uses of Jetty; Puma: A Modern, Concurrent Web Server for Ruby. Unlike other Ruby Webservers, Puma was built for speed and parallelism. Puma is a small library that provides a very fast and concurrent HTTP 1.1 server for Ruby web applications.
Jetty and Puma can be categorized as "Web Servers" tools.
"Lightweight" is the primary reason why developers consider Jetty over the competitors, whereas "Easy" was stated as the key factor in picking Puma.
Jetty and Puma are both open source tools. Puma with 5.78K GitHub stars and 987 forks on GitHub appears to be more popular than Jetty with 2.55K GitHub stars and 1.4K GitHub forks.
According to the StackShare community, Puma has a broader approval, being mentioned in 73 company stacks & 30 developers stacks; compared to Jetty, which is listed in 58 company stacks and 16 developer stacks.
What is Jetty?
What is Puma?
Need advice about which tool to choose?Ask the StackShare community!
Sign up to add, upvote and see more prosMake informed product decisions
Sign up to get full access to all the companiesMake informed product decisions
What tools integrate with Puma?
We switched from Unicorn (process model) to Puma (threaded model) to decrease the memory footprint of our Rails production web server. Memory indeed dropped from 6GB to only 1GB!
We just had to decrease our worker count and increase our thread count instead. Performance (response time and throughput) remained the same, if not slightly better. We had no thread-safety errors, which was good.
Free bonus points are:
- Requests are blazing fast on our dev and staging environments!
- Puma has first-class support for WebSockets, so we know for sure that Rails ActionCable or GraphQL subscriptions will work great.
- Being on Puma makes us even more "default Rails"-compliant since it is the default Rails web server these days.