flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maximilian Michels <...@apache.org>
Subject Re: readTextFile is not working for StreamExecutionEnvironment
Date Wed, 02 Mar 2016 12:38:57 GMT
Hi Balaji,

You forgot to execute your Flink program using

env.execute();

Cheers,
Max

On Wed, Mar 2, 2016 at 1:36 PM, Balaji Rajagopalan
<balaji.rajagopalan@olacabs.com> wrote:
> def main(args: Array[String]): Unit = {
>
>
>
>   val env: StreamExecutionEnvironment =
> StreamExecutionEnvironment.getExecutionEnvironment();
>   env.setStreamTimeCharacteristic(TimeCharacteristic.EventTime)
>   try {
>
>     val data1:DataStream[String] = env.readTextFile(“somefile.txt”);
>
>     data1.print()
>
>   }
>
>   catch {
>
>     case e: Exception => println(e)
>   }
>
> }
>
> I have non empty file that this does not print anything.
>
>
>

Mime
View raw message