DJabberd was the answer to LiveJournal's Jabber (XMPP) server needs. We needed:

•

good performance for tons of connected users

•

ability to scale to multiple nodes

•

ability to hook into LiveJournal at all places, not just auth

Basically we wanted the swiss army knife of Jabber servers (think qpsmtpd or
mod_perl), but none existed in any language. While some popular Jabber servers
let us do pluggable auth, none let us get our hands into roster storage,
vcards, avatars, presence, etc.

So we made DJabberd. It's a Jabber server where almost everything defers to
hooks to be implemented by plugins. It does the core spec itself (including
SSL, StartTLS, server-to-server, etc), but it doesn't come with any way to do
authentication or storage or rosters, etc. You'll need to go pick up a plugin
to do those.

You should be able to plop DJabberd into your existing systems / userbase with
minimal pain. Just find a plugin that's close (if a perfect match doesn't
already exist!) and tweak.

DJabberd is event-based so we can have really low per-connection memory
requirements, smaller than is possible with a threaded jabber server. Because
of this, all plugins can operate asynchronously, taking as long as they want
to finish their work, or to decline to the next handler. (in the meantime,
while plugins wait on a response from whatever they're talking to, the
DJabberd event loop continues at full speed) However, that's more work, so
some plugins may choose to operate synchronously, but they do so with the
understanding that those plugins will cause the whole server to get bogged
down. If you're running a Jabber server for 5 users, you may not care that the
SQLite authentication backend pauses your server for milliseconds at a time,
but on a site with hundreds of thousands of connections, that wouldn't be
acceptable. Watch out for those plugins.

Read HookDocs.pm, read the major base classes (Authen, RosterStorage,
PresenceChecker), join the mailing list, ask questions ... we're here to help.
If you want more hooks, let us know! If we forgot one, it doesn't hurt us to
add more.