flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deng Jie <smartdeng...@gmail.com>
Subject Re: /home/user/udfs.jar same question
Date Fri, 25 Sep 2015 08:15:46 GMT
Dear Chiwan,
However, 'createRemoteEnvironment' method must specify this parameter.

-- Best wishes for you
邓杰
15994846535

2015-09-25 13:42 GMT+08:00 Chiwan Park <chiwanpark@apache.org>:

> Hi Deng,
>
> The jarFiles parameter of `createRemoteEnvironment` means that the path of
> your custom library jar. If you don’t need custom library, you can omit the
> parameter.
>
> Regards,
> Chiwan Park
>
> > On Sep 25, 2015, at 10:48 AM, Deng Jie <smartdengjie@gmail.com> wrote:
> >
> > Dear Flink org,i have same question,like:
> > public static void main(String[] args) throws Exception {
> >
> >     ExecutionEnvironment env
> > =
> >  ExecutionEnvironment
> >
> > .createRemoteEnvironment("flink-master", 6123, "/home/user/udfs.jar");
> >
> >
> >     DataSet
> > <String> data = env.readTextFile("hdfs://path/to/file");
> >
> >
> >     data
> >
> > .filter(new FilterFunction<String>() {
> >
> >
> > public boolean filter(String value) {
> >
> >
> > return value.startsWith("http://");
> >
> >
> > }
> >
> >
> > })
> >
> >
> > .writeAsText("hdfs://path/to/result");
> >
> >
> >     env
> > .execute();
> > }
> >
> > How to write the file(udfs.jar),can you give me an example?In
> addition,can this parameter as an option?
> >
> > -- Best wishes for you
>
>
>
>

Mime
View raw message