You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@deltacloud.apache.org by ma...@apache.org on 2011/07/29 00:57:54 UTC

svn commit: r1152032 - /incubator/deltacloud/trunk/server/lib/deltacloud/drivers/ec2/ec2_driver.rb

Author: marios
Date: Thu Jul 28 22:57:54 2011
New Revision: 1152032

URL: http://svn.apache.org/viewvc?rev=1152032&view=rev
Log:
Fix typo in EC2 stop instance. No matter which instance you stopped
you would always get the details of the first intance in the list
returned (same for reboot instance).

Modified:
    incubator/deltacloud/trunk/server/lib/deltacloud/drivers/ec2/ec2_driver.rb

Modified: incubator/deltacloud/trunk/server/lib/deltacloud/drivers/ec2/ec2_driver.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/lib/deltacloud/drivers/ec2/ec2_driver.rb?rev=1152032&r1=1152031&r2=1152032&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/lib/deltacloud/drivers/ec2/ec2_driver.rb (original)
+++ incubator/deltacloud/trunk/server/lib/deltacloud/drivers/ec2/ec2_driver.rb Thu Jul 28 22:57:54 2011
@@ -232,7 +232,7 @@ module Deltacloud
         def reboot_instance(credentials, instance_id)
           ec2 = new_client(credentials)
           if ec2.reboot_instances([instance_id])
-            instance(credentials, instance_id)
+            instance(credentials, :id => instance_id)
           else
             raise Deltacloud::BackendError.new(500, "Instance", "Instance reboot failed", "")
           end
@@ -241,7 +241,7 @@ module Deltacloud
         def destroy_instance(credentials, instance_id)
           ec2 = new_client(credentials)
           if ec2.terminate_instances([instance_id])
-            instance(credentials, instance_id)
+            instance(credentials, :id => instance_id)
           else
             raise Deltacloud::BackendError.new(500, "Instance", "Instance cannot be terminated", "")
           end