You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltacloud.apache.org by mf...@redhat.com on 2013/02/27 15:23:34 UTC

[PATCH core 1/3] CIMI: Removed debug statements from AddressCollection

From: Michal Fojtik <mf...@redhat.com>


Signed-off-by: Michal fojtik <mf...@redhat.com>
---
 server/lib/cimi/collections/addresses.rb | 2 --
 1 file changed, 2 deletions(-)

diff --git a/server/lib/cimi/collections/addresses.rb b/server/lib/cimi/collections/addresses.rb
index 92aca3e..c34068d 100644
--- a/server/lib/cimi/collections/addresses.rb
+++ b/server/lib/cimi/collections/addresses.rb
@@ -25,9 +25,7 @@ module CIMI::Collections
       operation :index, :with_capability => :addresses do
         description 'List all Addresses in the AddressCollection'
         control do
-          puts "GET ADDRESSES"
           addresses = Address.list(self).select_by(params['$select'])
-          puts "GOT #{addresses.size}"
           respond_to do |format|
             format.xml {addresses.to_xml}
             format.json {addresses.to_json}
-- 
1.8.1.2


[PATCH core 3/3] Core: Change prefix for the Sinatra::Rabbit classes

Posted by mf...@redhat.com.
From: Michal Fojtik <mf...@redhat.com>

Sinatra::Rabbit for CIMI is now CIMI::Rabbit
Sinatra::Rabbit for Deltacloud is now Deltacloud::CIMI

Signed-off-by: Michal fojtik <mf...@redhat.com>
---
 server/lib/deltacloud/drivers/openstack/openstack_driver.rb    |  6 +++---
 server/lib/deltacloud/helpers/deltacloud_helper.rb             |  4 ++--
 server/tests/cimi/collections/cloud_entry_point_test.rb        |  2 +-
 server/tests/cimi/collections/machine_images_test.rb           |  4 ++--
 server/tests/cimi/collections/machines_test.rb                 |  4 ++--
 server/tests/cimi/collections/system_templates_test.rb         |  4 ++--
 server/tests/cimi/collections/systems_test.rb                  |  4 ++--
 server/tests/deltacloud/collections/buckets_collection_test.rb |  2 +-
 server/tests/deltacloud/collections/drivers_collection_test.rb |  4 ++--
 .../collections/hardware_profiles_collection_test.rb           |  4 ++--
 server/tests/deltacloud/collections/images_collection_test.rb  |  4 ++--
 .../deltacloud/collections/instance_states_collection_test.rb  |  2 +-
 .../tests/deltacloud/collections/instances_collection_test.rb  |  2 +-
 server/tests/deltacloud/collections/keys_collection_test.rb    |  4 ++--
 server/tests/deltacloud/collections/realms_collection_test.rb  |  4 ++--
 .../collections/storage_snapshots_collection_test.rb           |  4 ++--
 .../deltacloud/collections/storage_volumes_collection_test.rb  |  4 ++--
 server/tests/deltacloud/collections_test.rb                    |  4 ++--
 server/tests/deltacloud/server_test.rb                         |  2 +-
 server/tests/drivers/base/base_driver_test.rb                  | 10 +++++-----
 20 files changed, 39 insertions(+), 39 deletions(-)

diff --git a/server/lib/deltacloud/drivers/openstack/openstack_driver.rb b/server/lib/deltacloud/drivers/openstack/openstack_driver.rb
index 356d835..ab8db6e 100644
--- a/server/lib/deltacloud/drivers/openstack/openstack_driver.rb
+++ b/server/lib/deltacloud/drivers/openstack/openstack_driver.rb
@@ -50,17 +50,17 @@ module Deltacloud
           begin
             new_client(credentials, "compute")
           rescue Deltacloud::Exceptions::NotImplemented
-            super_collections = super_collections - [Sinatra::Rabbit::ImagesCollection, Sinatra::Rabbit::InstancesCollection, Sinatra::Rabbit::InstanceStatesCollection,Sinatra::Rabbit::KeysCollection,Sinatra::Rabbit::RealmsCollection, Sinatra::Rabbit::HardwareProfilesCollection]
+            super_collections = super_collections - [Deltacloud::Rabbit::ImagesCollection, Deltacloud::Rabbit::InstancesCollection, Deltacloud::Rabbit::InstanceStatesCollection,Deltacloud::Rabbit::KeysCollection,Deltacloud::Rabbit::RealmsCollection, Deltacloud::Rabbit::HardwareProfilesCollection]
           end
           begin
              new_client(credentials, "object-store")
           rescue Deltacloud::Exceptions::NotImplemented #OpenStack::Exception::NotImplemented...
-             super_collections = super_collections - [Sinatra::Rabbit::BucketsCollection]
+             super_collections = super_collections - [Deltacloud::Rabbit::BucketsCollection]
           end
           begin
               new_client(credentials, "volume")
           rescue Deltacloud::Exceptions::NotImplemented
-              super_collections = super_collections - [Sinatra::Rabbit::StorageVolumesCollection, Sinatra::Rabbit::StorageSnapshotsCollection]
+              super_collections = super_collections - [Deltacloud::Rabbit::StorageVolumesCollection, Deltacloud::Rabbit::StorageSnapshotsCollection]
           end
           super_collections
         end
diff --git a/server/lib/deltacloud/helpers/deltacloud_helper.rb b/server/lib/deltacloud/helpers/deltacloud_helper.rb
index 61256a1..8edc5b0 100644
--- a/server/lib/deltacloud/helpers/deltacloud_helper.rb
+++ b/server/lib/deltacloud/helpers/deltacloud_helper.rb
@@ -53,12 +53,12 @@ module Deltacloud::Helpers
     end
 
     def instance_action_method(action)
-      action_method(action, Sinatra::Rabbit::InstancesCollection)
+      action_method(action, Deltacloud::Rabbit::InstancesCollection)
     end
 
     def action_method(action, collection)
       http_method = collection.operation(action).http_method
-      http_method || Sinatra::Rabbit::BaseCollection.http_method_for(action)
+      http_method || Deltacloud::Rabbit::BaseCollection.http_method_for(action)
     end
 
     def filter_all(model)
diff --git a/server/tests/cimi/collections/cloud_entry_point_test.rb b/server/tests/cimi/collections/cloud_entry_point_test.rb
index 103c140..0790231 100644
--- a/server/tests/cimi/collections/cloud_entry_point_test.rb
+++ b/server/tests/cimi/collections/cloud_entry_point_test.rb
@@ -12,7 +12,7 @@ describe CIMI::Collections::CloudEntryPoint do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::CloudentrypointCollection::IndexOperation
+    @collection.operation(:index).must_equal CIMI::Rabbit::CloudentrypointCollection::IndexOperation
   end
 
   it 'advertise CIMI collections in XML format' do
diff --git a/server/tests/cimi/collections/machine_images_test.rb b/server/tests/cimi/collections/machine_images_test.rb
index 41be710..8bd91b9 100644
--- a/server/tests/cimi/collections/machine_images_test.rb
+++ b/server/tests/cimi/collections/machine_images_test.rb
@@ -12,11 +12,11 @@ describe CIMI::Collections::MachineImages do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::MachineImagesCollection::IndexOperation
+    @collection.operation(:index).must_equal CIMI::Rabbit::MachineImagesCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::MachineImagesCollection::ShowOperation
+    @collection.operation(:show).must_equal CIMI::Rabbit::MachineImagesCollection::ShowOperation
   end
 
   it 'returns list of images in various formats with index operation' do
diff --git a/server/tests/cimi/collections/machines_test.rb b/server/tests/cimi/collections/machines_test.rb
index f0d00ce..b2f7efb 100644
--- a/server/tests/cimi/collections/machines_test.rb
+++ b/server/tests/cimi/collections/machines_test.rb
@@ -14,11 +14,11 @@ describe CIMI::Collections::Machines do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::MachinesCollection::IndexOperation
+    @collection.operation(:index).must_equal CIMI::Rabbit::MachinesCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::MachinesCollection::ShowOperation
+    @collection.operation(:show).must_equal CIMI::Rabbit::MachinesCollection::ShowOperation
   end
 
   it 'returns list of machines in various formats with index operation' do
diff --git a/server/tests/cimi/collections/system_templates_test.rb b/server/tests/cimi/collections/system_templates_test.rb
index a9801f7..8c4f1a7 100644
--- a/server/tests/cimi/collections/system_templates_test.rb
+++ b/server/tests/cimi/collections/system_templates_test.rb
@@ -12,11 +12,11 @@ describe CIMI::Collections::SystemTemplates do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::SystemTemplatesCollection::IndexOperation
+    @collection.operation(:index).must_equal CIMI::Rabbit::SystemTemplatesCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::SystemTemplatesCollection::ShowOperation
+    @collection.operation(:show).must_equal CIMI::Rabbit::SystemTemplatesCollection::ShowOperation
   end
 
   it 'returns list of system templates in various formats with index operation' do
diff --git a/server/tests/cimi/collections/systems_test.rb b/server/tests/cimi/collections/systems_test.rb
index 2e650fd..cf7a7f0 100644
--- a/server/tests/cimi/collections/systems_test.rb
+++ b/server/tests/cimi/collections/systems_test.rb
@@ -12,11 +12,11 @@ describe CIMI::Collections::Systems do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::SystemsCollection::IndexOperation
+    @collection.operation(:index).must_equal CIMI::Rabbit::SystemsCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::SystemsCollection::ShowOperation
+    @collection.operation(:show).must_equal CIMI::Rabbit::SystemsCollection::ShowOperation
   end
 
   it 'returns list of systems in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/buckets_collection_test.rb b/server/tests/deltacloud/collections/buckets_collection_test.rb
index a30d221..9ca90c8 100644
--- a/server/tests/deltacloud/collections/buckets_collection_test.rb
+++ b/server/tests/deltacloud/collections/buckets_collection_test.rb
@@ -12,7 +12,7 @@ describe Deltacloud::Collections::Buckets do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::BucketsCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::BucketsCollection::IndexOperation
   end
 
   it 'provides URL to specify new bucket' do
diff --git a/server/tests/deltacloud/collections/drivers_collection_test.rb b/server/tests/deltacloud/collections/drivers_collection_test.rb
index cd844d7..0c94a1d 100644
--- a/server/tests/deltacloud/collections/drivers_collection_test.rb
+++ b/server/tests/deltacloud/collections/drivers_collection_test.rb
@@ -11,11 +11,11 @@ describe Deltacloud::Collections::Drivers do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::DriversCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::DriversCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::DriversCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::DriversCollection::ShowOperation
   end
 
   it 'returns list of drivers in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/hardware_profiles_collection_test.rb b/server/tests/deltacloud/collections/hardware_profiles_collection_test.rb
index eb30dcc..e09aa15 100644
--- a/server/tests/deltacloud/collections/hardware_profiles_collection_test.rb
+++ b/server/tests/deltacloud/collections/hardware_profiles_collection_test.rb
@@ -12,11 +12,11 @@ describe Deltacloud::Collections::HardwareProfiles do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::HardwareProfilesCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::HardwareProfilesCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::HardwareProfilesCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::HardwareProfilesCollection::ShowOperation
   end
 
   it 'returns list of hardware profiles in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/images_collection_test.rb b/server/tests/deltacloud/collections/images_collection_test.rb
index 19cd261..a432b40 100644
--- a/server/tests/deltacloud/collections/images_collection_test.rb
+++ b/server/tests/deltacloud/collections/images_collection_test.rb
@@ -12,11 +12,11 @@ describe Deltacloud::Collections::Images do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::ImagesCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::ImagesCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::ImagesCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::ImagesCollection::ShowOperation
   end
 
   it 'returns list of images in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/instance_states_collection_test.rb b/server/tests/deltacloud/collections/instance_states_collection_test.rb
index 134b664..2d1166d 100644
--- a/server/tests/deltacloud/collections/instance_states_collection_test.rb
+++ b/server/tests/deltacloud/collections/instance_states_collection_test.rb
@@ -12,7 +12,7 @@ describe Deltacloud::Collections::InstanceStates do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::InstanceStatesCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::InstanceStatesCollection::IndexOperation
   end
 
   it 'returns list of states for current driver in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/instances_collection_test.rb b/server/tests/deltacloud/collections/instances_collection_test.rb
index 7f643d7..4186f2c 100644
--- a/server/tests/deltacloud/collections/instances_collection_test.rb
+++ b/server/tests/deltacloud/collections/instances_collection_test.rb
@@ -12,7 +12,7 @@ describe Deltacloud::Collections::Instances do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::InstancesCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::InstancesCollection::IndexOperation
   end
 
   it 'provides URL to specify new instance' do
diff --git a/server/tests/deltacloud/collections/keys_collection_test.rb b/server/tests/deltacloud/collections/keys_collection_test.rb
index e719553..b73d6d6 100644
--- a/server/tests/deltacloud/collections/keys_collection_test.rb
+++ b/server/tests/deltacloud/collections/keys_collection_test.rb
@@ -12,11 +12,11 @@ describe Deltacloud::Collections::Keys do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::KeysCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::KeysCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::KeysCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::KeysCollection::ShowOperation
   end
 
   it 'returns list of keys in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/realms_collection_test.rb b/server/tests/deltacloud/collections/realms_collection_test.rb
index 9401f8d..d9885c4 100644
--- a/server/tests/deltacloud/collections/realms_collection_test.rb
+++ b/server/tests/deltacloud/collections/realms_collection_test.rb
@@ -12,11 +12,11 @@ describe Deltacloud::Collections::Realms do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::RealmsCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::RealmsCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::RealmsCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::RealmsCollection::ShowOperation
   end
 
   it 'returns list of realms in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/storage_snapshots_collection_test.rb b/server/tests/deltacloud/collections/storage_snapshots_collection_test.rb
index 7d8060b..2db74ed 100644
--- a/server/tests/deltacloud/collections/storage_snapshots_collection_test.rb
+++ b/server/tests/deltacloud/collections/storage_snapshots_collection_test.rb
@@ -12,11 +12,11 @@ describe Deltacloud::Collections::StorageSnapshots do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::StorageSnapshotsCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::StorageSnapshotsCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::StorageSnapshotsCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::StorageSnapshotsCollection::ShowOperation
   end
 
   it 'returns list of storage_snapshots in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections/storage_volumes_collection_test.rb b/server/tests/deltacloud/collections/storage_volumes_collection_test.rb
index 06463cc..434d975 100644
--- a/server/tests/deltacloud/collections/storage_volumes_collection_test.rb
+++ b/server/tests/deltacloud/collections/storage_volumes_collection_test.rb
@@ -12,11 +12,11 @@ describe Deltacloud::Collections::StorageVolumes do
   end
 
   it 'has index operation' do
-    @collection.operation(:index).must_equal Sinatra::Rabbit::StorageVolumesCollection::IndexOperation
+    @collection.operation(:index).must_equal Deltacloud::Rabbit::StorageVolumesCollection::IndexOperation
   end
 
   it 'has show operation' do
-    @collection.operation(:show).must_equal Sinatra::Rabbit::StorageVolumesCollection::ShowOperation
+    @collection.operation(:show).must_equal Deltacloud::Rabbit::StorageVolumesCollection::ShowOperation
   end
 
   it 'returns list of storage_volumes in various formats with index operation' do
diff --git a/server/tests/deltacloud/collections_test.rb b/server/tests/deltacloud/collections_test.rb
index 47dfb6c..19ee648 100644
--- a/server/tests/deltacloud/collections_test.rb
+++ b/server/tests/deltacloud/collections_test.rb
@@ -12,7 +12,7 @@ describe Deltacloud do
 
   it 'must provide access to collection classes' do
     Deltacloud.collections.wont_be_empty
-    Deltacloud.collections.must_include Sinatra::Rabbit::DriversCollection
+    Deltacloud.collections.must_include Deltacloud::Rabbit::DriversCollection
   end
 
   describe Deltacloud::Collections do
@@ -20,7 +20,7 @@ describe Deltacloud do
     it 'must return collection by name' do
       Deltacloud::Collections.must_respond_to :collection
       Deltacloud::Collections.collection(:drivers).wont_be_nil
-      Deltacloud::Collections.collection(:drivers).must_equal Sinatra::Rabbit::DriversCollection
+      Deltacloud::Collections.collection(:drivers).must_equal Deltacloud::Rabbit::DriversCollection
     end
 
     it 'must provide access to Deltacloud Sinatra modules' do
diff --git a/server/tests/deltacloud/server_test.rb b/server/tests/deltacloud/server_test.rb
index 0f02272..ca9d9d4 100644
--- a/server/tests/deltacloud/server_test.rb
+++ b/server/tests/deltacloud/server_test.rb
@@ -43,7 +43,7 @@ describe Deltacloud::API do
   it 'must return list of collections on OPTIONS' do
     options root_url
     headers['Allow'].wont_be_nil
-    headers['Allow'].split(',').must_include 'Sinatra::Rabbit::DriversCollection'
+    headers['Allow'].split(',').must_include 'Deltacloud::Rabbit::DriversCollection'
   end
 
   it 'must support setting driver and provider using POST' do
diff --git a/server/tests/drivers/base/base_driver_test.rb b/server/tests/drivers/base/base_driver_test.rb
index 9e1b9df..3972b52 100644
--- a/server/tests/drivers/base/base_driver_test.rb
+++ b/server/tests/drivers/base/base_driver_test.rb
@@ -41,7 +41,7 @@ describe Deltacloud::BaseDriver do
       def supported_collections(credentials)
         collections = super
         #lets add images/instances just for testing of method override from base
-        collections + [Sinatra::Rabbit::ImagesCollection, Sinatra::Rabbit::InstancesCollection]
+        collections + [Deltacloud::Rabbit::ImagesCollection, Deltacloud::Rabbit::InstancesCollection]
       end
     end
 
@@ -57,13 +57,13 @@ describe Deltacloud::BaseDriver do
       Thread.current[:driver] = 'test'
       credentials = OpenStruct.new(:user => 'unkown', :password => 'wrong')
       @driver.supported_collections(credentials).wont_be_empty
-      @driver.supported_collections(credentials).must_include Sinatra::Rabbit::InstancesCollection
+      @driver.supported_collections(credentials).must_include Deltacloud::Rabbit::InstancesCollection
       #check override of supported_collections, we added Images above
-      @driver.supported_collections(credentials).must_include Sinatra::Rabbit::ImagesCollection
-      @driver.supported_collections(credentials).wont_include Sinatra::Rabbit::KeysCollection
+      @driver.supported_collections(credentials).must_include Deltacloud::Rabbit::ImagesCollection
+      @driver.supported_collections(credentials).wont_include Deltacloud::Rabbit::KeysCollection
       #switch driver, check supported_collections
       Thread.current[:driver] = 'mock'
-      @driver.supported_collections(credentials).must_include Sinatra::Rabbit::KeysCollection
+      @driver.supported_collections(credentials).must_include Deltacloud::Rabbit::KeysCollection
       #restore driver to not impact other tests
       Thread.current[:driver] = current_driver
     end
-- 
1.8.1.2


[PATCH core 2/3] Core: Fixed Rabbit namespacing issues with Addresses (DTACLOUD-500)

Posted by mf...@redhat.com.
From: Michal Fojtik <mf...@redhat.com>

NOTE: A sinatra-rabbit >= 1.15 is required to make this work and to
fix the bug.

Signed-off-by: Michal fojtik <mf...@redhat.com>
---
 server/deltacloud-core.gemspec            | 2 +-
 server/lib/cimi/collections/base.rb       | 4 ++++
 server/lib/deltacloud/collections/base.rb | 4 ++++
 3 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/server/deltacloud-core.gemspec b/server/deltacloud-core.gemspec
index a8ecce0..d52c970 100644
--- a/server/deltacloud-core.gemspec
+++ b/server/deltacloud-core.gemspec
@@ -70,7 +70,7 @@ Gem::Specification.new do |s|
   s.add_dependency('rake', '>= 0.8.7')
   s.add_dependency('haml', '>= 2.2.17')
   s.add_dependency('sinatra', '>= 1.3.0')
-  s.add_dependency('sinatra-rabbit', '>= 1.0.11')
+  s.add_dependency('sinatra-rabbit', '>= 1.1.5')
   s.add_dependency('rack', '>= 1.0.0')
   s.add_dependency('rack-accept')
   s.add_dependency('json_pure', '>= 1.5.0')
diff --git a/server/lib/cimi/collections/base.rb b/server/lib/cimi/collections/base.rb
index cf92143..eac1c70 100644
--- a/server/lib/cimi/collections/base.rb
+++ b/server/lib/cimi/collections/base.rb
@@ -18,6 +18,10 @@ require_relative '../models'
 module CIMI::Collections
   class Base < Sinatra::Base
 
+    Sinatra::Rabbit.configure do
+      enable :use_namespace
+    end
+
     include Sinatra::Rabbit
     include Sinatra::Rabbit::Features
     include CIMI::Model
diff --git a/server/lib/deltacloud/collections/base.rb b/server/lib/deltacloud/collections/base.rb
index fe8ba2b..e6d7333 100644
--- a/server/lib/deltacloud/collections/base.rb
+++ b/server/lib/deltacloud/collections/base.rb
@@ -16,6 +16,10 @@
 module Deltacloud::Collections
   class Base < Sinatra::Base
 
+    Sinatra::Rabbit.configure do
+      enable :use_namespace
+    end
+
     include Sinatra::Rabbit
     include Sinatra::Rabbit::Features
 
-- 
1.8.1.2


Re: [PATCH core 1/3] CIMI: Removed debug statements from AddressCollection

Posted by Michal Fojtik <mf...@redhat.com>.
On 02/27, Ronelle Landy wrote:
> ACK to series - GET /api/addresses and GET /cimi/addresses both work now.
> Was able to gem install sinatra-rabbit-1.1.5

Thanks! Pushed.

> 
> > From: mfojtik@redhat.com
> > To: dev@deltacloud.apache.org
> > Sent: Wednesday, February 27, 2013 9:23:34 AM
> > Subject: [PATCH core 1/3] CIMI: Removed debug statements from AddressCollection
> > 
> > From: Michal Fojtik <mf...@redhat.com>
> > 
> > 
> > Signed-off-by: Michal fojtik <mf...@redhat.com>
> > ---
> >  server/lib/cimi/collections/addresses.rb | 2 --
> >  1 file changed, 2 deletions(-)
> > 
> > diff --git a/server/lib/cimi/collections/addresses.rb
> > b/server/lib/cimi/collections/addresses.rb
> > index 92aca3e..c34068d 100644
> > --- a/server/lib/cimi/collections/addresses.rb
> > +++ b/server/lib/cimi/collections/addresses.rb
> > @@ -25,9 +25,7 @@ module CIMI::Collections
> >        operation :index, :with_capability => :addresses do
> >          description 'List all Addresses in the AddressCollection'
> >          control do
> > -          puts "GET ADDRESSES"
> >            addresses =
> >            Address.list(self).select_by(params['$select'])
> > -          puts "GOT #{addresses.size}"
> >            respond_to do |format|
> >              format.xml {addresses.to_xml}
> >              format.json {addresses.to_json}
> > --
> > 1.8.1.2
> > 
> > 

-- 
Michal Fojtik <mf...@redhat.com>
Deltacloud API, CloudForms

Re: [PATCH core 1/3] CIMI: Removed debug statements from AddressCollection

Posted by Ronelle Landy <rl...@redhat.com>.
ACK to series - GET /api/addresses and GET /cimi/addresses both work now.
Was able to gem install sinatra-rabbit-1.1.5

> From: mfojtik@redhat.com
> To: dev@deltacloud.apache.org
> Sent: Wednesday, February 27, 2013 9:23:34 AM
> Subject: [PATCH core 1/3] CIMI: Removed debug statements from AddressCollection
> 
> From: Michal Fojtik <mf...@redhat.com>
> 
> 
> Signed-off-by: Michal fojtik <mf...@redhat.com>
> ---
>  server/lib/cimi/collections/addresses.rb | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/server/lib/cimi/collections/addresses.rb
> b/server/lib/cimi/collections/addresses.rb
> index 92aca3e..c34068d 100644
> --- a/server/lib/cimi/collections/addresses.rb
> +++ b/server/lib/cimi/collections/addresses.rb
> @@ -25,9 +25,7 @@ module CIMI::Collections
>        operation :index, :with_capability => :addresses do
>          description 'List all Addresses in the AddressCollection'
>          control do
> -          puts "GET ADDRESSES"
>            addresses =
>            Address.list(self).select_by(params['$select'])
> -          puts "GOT #{addresses.size}"
>            respond_to do |format|
>              format.xml {addresses.to_xml}
>              format.json {addresses.to_json}
> --
> 1.8.1.2
> 
>