deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mar...@apache.org
Subject git commit: Fix for JIRA DTACLOUD_258 - opennebula xml sent back from http://occi.c12g.com
Date Wed, 11 Jul 2012 11:28:49 GMT
Updated Branches:
  refs/heads/master 57b8272a3 -> 64ad28040


Fix for JIRA DTACLOUD_258 - opennebula xml sent back from http://occi.c12g.com

https://issues.apache.org/jira/browse/DTACLOUD-258

Seems the latest version of ON OCCI endpoint running at http://occi.c12g.com
is not compatible with our 'older' version of the opennebula driver (3.2?)


Project: http://git-wip-us.apache.org/repos/asf/deltacloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltacloud/commit/64ad2804
Tree: http://git-wip-us.apache.org/repos/asf/deltacloud/tree/64ad2804
Diff: http://git-wip-us.apache.org/repos/asf/deltacloud/diff/64ad2804

Branch: refs/heads/master
Commit: 64ad28040cb85a143741b16657d592d80bdfcab9
Parents: 57b8272
Author: marios <marios@redhat.com>
Authored: Tue Jul 10 17:34:30 2012 +0300
Committer: marios <marios@redhat.com>
Committed: Wed Jul 11 14:28:06 2012 +0300

----------------------------------------------------------------------
 .../drivers/opennebula/opennebula_driver.rb        |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/64ad2804/server/lib/deltacloud/drivers/opennebula/opennebula_driver.rb
----------------------------------------------------------------------
diff --git a/server/lib/deltacloud/drivers/opennebula/opennebula_driver.rb b/server/lib/deltacloud/drivers/opennebula/opennebula_driver.rb
index cc1f13e..b44482e 100644
--- a/server/lib/deltacloud/drivers/opennebula/opennebula_driver.rb
+++ b/server/lib/deltacloud/drivers/opennebula/opennebula_driver.rb
@@ -45,10 +45,10 @@ class OpennebulaDriver < Deltacloud::BaseDriver
       @hardware_profiles = REXML::Document.new(xml).root.elements.map {|d|
         elem = d.elements
         ::Deltacloud::HardwareProfile.new(elem['NAME'].text) {
-          cpu          elem['CPU']
-          memory       elem['MEMORY']
-          storage      elem['STORAGE']
-          architecture elem['ARCHITECTURE']
+          cpu          elem['CPU'].text if elem['CPU']
+          memory       elem['MEMORY'].text if elem['MEMORY']
+          storage      elem['STORAGE'].text  if elem['STORAGE']
+          architecture elem['ARCHITECTURE'].text if elem['ARCHITECTURE']
         }
       }
     end


Mime
View raw message