Streams

Ky
Last updated 2 months ago

A stream is a time-ordered list of events related to each other in some way that is denoted by the stream’s id. Some streams might be a single sensor, a vehicle with a number of sensors that are sampled periodically, or a whole facility. All events in a stream need not have the same structure, but it makes sense to create streams where events are closely related. Sentenai’s search functionality operates on streams, so results will return sets of events as query results. Since Sentenai supports queries across multiple streams, you do not have to group a large number of sensors or other entities together to make them queryable. A good rule of thumb is: create lots of small streams of events where each id represents the smallest uniquely identifiable entity in your relational mappings.