[erlang-questions] MongooseIM - Expose Roster Information to External Server

Mickaël Rémond mremond@REDACTED
Fri Jan 29 13:14:03 CET 2016


Hello,

> On 29 Jan 2016, at 00:05, Josh Spain <jspain@REDACTED> wrote:
> 
> I have some MongooseIM servers and would like to provide the roster information to another (non-XMPP) server. The ways I have thought of to do this are the following:
> - Use the ODBC roster module and pull the information directly from the SQL DB
> - Write a plugin that exposes the information through a REST API
> 
> These roster queries would not happen at high volume. What would the impact of using SQL to store roster information has on the XMPP servers? Is there a preferred way to do something like this?

For ejabberd and variations, the best approach is definitely not to duplicate the data.
ejabberd is extensible with hooks and you can build your own roster module quite easily with hooks. You can write a roster plugin that will either access your database directly or that query it through Rest API.

That's definitely the best approach.

You can also have a look in the code at mod_shared_roster. It is a good example showing that you can even write alternative logic to roster management.

You can mail me directly if you need some guidance.

Cheers,

-- 
Mickaël Rémond
 http://www.process-one.net




More information about the erlang-questions mailing list