Raj
Raj

Reputation: 1727

How can i configure a kafka batch consumer to retry a pre-defined no of times using SeekToCurrentBatchErrorHandler?

I'm using spring-kafka '2.2.7.RELEASE' to create a batch consumer and I'm trying to understand How can i configure a kafka batch consumer to retry a pre-defined no of times using SeekToCurrentBatchErrorHandler?

I see the one of the SeekToCurrentErrorHandler constructors takes 'maxFailures' as an argument but I don't see any such option for SeekToCurrentBatchErrorHandler. Please suggest.

Upvotes: 0

Views: 285

Answers (1)

Gary Russell
Gary Russell

Reputation: 174554

2.2.x is no longer supported.

See the documentation for the reasons why recovery after some number of failures is not supported with batch listeners and older versions of the framework.

You can use the RetryingBatchErrorHandler (since 2.3.7) or RecoveringBatchErrorHandler (since 2.5.0) instead.

Upvotes: 1

Related Questions