Skip to content

Commit

Permalink
Added a readme
Browse files Browse the repository at this point in the history
  • Loading branch information
baconpat committed May 21, 2011
1 parent 80af019 commit 7c56874
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.md
@@ -0,0 +1,11 @@
This is a sample project that illustrates some strange behavior I ran into trying to upload files to Amazon S3 using [EventMachine][http://rubyeventmachine.com/] and the [happening][http://github.com/peritor/happening] non-blocking S3 client.

You need to update the s3.yml file with your S3 account information and run `bundle install`. Then you can run either of the two included scripts:

`ruby lib/http_upload.rb`

or

`ruby lib/https_upload.rb`

On my machine (Mac OS X) when I run the **https** script the CPU spikes to 100% and the event loop is blocked for a couple of minutes before the file starts to transfer. However, the **http** version does not block the event loop, uses almost no CPU, and starts transferring data right away.

0 comments on commit 7c56874

Please sign in to comment.