ejabberd - Comments for "How can I do custom MySQL Queries with ejabberd?" https://www.ejabberd.im/node/9188 en I had more to say about this https://www.ejabberd.im/node/9188#comment-59378 <p>I had more to say about this before: <a href="http://www.ejabberd.im/node/8979" title="http://www.ejabberd.im/node/8979">http://www.ejabberd.im/node/8979</a></p> Fri, 11 Jan 2013 19:24:04 +0000 arpad9 comment 59378 at https://www.ejabberd.im I just finished building https://www.ejabberd.im/node/9188#comment-59374 <p>I just finished building almost exactly the same thing. I kept all of the xmpp authentication separate from the regular users' auth. The system uses xmpp on the users' behalf. I used Strophe in the browser to connect and pass the session info to Strophe via mod_warm_bindings so the web client doesn't need to know auth.</p> <p>I don't think MySQL is necessary. However, ejabberd does have pieces that allow you to authenticate to an external source if that's what you want. As a matter of fact, I'd say MySQL is the wrong path completely.</p> <p>I used MySQL and found that the xmpp challenge/response auth was too heavy for sending quick commands like managing users and pubsub. For most things, I was happy with mod_rest and mod_admin_extra. However, I ended up using a read-only MySQL user for some queries that weren't available via those methods.</p> <p>NOW... I'm looking at converting away from MySQL and back to mnesia. I believe that mnesia will offer better clustering possibilities and maybe even better performance... Clustered MySQL doesn't support views and some index naming used in mod_mysql and therefore doesn't support ejabberd.</p> <p>To access mnesia directly, I'm either going to dig into some erlang and build off of mod_admin_extra. Currently, mod_admin_extra accepts random xml stanzas but in most cases, doesn't return anything because, I believe, most xmpp commands aren't meant to be synchronous. OR, I'm going to look at a ruby/mnesia bridge that exists out there for reads into mnesia.</p> <p>I basically had a "doh" moment when I was setting up the mnesia clustering... which seems to work really well and is build for just the kind of things we need to do.</p> Fri, 11 Jan 2013 18:04:24 +0000 arpad9 comment 59374 at https://www.ejabberd.im