by diljitpr · 10mo ago · 0 comments
ExponentialBackOffWithMaxRetries backOff = new ExponentialBackOffWithMaxRetries(3);
backOff.setInitialInterval(2000L); // 2 seconds initial delay
backOff.setMultiplier(2.0); // Exponential backoff
backOff.setMaxInterval(30000L); // Max delay 30 seconds
backOff.setMaxAttempts(3); // Retry 3 times before DLQ
Updated this in my blog.
No comments yet.