Return-Path: X-Original-To: apmail-flink-issues-archive@minotaur.apache.org Delivered-To: apmail-flink-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8336118406 for ; Wed, 18 Nov 2015 13:51:11 +0000 (UTC) Received: (qmail 95585 invoked by uid 500); 18 Nov 2015 13:51:11 -0000 Delivered-To: apmail-flink-issues-archive@flink.apache.org Received: (qmail 95546 invoked by uid 500); 18 Nov 2015 13:51:11 -0000 Mailing-List: contact issues-help@flink.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flink.apache.org Delivered-To: mailing list issues@flink.apache.org Received: (qmail 95373 invoked by uid 99); 18 Nov 2015 13:51:11 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 18 Nov 2015 13:51:11 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 156C02C1F6E for ; Wed, 18 Nov 2015 13:51:11 +0000 (UTC) Date: Wed, 18 Nov 2015 13:51:11 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: issues@flink.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (FLINK-2249) ExecutionEnvironment: Ignore calls to execute() if no data sinks defined MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/FLINK-2249?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15011005#comment-15011005 ] ASF GitHub Bot commented on FLINK-2249: --------------------------------------- Github user StephanEwen commented on the pull request: https://github.com/apache/flink/pull/1375#issuecomment-157718710 I think there was a discussion about that before, and the decision was to not change the behavior. The reason was that failing loudly with a good error message is easier to figure out than silently ignoring a call to execute(). > ExecutionEnvironment: Ignore calls to execute() if no data sinks defined > ------------------------------------------------------------------------ > > Key: FLINK-2249 > URL: https://issues.apache.org/jira/browse/FLINK-2249 > Project: Flink > Issue Type: Improvement > Components: Java API, Scala API > Affects Versions: 0.9 > Reporter: Maximilian Michels > Assignee: Chesnay Schepler > > The basic skeleton of a Flink program looks like this: > {code} > ExecutionEnvironment env = ExecutionEnvironment.getExecutionEnvironment(); > // bootstrap DataSet > DataSet<..> ds = env.fromElements(1,2,3,4); > // perform transformations > .. > // define sinks, e.g. > ds.writeToTextFile("/some/path"); > // execute > env.execute() > {code} > First thing users do is to change {{ds.writeToTextFile("/some/path");}} into {{ds.print();}}. But that fails with an Exception ("No new data sinks defined..."). > In FLINK-2026 we made this exception message easier to understand. However, users still don't understand what is happening. Especially because they see Flink executing and then failing. > I propose to ignore calls to execute() when no sinks are defined. Instead, we should just print a warning: "Detected call to execute without any data sinks. Not executing." -- This message was sent by Atlassian JIRA (v6.3.4#6332)