This joins the server thread, right? Why is this needed?