Implementing Event-Driven Microservices architecture in Functional language
summary
Shows how to build event‑driven microservices in F# using Domain‑Driven Design to define service boundaries, Discriminated Unions to model domain events and responses, and Computation Expressions to express workflows. Covers event sourcing with List.fold, distributed sagas (as an alternative to two‑phase commits) for eventual consistency, and using F# Type Providers or IDL tools (Thrift/Protobuf via C#) to evolve service interfaces; emphasizes pure functions, immutability and scalability.
AI-written summary · about
chapters (40)
- 0:00This recording is from NDC Oslo 2018
- 0:45Objectives
- 1:01Monolithic: The old school approach...
- 2:18Microservices: The Brave new world...
- 3:04Microservice Architecture
- 4:34Advantages
- 5:36Microservice: A functional view
- 7:54Why not to use OOP?
- 11:57Modelling a Service using FP
- 13:55Implementation: Example in F#
- 15:11Asynchronous workflows
- 15:56Loose Coupling implies Distributed Data
- 17:29Domain Driven Design (DDD)
- 18:37Elements of DDD
- 19:43DDD: Aggregates
- 20:35Data Partition Strategies: Use DDD
- 23:40DDD: Architecture Layers
- 26:19Problems with Distributed Data
- 27:43Cannot use ACID Transactions
- 29:56Cannot use 2-Phase Commit
- 30:55Eventual Consistency
- 34:10Event Driven Architecture
- 35:53Introducing Sagas
- 38:09Communication: Request/Response
- 40:09Communication: Event-Driven
- 41:10Communication Patterns
- 42:21Contract Management
- 44:13Event Sourcing: Introduction
- 47:38Implementing Event Sourcing in F#
- 49:08Event Sourcing: Benefits & Drawbacks
- 50:15Command Query Responsibility Segregation
- 51:10Multiple Views from Single events stream
- 51:55CORS: Benefits & Drawbacks
- 52:14Testing Microservices (Request/Response)
- 53:01Testing Microservices (Event Driven)
- 53:20Static Analysis of Functional style code
- 54:45Scalability
- 55:04Code Correctness
- 56:01Case Study: Twitter
- 56:31Summary
related talks
26mImplementing Event-Driven Microservices Architecture (...)
44mBuilding event-driven microservices with Scala and Functional Domain Models
58mImplementing Event-driven Microservices
47mEvent-Driven Microservices = Microservices Done Right
51mPatterns & Practices of Implementing Event-driven MicroSvc...
49mMicroservices guided by DDD and reactive systems paradigm
49mFunctional programming in practice, with all its consequences
42mDesign Principles for an Event-Driven Architecture
