Adding logging example to write a log every second until the server shuts down