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

Remove ReadyService #68

Merged
merged 3 commits into from
Apr 25, 2018
Merged

Remove ReadyService #68

merged 3 commits into from
Apr 25, 2018

Conversation

carllerche
Copy link
Member

The value added by having a separate trait is not obvious. Equivalent
behavior can be provided by a Service implementation that is always
"ready".

The value added by having a separate trait is not obvious. Equivalent
behavior can be provided by a `Service` implementation that is always
"ready".
@olix0r
Copy link
Collaborator

olix0r commented Apr 25, 2018

And, so, generally, we expect service implementations to be graceful when poll_ready has not been called (i.e. should not panic, at least). Should this be reflected in the trait docs?

@@ -189,6 +189,9 @@ pub trait Service {
/// implementations should take care to not call `poll_ready`. If the
/// service is at capacity and the request is unable to be handled, the
/// returned `Future` should resolve to an error.
///
/// Calling `poll_ready` before calling `call` is permitted. The
Copy link
Collaborator

Choose a reason for hiding this comment

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

Calling call before calling poll_ready is permitted!

@carllerche carllerche merged commit 295ae58 into master Apr 25, 2018
@carllerche carllerche deleted the remove-ready-service branch April 30, 2018 19:08
@hawkw hawkw mentioned this pull request Jan 10, 2022
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.

2 participants