diff --git a/openstack/resource.py b/openstack/resource.py index e8c1830c2..35e9c908f 100644 --- a/openstack/resource.py +++ b/openstack/resource.py @@ -471,9 +471,6 @@ class Resource(dict): #: The base part of the URI for this resource. base_path = "" - #: The service associated with this resource to find the service URL. - service = None - #: Allow create operation for this resource. allow_create = False #: Allow get operation for this resource. @@ -1339,9 +1336,6 @@ class Resource(dict): # Resource class that is calling session.$something to be complete. if isinstance(session, adapter.Adapter): return session - if hasattr(session, '_sdk_connection'): - service_type = cls.service['service_type'] - return getattr(session._sdk_connection, service_type) raise ValueError( "The session argument to Resource methods requires either an" " instance of an openstack.proxy.Proxy object or at the very least" diff --git a/openstack/tests/unit/compute/v2/test_limits.py b/openstack/tests/unit/compute/v2/test_limits.py index 90da84d9d..4971dad1d 100644 --- a/openstack/tests/unit/compute/v2/test_limits.py +++ b/openstack/tests/unit/compute/v2/test_limits.py @@ -113,7 +113,6 @@ class TestRateLimit(base.TestCase): self.assertIsNone(sot.resource_key) self.assertIsNone(sot.resources_key) self.assertEqual("", sot.base_path) - self.assertIsNone(sot.service) self.assertFalse(sot.allow_create) self.assertFalse(sot.allow_fetch) self.assertFalse(sot.allow_commit)