Hi, I want the sender to send message to multiple receivers. in my case, i have like 4000 senders and 4000 receivers, but i want to have a super receiver will receive all the packets from all the senders and do a seperate work. so i thought that each sender could send the packet to their intented receiver and to the super receiver. But I dont want sender to send two different packets cos this ll cause overhead in the client side. So with single packet can i have two receivers?
You might want to look at pubsub. Or a multiuser chat room if there are lots of receivers.
Yes, a single stanza can have multiple ´to´ addresses. This extension to XMPP is called ´Extended Stanza Addressing` and is documented in http://xmpp.org/extensions/xep-0033.html
Openfire fully supports this extension.
Is there an openfire API to send IQ packets as well just to users belongins to a certain room?
Thanks for the reply…I did the following in MessageRouter.java and it worked
JID globalJID = new JID(globalReceiverNode);
Message newPacket = packet.createCopy();
routingTable.routePacket(recipientJID, packet, false);//original code
routingTable.routePacket(globalJID, newPacket, false);
Here, i hardcoded the global id and after routing the original packet to the intended users, it ll send it to global id too…
But is this good in terms of performance??