Skip to content

KFoxder/udp_multicast_examples

Repository files navigation

OCaml UDP Multicast Examples

Goal of this is to provide UDP multicast examples using the two main OCaml concurrency libraries lwt, async and no concurrency. I couldn't find good examples at the time so I created them for anyone who may need them as a starting point in the future.

See blog post: https://www.kevinfox.dev/udp-multicast

Setup / Install

opam switch create udp_multicast ocaml.5.1.1
eval $(opam env --switch=udp_multicast)
opam install . --deps-only

Run UDP Multicast Listener

# Run one (or all three) of the multicast listeners
# Option 1: Run lwt
dune exec multicast_udp lwt
# Option 2: Run async 
dune exec multicast_udp async
# Option 3: Run with no concurrency
dune exec multicast_udp none

Run UDP Multicast Sender

# In a seperate terminal run:
dune exec multicast_udp sender

Screenshots

Helpful Resources

About

UDP Multicast Examples using OCaml

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages