Codecs and Funny Looking Functors
summary
Uses scodec to build actual encoders/decoders: shows the greedy-string problem, implements a size‑prefixed (var) encoder over bitvectors and Attempt results, composes primitive codecs into a DNS packet codec, derives ISOs to move between bitvector/bytearray/tuples, and plugs codecs into Netty/NIO as a profunctor IO abstraction. Produces a working DNS client that round-trips UDP packets and returns multiple IPs, with STUN mentioned as another real protocol example.
AI-written summary · about
chapters (12)
- 0:00Start
- 1:04Building Real-World Applications with Fp Libraries
- 3:02Encoder
- 3:26Decoder
- 3:39Decode Result
- 4:19Utf-8
- 8:15Custom Codec
- 9:24Var Encoder
- 20:53Ipv4 Codec
- 21:15Io Non-Blocking I / O
- 28:35Isomorphism
- 34:37Write a Dns Client from Scratch








