add logging to retry