-
Notifications
You must be signed in to change notification settings - Fork 514
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
Set HTTPMaximumConnectionsPerHost to PINRemoteImageHTTPMaximumConnectionsPerHost only if user don't provide sessionConfiguration #516
Conversation
…ionsPerHost only if user don't provide sessionConfiguration
Please add a test. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you're right that this is a good change. I'm wondering if we should update the documentation in the header to mention that users don't want to forget to set it if they provide they're own sessionConfiguration?
@garrettmoon Yep, I agree, tell users to set |
Thanks for the test! |
@zhongwuzw do you mind adding an entry to CHANGELOG.md for this one? |
Changelog added. |
🚫 CI failed with log |
🚫 CI failed with log |
Mind rebasing against master? I think I fixed a flakey test. |
🚫 CI failed with log |
If user provide its own
sessionConfiguration
, we need to respect their configuration, so here we setHTTPMaximumConnectionsPerHost
toPINRemoteImageHTTPMaximumConnectionsPerHost
,but it may not always user expected, andHTTPMaximumConnectionsPerHost
is for any url which belongs to the same host, so it's different fromMaxConcurrentOperations
.The original commit is from #342, but I think
HTTPMaximumConnectionsPerHost
little thanMaxConcurrentOperations
not means it would always timeout, because they are different concepts. :) And in weak network quality, I think we need to constrain the tcp connections, not set maximum connections to a unlimited number.