Implementing a room-based chat application