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

Support Net::HTTP::Persistent.write_timeout #586

Open
wants to merge 42 commits into
base: main
Choose a base branch
from

Conversation

maurycy
Copy link

@maurycy maurycy commented Aug 8, 2021

Net::HTTP::Persistent.write_timeout now exposes Net::HTTP.write_timeout since drbrain/net-http-persistent#99

@flavorjones
Copy link
Member

@maurycy Thank you for submitting this! Looks good, but I'd like to make some time to do a deeper dive on the timeouts (the test coverage seems pretty thin for read_timeout and this might be a good opportunity for me to learn a bit more and improve the test coverage).

@maurycy
Copy link
Author

maurycy commented Aug 9, 2021

@flavorjones Thank you as well! That's true. I had to manually byebug.

@maurycy
Copy link
Author

maurycy commented Aug 9, 2021

@flavorjones While we're at it, what do you think about covering ssl_timeout as well? It's well supported by net-http-persistent. I can handle this.

Net::HTTP.keep_alive_timeout is shadowed by Net::HTTP::Persistent.idle_timeout, so not much we can do.

Net::HTTP.continue_timeout is not supported by net-http-persistent.

ncs1 and others added 11 commits November 9, 2021 06:48
…se-psych-safe-load

use safe_load when using Psych >= 3.1
…pdate-ci-to-ruby31

ci: update to cover Ruby 3.1
Note that in this case we treat cookies differently from credentials
per RFC 6265 section 8.5:

https://datatracker.ietf.org/doc/html/rfc6265#section-8.5

> Cookies do not provide isolation by port.  If a cookie is readable
> by a service running on one port, the cookie is also readable by a
> service running on another port of the same server.  If a cookie is
> writable by a service on one port, the cookie is also writable by a
> service running on another port of the same server.  For this
> reason, servers SHOULD NOT both run mutually distrusting services on
> different ports of the same host and use cookies to store security-
> sensitive information.
…edirect-headers

fix: clear credentials when redirecting to a different port
@flavorjones
Copy link
Member

@maurycy Since you emailed me directly let me respond here. Would you be willing to add test coverage to this PR that exercises the write timeout, either using the test server or via a mock? That would help me be confident in supporting it as a feature going forward.

flavorjones and others added 17 commits April 7, 2023 09:08
…rop-force-encoding

fix: stop force_encoding the page body
to quash the node 12 warnings
…pdate-ci-actions

ci: update actions/checkout version
…h-latest-user-agents

Update user agent strings for agent aliases
versions 2.11.0..2.11.4 do not recover from encoding errors. upcoming
release will change the encoding of the resulting doc as a result of
recovery changes in libxml2.

See https://gitlab.gnome.org/GNOME/libxml2/-/issues/543 for more
context.
…sts-for-libxml2-encoding-changes

test: work around libxml2 encoding changes
Related to 762df0c, we're seeing the upstream fixes did not ship in
v2.11.5 so let's change the version test to assume it won't land until
v2.12.0.
…ix-require-order

ci: test_mechanize_page_link requires nokogiri before using it
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.

None yet

5 participants