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

1.x: fix reset() shutting down everything other than the schedulers #3996

Merged
merged 1 commit into from
Jun 7, 2016

Conversation

akarnokd
Copy link
Member

@akarnokd akarnokd commented Jun 7, 2016

The reset shut down all the main schedulers and the helper pools, causing the failure in #3993 .

@hzsweers, you were right with the need for the instance-shutdown method.

@akarnokd akarnokd added the Bug label Jun 7, 2016
/**
* Start the instance-specific schedulers.
*/
synchronized void startInstance() {
Copy link
Contributor

@ZacSweers ZacSweers Jun 7, 2016

Choose a reason for hiding this comment

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

Any reason to not make these private?

Copy link
Member Author

Choose a reason for hiding this comment

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

We try to avoid too much private modifiers; generally it adds hidden bridge methods, increasing the method count which is bad for Android. Also package level access leaves it open to same-package unit testing.

Copy link
Contributor

Choose a reason for hiding this comment

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

Fair enough, though this case wouldn't generate synthetic accessors I don't think.

Copy link
Member Author

Choose a reason for hiding this comment

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

Right, bridges are not in play here; it has become a second nature of me scoping as package-private.

Copy link
Contributor

Choose a reason for hiding this comment

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

Not a bad approach :). LGTM then

@ZacSweers
Copy link
Contributor

Minor nit, rest of the code looks good 👍

Nice catch, sorry for the inadvertent bug and glad it was a relatively simple fix

@artem-zinnatullin
Copy link
Contributor

👍

1 similar comment
@stevegury
Copy link
Member

👍

@akarnokd akarnokd merged commit 08a2130 into ReactiveX:1.x Jun 7, 2016
@akarnokd akarnokd deleted the Lifecyclefix branch June 7, 2016 23:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants