Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

YouTube

Readers vs Constructors - Dependency Injection Showdown

Scala Days Conferences via YouTube

Overview

Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Explore the world of dependency injection in Scala through this 49-minute conference talk from Scala Days Chicago 2017. Dive into various approaches for managing in-code dependencies, a crucial decision in project development. Compare the evolution of dependency injection techniques, from the boilerplate-heavy Cake Pattern to constructor-based wiring with MacWire, hybrid service locators like SubCut and Scaldi, and the functional approach using the Reader Monad. Evaluate the pros and cons of each method, including the use of established Java solutions like Guice. Through practical examples involving a key-value store and food storage system, gain insights into compile-time errors, method signatures, and tracking effects. Conclude with a comprehensive summary of dependency injection strategies to enhance your Scala development skills.

Syllabus

Introduction
Dependency Injection
What you dont need
Who is Adam
KeyValue Store
Food Storage
Add Food
Class Parameters
Compile Time Error
Create IOT dependency
Change method signature
Reader monad
Remove function
Tracking effects
Combining the two
Summary

Taught by

Scala Days Conferences

Reviews

Start your review of Readers vs Constructors - Dependency Injection Showdown

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.