dataIntegrityViolationException, newYangResourceEntities);
convertedException.ifPresent(
e -> {
- final RetryContext context = RetrySynchronizationManager.getContext();
- int retryCount = context == null ? 0 : context.getRetryCount();
+ final RetryContext retryContext = RetrySynchronizationManager.getContext();
+ int retryCount = retryContext == null ? 0 : retryContext.getRetryCount();
log.warn("Cannot persist duplicated yang resource. System will attempt this method "
+ "up to 5 times. Current retry count : {}", ++retryCount, e);
});