Failed connections are now handled correctly.
Created a shutdown sequence. Main thread catches a SIGINT signal and shuts down the server. The server itself shuts down all observers in a controlled manner.