You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by neo21 zerro <ne...@yahoo.com> on 2016/04/14 01:22:48 UTC

Sink partitioning

Hello everybody,

I have an elasticsearch sink in my flink topology.
My requirement is to write the data in a partitioned fashion to my Sink. 

For example I have Tuple which contains a user id. I want to group all events by a user id and partition all events for one particular user to the same Es Sink. 

Is it possible to achieve something like this in Flink?


Thanks!

Re: Sink partitioning

Posted by Konstantin Knauf <ko...@tngtech.com>.
Hi,

calling DataStream.partitionCustom() with the respective arguments
before the sink should do the trick, I think.

Cheers,

Konstantin

On 14.04.2016 01:22, neo21 zerro wrote:
> Hello everybody,
> 
> I have an elasticsearch sink in my flink topology.
> My requirement is to write the data in a partitioned fashion to my Sink. 
> 
> For example I have Tuple which contains a user id. I want to group all events by a user id and partition all events for one particular user to the same Es Sink. 
> 
> Is it possible to achieve something like this in Flink?
> 
> 
> Thanks!
> 

-- 
Konstantin Knauf * konstantin.knauf@tngtech.com * +49-174-3413182
TNG Technology Consulting GmbH, Betastr. 13a, 85774 Unterföhring
Geschäftsführer: Henrik Klagges, Christoph Stock, Dr. Robert Dahlke
Sitz: Unterföhring * Amtsgericht München * HRB 135082