incubator-deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfoj...@redhat.com
Subject [PATCH core 3/4] CIMI: Fixed wrong properties types in MachineImage and MachineConfiguration models
Date Wed, 16 Nov 2011 20:34:32 GMT
From: Michal Fojtik <mfojtik@redhat.com>

---
 server/lib/cimi/model/machine_configuration.rb |   15 ++++++++++++---
 server/lib/cimi/model/machine_image.rb         |    2 +-
 2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/server/lib/cimi/model/machine_configuration.rb b/server/lib/cimi/model/machine_configuration.rb
index 221236c..ea78217 100644
--- a/server/lib/cimi/model/machine_configuration.rb
+++ b/server/lib/cimi/model/machine_configuration.rb
@@ -15,11 +15,20 @@
 
 class CIMI::Model::MachineConfiguration < CIMI::Model::Base
 
-  scalar :memory
+  struct :memory do
+    scalar :quantity
+    scalar :units
+  end
+
   text :cpu
 
-  array :disk do
-    scalar :capacity
+  array :disks do
+    struct :capacity do
+      scalar :format
+      scalar :quantity
+      scalar :attachment_point
+      scalar :units
+    end
   end
 
   array :operations do
diff --git a/server/lib/cimi/model/machine_image.rb b/server/lib/cimi/model/machine_image.rb
index a23638f..18d91d4 100644
--- a/server/lib/cimi/model/machine_image.rb
+++ b/server/lib/cimi/model/machine_image.rb
@@ -15,7 +15,7 @@
 
 class CIMI::Model::MachineImage < CIMI::Model::Base
 
-  scalar :image_location
+  href :image_location
   text :image_data
 
   array :operations do
-- 
1.7.7.3


Mime
View raw message