add logging for shutdown exceptions