longevity

A Persistence Framework for Scala and NoSQL

View project on GitHub

queries

Longevity queries provide you with a way to retrieve multiple persistent objects, either all at once, or in a stream.

To build queries, you can either use the query DSL, or you can assemble them by hand using the classes and factory methods in package longevity.model.query. The query DSL is complete, so that any query you can build by hand, you can also build with the DSL. We will focus our discussion here on the DSL, since it is much more convenient to use. If you prefer to construct them by hand, please refer to the ScalaDocs.

Please note that, due to the limited nature of Cassandra SELECT statements, many of the queries discussed in this chapter will not work when using a Cassandra back end. Please see the section on Cassandra limitations for the details.

This chapter is organized as follows:

prev: polymorphic repositories
up: user manual
next: using the query dsl