-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cancel subscription for MPS.subscribeToPublisher
The `Flux.takeWhile()` only works if there is data in the `Publisher` to consume. We still need to be able to cancel subscription and stop producing even if there is no data at the moment. * Change `takeWhile()` to the `doOnSubscribe()` and store `subscription` in the `volatile` property of the `MessageProducerSupport` * Cancel such a subscription in the `doStop()` impl * Propagate `doStop()` to super in the `ZeroMqMessageProducer` which is only one reactive channel adapter overriding `doStop()` * Verify in the `ReactiveMessageProducerTests` that subscription is cancelled for delayed data in the `Publisher` **Cherry-pick to `5.5.x`**
- Loading branch information
1 parent
0550380
commit e434a46
Showing
3 changed files
with
45 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters