Georg Dresler
Tackling Complexity With Functional Programming And Kotlin
#1about 3 minutes
Understanding a complex and unusual feature request
A real-world example of a complex feature request involves an offline form editor that syncs data via JSON embedded in PDF metadata.
#2about 3 minutes
Why traditional try-catch blocks fail for complex errors
Traditional try-catch blocks for error handling either obscure an error's origin or make the code unreadable with excessive boilerplate.
#3about 7 minutes
Using the Either type for robust functional error handling
Replace exceptions with the `Either` sealed class, using `flatMap` to chain successful operations and `fold` to handle the final success or error state.
#4about 4 minutes
Enforcing data validation using private constructors in Kotlin
Use a private constructor combined with a companion object's `invoke` operator to run validation logic upon object creation, preventing invalid states.
#5about 7 minutes
Modeling distinct data states with algebraic data types
Use sealed classes (sum types) to model different states like `Draft` and `Validated`, letting the compiler enforce state-specific logic instead of relying on boolean flags.
#6about 4 minutes
Recap of functional techniques and audience Q&A
A summary of using `Either` for errors, private constructors for validation, and ADTs for state, followed by a Q&A on libraries like Arrow and custom exceptions.
Related jobs
Jobs that call for the skills explored in this talk.
PROSOZ Herten GmbH
Herten, Germany
€47-70K
Junior
Intermediate
Senior
Java
tree-IT GmbH
Bad Neustadt an der Saale, Germany
€54-80K
Intermediate
Senior
Java
TypeScript
+1
Hubert Burda Media
München, Germany
€80-95K
Intermediate
Senior
JavaScript
Node.js
+1
Matching moments
03:57 MIN
Modern object orientation with Kotlin data classes
Moving from Java to Kotlin
02:29 MIN
Using Kotlin Coroutines to simplify complex reactive code
Back(end) to the Future: Embracing the continuous Evolution of Infrastructure and Code
01:26 MIN
Leveraging functional programming with first-class functions
Moving from Java to Kotlin
10:56 MIN
Audience Q&A on Kotlin features and learning resources
Route from Java to Kotlin
02:00 MIN
Real-world applications of functional programming
A Guide To Functional Programming
01:40 MIN
Creating reusable UI components with Kotlin extension functions
How to kill JavaScript from your Stack with HTMX and Kotlin
06:04 MIN
Audience Q&A on functional programming concepts
A Guide To Functional Programming
02:58 MIN
Introduction to Kotlin and its Java interoperability
Route from Java to Kotlin
Featured Partners
Related Videos
Moving from Java to Kotlin
Urs Peter
Route from Java to Kotlin
Christian Woerz
Java Sealed Classes vs. Kotlin Sealed Classes #Slideless
Lothar Schulz
Build Delightful Mobile Experiences with Kotlin, Realm, and Atlas Device Sync
Timothy Marland
The best of both worlds: Combining Python and Kotlin for Machine Learning
Nils Kasseckert
Slip Through the Boundaries of Legacy Systems with Kotlin and Spring WebFlux
Lukas Georgieff & Alberto Gisbert
Kotlin Multiplatform - True power of native code reuse
Petar Marijanović
Algebraic Data Types + Pattern Matching = Elegant and readable Java code
Balkrishna Rawool
Related Articles
View all articles



From learning to earning
Jobs that call for the skills explored in this talk.



ITERGO Informationstechnologie GmbH
Augsburg, Germany
Senior
Java
DevOps
Kotlin
Docker
Kubernetes
+3


ITERGO Informationstechnologie GmbH
Klagenfurt am Wörthersee, Austria
€53-67K
Senior
Java
DevOps
Spring
Kotlin
+5

JetBrains
Amsterdam, Netherlands
Senior
API
iOS
Java
gRPC
React
+9

ITERGO Informationstechnologie GmbH
Graz, Austria
€53-67K
Senior
Java
DevOps
Spring
Kotlin
+5

Clever Recruiting
Amsterdam, Netherlands
Senior
API
Java
REST
gRPC
React
+6

Delivery Hero AG
Berlin, Germany
Kafka
Python
Kotlin
Microservices
Machine Learning