HoneyryderChuck
25c717d29e
added missing change to changelog from 0.8.0
2020-04-23 10:25:08 +01:00
HoneyryderChuck
53710aaf37
bump to 0.8.0
v0.8.0
2020-04-23 01:16:15 +01:00
HoneyryderChuck
7aa622c28e
Merge branch 'issue-90' into 'master'
...
Reducing loop/select calls
See merge request honeyryderchuck/httpx!83
2020-04-22 23:53:13 +00:00
HoneyryderChuck
24f1b1426f
deleting io monitor (not needed)
2020-04-23 00:39:01 +01:00
HoneyryderChuck
ec6e39d7b9
remove connect call from selector, making it implicit when selecting interests
2020-04-23 00:39:01 +01:00
HoneyryderChuck
f977db76ef
connection: perform all io in #consume
...
when condensing all io in the same method, one can now infer whether the
socket can process read/write still, thereby not needlessly sending it
to IO.select. This makes it for more efficient usage of cpu time.
Now we just need to do the same with the connect phase...
2020-04-23 00:39:01 +01:00
HoneyryderChuck
9a66db3ab4
proxy: add inflight bookkeeping for http proxy; close the connection if receiving connect request error
2020-04-18 17:44:32 +01:00
HoneyryderChuck
1b97001b5f
moved check o expect-100 response to the headers callback, as in http2, it doesn't close the stream when waiting for the body (I have no idea how this was working)
2020-04-18 17:43:21 +01:00
HoneyryderChuck
e7181132ab
io read: making sure that the read buffer is flushed when one can't read from the io, as we'll need this information later
2020-04-18 17:42:22 +01:00
HoneyryderChuck
203cdb1b8e
response: fixed usage of unexisting method
2020-04-18 17:41:10 +01:00
HoneyryderChuck
af2524cf6e
abstracted retry request verification to an helper method
2020-04-18 17:40:29 +01:00
HoneyryderChuck
93e30f0abf
connection: connect before select
...
a refactoring was performed on the connection, so they could connect out
of the #to_io call; in order to proper read the interests, it was
thought that it was too late at that point, as interests before #to_io
would be different from post #to_io; this makes our selector less
"portable", as we rely on internal logic being called now
2020-04-18 14:53:04 +01:00
HoneyryderChuck
382139e0a5
wrong timeout class
2020-04-18 01:48:38 +01:00
HoneyryderChuck
11cec68952
Merge branch 'issue-91' into 'master'
...
reset parser only if reinitializing the connection
Closes #91
See merge request honeyryderchuck/httpx!82
2020-04-18 00:45:43 +00:00
HoneyryderChuck
7877b4ee73
reset parser only if reinitializing the connection
2020-04-18 01:37:02 +01:00
HoneyryderChuck
d8a24b2c63
altsvc: clear altsvcs for origin when "clear"
...
implemented missing support for the "clear" value, which states that
alternatives to the origin should be pruned.
Fixes #92
2020-04-17 17:26:48 +01:00
HoneyryderChuck
9dd7f6f7d1
Merge branch 'opts' into 'master'
...
Optimizations
See merge request honeyryderchuck/httpx!81
2020-04-14 08:38:08 +00:00
HoneyryderChuck
ee49b47dab
reenabling select for all rubies; refined waiting for reads and writes simultaneously on one IO
2020-04-13 23:23:00 +01:00
HoneyryderChuck
dc07b50466
moved back to read-write for ssl negotiation, until we have the loop figured out
2020-04-13 22:56:30 +01:00
HoneyryderChuck
5823a040d0
adding more methods necessary for the faraday adapter when it comes to multi-response errors
2020-04-13 18:07:27 +01:00
HoneyryderChuck
cf5be6b899
jruby: gave up and rw on connect, as we're entering an infinite loop too many times after ssl connect and waiting for writes. the problem is identified though, and will be worked on once we work on polling less
2020-04-13 18:07:27 +01:00
HoneyryderChuck
5595a6c79f
remove unused #close method for selector
2020-04-13 15:23:20 +01:00
HoneyryderChuck
4997548d95
do not use the select_one variant for ruby 2.1, as there is a deadlock on ssl connect that is triggered in a test
2020-04-13 15:23:20 +01:00
HoneyryderChuck
ed23525daf
selector: use poll when possible, instead of IO.select
...
Using IO.select is costly for the one-request/one-origin case, as we
have to build array to pass, and we receive arrays, and that generates a
lot of needless garbage when we only request once. Instead, it now uses
IO#wait_readable and IO#wait_writable, which does not require extra
arrays, and uses poll under the hood.
2020-04-12 03:32:04 +01:00
HoneyryderChuck
2c5757b1a5
implementing #body for error response, as faraday passes it down in parallel mode
2020-04-12 03:32:04 +01:00
HoneyryderChuck
4af6c14fdc
typo
2020-04-12 03:32:04 +01:00
HoneyryderChuck
de773f6885
removing needless pipes on selector (wakeup sockets are necessary only for the server case)
2020-04-12 03:32:04 +01:00
HoneyryderChuck
78ce18027c
passing interests call to the underlying io object, which makes it more accurate for the ssl case
2020-04-12 03:32:04 +01:00
HoneyryderChuck
83b9c645d1
honor operation timeout in connection
...
there was an inconsistency when dealing with timeouts, where the lower
one would trigger a timeout error in otehr connections. we have to
bookkeep per connection how much we spent before triggering.
2020-04-12 03:32:04 +01:00
HoneyryderChuck
fdb2545588
unnecessarily attribute variable
2020-04-12 03:32:04 +01:00
HoneyryderChuck
1e66528925
emit error for http1 parser errors as well
2020-04-12 03:32:04 +01:00
HoneyryderChuck
990e550a6e
making sure that keep alive timeout isn't triggered unnecessarily, such as when it was cancelled already, and triggeres a double-reset that stalls the process
2020-04-12 03:32:04 +01:00
HoneyryderChuck
5258f8230b
fixed error being assigned nil
2020-04-12 03:32:04 +01:00
HoneyryderChuck
97a727b286
added profiler helpers; also, gave a polish to the rubocop file
2020-04-12 03:32:04 +01:00
HoneyryderChuck
f6475009fe
now that the timer interval is used in the selector, make sure that timeouts from selecting are properly reflected as total timeouts when they are
2020-04-12 03:32:04 +01:00
HoneyryderChuck
9d6f31d940
calculate interests down to connection and parser
...
by analyzing all of the data down to the parser, one can estimate better
whether io wants to read/write/both, thereby avoiding spurious wakeups.
This also greatly simplifies the monitor API, and solves the 100% CPU
utilization issue.
2020-04-12 03:32:04 +01:00
HoneyryderChuck
0136200b85
allow parser to close connection by passing a special flag
...
this works for http/1, where one can close the socket immediately.
2020-04-12 03:32:04 +01:00
HoneyryderChuck
79d71dcc92
re-set the http2 max streams on settings negotiation.
...
there was a bug where the max streams in the connection would trigger a
stream limit exceeded, however the check done was based on active
streams that max requests variable from the httpx connection. This is
wrong when peer negotiates more concurrent streams, but is checking the
stream limit against the wrong value received from httpx.
2020-04-12 03:32:04 +01:00
HoneyryderChuck
fef2d78382
show what happened if not the timeout
2020-04-05 04:26:43 +01:00
HoneyryderChuck
a733e7da6d
removing option from plugin from mainline (not even used anymore)
2020-04-05 04:26:43 +01:00
HoneyryderChuck
f5eef2877e
improving #inspect
2020-04-05 04:26:43 +01:00
HoneyryderChuck
9e349dc81d
resolver options: fixing API
2020-04-05 04:26:43 +01:00
HoneyryderChuck
de3decdf9c
fixing double emission of close even from the resolver
2020-04-05 04:26:43 +01:00
HoneyryderChuck
d92a137655
registry: only const_get the first time
2020-04-05 04:26:43 +01:00
HoneyryderChuck
d2a3c51834
parser#consume: skip fully buffered requests
2020-04-05 04:26:43 +01:00
HoneyryderChuck
1aef976b57
replaced define_method with class_eval in options
2020-04-05 04:26:43 +01:00
HoneyryderChuck
138bfd79ac
options: convert to Headers on setter; def_option -> only use instance_exec when absolutely necessary
2020-03-31 13:00:24 +01:00
HoneyryderChuck
a78f7afac6
removed label parameter from logs, in order to avoid needless string allocations by default
2020-03-31 09:42:52 +01:00
HoneyryderChuck
90a4c9a980
Merge branch 'keep-alive-timeout' into 'master'
...
Keep alive timeout
See merge request honeyryderchuck/httpx!80
2020-03-31 00:20:25 +00:00
HoneyryderChuck
801895a96a
Merge branch 'test-latest-issues' into 'master'
...
Test latest issues
See merge request honeyryderchuck/httpx!79
2020-03-31 00:19:49 +00:00