spring-integration

Spring retry find the last retry

久未见 提交于 2020-12-01 14:53:32
问题 I am using Spring-retry-1.2.0, Retry is working fine, but in my method i want to find it out whether the retrial is the last retrial or not, Is there any method available to get the retrialCount or last retrial in spring-retry? Retrial.java public class Offers extends SimpleRetryPolicy { @Async @Retryable(maxAttemptsExpression = "#{retrial.times}", backoff = @Backoff(delayExpression = "#{retrial.delay}")) public void handleOfferes(Data data) { AlwaysRetryPolicy policy = new AlwaysRetryPolicy(