Time series pattern

In an IoT application with Cassandra as the data store, a time series can be modeled with the timestamp or timeuuid data types in conjunction with an appropriate data type for the data points. Corresponding to each data point, a time data type is to be used. In this design pattern, a timestamp or timeuuid data type column must not be used as the single partition key because there will be only one data point per row. There should be at least one associated timestamp or timeuuid for each of the data points. It is ideal to choose a meaningful partition key so that the Cassandra CQL queries return data points in a given period without reading multiple rows. It is ideal to store all the most commonly needed records in one big row ...

Get Cassandra Design Patterns - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.