Add filters to the subscribers that filter the chat messages for their specific chat room(s).
This works depending on your traffic.
Mind, I wouldn't use this approach at all. I'd look at any of the bastions of this process on the net (like IRC or Jabber or The Acronym Escapes Me for the P2P Java standard that works for this).
I wouldn't reinvent this wheel, basically.
[Message sent by forum member 'whartung' (whartung)]
http://forums.java.net/jive/thread.jspa?messageID=253334