When routing a packet to a remote server then a new outgoing connection will be created to the remote server if none was found and the packet will be delivered. If an existing outgoing connection already exists then it will be used for delivering the packet. Moreover, when running inside of a cluster the node that has the actual outgoing connection will be requested to deliver the requested packet.
Packets routed to components will only be sent if the internal or external component is connected to the server. Moreover, when running inside of a cluster the node that is hosting the component will be requested to deliver the requested packet. It will be first checked if the component is available in this JVM and if not then the first cluster node found hosting the component will be used.
Packets routed to users will be delivered if the user is connected to the server. Depending on the packet type and the sender of the packet only available or all user sessions could be considered. For instance, {@link org.xmpp.packet.Message Messages} and{@link org.xmpp.packet.Presence Presences} are only sent to available client sessions whilst{@link org.xmpp.packet.IQ IQs} originated to the server can be sent to available or unavailablesessions. When running inside of a cluster the node that is hosting the user session will be requested to deliver the requested packet.
@param jid the recipient of the packet to route. @param packet the packet to route. @param fromServer true if the packet was created by the server. This packets shouldalways be delivered @throws PacketException thrown if the packet is malformed (results in the sender'ssession being shutdown).
|
|
|
|
|
|