Commit cd6e094f by Dudás Ádám

vm: public synchronous call method for operations

parent fe6b5e32
......@@ -32,10 +32,7 @@ class Operation:
self.instance = instance
def __call__(self, **kwargs):
"""Execute the operation synchronously.
"""
activity = self.__prelude(kwargs)
return self._exec_op(activity=activity, **kwargs)
return self.call(**kwargs)
def __unicode__(self):
return self.name
......@@ -73,6 +70,12 @@ class Operation:
activity.pk), kwargs=kwargs,
queue=self.async_queue)
def call(self, **kwargs):
"""Execute the operation synchronously.
"""
activity = self.__prelude(kwargs)
return self._exec_op(activity=activity, **kwargs)
def check_precond(self):
pass
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment