fs2 is an excellent functional streaming library with a rich toolbox for
transforming streams. But sometimes we need a transformation that’s outside
that box. In this tutorial we’ll learn how to write custom transformations
using the fs2.Pull
datatype. By the end of it you’ll be
able to write every stream transformation you can think of.
You will learn
How to write custom stream transformations using pulls.
How fs2 own transformations, such as
take
, are built.
I assume you know
How to build streams with the
fs2.Stream
datatype.How to use stream transformations such as
take
.A bit about the cats effect
IO
datatype, to the extent that you can create and run anIO
.
You’ll get the most out of this if you’ve extensively used fs2, but haven’t yet explored pulls.