def _exec_script(self, name=None, body=None, exec_timeout=None): if not self._script_executor: self._script_executor = script_executor.get_handlers()[0] self._logger.info('Executing %s script', name) kwargs = dict(name=name, body=body, exec_timeout=exec_timeout or 3600) self._script_executor.execute_scripts(scripts=(script_executor.Script(**kwargs), ))
def _exec_script(self, name=None, body=None, exec_timeout=None): if not self._script_executor: self._script_executor = script_executor.get_handlers()[0] self._logger.info('Executing %s script', name) kwargs = dict(name=name, body=body, exec_timeout=exec_timeout or 3600) self._script_executor.execute_scripts(scripts=(script_executor.Script( **kwargs), ))
def do_execute_scripts(op): msg = lambda: None msg.name = event_name msg.role_name = role_name msg.body = { 'scripts': scripts or [], 'global_variables': global_variables or [] } hdlr = script_executor.get_handlers()[0] hdlr(msg)