This chapter focuses on design patterns that produce a top-level, summarized view of your data, so you can glean insights not available from looking at a localized set of records alone. Aggregation, or summarization, analytics are all about grouping similar data together and then performing an operation, such as calculating a statistic, building an index, or simply counting.
The patterns in this chapter are numerical summarizations, inverted index, and counting with counters:
The aggregation pattern is a general pattern for calculating aggregate statistical values over your data, and is discussed in detail. It is important to use the combiner properly, and to understand the calculation you are performing before writing the code. Basically, the logic is to group records together by a key field and calculate a numerical aggregate per group.
Aggregations, or numerical summarizations, can be used when both of the following are true: