rough cleanup of the slicemanager business
[sfa.git] / sfa / server / xmlrpcapi.py
index 9b1e1b8..f3d4e68 100644 (file)
@@ -15,7 +15,6 @@ except ImportError:
     SOAPpy = None
 
 ####################
-#from sfa.util.faults import SfaNotImplemented, SfaAPIError, SfaInvalidAPIMethod, SfaFault
 from sfa.util.faults import SfaInvalidAPIMethod, SfaAPIError, SfaFault
 from sfa.util.sfalogging import logger
 from sfa.util.py23 import xmlrpc_client
@@ -92,7 +91,7 @@ xmlrpc_client.Marshaller._Marshaller__dump = xmlrpclib_dump
 
 class XmlrpcApi:
     """
-    The XmlrpcApi class implements a basic xmlrpc (or soap) service 
+    The XmlrpcApi class implements a basic xmlrpc (or soap) service
     """
 
     protocol = None
@@ -107,8 +106,6 @@ class XmlrpcApi:
             methods, fromlist=[methods])
         self.methods = methods_module.all
 
-        self.logger = logger
-
     def callable(self, method):
         """
         Return a new instance of the specified method.
@@ -125,7 +122,7 @@ class XmlrpcApi:
             callablemethod = getattr(module, classname)(self)
             return getattr(module, classname)(self)
         except (ImportError, AttributeError):
-            self.logger.log_exc("Error importing method: %s" % method)
+            logger.log_exc("Error importing method: %s" % method)
             raise SfaInvalidAPIMethod(method)
 
     def call(self, source, method, *args):
@@ -167,9 +164,9 @@ class XmlrpcApi:
             result = self.call(source, method, *args)
         except SfaFault as fault:
             result = fault
-            self.logger.log_exc("XmlrpcApi.handle has caught Exception")
+            logger.log_exc("XmlrpcApi.handle has caught Exception")
         except Exception as fault:
-            self.logger.log_exc("XmlrpcApi.handle has caught Exception")
+            logger.log_exc("XmlrpcApi.handle has caught Exception")
             result = SfaAPIError(fault)
 
         # Return result