O'Reilly logo

Scalatra in Action by Stefan Ollinger Dave Hrycyszyn Ross A. Baker

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 12. Asynchronous programming

This chapter covers

  • Scala, servlets, and mutable state
  • Using Futures for asynchronous programming
  • Using Akka Actors with Scalatra
  • Big data in Scalatra with Spark

Scala makes multicore, distributed, and asynchronous programming easier. Its focus on immutability, as well as associated libraries such as Akka, lower the conceptual burdens of concurrency management by making it easier to reason about your code. Why is this important?

Most other languages still rely on old-style concurrency management tools like locks and threads, which can be extremely difficult to use because they are non-deterministic. That is, you can’t necessarily reproduce your threading bugs when you want, because they can be the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required