Enable shutdown hook to close sockets. Start writing end to end test
End-to-end test and shutdown working properly
test cleanup