Permalink
Browse files

Cleanup, gem dep fixes

  • Loading branch information...
mperham committed Apr 3, 2010
1 parent 1f94605 commit 5a7d1f895531d9a8604f42b88964a3d3d208aec9
Showing with 14 additions and 9 deletions.
  1. +1 −1 Gemfile
  2. +3 −3 Gemfile.lock
  3. +6 −1 performance.txt → Performance.md
  4. +0 −4 app/controllers/hello_controller.rb
  5. +3 −0 app/models/site.rb
  6. +1 −0 config/database.yml
View
@@ -2,7 +2,7 @@ gem 'em-http-request', '0.2.7'
gem 'rails', '2.3.5'
gem 'postgres-pr', '0.6.1'
gem 'eventmachine', '0.12.10'
-gem 'em_postgresql', '0.2.1'
+gem 'em_postgresql', '0.3.0'
gem 'rake', '0.8.7'
gem 'thin', '1.2.7'
gem 'rack', '>=1.0.0'
View
@@ -1,5 +1,5 @@
---
-hash: 64bf2723827f4074d746764c16a29381077ca9c7
+hash: 2c0189aa610cd85e3236b6e3b0a5d297d0322291
sources: []
specs:
@@ -46,7 +46,7 @@ specs:
- postgres-pr:
version: 0.6.1
- em_postgresql:
- version: 0.2.1
+ version: 0.3.0
- rails:
version: 2.3.5
- em-http-request:
@@ -69,7 +69,7 @@ dependencies:
group:
- :default
em_postgresql:
- version: = 0.2.1
+ version: = 0.3.0
group:
- :default
rake:
@@ -1,4 +1,7 @@
-EventMachine works best when you have unpredictable network delays.
+# A Simple Performance Test
+
+EventMachine works best when you have significant network latency. A simple
+test with database access over a coffeeshop WiFi:
Without EventMachine:
Requests per second: 4.39 [#/sec] (mean)
@@ -7,6 +10,8 @@ EventMachine works best when you have unpredictable network delays.
Requests per second: 21.31 [#/sec] (mean)
+## More detail:
+
Without EventMachine, where database is across a slow network (aka coffeeshop WiFi)
> ab -n 1000 -c 50 http://localhost:3000/hello/world
@@ -1,7 +1,3 @@
-class Site < ActiveRecord::Base
- set_table_name 'site'
-end
-
class HelloController < ApplicationController
def world
View
@@ -0,0 +1,3 @@
+class Site < ActiveRecord::Base
+ set_table_name 'site'
+end
View
@@ -5,6 +5,7 @@ base: &base
database: onespot_test
username: mike
password: password
+ schema_search_path: bdu,public
development:
<<: *base

0 comments on commit 5a7d1f8

Please sign in to comment.