getting messages from server