2
votes

I am looking at a solution to pause the consumption of messages from a kinesis stream from the app itself when the down stream service is down. I am using spring-cloud-stream-binder-kinesis. There is no obvious option to do that. There doesn't seem to be an option on KCL api as well.There is stop/pause on spring actuator bindings end point which doesn't seem to work for Kinesis. One option is to use AWS SDK api and do a pull rather than the push mechanism of KCL/Spring cloud and stop pulling on a circuit breaker.

Are there any other options to do this?

1

1 Answers

0
votes

Kinesis consumers (independently of library) don't support pause/resume at all. There is just no such a concept in AWS Kinesis.

You indeed can use start/stop actuator endpoints for particular binding to control its lifecycle.

Not sure why do you say it doesn't work: there is no difference with other binders in this part.