<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>lib/client.rb</filename>
    </added>
    <added>
      <filename>views/queue_created.haml</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -5,7 +5,7 @@ SQS Accelerator
 
 _WARNING: this is totally experimental right now! It's just an idea I'm playing with and I'm trying to see if it works. (But please try it out and tell me what you think!)_
 
-This is a simple evented server (using [Event Machine](http://eventmachine.rubyforge.org)) that proxies requests to Amazon's [Simple Queue Service](http://aws.amazon.com/sqs/) hosted queue. It's purpose is to queue messages very quickly, because otherwise SQS is too slow to use from within a web app (to be precise, the time it takes to queue a message is often too long).
+This is a simple and scalable event-driven server (using [Event Machine](http://eventmachine.rubyforge.org)) that proxies requests to Amazon's [Simple Queue Service](http://aws.amazon.com/sqs/) hosted queue. It's purpose is to queue messages very quickly, because otherwise SQS is too slow to use from within a web app (to be precise, the time it takes to queue a message is often too long).
 
 It provides a simple RESTful interface for interacting with SQS that's also convenient to use from a browser.
 </diff>
      <filename>README.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,14 @@
 require &quot;em-http&quot;
-require &quot;sqs_helper&quot;
-require &quot;sqs_proxy&quot;
+require &quot;haml&quot;
+require &quot;logger&quot;
+require &quot;pp&quot;
+require &quot;sinatra/async&quot;
 require &quot;xml&quot;
 
+require &quot;#{File.dirname(__FILE__)}/sqs_accelerator&quot;
+require &quot;#{File.dirname(__FILE__)}/sqs_helper&quot;
+require &quot;#{File.dirname(__FILE__)}/sqs_proxy&quot;
+
 class SqsAccelerator::Server &lt; Sinatra::Base  
   register Sinatra::Async
   
@@ -81,7 +87,10 @@ class SqsAccelerator::Server &lt; Sinatra::Base
     operation = proc do
       sqs = SqsAccelerator::SqsProxy.new(aws_access_key_id, aws_secret_access_key, :logger =&gt; logger)
       sqs.create_queue(queue_name, visibility_timeout)
-      redirect &quot;/queues/#{queue_name}&quot;
+      # TODO check the result and return an error unless success
+      # TODO set Location header field with URI
+      response.status = 201 # &quot;Created&quot;: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
+      body haml :queue_created, :locals =&gt; { :queue_name =&gt; queue_name }
     end
     EM.defer(operation)    
   end
@@ -121,7 +130,9 @@ class SqsAccelerator::Server &lt; Sinatra::Base
     end
     
     # Messaage seems to be OK, return a response immediately then send message to SQS
+    response.status = 202 # &quot;Accepted&quot;: http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
     body &quot;Message will be queued, check log for errors.\n&quot;
+    # TODO generate and return a message id then log that with the SQS message id?
     
     request_hash = generate_request_hash(&quot;SendMessage&quot;, :message =&gt; message_body)
     # build the body string ourselves for now until Ilya's gem gets updated because of the content-length bug</diff>
      <filename>lib/server.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,12 +1,2 @@
-require &quot;sinatra/async&quot;
-require &quot;logger&quot;
-require &quot;haml&quot;
-require &quot;pp&quot;
-
 module SqsAccelerator  
 end
-
-# Dir.glob(File.dirname(__FILE__) + &quot;/*.rb&quot;).each do |file|
-#   require file
-# end
-require &quot;lib/server&quot;
\ No newline at end of file</diff>
      <filename>lib/sqs_accelerator.rb</filename>
    </modified>
    <modified>
      <diff>@@ -3,7 +3,7 @@ spec = Gem::Specification.new do |s|
   s.version = '0.0.1'
   s.date = '2009-06-22'
   s.summary = 'SQS Accelerator'
-  s.description = &quot;A simple evented server that proxies requests to Amazon's Simple Queue Service to queue messages very quickly.&quot;
+  s.description = &quot;A simple and scalable event-drive server that proxies requests to Amazon's Simple Queue Service to queue messages very quickly.&quot;
   s.email = 'paul@pauldowman.com'
   s.homepage = &quot;http://github.com/pauldowman/sqs-accelerator&quot;
   s.has_rdoc = false</diff>
      <filename>sqs_accelerator.gemspec</filename>
    </modified>
    <modified>
      <diff>@@ -1,5 +1,5 @@
 #!/usr/bin/env rackup -Ilib:../lib -s thin
 
-require 'lib/sqs_accelerator'
+require 'lib/server'
 
 run SqsAccelerator::Server.new</diff>
      <filename>sqs_accelerator.ru</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>e6fd8ce1f63659ba6abc0bfc0e8bc5f7d97fbf81</id>
    </parent>
  </parents>
  <author>
    <name>Paul Dowman</name>
    <email>paul@pauldowman.com</email>
  </author>
  <url>http://github.com/pauldowman/sqs_accelerator/commit/37a52ff98af5d4b51e136be4d8f34982c1529e1b</url>
  <id>37a52ff98af5d4b51e136be4d8f34982c1529e1b</id>
  <committed-date>2009-06-23T13:21:59-07:00</committed-date>
  <authored-date>2009-06-23T12:42:45-07:00</authored-date>
  <message>Added simple ruby client class and server actions now return more precise HTTP response codes</message>
  <tree>34b2c5160307605bfddcad651bc1bb645b57c6a0</tree>
  <committer>
    <name>Paul Dowman</name>
    <email>paul@pauldowman.com</email>
  </committer>
</commit>
