In previous articles we have described how to build a REST Api with Spray and how to (de)serialize case classes with json4s. However, in order to keep things simple, we didn't always do things as suggested by spray.io. In this article we will redeem ourselves and we will describe how to build a REST CRUD… Continue reading How to build a Scala REST CRUD application with Spray
Tag: Spray
Spray: how to (de)serialize objects with json4s
A while ago I wrote an article on how to build a REST api with Spray, where I used the Spray facilities to serialize and deserialize objects to and from JSON. This article will analyze how we can make the (de)serialization of our case classes easier, by using a library called json4s. All the code… Continue reading Spray: how to (de)serialize objects with json4s
How to Create a Spray Custom Authenticator
Spray has a few standard authenticators already built in. However, what if the authentication we need is not supported? In this article we will describe how to create a custom authenticator in Spray. In particular, we will implement a custom client id/secret token-based authentication. Spray Authentication: how it works Spray has already some built in… Continue reading How to Create a Spray Custom Authenticator
How to build a REST api with Spray and Akka
Spray is a library written on top of Akka and Scala that allows to quickly create REST interfaces. It is becoming more and more popular in the Scala community because it is easy to use and performant thanks to this asynchronous, actor-based model. This article describes how to efficiently exploit Spray to create a simple… Continue reading How to build a REST api with Spray and Akka