powered by Jive Software

Presence status is not correct

I am developing a simple chat application.I am creating three users using asmack

first of all I create user first

1.) 111 with two roster entries (JID=222@localhost.localdomain,JID=333@localhost.localdomain)

now my roster entries for user 111 are

then I create user second

2.) 222 with two roster entries (JID=111@localhost.localdomain,JID=333@localhost.localdomain)

roster entries for 111(now the subscription of 222 has changed from “none” to “from”)

roster entries for 222(subscription of 111 is to)

then I create user 333

3.) 333 with two roster entries (JID=111@localhost.localdomain,JID=222@localhost.localdomain)

roster entry for 111

roster entry for 222

roster entry for 333

So My problem is although all three users are online But the Presence is as follow

111 is “available” for 222 and 333

222 is “available” for only 333

333 is neither available to 111 and 222

this is due to “from” status .But I want that as all are online and all are added into each others roster list, so I need subscription status “both” for all three users roster list.So they will be “available” for each other if they are online.

Please help me how can I achieve this.

If you want a subscription status both then other users need to accept adding someone to rooster.

There is an plugin in openfire tab “plugins” called “Subscription”

This may be an easy way out for you.