Summary

In this chapter, we saw different ways of persisting application data in an application built using the Play Framework. In doing so, we have seen two contrasting approaches: one using a relational DB and the other using a NoSQL DB. To persist in a relational DB, we looked at how the Anorm module and the JDBC plugin work. To use a NoSQL database (MongoDB) for our application's backend, we used the Play plugin for ReactiveMongo. In addition to this, we saw how the Play Cache API can be used and how it works.

In the next chapter, we will be learning all about handling data streams in Play.

Get Mastering Play Framework for Scala 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.