You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by Vinaya M S <vi...@gmail.com> on 2016/01/20 15:37:37 UTC
groupBy(int) is undefined for the type SingleOutputStreamOperator
while running streaming example provided on webpage
Hi,
I'm new to Flink. Can anyone help me with the error below.
Exception in thread "main" java.lang.Error: Unresolved compilation problem:
The method groupBy(int) is undefined for the type
SingleOutputStreamOperator<Tuple2<String,Integer>,capture#1-of ?>
The code snippet is:
DataStream<Tuple2<String, Integer>> dataStream = env
.socketTextStream("localhost", 9999)
.flatMap(new Splitter())
.groupBy(0)
.sum(1);
Thank you.
Re: groupBy(int) is undefined for the type SingleOutputStreamOperator
while running streaming example provided on webpage
Posted by Robert Metzger <rm...@apache.org>.
Hi,
as you can see from the URL, its the documentation for Flink 0.8. The
current documentation is here:
https://ci.apache.org/projects/flink/flink-docs-release-0.10/apis/streaming_guide.html
In the 0.10. release announcement (
http://flink.apache.org/news/2015/11/16/release-0.10.0.html ) the change
has been mentioned.
On Wed, Jan 20, 2016 at 3:47 PM, Vinaya M S <vi...@gmail.com> wrote:
> Version FLink 0.10.
>
> Example is mentioned in
> https://ci.apache.org/projects/flink/flink-docs-release-0.8/streaming_guide.html
> Please let me know where I can find these kind of updates.
>
> Thank you.
>
> On Wed, Jan 20, 2016 at 9:41 AM, Robert Metzger <rm...@apache.org>
> wrote:
>
>> Hi.
>>
>> which Flink version are you using?
>> Starting from Flink 0.10., "groupBy" has been renamed to "keyBy".
>>
>> Where did you find the "groupBy" example?
>>
>> On Wed, Jan 20, 2016 at 3:37 PM, Vinaya M S <vi...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> I'm new to Flink. Can anyone help me with the error below.
>>>
>>> Exception in thread "main" java.lang.Error: Unresolved compilation
>>> problem:
>>>
>>> The method groupBy(int) is undefined for the type
>>> SingleOutputStreamOperator<Tuple2<String,Integer>,capture#1-of ?>
>>>
>>>
>>> The code snippet is:
>>>
>>> DataStream<Tuple2<String, Integer>> dataStream = env
>>>
>>> .socketTextStream("localhost", 9999)
>>>
>>> .flatMap(new Splitter())
>>>
>>> .groupBy(0)
>>>
>>> .sum(1);
>>>
>>>
>>> Thank you.
>>>
>>
>>
>
Re: groupBy(int) is undefined for the type SingleOutputStreamOperator
while running streaming example provided on webpage
Posted by Vinaya M S <vi...@gmail.com>.
Version FLink 0.10.
Example is mentioned in
https://ci.apache.org/projects/flink/flink-docs-release-0.8/streaming_guide.html
Please let me know where I can find these kind of updates.
Thank you.
On Wed, Jan 20, 2016 at 9:41 AM, Robert Metzger <rm...@apache.org> wrote:
> Hi.
>
> which Flink version are you using?
> Starting from Flink 0.10., "groupBy" has been renamed to "keyBy".
>
> Where did you find the "groupBy" example?
>
> On Wed, Jan 20, 2016 at 3:37 PM, Vinaya M S <vi...@gmail.com> wrote:
>
>> Hi,
>>
>> I'm new to Flink. Can anyone help me with the error below.
>>
>> Exception in thread "main" java.lang.Error: Unresolved compilation
>> problem:
>>
>> The method groupBy(int) is undefined for the type
>> SingleOutputStreamOperator<Tuple2<String,Integer>,capture#1-of ?>
>>
>>
>> The code snippet is:
>>
>> DataStream<Tuple2<String, Integer>> dataStream = env
>>
>> .socketTextStream("localhost", 9999)
>>
>> .flatMap(new Splitter())
>>
>> .groupBy(0)
>>
>> .sum(1);
>>
>>
>> Thank you.
>>
>
>
Re: groupBy(int) is undefined for the type SingleOutputStreamOperator
while running streaming example provided on webpage
Posted by Robert Metzger <rm...@apache.org>.
Hi.
which Flink version are you using?
Starting from Flink 0.10., "groupBy" has been renamed to "keyBy".
Where did you find the "groupBy" example?
On Wed, Jan 20, 2016 at 3:37 PM, Vinaya M S <vi...@gmail.com> wrote:
> Hi,
>
> I'm new to Flink. Can anyone help me with the error below.
>
> Exception in thread "main" java.lang.Error: Unresolved compilation
> problem:
>
> The method groupBy(int) is undefined for the type
> SingleOutputStreamOperator<Tuple2<String,Integer>,capture#1-of ?>
>
>
> The code snippet is:
>
> DataStream<Tuple2<String, Integer>> dataStream = env
>
> .socketTextStream("localhost", 9999)
>
> .flatMap(new Splitter())
>
> .groupBy(0)
>
> .sum(1);
>
>
> Thank you.
>