Articles

Tips on Scala, functional programming, Akka, Spache Spark and more

Type-Level Programming in Scala, Part 1

In this mini-series I'll introduce you to some advanced Scala techniques for type-level programming. In other words, you'll learn to use the power of the Scala compiler to solve problems for you and to validate properties of types.This article (and its subsequent parts) require an advanced...

READ MORE

The Practical Difference Between Abstract Classes and Traits in Scala

This short article will compare abstract classes and traits as means of inheritance. This is for the beginner Scala programmer who is just getting started with Scala's inheritance model. If you're trying to figure out which is the best way to create OO-style type hierarchies and abstract classes...

READ MORE

How Does "20 seconds" Work in Scala?

This short article will show you how apparently magical constructs like 20.seconds works in Scala, although the Int type doesn't have such methods natively.This article will make more sense if you know the basics of implicits, but then again, if you do know how implicits work, there's only...

READ MORE

The Difference Between Null, Nothing, Nil, None and Unit in Scala

There are lots of terms to express the lack of values in Scala. Today we're going to discuss the difference between null, Null (not a typo), None, Nil, Unit and Nothing. They all seemingly describe the lack of a meaningful value, which can definitely be confusing. Thank goodness Scala doesn't...

READ MORE

How to Use Akka Streams Graph DSL

This article is for the Scala programmer with a little bit of Akka background, but who is utterly baffled by the seemingly magical Akka Streams Graph DSL. This article will attempt to demystify the apparent magic of the DSL into bits of Scala code that are easy to understand.If you want to...

READ MORE

Java Tutorial for Beginners - Learn Java in 3 hours

Enroll into this mini-course and download it here, or watch this in real time below or on YouTube. This tutorial was designed so that you can code with me side by side without switching back and forth between the video and your own code. Enjoy!

READ MORE

Comparing Akka Streams, Kafka Streams and Spark Streaming

This article is for the Java/Scala programmer who wants to decide which framework to use for the streaming part of a massive application, or simply wants to know the fundamental differences between them, just in case. I'm going to write Scala, but all the frameworks I'm going to describe also...

READ MORE

Why are Type Classes Useful?

This article is for the Scala programmer who knows what implicits are and (for the most part) how they work. This article will also involve a somewhat high degree of abstraction.Type classes are these super-abstract concepts in functional programming, which FP purists and Haskellers eat for...

READ MORE

Akka HTTP to Heroku in 10 Minutes

This article is for newbies to Akka HTTP and for those who have written some Akka HTTP but have never deployed their own server. Here I'll teach you what you need to know and do so that you have your first server up and running on Heroku in just a few minutes.I'll be working in IntelliJ IDEA...

READ MORE

A Monads Approach for Beginners

There are so many tutorials on Monads it's not even funny. In fact, it's not funny at all - the more analogies people make, the more confused readers and listeners seem to be, because how could you bridge the gap between burritos, programmable semicolons, applicative functors? Perhaps you...

READ MORE