Skip to content
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

(Reactive) Bindings do not recover from application restart #3083

Open
kschlesselmann opened this issue Feb 13, 2025 · 1 comment
Open

(Reactive) Bindings do not recover from application restart #3083

kschlesselmann opened this issue Feb 13, 2025 · 1 comment

Comments

@kschlesselmann
Copy link

kschlesselmann commented Feb 13, 2025

Describe the issue
It seems that functions (especially producers) do not recover from application restarts. We were trying to use the auto property reload features from Spring AWS and after a context restart our functions are broken.

I've created a minimal sample to show the issue.

To Reproduce
Steps to reproduce the behavior:

  1. Start kafka via docker compose up
  2. Start the application
  3. Watch for successfully consumed messages (It just prints 1, 2, 3, ...)
  4. Restart the application via http POST :8080/actuator/restart
  5. Now the stream functions are broken

Expected behavior
The application should restart and the bindings should be fine again.

@kschlesselmann kschlesselmann changed the title (Reactive) Bindings do not Recover from an Application Restart (Reactive) Bindings do not recover from application restart Feb 13, 2025
@FlxGschlr
Copy link

I've played around with the sample and it seems like the the producer is not shutdown correctly on restart. Add a print to the producer bean and you'll see that there are two producers after the /restart call. One works as expected and one throws the following error:

org.springframework.messaging.MessageDeliveryException: failed to send Message to channel 'produce_integrationflow.channel#0'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants