Skip to content

Allow StreamRabbitListenerContainerFactory message listeners to retry messages in a standard manner #1455

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
daniel-bray-sonalake opened this issue Apr 26, 2022 · 0 comments · Fixed by #1456
Assignees
Milestone

Comments

@daniel-bray-sonalake
Copy link

Expected Behavior

I spotted this when looking into this: Can StreamRabbitListenerContainerFactory message listeners retry messages?

Retries for deliveries in the classic listener containers is implemented using the advice chain (with a retry interceptor https://docs.spring.io/spring-amqp/docs/current/reference/html/#retry).

So there's no standard way to handle retries as part of the stream container factory, that do exist on the SimpleMessageListenerContainer

Current Behavior

There is currently no advice chain support in the StreamListenerContainer.

Context

There are workarounds - suggested in the Can StreamRabbitListenerContainerFactory message listeners retry messages? - but it pushes the retry logic out into all the @RabbitListeners, instead of keeping it central.

@garyrussell garyrussell added this to the 3.0.0-M3 milestone Apr 26, 2022
@garyrussell garyrussell self-assigned this Apr 26, 2022
garyrussell added a commit to garyrussell/spring-amqp that referenced this issue Apr 26, 2022
Resolves spring-projects#1455

Add an advice chain to the stream listener container and its factory.
Add a `StreamMessageRecoverer` for native stream messages.
Add a retry interceptor to work with native stream messages.

**cherry-pick to 2.4.x**
garyrussell added a commit to garyrussell/spring-amqp that referenced this issue Apr 26, 2022
Resolves spring-projects#1455

Add an advice chain to the stream listener container and its factory.
Add a `StreamMessageRecoverer` for native stream messages.
Add a retry interceptor to work with native stream messages.

**cherry-pick to 2.4.x**
artembilan pushed a commit that referenced this issue Apr 27, 2022
Resolves #1455

Add an advice chain to the stream listener container and its factory.
Add a `StreamMessageRecoverer` for native stream messages.
Add a retry interceptor to work with native stream messages.

**cherry-pick to 2.4.x**

* Add since to new setter.
artembilan pushed a commit that referenced this issue Apr 27, 2022
Resolves #1455

Add an advice chain to the stream listener container and its factory.
Add a `StreamMessageRecoverer` for native stream messages.
Add a retry interceptor to work with native stream messages.

**cherry-pick to 2.4.x**

* Add since to new setter.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants