def invoke(self, func, rpc_id, args, kwargs):
# put the process in the host list pthreads
self.host.pthreads[getcurrent()] = self.__actor.url
try:
result = func(*args, **kwargs)
except Exception, e:
result = e
self.__actor.receive_from_ask(result, rpc_id)
# remove the process from pthreads
del self.host.pthreads[getcurrent()]
评论列表
文章目录