incubator-deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lut...@apache.org
Subject svn commit: r962233 - in /incubator/deltacloud/trunk/server/libexec: ./ lib/deltacloud/base_driver/ lib/deltacloud/drivers/mock/ lib/deltacloud/drivers/rackspace/ lib/deltacloud/drivers/rhevm/ lib/deltacloud/drivers/rimu/
Date Thu, 08 Jul 2010 23:38:29 GMT
Author: lutter
Date: Thu Jul  8 23:38:29 2010
New Revision: 962233

URL: http://svn.apache.org/viewvc?rev=962233&view=rev
Log:
Advertise feature user_name in drivers that support it

Modified:
    incubator/deltacloud/trunk/server/libexec/lib/deltacloud/base_driver/features.rb
    incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/mock/mock_driver.rb
    incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rackspace/rackspace_driver.rb
    incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
    incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rimu/rimu_hosting_driver.rb
    incubator/deltacloud/trunk/server/libexec/server.rb

Modified: incubator/deltacloud/trunk/server/libexec/lib/deltacloud/base_driver/features.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/libexec/lib/deltacloud/base_driver/features.rb?rev=962233&r1=962232&r2=962233&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/libexec/lib/deltacloud/base_driver/features.rb (original)
+++ incubator/deltacloud/trunk/server/libexec/lib/deltacloud/base_driver/features.rb Thu Jul
 8 23:38:29 2010
@@ -110,5 +110,12 @@ module Deltacloud
     #
     # Declaration of optional features
     #
+    declare_feature :instances, :user_name do
+      description "Accept a user-defined name on instance creation"
+      operation :create do
+        param :name, :string, :optional, nil,
+        "The user-defined name"
+      end
+    end
   end
 end

Modified: incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/mock/mock_driver.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/mock/mock_driver.rb?rev=962233&r1=962232&r2=962233&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/mock/mock_driver.rb (original)
+++ incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/mock/mock_driver.rb Thu
Jul  8 23:38:29 2010
@@ -87,6 +87,8 @@ class MockDriver < Deltacloud::BaseDrive
     stopped.to( :finish )      .on( :destroy )
   end
 
+  feature :instances, :user_name
+
   def initialize
     if ENV["DELTACLOUD_MOCK_STORAGE"]
       @storage_root = ENV["DELTACLOUD_MOCK_STORAGE"]

Modified: incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rackspace/rackspace_driver.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rackspace/rackspace_driver.rb?rev=962233&r1=962232&r2=962233&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rackspace/rackspace_driver.rb
(original)
+++ incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rackspace/rackspace_driver.rb
Thu Jul  8 23:38:29 2010
@@ -24,6 +24,8 @@ module Deltacloud
 
 class RackspaceDriver < Deltacloud::BaseDriver
 
+  feature :instances, :user_name
+
   def flavors(credentials, opts=nil)
     racks = new_client( credentials )
     results = racks.list_flavors.map do |flav|

Modified: incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rhevm/rhevm_driver.rb?rev=962233&r1=962232&r2=962233&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
(original)
+++ incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rhevm/rhevm_driver.rb
Thu Jul  8 23:38:29 2010
@@ -32,6 +32,8 @@ class RHEVMDriver < Deltacloud::BaseDriv
   POWERSHELL="c:\\Windows\\system32\\WindowsPowerShell\\v1.0\\powershell.exe"
   NO_OWNER=""
 
+  feature :instances, :user_name
+
   #
   # Execute a Powershell command, and convert the output
   # to YAML in order to get back an array of maps.

Modified: incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rimu/rimu_hosting_driver.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rimu/rimu_hosting_driver.rb?rev=962233&r1=962232&r2=962233&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rimu/rimu_hosting_driver.rb
(original)
+++ incubator/deltacloud/trunk/server/libexec/lib/deltacloud/drivers/rimu/rimu_hosting_driver.rb
Thu Jul  8 23:38:29 2010
@@ -24,6 +24,9 @@ module Deltacloud
     module Rimu
 
 class RimuHostingDriver < Deltacloud::BaseDriver
+
+  feature :instances, :user_name
+
   def images(credentails, opts=nil)
     rh = RimuHostingClient.new(credentails)
     images = rh.list_images.map do | image |

Modified: incubator/deltacloud/trunk/server/libexec/server.rb
URL: http://svn.apache.org/viewvc/incubator/deltacloud/trunk/server/libexec/server.rb?rev=962233&r1=962232&r2=962233&view=diff
==============================================================================
--- incubator/deltacloud/trunk/server/libexec/server.rb (original)
+++ incubator/deltacloud/trunk/server/libexec/server.rb Thu Jul  8 23:38:29 2010
@@ -231,8 +231,6 @@ collection :instances do
     param :image_id,     :string, :required
     param :realm_id,     :string, :optional
     param :flavor_id,    :string, :optional
-    # FIXME: name is really a driver-specific feature
-    param :name,         :string, :optional
     control do
       @image = driver.image(credentials, :id => params[:image_id])
       instance = driver.create_instance(credentials, @image.id, params)



Mime
View raw message