Immutability Against The Machine
summary
Builds a movie travel guide by querying Wikidata with Apache Jena and models every external call as immutable IO values so business logic is pure until a single unsafeRunSync executes it. Uses Option type for safe parsing, wraps connections in a Resource that guarantees release, and stores cache state in a Ref. Shows mapping, sequence vs parallel parSequence to run 100 queries in seconds, and removes try/catch plumbing by composing values and flattening program descriptions.
AI-written summary · about
chapters (11)
- 0:00Introduction to immutability
- 3:34Operational vs functional
- 6:57Handling exceptions
- 12:53Data-oriented programming
- 16:33Practical implementation
- 23:52Refining the application
- 27:13Business logic separation
- 29:07Assembling the pipeline
- 32:41Advanced functional techniques
- 38:52Managing resources and cache
- 46:56Conclusion and resources
