def run(self): run_swf_command( 'register_domain', name=self.args.name, workflowExecutionRetentionPeriodInDays=self.args.retention_days, description=self.args.description, )
def run(self): run_swf_command( 'signal_workflow_execution', domain=self.args.domain, workflowId=self.args.id, signalName=self.args.signal, runId=self.args.run_id, input=self.args.input, ) return 'Signal sent.'
def run(self): run_swf_command( 'terminate_workflow_execution', domain=self.args.domain, workflowId=self.args.id, runId=self.args.run_id, reason=self.args.reason, details=self.args.details, childPolicy=self.args.child_policy, ) return 'Execution terminated.'
def run(self): response = run_swf_command( 'list_domains', registrationStatus=self.args.registration_status ) return response['domainInfos']
def run(self): workflow_type = {'name': self.args.name, 'version': self.args.version} if self.args.task_list is not None: task_list = {'name': self.args.task_list} else: task_list = None if self.args.tag_list: tag_list = self.args.tag_list.split() else: tag_list = None response = run_swf_command( 'start_workflow_execution', domain=self.args.domain, workflowId=self.args.id, workflowType=workflow_type, input=self.args.input, taskList=task_list, tagList=tag_list, executionStartToCloseTimeout=self.args.execution_timeout, taskStartToCloseTimeout=self.args.task_timeout, childPolicy=self.args.child_policy, lambdaRole=self.args.lambda_role, ) return 'Execution started. RunId: %s' % response['runId']
def run(self): time_filter = { 'oldestDate': self.args.oldest.naive, 'latestDate': self.args.latest.naive, } if self.args.name is not None: type_filter = { 'name': self.args.name, } if self.args.version is not None: type_filter['version'] = self.args.version else: type_filter = None if self.args.tag is not None: tag_filter = { 'tag': self.args.tag, } else: tag_filter = None if self.args.id is not None: execution_filter = { 'workflowId': self.args.id, } else: execution_filter = None response = run_swf_command( 'list_open_workflow_executions', domain=self.args.domain, startTimeFilter=time_filter, typeFilter=type_filter, tagFilter=tag_filter, executionFilter=execution_filter, ) return response['executionInfos']