Hi Esa, In Flink documentation[1], what you specified before env.execute() is the job graph. "Once you specified the complete program you need to *trigger the program execution* by calling execute()".
execute() can be finite or infinite, depending on whether your data source is finite, or whether you interrupt the program. Best, Rong [1]: https://ci.apache.org/projects/flink/flink-docs-release-1.5/dev/api_concepts.html#anatomy-of-a-flink-program On Tue, May 29, 2018 at 3:56 AM, Esa Heikkinen <esa.heikki...@student.tut.fi > wrote: > Hi > > > > Are there only one env.execute() in application ? > > > > Is it unstoppable forever loop ? > > > > Or can I stop env.execute() and then do something and after that restart > it ? > > > > Best, Esa > > > > *From:* Fabian Hueske <fhue...@gmail.com> > *Sent:* Tuesday, May 29, 2018 1:35 PM > *To:* Esa Heikkinen <esa.heikki...@student.tut.fi> > *Cc:* user@flink.apache.org > *Subject:* Re: env.execute() ? > > > > Hi, > > > > It is mandatory for all DataStream programs and most DataSet programs. > > > > Exceptions are ExecutionEnvironment.print() and > ExecutionEnvironment.collect(). > > Both methods are defined on the DataSet ExecutionEnvironment and call > execute() internally. > > > > Best, Fabian > > > > 2018-05-29 12:31 GMT+02:00 Esa Heikkinen <esa.heikki...@student.tut.fi>: > > Hi > > > > Is it env.execute() mandatory at the end of application ? It is possible > to run the application without it ? > > > > I found some examples where it is missing. > > > > Best, Esa > > >