3

I am thinking of implementing an easy Instant Messaging server in Java, but I don't want to create yet another protocol, but instead use an already simple IM-protocol. But I don't know which protocol I should use.

The reason Why I want to use an already existing IM-protocol, is that I would like my 'users' to be able to use their own clients, for example pidgin - which already offers a wide spread of protocols, such as XMPP, Simple, Bonjour, etc - and I don't have to develop any clients.

I have looked a bit a XMPP but it since a lot of work embed that protocol into a new server. Maybe there are other protocols that are easier to use?

My questions is, do you guys have any suggestions of protocols that are real basic and easy to use in Java? Pidgin supports a whole bunch of protocols, but which protocols are relevant for me?

GEOCHET
  • 21,119
  • 15
  • 74
  • 98
corgrath
  • 11,673
  • 15
  • 68
  • 99
  • 1
    What is wrong with XMPP again? I didn't quite catch that... – OscarRyz Jun 09 '09 at 17:27
  • Are you reinventing the wheel as a learning exercise, or is this intended for eventual use? – ceejayoz Jun 09 '09 at 17:29
  • @Oscar Nothing is wrong with XMPP, just my first impression said "i am going to be difficult". @ceejayoz I don't want to reinvent the wheel. In fact, thats why i am looking for an easy open and free protocol so I can get coding ASAP :) – corgrath Jun 09 '09 at 17:51

3 Answers3

10

XMPP is widely used and has standards backing behind it. It is pretty easy to use if you use an existing library - there are many client libraries for it in many languages. The google says there are many in java.

An advantage of using XMPP is that your server can act as a gateway to all the other Xmpp/Jabber servers on the net, so your users can talk in & out of your network - like to people logged into GoogleTalk, using standard JID addresses, like bob@yourhost.com/desktop.

sean riley
  • 2,633
  • 1
  • 22
  • 22
  • Do you suggest any of those XMPP Java libs? Got any first hand experience? – corgrath Jun 09 '09 at 17:39
  • 1
    I suggest the Igniterealtime Library called Smack. I wrote some thing with it and you get a good start and the library is very useful for extension of the xmpp protocol – Janusz Jun 09 '09 at 18:04
  • suggest: http://www.igniterealtime.org/projects/openfire/index.jsp as their XMPP library, smack – basszero Jun 09 '09 at 18:18
  • Go with Smack; I used it for a small project and it was dead easy. Import, create a class, call a few methods on it, and I was up and running. – Alex Feinman Jun 09 '09 at 18:42
1

For the widest support I would go with XMPP/Jabber. There's no other choice really.

rein
  • 32,967
  • 23
  • 82
  • 106
0

According to this thread, it seems like a pain to develop an XMPP-server in Java:

Good XMPP Java Libraries for server side?

Even one comment stated that its better of using an existing server instead of creating one from scratch with a library.

Community
  • 1
  • 1
corgrath
  • 11,673
  • 15
  • 68
  • 99
  • 1
    I think that was the point of the "reinventing the wheel" comment on the question. Why would you write your own server if you can simply download and install, unless it is an exercise of some sort. – Robin Jun 09 '09 at 18:31