Details
-
Improvement
-
Resolution: Unresolved
-
Major
-
None
-
None
-
None
-
None
-
1
Description
Currently the IO promises are completed on the netty threads, and as a result all downstream operations are also performed on the netty thread (unless the user manually hops threads with a `publishOn` operator). This is great for performance, but it's a change in behavior from SDK 2, where the promises were completed on the IO thread.
To help users who want to retain the SDK 2 behavior, or who want to use a different scheduler globally for performance reasons, we can add a flag to the environment, and complete the IO promises using the CoreEnvironment's scheduler instead of the Netty scheduler.
Michael N notes that for this to work with the Async API, we'll need to do this thread hop close to the metal; we can scheduler a task on the CoreEnvironment's scheduler, and this task can complete the CompletableFuture. The downstream operations will then happen on the CoreEnvironment's scheduler (unless user overrides with a `publishOn` operator).
Attachments
Issue Links
- links to