You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Theodore Vasiloudis (JIRA)" <ji...@apache.org> on 2015/06/19 14:27:01 UTC
[jira] [Comment Edited] (FLINK-2249) ExecutionEnvironment: Ignore
calls to execute() if no data sinks defined
[ https://issues.apache.org/jira/browse/FLINK-2249?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14593376#comment-14593376 ]
Theodore Vasiloudis edited comment on FLINK-2249 at 6/19/15 12:26 PM:
----------------------------------------------------------------------
I had this problem appear as well. My use case was that I wanted to see how long a job takes to run and did not want to create any output. So I had something like:
{code}
//Read input, do some things and have ds as a result
ds.collect()
env.execute()
{code}
Which resulted in the aforementioned exception, which of course is not the expected behaviour for me.
was (Author: tvas):
I had this problem appear as well. My use case was that I wanted to see how long a job takes to run and did not want to create any output. So I had something like:
{code}
//Read input, do some things to and ds have as a result
ds.collect()
env.execute()
{code}
Which resulted in the aforementioned exception, which of course is not the expected behaviour for me.
> 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
>
> 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)