9

Hi I am new to this: I have set up an Openfire Server and using Spark IM to test it. But for Android application code what should be the JID for the user in session:

I have tried username@ip_address , username@ip_address/Smack , username@ip_address/Spark. Please see the image below and help:

enter image description here

What would be the solution for this .please help.

Navdroid
  • 1,541
  • 3
  • 25
  • 52

1 Answers1

11

JID is: username@xmpp-domain/Resource. The IP address of your Openfire host can be different to the XMPP Domain. You can see you XMPP Domain if you are in Openfire Web Interface under "Server Name". Resource can be everything, for e.g workstation, mobile or just customerXY.

Roman S.
  • 1,206
  • 15
  • 24
  • what comes under `resource` – Phaneendra Charyulu Kanduri Apr 16 '16 at 16:42
  • 1
    `resource` can be everything. e.g. laptop, workstation, mobile or customerX – Roman S. Jul 12 '16 at 08:23
  • 1
    @Roman why we are getting /Smack like username@xmpp-domain/Smack sometimes and number in resource sometimes like this username@xmpp-domain/789522112. – Ajay Aug 04 '16 at 14:37
  • 1
    Resource will be defined by the client (In your case its seems to be Smack), If you don't explicitly set it, it will be just "Smack". Regarding the number i'm unsure. Maybe its because the user with the same resource is already there and it takes a random number. – Roman S. Aug 04 '16 at 14:40