The 'Keeping It Realtime' conference just finished. It reignited some ideas about how to move data around in a stream-oriented way.
The reworking of icecondor.com will have API endpoints that are indented to hold a TCP(or ZMQ?) connection open and stream results as they happen. Laying out the end points feels like object oriented programming for the first time - a new paradigm that takes a bit of thought how to lay things out.
Identify the basic nouns in the system as Location, Device, User, Group and Fence. There is a channel for each noun. Serialized objects come down the channel as they are received by the system from other actors. Assuming a default of all available location objects coming down the location pipe, that results in a firehose. A filter can be sent up the channel, such as "Device X", and "Inside bounding box X,Y". Filters are stacked/applied with an "and" operator. To listen to the results of two different filter stacks, make two connections to the API. As I write this I'm realizing the default should be no objects and filters expand what comes down the pipe, rather than a wide open default with filters limiting what comes down.