Added feature to shutdown the server