From the previous article, you know how givens work. Let’s compare them with the old Scala implicits.
Posts by Year
The given/using clauses are some of the most important features of Scala 3. Read on for the essential concepts and how to use them.”
We’ll take a look at the famous “covariant type occurs in contravariant position” problem, and what we can do about it.
A quick article on one of the simple, but expressive features of the Scala 3 method syntax.
Some people love it, some hate it. Scala 3 indented syntax is not that bad, and it might actually help. Let’s take a look at how Scala 3 can change the struc...
Akka Typed has not only made fundamental changes in the actor protocol definitions, but made significant improvements in actor mechanics as well.
Akka Typed has fundamentally changed the way we create actors. In this article we’ll look at several ways we can keep state inside Akka actors.
It’s obvious that Spark allows us to join tables. What’s not obvious is how many different kinds of joins Spark supports. We explore them in this article.
Broadcast joins in Apache Spark are one of the most bang-for-the-buck techniques for optimizing speed and avoiding memory issues. Let’s take a look.
Exploring a quick but powerful structure in Scala 3 - type lambdas. This will help you think higher-level.
Scala has a powerful type system. We look at how Scala types can be organized, what type constructors are, and why we should care.
We discover opaque type aliases in Scala 3 and how we can define new types with zero overhead.
This article will continue some of the previous explorations of Scala 3. Here, we’ll discuss some of the new functionality of traits in Scala 3.
Scala 3 introduces enums. About time! Even though it might seem like something minor, it has important implications.
Scala 3 introduces some new kinds of types, which we’re eagerly awaiting for.
A really nice way to inspect, extract and modify deeply nested data structures in Scala.
Akka HTTP needs JSON like humans need water. We show you how to integrate Spray-Json, Circe and Jackson into Akka HTTP.
Scala code is super easy to deploy to AWS lambda. We show you how in this step by step tutorial.
We look at how we can impose constraints on values at compile time with the Refined library.
Scala syntax is so confusing sometimes - I’ll show almost all uses of underscores in Scala. Sometimes the philosophy is inconsistent, but it’s worth at least...
Drawing the line between two fundamental repartitioning operations in Apache Spark.
We explore some not-so-well-understood territory in the form of eta-expansion and how methods and functions interoperate.
Final blow in the type-level trilogy. We learn how to sort lists… at compile time.
We continue down the path of type-level power in Scala. We learn to add numbers as types, at compile time.
This one is hardcode. We make the Scala compiler infer type relationships for us at compile time. Pure power.
Abstract classes and traits share a lot of overlap in Scala. How are they actually different?
Various constructions like “20.seconds” look like baked into the Scala language. Let’s see how these work.
We explore the various flavors of nothing-ness in Scala.
Akka Streams has the Graph DSL, which is one of its most powerful APIs. Learn how to use it and get started quickly with Akka Streams.
We compare three of the most popular streaming libraries and see where Akka Streams, Kafka Streams and Spark Streaming are most useful.
FP fans talk about pure functional programming in Scala with type classes. They’re hard. Why do we really need them?
Akka HTTP is super easy to deploy to a web server. Learn how to use Heroku and deploy your first Akka HTTP service in minutes.
A Scala tutorial on Monads that makes no assumptions and starts from practical needs. We derive the monad patterns (“laws”) from scratch.
Scala is an amazingly expressive language, but even the most experienced devs aren’t aware of all the subtleties.
Yep, you can write your own interpolator that looks like it was built into the Scala language. Learn how.
Akka Typed is one of the best things that happened with the Akka API. We explore how good practices are baked into the API directly.
We discuss the tradeoffs between 3 different styles of writing parallel code, in terms of thread use (and other effects) in Scala and Akka.
Learn to read files in Scala like a boss and compare it to other styles in other languages. We write a simple API which looks almost as easy as Python’s read...
Maximize the call-by-name semantics in Scala and manipulate your results when you want them.
We walk you through one of the foundational skills for Spark performance optimization: reading the Spark UI and the graph of how your job is structured.
We go on a short trip to Nothing (and nothing-ness) in Scala. Nothing is actually pretty useful.
Daniel goes into another rant about learning (and teaching) Scala using loops. Are they actually useful?
We demystify one of the hardest concepts in Akka Streams: materialized values.
In this article you’ll learn one of the most important Spark skill: reading how your job will run. This is foundational to any further Spark optimization.
Daniel goes into a small rant about learning (and teaching) Scala using variables.
For OO programmers looking to dive into functional programming in Scala: a gentle introduction to functions working with other functions.
In this article we learn to address the problem of “deterministic” Futures in Scala, using Promises.
Self types are a really interesting way to enforce type constraints in Scala. Learn to use it in a few minutes.
Learn to use Akka HTTP with Scala and send HTTP requests in just a few minutes with the Akka HTTP server DSL.
The Scala type system is powerful, but also hard. We look at contravariance in Scala and try to make some sense out of it.
Pattern matching is one of the most powerful Scala features. Learn to use it to the max so you can write your best Scala code.