xmpp tested, cleaned and documented