SINATRA - files.meetup.comfiles.meetup.com/432104/sinatra_synopsis.pdf · What Sinatra is... Small...
Transcript of SINATRA - files.meetup.comfiles.meetup.com/432104/sinatra_synopsis.pdf · What Sinatra is... Small...
What Sinatra is...
Small library
Fast
Thread-safe
Rack-mounted (on top of mongrel)
Domain (very) Specific Language
Makes few assumptions about user’s app
What Sinatra isn’t...
A replacement for Rails, Merb or that mysterious Camping...
An end-all solution
Slow
Cumbersome
PAINFUL
What Sinatra isn’t...
A replacement for Rails, Merb or that mysterious Camping...
An end-all solution
Slow
Cumbersome
PAINFUL
What Sinatra isn’t...
A replacement for Rails, Merb or that mysterious Camping...
An end-all solution
Slow
Cumbersome
PAINFUL
Sinatra Performance
0
50
100
150
200
250
1 2 3 4 5
req_rate_localhostcon_rate_localhostmin_rep_rate_localhostavg_rep_rate_localhostmax_rep_rate_localhoststddev_rep_rate_localhostresp_time_localhostnet_io_localhosterrors_localhost
Rails Performance
0
200
400
600
800
1000
1200
dem_req_rate
req_rate_localhost
con_rate_localhost
min_rep_rate_localhost
avg_rep_rate_localhost
max_rep_rate_localhost
stddev_rep_rate_localhost
resp_time_localhost
net_io_localhost
errors_localhost
Series1Series2Series3Series4Series5
For a hello world application
Sinatra ran an average of
26x faster than the rails hello world app
In a basic httperf -driven autobench. Both were
run in development mode!
Resources
http://sinatra.rubyforge.nethttp://xnot.org/sinatra
Blake Mizerany - [email protected] Lerner - [email protected]