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

feat(server): add http2_max_concurrent_streams builder option #1774

Merged
merged 1 commit into from
Mar 1, 2019

Conversation

seanmonstar
Copy link
Member

Closes #1772

@seanmonstar seanmonstar merged commit cbae429 into master Mar 1, 2019
@seanmonstar seanmonstar deleted the http2-max-streams branch March 1, 2019 00:19
///
/// [spec]: https://http2.github.io/http2-spec/#SETTINGS_MAX_CONCURRENT_STREAMS
pub fn http2_max_concurrent_streams(mut self, max: impl Into<Option<u32>>) -> Self {
self.protocol.http2_max_concurrent_streams(max.into());
Copy link
Contributor

Choose a reason for hiding this comment

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

Why do you have max.into() here, but

if let Some(max) = max.into {
    ...
}

in src/server/conn?

Copy link
Member Author

Choose a reason for hiding this comment

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

Hm, didn't think much about it, really!

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh okay!

Copy link
Contributor

@kleimkuhler kleimkuhler Mar 1, 2019

Choose a reason for hiding this comment

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

Oh no this makes sense. h2's fn max_concurrent_streams needs a value, while here you are passing in an Option to conn::Http's wrapper.

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