Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 6850C200CAD for ; Wed, 28 Jun 2017 11:36:55 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 670F2160BF7; Wed, 28 Jun 2017 09:36:55 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id AC3D4160BE8 for ; Wed, 28 Jun 2017 11:36:54 +0200 (CEST) Received: (qmail 67915 invoked by uid 500); 28 Jun 2017 09:36:53 -0000 Mailing-List: contact commits-help@ariatosca.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ariatosca.incubator.apache.org Delivered-To: mailing list commits@ariatosca.incubator.apache.org Received: (qmail 67906 invoked by uid 99); 28 Jun 2017 09:36:53 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 Jun 2017 09:36:53 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 5D09FCA990 for ; Wed, 28 Jun 2017 09:36:53 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -4.231 X-Spam-Level: X-Spam-Status: No, score=-4.231 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id f5FdzdzgmZyE for ; Wed, 28 Jun 2017 09:36:50 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with SMTP id EFC985FB96 for ; Wed, 28 Jun 2017 09:36:49 +0000 (UTC) Received: (qmail 67891 invoked by uid 99); 28 Jun 2017 09:36:49 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 Jun 2017 09:36:49 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 63588DFB8A; Wed, 28 Jun 2017 09:36:49 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: mxmrlv@apache.org To: commits@ariatosca.incubator.apache.org Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: incubator-ariatosca git commit: ARIA-289 Don't attempt resuming a workflow which finished successfully [Forced Update!] Date: Wed, 28 Jun 2017 09:36:49 +0000 (UTC) archived-at: Wed, 28 Jun 2017 09:36:55 -0000 Repository: incubator-ariatosca Updated Branches: refs/heads/ARIA-289-Dont-attempt-resuming-a-workflow-which-finished-successfully bc9fbd12a -> 5783ed789 (forced update) ARIA-289 Don't attempt resuming a workflow which finished successfully Project: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/commit/5783ed78 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/tree/5783ed78 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/diff/5783ed78 Branch: refs/heads/ARIA-289-Dont-attempt-resuming-a-workflow-which-finished-successfully Commit: 5783ed789c688fb978fe02aeb3b4495524bbf6d3 Parents: b1b1ee4 Author: max-orlov Authored: Wed Jun 28 12:27:38 2017 +0300 Committer: max-orlov Committed: Wed Jun 28 12:36:43 2017 +0300 ---------------------------------------------------------------------- README.rst | 2 +- aria/cli/commands/executions.py | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/5783ed78/README.rst ---------------------------------------------------------------------- diff --git a/README.rst b/README.rst index d4740cd..b9a8213 100644 --- a/README.rst +++ b/README.rst @@ -138,7 +138,7 @@ Subscribe by sending a mail to ``-subscribe@ariatosca.incubator.apache.or lists `here `__. For past correspondence, see the -`dev mailing list archive `__. +`dev mailing list archive `__. License http://git-wip-us.apache.org/repos/asf/incubator-ariatosca/blob/5783ed78/aria/cli/commands/executions.py ---------------------------------------------------------------------- diff --git a/aria/cli/commands/executions.py b/aria/cli/commands/executions.py index b337e84..f0324ff 100644 --- a/aria/cli/commands/executions.py +++ b/aria/cli/commands/executions.py @@ -168,6 +168,12 @@ def resume(execution_id, logger): executor = DryExecutor() if dry else None # use WorkflowRunner's default executor + execution = model_storage.execution.get(execution_id) + if execution.status != execution.status.CANCELLED: + logger.info('Execution {execution.id} has ended with status {execution.status}. ' + 'It is not resumable'.format(execution=execution)) + return + workflow_runner = \ WorkflowRunner( model_storage, resource_storage, plugin_manager,