r/FlutterDev • u/Ok-Willingness2266 • 55m ago
Article What are you using for low-latency live video in Flutter apps?
I work at Ant Media, so take this with that in mind. We've had a MoQ plugin for a while, and the obvious problem was that every viewer connects to the relay on your own server. Do the math on a 1 Gbps port and you're at roughly 330 viewers of a 1080p stream before you run out of bandwidth.
So we wired it up to push to Cloudflare's MoQ relays too. The server sends each track once and Cloudflare handles getting it to viewers. It's one config line, and in our test the Cloudflare copy stayed within a fraction of a second of the source.
Two things that cost us time: it only works with the draft-16 host right now, and if you use a draft-14 host everything looks fine in the logs but no viewer can ever find the stream. Also it's still beta with no SLA, so I wouldn't put anything critical on it yet.
We wrote the steps down here: https://antmedia.io/cloudflare-moq-cdn/
Is anyone else running MoQ behind a CDN or their own relays? I'm wondering what people are doing for auth, since a single shared subscribe token isn't great.