set up longPolling for users and chat, then updateUsers and getMessages.