Skip to content

Instantly share code, notes, and snippets.

@sdogruyol
Created January 6, 2016 06:45
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sdogruyol/55fc52902290494670d5 to your computer and use it in GitHub Desktop.
Save sdogruyol/55fc52902290494670d5 to your computer and use it in GitHub Desktop.

Kemal Crystal v0.10.0 vs new-fibers

This benchmark demonstrates the new-fibers improvements via Kemal.

# app.cr
require "kemal"

get "/" do
  "Hello World"
end

To run the app

crystal build --release src/app.cr && ./app

wrk is used to perform the benchmarks

wrk -c 100 -d 10 http://localhost:3000/

Crystal Request Per Second Avg. Response Time
new-fibers 64322.55 1.55ms
v0.10.0 53218.11 1.86ms

Seems like new-fibers increases the rps throughput by around %10 - %20 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment