mercredi 16 avril 2014

A Typesafe Activator plugin for Play-Slick

Typesafe Activator is a very cool tool to bootstrap applications built with the Typesafe stack (Scala, Play, Akka...).

I've just published an activator template for play-slick :

Slick is the default library for databases access in the Typesafe stack. This template may help you integrate Play Framework and Slick to create a new Web application or a JSON API.

Play relies on asynchronous and non blocking IO. As Slick, uses only blocking IO (it uses on JDBC drivers under the hood), the template uses a DBAction to provide a "slick execution context" with a bigger thread pool to execute the blocking queries. This way you can use Slick without thinking about this kind of problem.