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

provides ordered stream id issuing #811

Merged
merged 1 commit into from May 4, 2020
Merged

Conversation

OlegDokuka
Copy link
Member

@OlegDokuka OlegDokuka commented May 2, 2020

This PR ensures that stream ids are issued in order even under high racing between logical streams in the way of scheduling stream id issuing on the event loop scheduler.

This is done on the level of RSocket because of the incorrect Transport level design and should be considered as a workaround until DuplexConnection will be revised in 1.1

Signed-off-by: Oleh Dokuka shadowgun@i.ua

@OlegDokuka OlegDokuka added the bug label May 2, 2020
@OlegDokuka OlegDokuka added this to Done in Core May 2, 2020
@OlegDokuka OlegDokuka added this to Done in Transoport-Netty May 2, 2020
@OlegDokuka OlegDokuka added this to the 1.0 milestone May 2, 2020
@OlegDokuka OlegDokuka linked an issue May 2, 2020 that may be closed by this pull request
Copy link
Contributor

@rstoyanchev rstoyanchev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering about the performance impact of putting this on the EventLoop scheduler and also whether serial execution would be enforced across multiple connections with global resources in Reactor Netty?

On other hand why not create Schedulers.single(Schedulers.parallel()) in RSocketRequester and not involve DuplexConnection at all?

@OlegDokuka
Copy link
Member Author

I guess you are right. We can sacrifice a new API method in favor of just solving the problem

@OlegDokuka
Copy link
Member Author

OlegDokuka commented May 4, 2020

@rstoyanchev fixed. Followed your suggestion to use Scheduler.single(Schedulers.parallel()) Since this is a workaround, a configuration of that should never be public API until one request for that

Signed-off-by: Oleh Dokuka <shadowgun@i.ua>
@OlegDokuka OlegDokuka merged commit 202e27f into develop May 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Core
  
Done
Development

Successfully merging this pull request may close these issues.

Requests may have non-sequential stream ids
2 participants