Mafalda SFU perpetual beta (AKA 1.0)

After exactly
three years of development,
lots of awake nights (and sunshines), and uncountable hours of debugging and
testing, we are proud to announce today, April 1st 2024, that we have completed
Mediasoup aggregated scalability and stability
tests, and we are ready to publicly release the first feature complete version
of Mafalda SFU. In other words, at last Mafalda SFU has got “1.0 version” status :partying_face:

This has been a huge milestone, so between highs and lows during these last
three years (including some hiatus periods due to professional or personal
reasons), we have finally reached the point where we can say that Mafalda SFU
is ready for any kind of production use case, being that by having lots of small
sized rooms each one under a single CPU capacity limits where
horizontal scalability is the best fit, one or several medium sized rooms
making use of several CPUs from a single server (vertical scalability), up to
having one or several big sized rooms extending over multiple servers where
aggregated scalability shines. Also, the high modularity of Mafalda SFU (at
this moment we have 11 main projects, and
73 repositories on GitHub between public and
privates ones) allows us to adapt to any kind of use case and architecture, and
to evolve over time with your future requirements.

Now you would be asking,
“why are you calling it ‘perpetual beta’ if you are releasing a 1.0 version?”
Well, there are three reasons for that (three is a magic number :notes:):

  1. First of all, as part of our commitment to be 100% API compatible with
    Mediasoup, we automatically check three times a day for new
    Mediasoup releases and
    pass all our project tests against them (and also, we pass all Mafalda SFU
    projects against
    Mediasoup tests themselves)
    for each new version, so instead of following semantic versioning, we make
    and publish a new release of all Mafalda SFU projects from their git main
    branches every time a new Mediasoup version is released, with all both
    Mediasoup and Mafalda SFU features and bug fixes up to that date. This
    way, the version number warrants the compatibility of each Mafalda SFU
    package with the exact same Mediasoup version.
  2. We are not going to stop developing Mafalda SFU: we have a lot of ideas not
    only about how to improve Mafalda SFU reliability and performance (and
    they are already pretty high!), but also about new features and projects in
    mind that we want to implement, like monitoring tools, offering
    Mafalda/Mediasoup as a Service (MaaS) in addition to our current
    on-premises approach, or even decentralized P2P streaming on top of
    Mediasoup over multiple regions in the world.
  3. And finally, we are going to keep the “perpetual beta” status as a reminder
    that we are always looking for feedback, and we are always open to new ideas
    and improvements, so if you have any suggestion, idea, or you want to
    collaborate with us, please don’t hesitate to contact us.

And if you are questioning yourself: no, this is not an April Fools’ joke, we
are really releasing Mafalda SFU 1.0 today, we just wanted to make you think
it :wink: So, if you want to know more about Mafalda SFU, please visit our
website, or if you want to contact us, please write us to
info@mafalda.io.

2 Likes

Hi, can you give us some insights on what metric were used to measure the vertical scaling? How much is the warm up time for new servers? How well does it handles the sudden load?

Mafalda is focused only on the media part and the logic of the load balancing, not on the infraestructure. It notify when new servers are needed, but It doesn’t spin them Up by itself, althought it’s on the roadmap to create a new module to do that.

Regarding heuristics for the vertical scaling, it’s making use of the actual CPUs usage, and algorythm try to concentrate Consumers in the less amount of Workers, reusing current ones if their CPU have still some available cycles.

Ok thanks

1 Like

Hey Piranna, sounds good! I had this thought that merging Mafalda SFU with MiroTalk SFU could be pretty fascinating to experiment with. If you’re up for it, you could fork our repository and add a commit for integrating Mafalda SFU into our existing logic. It’d be awesome to see how it performs and scales compared to what we have now. Who knows, it might lead to some exciting discoveries!

Mafalda SFU have the same API as Mediasoup, so the migration should be trivial. I have pending to write a blog post with instructions about the process, have already done it sucesfully with EduMeet (Mediasoup-demo) and it’s possible to achieve it with less than 30 lines of code and 5 minutes.

Meanwhile, maybe you would be interested on give it a try with Remote Mediasoup client mock, that provides the same common API of Remote Mediasoup and all Mafalda SFU packages, but implemented on top of vanilla Mediasoup, so no network or extra functionality involved. This way you can check yourself how much easy is to port your current codebase to Mafalda SFU, so later the migration to the real ones would be trivial and you could get both the vertical and horizontal scalability features instantly without needing to do anything more :slight_smile:

Ok, Thank you!

1 Like

Hi Piranna,

How do we get it installed for edumeet client. use case is for connecting atleast 500 users in a single session with only 16 videos in continuos presence. we are looking for Mediasoup vertical cluster.

Please let me know if we have documentation for this or is this a commercial project.

Hi Alex, Mafalda SFU is a comercial product, but really easy to use and intégrate. You can check It yourself by making use of GitHub - Mafalda-SFU/Remote-Mediasoup-client-mock: Mock of `Remote Mediasoup client`. If interested, you can write me to info@mafalda.io so we can talk about your use case and give you more info details.

Thanks Piranna,

Our client is not a server based we use AWS S3 to deploy the client and connect to the edumeet server deployed on the servers. In this case how can we utllize. GitHub - Mafalda-SFU/Remote-Mediasoup-client-mock: Mock of `Remote Mediasoup client`

Thanks
Alex

Mafalda SFU is a drop-in replacement of Mediasoup, so you would need to replace it server side in your EduMeet instance. Vertical scaling is done server side using all CPUs of the server, so It’s not possible to do it only with client-side libraries and/or without being able to modify the server code to make use of them. You’ll need to rethink your software architecture.

If interested, I can offer my freelance services to help you study what’s the best architecture aproach for your use case, and look for alternatives that better fit, maybe we can find a quick solution to it. Please send me an email to info@mafalda.io and let’s talk about the details over there.

We will definatly connect with, how can i install mafalda SFU server and just connect the edumeet client for us to quickly verify.

To install Mafalda SFU Remote Mediasoup server, it’s as simple as install any Node.js app globally, and modify EduMeet to make use of Remote Mediasoup client. i can provide you more details over email, meanwhile you can check the instructions at Remote Mediasoup client mock.