flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maximilian Michels <...@apache.org>
Subject Re: Processing events through web socket
Date Mon, 10 Oct 2016 13:49:44 GMT
You don't have to wrap the existing socket source. You will have to
create your own source function which directly reads from the web
socket and forwards the results to the next Flink operator. Then you
will call env.addSource(new YourWebSocketSource());

To get started, you might want to read the code of the existing
SocketTextStreamFunction as a basis for your implementation.


On Mon, Oct 10, 2016 at 1:58 PM, Abdul Salam Shaikh
<abd.salam.shaikh@gmail.com> wrote:
> Thanks for responding.
> I want to read json streams from web sockets but at the moment socketStream
> method of Flink only supports plain TCP sockets.
> What could be the probable solution for this ?
> All I can think of so far is a wrapper which listens to from the web sockets
> and sends it to the TCP sockets.
> Please let me know if there is anything more efficient than that.
> Thanks.

View raw message