Advanced Scala

The course for Scala developers who want to take the next step in architecting FP systems.

Overview

Advanced Scala teaches the mental models and Scala language features for building large scale FP systems.

Well designed functional programming applications are built by constructing small composable interfaces to concisely express each concept in the domain. Advanced Scala introduces the core concepts to build these kinds of applications:

  • The monoid, monad, and applicative type classes as foundational mental models, as well as their implementation in Cats.

  • The interpreter pattern for handling effects in a controlled way, by separating the description of an action from the act of carrying it out.

  • Implementing interpreters using generalized algebraic data types or tagless final style.

  • Modularity for large systems, using traits and mixins.

Pre-requisites

Attendees should be proficient in Scala fundamentals, such as those taught in our Essential Scala course.

Curriculum

Core type classes

  • Monoids for combining values
  • Monads for composing sequential operations
  • Applicative for combining independent operations

The intepreter pattern

  • Why FP separates description from action
  • Reified interpreters
  • Generalized algebraic data types
  • Tagless final interpreters
  • Relationship between the two

Modularity

  • Traits as modules
  • Modular programming pitfalls and best practices

Case studies

  • Case studies are chosen in collaboration with students to illustrate how the concepts transfer to work situations.

Delivery

Advanced Scala runs over 3 days, when delivered onsite. When delivered online there is more flexibility. We usually recommend six sessions of 3.5 hours.