Skip to content

fromEmitter same-pool deadlock #4735

Closed
Closed
@akarnokd

Description

@akarnokd

This affects both 1.x and 2.x.

There is a question on StackOverflow where the example program hangs after it delivered the default bufferSize elements until the fromEmitter source completes.

The problem is that subscribeOn schedules the downstream's replenishing request on the same thread that is busy/sleeping and has no opportunity to update its internal requested amount. We had similar problems with onBackpressureBlock which had to be dropped.

We could introduce a subscribeOn mode in which it doesn't reschedule the request from downstream but it will confuse some and make wonder others.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions