You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltacloud.apache.org by ma...@redhat.com on 2011/06/08 19:09:34 UTC
[PATCH 3/4] Fixes minor formatting nits
From: marios <ma...@redhat.com>
Signed-off-by: marios <ma...@redhat.com>
---
server/lib/deltacloud/drivers/ec2/ec2_driver.rb | 6 +++---
server/lib/deltacloud/helpers/blob_stream.rb | 9 +++++----
2 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/server/lib/deltacloud/drivers/ec2/ec2_driver.rb b/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
index 3f6514c..4fff243 100644
--- a/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
+++ b/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
@@ -355,9 +355,9 @@ module Deltacloud
bucket_list = s3_client.buckets
bucket_list.each do |current|
buckets << Bucket.new({:name => current.name, :id => current.name})
- end #bucket_list.each
- end #if
- end #safely
+ end
+ end
+ end
filter_on(buckets, :id, opts)
end
diff --git a/server/lib/deltacloud/helpers/blob_stream.rb b/server/lib/deltacloud/helpers/blob_stream.rb
index 094bfe6..440529b 100644
--- a/server/lib/deltacloud/helpers/blob_stream.rb
+++ b/server/lib/deltacloud/helpers/blob_stream.rb
@@ -17,7 +17,8 @@ include Deltacloud
begin
require 'eventmachine'
#--
- # based on the example from http://macournoyer.com/blog/2009/06/04/pusher-and-async-with-thin/
+ # based on the example from
+ # http://macournoyer.com/blog/2009/06/04/pusher-and-async-with-thin/
#--
class BlobStream
AsyncResponse = [-1, {}, []].freeze
@@ -32,11 +33,11 @@ begin
'Content-Disposition' => params["content_disposition"],
'Content-Length' => "#{params['content_length']}"}, body]
}
- #call the driver from here. the driver method yields for every chunk of blob it receives. We then
- #use body.call to write that chunk as received.
+ #call the driver from here. the driver method yields for every chunk
+ #of blob it receives. Then use body.call to write that chunk as received.
driver.blob_data(credentials, params[:bucket], params[:blob], params) {|chunk| body.call ["#{chunk}"]} #close blob_data block
body.succeed
- AsyncResponse # Tells Thin to not close the connection and continue it's work on other request
+ AsyncResponse # Tell Thin to not close connection & work other requests
end
end
--
1.7.3.4
Re: [PATCH 3/4] Fixes minor formatting nits
Posted by David Lutterkort <lu...@redhat.com>.
On Wed, 2011-06-08 at 20:09 +0300, marios@redhat.com wrote:
> From: marios <ma...@redhat.com>
>
>
> Signed-off-by: marios <ma...@redhat.com>
> ---
> server/lib/deltacloud/drivers/ec2/ec2_driver.rb | 6 +++---
> server/lib/deltacloud/helpers/blob_stream.rb | 9 +++++----
> 2 files changed, 8 insertions(+), 7 deletions(-)
ACK