-
Notifications
You must be signed in to change notification settings - Fork 82
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
Add logic to replace the standard RxJava 2 schedulers with reactor ones #202
Conversation
Hi @akarnokd, Nice to see this topic being discussed :) Have you seen reactor/reactor-core#1655 by any chance? |
I don't know what that issue is about. |
reactor-adapter/src/main/java/reactor/adapter/rxjava/RxJava2Schedulers.java
Outdated
Show resolved
Hide resolved
…hedulers.java Co-Authored-By: akarnokd <akarnokd@gmail.com>
We identified a problem when users shade Reactor (aka relocate it with different package name) that the schedulers are obviously not shared anymore. It correlates with your motivation ( "so that redundant worker threads could be avoided" ) in this PR, but from a different perspective, this is why I thought you may be interested in joining the conversation there. |
reactor-adapter/src/test/java/reactor/adapter/rxjava/RxJava2SchedulersTest.java
Outdated
Show resolved
Hide resolved
…hedulersTest.java Co-Authored-By: akarnokd <akarnokd@gmail.com>
Thanks for the PR @akarnokd 🙇 Regarding the core issue quoted by @bsideup, have you got any insight on shading? Has it come up in RxJava 2 world that some library would shade RxJava (with package relocation) and then duplicate worker threads issue would arise for downstream users that use both said library and vanilla RxJava? |
You'd have to know where |
This PR allows the user to replace the standard RxJava 2 schedulers with its Reactor-Core counterparts (and restore the defaults as well) so that redundant worker threads could be avoided.