The Future of FreeSWITCH
I was amongst those lucky enough to attend the ClueCon conference this year in Chicago. Run by the guys responsible for FreeSWITCH, ClueCon is a yearly open source telephony conference with a distinctly non-Asterisk feel. While the goals of the two projects aren't exactly the same, FreeSWITCH is still emerging as a significant competitor to Asterisk, the incumbent of open source VoIP applications.
I had the opportunity to sit down with Anthony Minessale, the author of FreeSWITCH, to talk about the project. He had given a talk earlier covering the FreeSWITCH architecture so our chat helped to clarify some of the theory behind the project's major design decisions as well as illuminate some of the project's future direction.
The FreeSWITCH project is run by Anthony Minessale, the primary developer, Brian West who did the Mac and BSD port and manages community relations and quality assurance, and Mike Jeris who manages the Windows port and does the builds and bug tracking. A number of others have donated significant time as well including Simon Perreault who just completed the IPv6 implementation.
FreeSWITCH employs a model where each connection and subsystem lives in its own thread with messages being pushed in by event handlers. The theory here is that concurrency is better handled by the operating system. Rather than trying to code around concurrency issues within the application, Minessale feels that the kernel is a better place to handle this. He mentions that he would rather code practical examples for operating system designers to debug from than code around concurrency issues in the application layer. While this approach might make bug fixes take a bit longer as they would involve external developers, in the long run concurrency performance bugs are fixed better in the kernel. In practice, the kernel is highly optimized already from years of performance related improvements and FreeSWITCH benefits from this immensely so this isn't much of an issue. My tests show a better than 10x performance improvement in call concurrency over Asterisk. It would be hard to imagine a more significant affirmation of the threaded concurrency design decision.
The FreeSWITCH design also employs a protected core where critical data structures are opaque to modules hooked into the system. Complicated code is kept all in one place where it can benefit from reuse while remaining shielded from potentially misbehaving code. Developer write access to the code in the protected core is held under lock and key by Minessale personally. Of course developers can see the code in the core as it is open just as the entire project is but one would need to demonstrate significant working knowledge before Minessale would consider code for inclusion. A system of dynamic modules similar to the architecture of the Linux kernel itself allows FreeSWITCH to be extended without much knowledge of the internals. This keeps the overall product quite stable while allowing functionality to be easily extended.
While some of this architecture is similar to other projects, it is most importantly dissimilar to Asterisk. And because of that, I was most interested in finding out what the future held for FreeSWITCH.
Minessale mentions that FreeSWITCH will soon be gaining a G.729 licensing model similar to the one in Asterisk. As licensing is a necessary evil of the G.729 protocol, the FreeSWITCH project is eager to hammer out a deal where G.729 can be officially supported.
On of the most interesting things about FreeSWITCH to me has been the fact that most data in the system such as registrations are kept in a SQL database. The default installation uses SQLite internally though you can easily point FreeSWITCH at one of a number of other SQL servers such as PostgreSQL or MySQL via UnixODBC. Sadly, SQLite has become somewhat of a bottleneck in the core so future versions of FreeSWITCH will use less of it. For example, doing a "show channels" with over 500 channels in use starts to show issues. While I'm sad to see SQLite go in these cases, I am anxious to see how Minessale replaces it.
He also discussed H.323 improvements through the OPAL library and a new call control module that, for example, would be able to sit between two other calls and connect them. Continued OpenZAP integration is also in the works as is ongoing work to stabilize the Phoenix branch. Minessale also mentions that he has started work on a mod_fax for spandsp faxing and will probably eventually support t.38. Other ideas kicking around include adding a mod_sofia_proxy or proxy_profiles to mod_sofia that would supply more OpenSER-like behavior right in FreeSWITCH. In all, the FreeSWITCH team has a pile of great ideas to keep them busy for quite some time.
If you are interested, there is a 199.2MB MP4 video of Minessale's talk available online. Other ClueCon talks are available as well and Brian West mentions that more will be posted over the coming weeks.
If you haven't given it a try yet, FreeSWITCH is a compelling project. As discussed before, I'm not a fan of XML for configuration, but that is a tiny price to pay in the face of a fantastic project. The default XML configurations that come with FreeSWITCH can easily be modified to flex to meet a wide range of configuration requirements.
I want to thank Anthony Minessale and the other FreeSWITCH guys for taking the time to chat with me. If this year's ClueCon conference was any measure, it would be wise not to miss next year's event.
Tags
FreeSWITCH ClueCon Anthony MinessaleTrackbacks
To send a trackback, use the URL of this story appending ?page=tb at the end.Comments (3)
Antonio Gallo from italy
Yes, FreeSwitch is a great project. It solved a lots of disaster we had with other tools. It missed some features but their coming. Fax is ready for testing. ISDN BRI support is in beta stage and i heard too that G.729 licensing is coming.
David Ankers from Melbourne, Australia
I've been working a lot with FreeSWITCH lately and it's very impressive, specifically the amount of concurrent calls it can handle. I'm also testing it for conferencing in one large site with a sipXecs install.
Most of my clients are Cisco CM & Avaya based with a few on Asterisk, FreeSWITCH slots in really well in these environments and the more it matures the more it will replace functionality they provide.
Finally, great article but there is something I'd like to add; FreeSWITCH is rock solid, this is what I love most about it. Most of the other platforms I work with need a great deal more attention, FreeSwitch just works and stays working.
Diego Viola from
The only thing I don't like about FS is it's VAD module.
It's not very efficient, I hope they will replace it with something that works better soon.
Leave a Comment
To create links in comments:
[link:http://www.anders.com/] becomes http://www.anders.com/
[link:http://www.anders.com/|Anders.com] becomes Anders.com
Notice there is no rel="nofollow" in these hrefs. Links in comments will carry page rank from this site so only link to things worthy of people's attention.