Skip to content
0:00 / 0:00

#scala#fs2#cats-effect

Declarative Control Flow with fs2 Stream – Fabio Labella

Typelevel

2.6K subscribers • 8 videos on Hallway

YouTube
  • Recommended by 2 people: 2 in engineering communities.
  • Presented by Fabio Labella

Intermediate. Assumes working knowledge.

7.9K views8 years ago2 recommendations

Programming languagesSoftware designFunctional programmingConcurrency and parallelism

Fabio Labella demonstrates how to use fs2 streams as a declarative abstraction for concurrent control flow in Scala.

fs2 is a purely functional streaming library, with support for concurrent and nondeterministic merging of arbitrary streams. Concurrency support means that we can use Stream not only to process data in constant memory, but also as a very general abstraction for control flow: whilst IO gives us an excellent model for a single effectful action, assembling behaviour with it often has a very imperative flavour (pure, but still imperative). This talk will introduce fs2 combinators by example, and will hopefully show how we can model control flow in a declarative, high level, composable fashion. In particular, we will focus on concurrent combinators. * Material * Slides: systemfw.github.io/TL-Summit-Boston-2018/#/ * Event * Typelevel Summit Boston, March 2018: typelevel.org/event/2018-03-summit-boston/ * About Speaker * I’m a Senior Software Engineer based in Edinburgh, UK, working in Scala in the financial industry. I also actively participate in Open Source (as SystemFw): I’m one of the maintainers of fs2, and a contributor to cats, shapeless, http4s and most of the other libraries in the Scala FP ecosystem. I have a passion for helping people master advanced concepts, so hit me up on Gitter if you have a question! * Licensing * This recording is licensed under CC-BY 4.0 (creativecommons.org/licenses/by/4.0/).

Why it's here

2 people recommend this

What people say. Highly recommended as a great introduction to using fs2 for control flow and concurrency beyond simple data streaming.

u/TimWSpencein r/scala • Recommends

On “Where can I practically use FS2?”

This is a great talk by Fabio on why you should use fs2 for much more than just streaming: link to this video

u/justinhjin r/scala • Recommends

On “Need help to understand fs2 library”

To be very brief… streaming and control flow. see link to this video for a great intro to the latter