11 Commits

Author SHA1 Message Date
HoneyryderChuck
b5775d73c8 adding TCP#addresses?, which drops on-the-fly expired entries, and therefore makes possible to DNS query for persistent connections 2025-09-02 10:58:06 +01:00
HoneyryderChuck
cfce76bd8b adding Resolver::Entry, using it everywhere internally
this acts as a delegator to ipaddr, and should be a drop-in replacement everywhere the ipaddress was used, with the extra information about expiration
2025-09-02 10:58:06 +01:00
HoneyryderChuck
0f3e3ab068 remove trailing :: from IO module usage, as there's no more internal module 2025-08-07 12:30:21 +01:00
HoneyryderChuck
b0016525e3 recover from network unreachable errors when using cached IPs
while this type of error is avoided when doing HEv2, the IPs remain
in the cache; this means that, one the same host is reached, the
IPs are loaded onto the same socket, and if the issue is IPv6
connectivity, it'll break outside of the HEv2 flow.

this error is now protected inside the connect block, so that other
IPs in the list can be tried after; the IP is then evicted from the
cachee.

HEv2 related regression test is disabled in CI, as it's currently
reliable in Gitlab CI, which allows to resolve the IPv6 address,
but does not allow connecting to it
2025-07-14 15:44:47 +01:00
HoneyryderChuck
12483fa7c8 missing ivar sigs in tcp class 2025-05-16 11:15:28 +01:00
HoneyryderChuck
8b2ee0b466 remove form, json, ,xml and body from the Options class
Options become a bunch of session and connection level parameters, and requests do not need to maintain a separate Options object when they contain a body anymore, instead, objects is shared with the session, while request-only parameters get passed downwards to the request and its body. This reduces allocations of Options, currently the heaviest object to manage.
2024-06-11 18:23:45 +01:00
HoneyryderChuck
587271ff77 improving sigs 2024-06-11 18:21:22 +01:00
HoneyryderChuck
9465a077b1 Add Response#peer_address and ErrorResponse#peer_address
responses can now expose the IP address used to connect to the peer
server to fetch the response from.
2023-10-30 09:52:30 +00:00
HoneyryderChuck
487a747544 allow reuse of previously closed connections within the scope of a session
when closed, connections are now placed in a place called eden_connections; whenever a connection is matched for, after checking the live connections and finding none, a match is looked in eden connections; the match is accepted **if** the IP is considered fresh (the input is validated in the cache, or input was an ip or in /etc/hosts, or it's an external socket) and, if a TLS connection, the stored TLS session did not expire; if these conditions do not match, the connection is dropped from the eden and a new connection will started instead; this will therefore allow reusing ruby objects, reusing TLS sessions, and still respect the DNs cache
2023-09-06 22:09:56 +01:00
HoneyryderChuck
cfac38dc62 added more typing, improved correctness of a few checks 2023-04-28 23:57:25 +01:00
HoneyryderChuck
d699526ec2 updated signatures of IO objects 2023-04-25 22:46:54 +01:00