I have a flash system I would like to integrate with another off-the-shelf flash application with XIFF. I want App.A to be able to show the users in a Multi User Chatroom (MUC) as well as a user’'s Roster. I want App.B to be able to actually show the chat room and private messages.
The key is that App.A is able to initiate messages or invite a user to a newly created MUC that is shown in App.B
My idea was to bind each one as a separate resources:
If I make App.A bind first, then App.B…by priority all new messages will go to App.B even if they are initiated by App.A. Also all MUC stanzas will go to App.B also, right?
If this approach is totally wrong, I’‘m open to suggestions. Sorry if this is a rehash but I’'m just starting to learn XMPP. Thank you!
You can use a single account and log from many places/resources. If user@example/App.A wants to send a message to user@example/App.B then he needs to send it to user@example/App.B and not user@example. Otherwise, the presence priority logic will be used. Each connected resource can also join the room just if they were different users.
The only issue that I can see is that all connected resource of the same user will share the same roster. If you need each connected resource to have a unique/personal roster then you will have to use different accounts. Anyway, since messages sent to bare JIDs will be redirected to a single resource I would recommend using different accounts (if at all possible).
I was pretty sure my logic was correct. Since I have granular control over both applications I am able to make sure that calls are not made to bare JIDs. This will allow me to coordinate traffic between the two. And its good they’'re sharing the same Roster. I want the experience to be seamless for the user. This way they will be using two different applications but the chat will pass smoothly between them.
Thank you Gato, you’'ve been most helpful!