Any ideas how to create parameterised streaming api?


I want to create parameterised streaming api like

The straightforward way I see is following:

  1. Create redis channel for messages (like twitter statuses).
  2. Each connected socket subscribes on this channel.
  3. Inside redis callback each sockets check if current message fits supplied parameters (parameters could be set as separate socket message)

What you think guys?

Problem courtesy of: Alexey Zakharov


You might want to look at nats

Solution courtesy of: Steve Wilhelm

View additional discussion.