[server/session] remove json dumps around call_service
authorJulien Cristau <julien.cristau@logilab.fr>
Wed, 23 Apr 2014 18:41:34 +0200
changeset 9721 2f08bd4c813b
parent 9720 a7210c912507
child 9722 c0ae36be84ee
[server/session] remove json dumps around call_service This backouts changeset b151beea9cb6. With call_service being in-process and synchronous, there's no RPC use case.
server/session.py
--- a/server/session.py	Wed Apr 30 08:07:59 2014 +0200
+++ b/server/session.py	Wed Apr 23 18:41:34 2014 +0200
@@ -23,7 +23,6 @@
 from time import time
 from uuid import uuid4
 from warnings import warn
-import json
 import functools
 from contextlib import contextmanager
 
@@ -1154,18 +1153,9 @@
     @_with_cnx_set
     @_open_only
     def call_service(self, regid, **kwargs):
-        json.dumps(kwargs) # This line ensure that people use serialisable
-                           # argument for call service. this is very important
-                           # to enforce that from start to make sure RPC
-                           # version is available.
-        self.info('calling service %s', regid)
+        self.debug('calling service %s', regid)
         service = self.vreg['services'].select(regid, self, **kwargs)
-        result = service.call(**kwargs)
-        json.dumps(result) # This line ensure that service have serialisable
-                           # output. this is very important to enforce that
-                           # from start to make sure RPC version is
-                           # available.
-        return result
+        return service.call(**kwargs)
 
     @_with_cnx_set
     @_open_only