diff --git a/spring-kafka-docs/src/main/antora/modules/ROOT/pages/retrytopic/topic-naming.adoc b/spring-kafka-docs/src/main/antora/modules/ROOT/pages/retrytopic/topic-naming.adoc index 1d97f7a26c..d108a7616f 100644 --- a/spring-kafka-docs/src/main/antora/modules/ROOT/pages/retrytopic/topic-naming.adoc +++ b/spring-kafka-docs/src/main/antora/modules/ROOT/pages/retrytopic/topic-naming.adoc @@ -79,7 +79,7 @@ NOTE: The previous `FixedDelayStrategy` is now deprecated, and can be replaced b [source, java] ---- -@RetryableTopic(backoff = @Backoff(2_000), fixedDelayTopicStrategy = FixedDelayStrategy.SINGLE_TOPIC) +@RetryableTopic(backoff = @Backoff(2_000), sameIntervalTopicReuseStrategy = SameIntervalTopicReuseStrategy.SINGLE_TOPIC) @KafkaListener(topics = "my-annotated-topic") public void processMessage(MyPojo message) { // ... message processing @@ -94,7 +94,7 @@ public RetryTopicConfiguration myRetryTopic(KafkaTemplate templa .newInstance() .fixedBackOff(3_000) .maxAttempts(5) - .useSingleTopicForFixedDelays() + .useSingleTopicForSameIntervals() .create(template); } ---- diff --git a/spring-kafka/src/main/java/org/springframework/kafka/annotation/EnableKafkaRetryTopic.java b/spring-kafka/src/main/java/org/springframework/kafka/annotation/EnableKafkaRetryTopic.java index a798c76c3f..f6c4e1525c 100644 --- a/spring-kafka/src/main/java/org/springframework/kafka/annotation/EnableKafkaRetryTopic.java +++ b/spring-kafka/src/main/java/org/springframework/kafka/annotation/EnableKafkaRetryTopic.java @@ -39,7 +39,7 @@ * @Component * public class MyListener { * - * @RetryableTopic(fixedDelayTopicStrategy = FixedDelayStrategy.SINGLE_TOPIC, backoff = @Backoff(4000)) + * @RetryableTopic(sameIntervalTopicReuseStrategy = SameIntervalTopicReuseStrategy.SINGLE_TOPIC, backoff = @Backoff(4000)) * @KafkaListener(topics = "myTopic") * public void listen(String message, @Header(KafkaHeaders.RECEIVED_TOPIC) String receivedTopic) { * logger.info("Message {} received in topic {} ", message, receivedTopic);