deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfoj...@apache.org
Subject [3/3] git commit: CIMI - Remove credentialTemplates from CEP COLLECTIONS. Use ruby style hash iteration on CEP COLLECTIONS. Fix typos uncovered during testing.
Date Tue, 30 Apr 2013 14:41:25 GMT
CIMI - Remove credentialTemplates from CEP COLLECTIONS.
       Use ruby style hash iteration on CEP COLLECTIONS.
       Fix typos uncovered during testing.

       These changes address review feedback from Michal Fojtik.


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

Branch: refs/heads/master
Commit: aa9a232aa965ac53b08e44a7051e30810419be97
Parents: 959cc62
Author: Joe VLcek <jvlcek@redhat.com>
Authored: Mon Apr 29 14:27:53 2013 -0400
Committer: Michal fojtik <mfojtik@redhat.com>
Committed: Tue Apr 30 16:40:26 2013 +0200

----------------------------------------------------------------------
 .../cimi/models/cloud_entry_point_collections.rb   |    8 +++-----
 server/lib/cimi/service.rb                         |    4 ++--
 2 files changed, 5 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/aa9a232a/server/lib/cimi/models/cloud_entry_point_collections.rb
----------------------------------------------------------------------
diff --git a/server/lib/cimi/models/cloud_entry_point_collections.rb b/server/lib/cimi/models/cloud_entry_point_collections.rb
index 00b3512..6cf4866 100644
--- a/server/lib/cimi/models/cloud_entry_point_collections.rb
+++ b/server/lib/cimi/models/cloud_entry_point_collections.rb
@@ -26,14 +26,13 @@ class CIMI::Model::CloudEntryPoint < CIMI::Model::Base
     "machineTemplates" => CIMI::Model::MachineTemplate,
     "machineImages" => CIMI::Model::MachineImage,
     "credentials" => CIMI::Model::Credential,
-    "credentialTemplates" => CIMI::Model::CredentialTemplate,
     "volumes" => CIMI::Model::Volume,
     "volumeTemplates" => CIMI::Model::VolumeTemplate,
     "volumeImages" => CIMI::Model::VolumeImage,
     "networks" => CIMI::Model::Network,
     "networkTemplates" => CIMI::Model::NetworkTemplate,
     "networkPorts" => CIMI::Model::NetworkPort,
-    "networkPortTemplates" => CIMI::Model::NetworkTemplate,
+    "networkPortTemplates" => CIMI::Model::NetworkPortTemplate,
     "addresses" => CIMI::Model::Address,
     "addressTemplates" => CIMI::Model::AddressTemplate,
     "forwardingGroups" => CIMI::Model::ForwardingGroup,
@@ -50,9 +49,8 @@ class CIMI::Model::CloudEntryPoint < CIMI::Model::Base
     "eventLogTemplates" => nil
   }
 
-  COLLECTIONS.each do |coll|
-    coll_entry = coll
-    collection coll_entry[0].underscore.to_sym, :class => coll_entry[1] unless coll_entry[1]
== nil
+  COLLECTIONS.each do |name, klass|
+    collection name.underscore.to_sym, :class => klass unless klass == nil
   end
 
 end

http://git-wip-us.apache.org/repos/asf/deltacloud/blob/aa9a232a/server/lib/cimi/service.rb
----------------------------------------------------------------------
diff --git a/server/lib/cimi/service.rb b/server/lib/cimi/service.rb
index a8b64f5..c3473f5 100644
--- a/server/lib/cimi/service.rb
+++ b/server/lib/cimi/service.rb
@@ -96,8 +96,8 @@ SERVICES = {
   "networks" => CIMI::Service::Network,
   "network_templates" => CIMI::Service::NetworkTemplate,
   "network_configurations" => CIMI::Service::NetworkConfiguration,
-  "network_port" => CIMI::Service::NetworkPort,
-  "network_port_template" => CIMI::Service::NetworkPortTemplate,
+  "network_ports" => CIMI::Service::NetworkPort,
+  "network_port_templates" => CIMI::Service::NetworkPortTemplate,
   "network_port_configurations" => CIMI::Service::NetworkPortConfiguration,
   "addresses" => CIMI::Service::Address,
   "address_templates" => CIMI::Service::AddressTemplate,


Mime
View raw message