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

ExecutorScheduler to wrap an Executor #1272

Merged
merged 1 commit into from
May 28, 2014

Conversation

akarnokd
Copy link
Member

For issue #1219 (and #1206)

This implementation should conform with the Scheduler contract except it is not possible to avoid thread-hopping (don't worry, the tasks execute serially, but maybe not on the same physical thread).

Few open improvement possibilities:

  • Usage of MpscLinkedQueue once available.
  • A better performing subscription container for this kind of queue-drain task tracking instead of CompositeSubscription.
  • Ability to remove a Subscription from a CompositeSubscription without it calling unsubscribe on the removed Subscription, á la MultipleAssignmentSubscription.set().

@cloudbees-pull-request-builder

RxJava-pull-requests #1170 SUCCESS
This pull request looks good

@benjchristensen
Copy link
Member

Thanks @akarnokd for this. Looks good for a first cut. The trade-offs (thread hopping) are expected, and why we won't use this as a default for anything, and agreed on possible improvements, but those can come later.

benjchristensen added a commit that referenced this pull request May 28, 2014
ExecutorScheduler to wrap an Executor
@benjchristensen benjchristensen merged commit 5f2cf72 into ReactiveX:master May 28, 2014
@akarnokd akarnokd deleted the ExecutorScheduler branch May 28, 2014 20:39
@benjchristensen benjchristensen mentioned this pull request Jun 1, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants