rsocket / rsocket-java

Java implementation of RSocket
http://rsocket.io
Apache License 2.0
2.35k stars 354 forks source link

updates versions and fixes memleak in UnboundedProcessor #1106

Closed OlegDokuka closed 6 months ago

OlegDokuka commented 6 months ago

This PR updates dependencies and makes minor modifications to UnboundedProcessor due to repeating failures of UnboundedProcessorJCStreassTest, which started reproducing some unspotted issues.

Motivation:

UnboundedProcessor is a critical component in the RSocket-Java ecosystem and must work properly. After analysis of its internal state machine, it was spotted that sometimes:

  1. Request may not be delivered due to natural concurrency
  2. Terminal signal may not be delivered since it checks for demand which might be consumed already (due to natural concurrency)
  3. Final value could be delivered violating reactive-streams spec

Modifications:

This PR adds a minimal set of changes, preserving old implementation but eliminating the mentioned bugs

Result:

[After your change, what will change.]