SpringSource/spring-data-mongodb — pull request #25 by ttrelle (2013-02-08 07:00:24+00:00)
Title: Implemented DATAMONGO-586

Basic implementation for the aggregation framework introduced in MongoDB 2.2.

I added an aggregate() method to the MongoTemplate and provided an abstraction AggregationPipeline of the input parameters exposing a fluent API. All pipeline operations can be used via a raw JSON string so the full aggregation API is supported.

Some pipeline operations ($project and $group) offer a very rich DSL (having a gazillion of expression operators, see http://docs.mongodb.org/manual/reference/aggregation/#aggregation-expression-operators). These are not (yet) implemented in a type safe way and with a fluent API, but I started this with an abstraction "Project".