ejabberd and dependencies: major set of open source repositories

Mickaël Rémond
· 3 min read
Send by email

Since 2002, ejabberd established itself as a major Erlang project. People learn Erlang because of ejabberd. For this reason alone, ProcessOne is one of the major contributors in the open source Erlang community, along with Erlang OTP itself (heavy investment from Ericsson), Elixir mainly from PlataformatecRiak from BashoCowboy from NineNinesChicagoBoss and Zotonic.

However, ejabberd is just the tips of the iceberg. When we decide to make ejabberd more modular in 2013, we split the code base into small reusable components. They are now “ejabberd dependencies”, but of course count as major contribution from ProcessOne as well and can be reused and improved independently.

This post is a walkthrough all ejabberd dependencies, as multiple spin-off effort of ejabberd development process:

ejabberd dependencies

ejabberd code based is split among several repositories so effectively ejabberd code is much more than what is in its primary repository.

Required dependencies

The main ejabberd repository is processone/ejabberd

There is hundreds of forks, but we actively maintain ejabberd to make it the most reliable and up to date version. This is thus your best starting point.

When you build ejabberd yourself, the build chain will download a few Erlang dependencies:

  • processone/cache_tab: Flexible in-memory Erlang caching module.
  • processone/eiconv: Native iconv driver for Erlang. This is use for fast character encoding conversion.
  • processone/xml: Fast native Expat based Erlang XML parsing library. XML is the core of XMPP so we needed to provide the fast and more robust XML parsing stack as possible. It means that if you are looking for a great XML parser, reusing p1_xml is probably a great idea.
  • processone/stringprep: Fast and efficient Erlang Stringprep native driver. Stringprep is heavily used in XMPP to define encoding rules of various XMPP objects.
  • processone/p1_yaml: Native Erlang interface to libyaml, for fast robust YAML parsing. This is needed by our new config file format.
  • processone/zlib: Native zlib driver for Erlang. Used for fast / efficient stream compression.
  • processone/tls: Erlang native driver for TLS / SSL. It is build for performance and is more scalable that Erlang SSL driver. If your Erlang server is handling heavy load and is using TLS, we strongly recommand you check / compare with this driver.
  • processone/p1_sip: ProcessOne SIP protocol support to add SIP-based voice capabilities to ejabberd. If you have ever studied SIP, you know this is huge :)
  • processone/stun: Implementation of Session Traversal Utilities for NAT. It is used for XMPP and SIP media capabilities, to help client discover their visible IP address and allow them to get in touch through NAT. This is basically useful for voice and file transfers.
  • processone/p1_utils: This is extra Erlang modules developed for ejabberd but that can be useful in other Erlang applications.
  • processone/p1_logger: Logger wrapper to allow selecting your prefered logger at build time.
  • basho/lager: Erlang logger module.
  • DeadZen/goldrush: Small Erlang app that provides fast event stream processing. It is used by lager.
  • vaxelfel/eHyperLogLog: HyperLogLog, a distinct values estimator, in Erlang. Used for analytics.

Optional dependencies

Then, we use a few other dependant repositories that may be used if you have enables support in the configure script.

Here are the dependancies for relational database support:

Here are the dependencies for Elixir support:

Here are the dependencies for Riak support:

Conclusion

This is just a taste of what ProcessOne has been building over the past 13 years. I could also mention other major contribution as Tsung, the most scalable and affordable benchmarking platform available. That can be used for testing large scale web or XMPP platforms.