Fix/3.x/adding logging to client shutdown