views:

1303

answers:

3

Where can I find a good XMPP (Jabber) tutorial with detailed information on the XML that's sent to/from a Jabber client and server. I've looked at the xmpp.org website, but what they show there is confusing and doesn't help me learn.

I want to write an XMPP client in C# that uses a TcpClient to connect to the server and send/receive XML data.

+1  A: 

Not a tutorial, but a great way to start is with the Agsxmpp library. http://www.ag-software.de/agsxmpp-sdk.html

That will help you gain familiarity with the flow of messages.

Hightechrider
+1  A: 

I can highly recommend XMPP: The Definitive Guide from O'Reilly. It goes into great detail about how stanzas are constructed and what the various major protocols require. It does not however have any code in it, aside from the final chapter.

I also recommend using one of the already available C# libraries for doing your XMPP programming instead of writing your own. Dealing with TLS, stream setup, and asynchronous XML parsing can be a hard way to get started. I can recommend Jabber-net for this.

If you want a tutorial that is more code focused, I wrote a book called Professional XMPP Programming that goes through a number of example applications using JavaScript as the implementation language. The main concepts all apply equally well to any XMPP development.

metajack
A: 

I second "XMPP: The Definitive Guide" as a way to really understand what is happening behind-the-scenes. It's very accessible and does go into enough depth that you can figure things out for yourself afterwards.

I would recommend you not go with the "Professional XMPP Programming" book though. I purchased both of these together and I was not able to run even a single example app in the latter book as the BOSH stuff he is using would just not work (there is a problem with the newer browsers and his implementation of running cross-site AJAX). There are complaints on the forums for that book but are largely unanswered.

After going through all servers and libraries, I can recommend ejabberd as it seems to be the most stable and easy to set up. For libraries, I found MatriX to be the best (and only one that I could actually do any programming for). I am trying to use .Net though, so YMMV MatriX is the newer version of agsxmpp mentioned above.

electrichead