Last active
November 11, 2015 07:28
-
-
Save xxuejie/ab6ec03a17d14b942e77 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ # testing syro | |
| $ wrk -t12 -c400 -d30s http://localhost:9292/foo/bar | |
| Running 30s test @ http://localhost:9292/foo/bar | |
| 12 threads and 400 connections | |
| Thread Stats Avg Stdev Max +/- Stdev | |
| Latency 167.40ms 82.15ms 1.91s 79.52% | |
| Req/Sec 103.17 77.63 420.00 61.45% | |
| 17668 requests in 30.09s, 3.10MB read | |
| Socket errors: connect 0, read 439, write 14, timeout 19 | |
| Requests/sec: 587.24 | |
| Transfer/sec: 105.52KB | |
| $ # testing kemal | |
| $ wrk -t12 -c400 -d30s http://localhost:3000/foo/bar | |
| Running 30s test @ http://localhost:3000/foo/bar | |
| 12 threads and 400 connections | |
| Thread Stats Avg Stdev Max +/- Stdev | |
| Latency 16.06ms 1.37ms 33.33ms 90.16% | |
| Req/Sec 2.05k 169.30 8.65k 89.86% | |
| 733524 requests in 30.08s, 69.25MB read | |
| Socket errors: connect 0, read 227, write 12, timeout 0 | |
| Requests/sec: 24386.78 | |
| Transfer/sec: 2.30MB | |
| $ # syro again | |
| $ wrk -t12 -c400 -d30s http://localhost:9292/admin | |
| Running 30s test @ http://localhost:9292/admin | |
| 12 threads and 400 connections | |
| Thread Stats Avg Stdev Max +/- Stdev | |
| Latency 172.86ms 66.40ms 585.74ms 71.93% | |
| Req/Sec 95.39 76.58 400.00 53.70% | |
| 17331 requests in 30.10s, 3.02MB read | |
| Socket errors: connect 0, read 35, write 1, timeout 0 | |
| Requests/sec: 575.85 | |
| Transfer/sec: 102.92KB | |
| $ # kemal again | |
| $ wrk -t12 -c400 -d30s http://localhost:3000/admin | |
| Running 30s test @ http://localhost:3000/admin | |
| 12 threads and 400 connections | |
| Thread Stats Avg Stdev Max +/- Stdev | |
| Latency 16.37ms 1.47ms 45.96ms 89.55% | |
| Req/Sec 2.02k 107.11 2.34k 80.94% | |
| 723533 requests in 30.05s, 71.76MB read | |
| Socket errors: connect 0, read 202, write 0, timeout 0 | |
| Non-2xx or 3xx responses: 723533 | |
| Requests/sec: 24079.76 | |
| Transfer/sec: 2.39MB |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "kemal" | |
| get "/foo/bar" do | |
| "hello world" | |
| end | |
| get "admin" do | |
| "for admins" | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Started with a plain rackup | |
| require "syro" | |
| Admin = Syro.new { | |
| get { | |
| res.write("for admins") | |
| } | |
| } | |
| App = Syro.new { | |
| on("foo/bar") { | |
| get { | |
| res.write("hello world") | |
| } | |
| } | |
| on("admin") { | |
| run(Admin) | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment