-
Type:
Improvement
-
Resolution: Unresolved
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: Reactive Streams
As per valentin.kovalenko@mongodb.com observations in #1178
I am not sure synchronization is needed here at all, because of the following rules:
- Subscription #1: Subscription.request and Subscription.cancel MUST only be called inside of its Subscriber context.
- Subscriber #7: A Subscriber MUST ensure that all calls on its Subscription's request and cancel methods are performed serially.
But, because I am not sure it is not needed (I may be missing or misunderstanding something), I preserved the synchronization.
Since upgrading the reactor to 2022.0.0 - the compliance with the reactive streams spec should enable the removal of the lock / synchronization.