AgeCommit message (Collapse)Author
2020-05-23Remove jQuery, cleanup Websocket example a bit2.8.0Loïc Hoguin
2020-05-21Cowboy 2.8.0Loïc Hoguin
2020-05-20204 and 304 responses must not include a bodyLoïc Hoguin
When calling cowboy_req:reply/4 with a body a crash will occur resulting in a 500 response. When calling cowboy_req:stream_reply/2,3 and then attempting to send a body a crash will occur.
2020-05-20Increase the default max_keepalive HTTP option to 1000Loïc Hoguin
100 is very low for current deployments. 1000 is more appropriate as a default value.
2020-05-20Don't stop listeners that don't exist in static_handler_SUITELoïc Hoguin
2020-05-20Clarify the routing algorithmLoïc Hoguin
2020-04-08Increase the timetrap timeout in req_SUITE on WindowsLoïc Hoguin
Still seeing intermittent failures on Windows due to timetrap so let's see if doubling the timeout again helps.
2020-04-08Get rid of timeouts in metrics_SUITELoïc Hoguin
Again to avoid intermittent issues.
2020-04-08Document the HTTP/2 linger_timeout optionLoïc Hoguin
2020-04-08Clarify that protocol opts may be defined by stream handlersLoïc Hoguin
2020-04-07Allow {error, enotconn} as test success in security_SUITELoïc Hoguin
This happens from time to time on Windows and is partially due to how the test is written.
2020-04-06Rely on timetrap timeouts for tracer_SUITELoïc Hoguin
2020-04-06NO_PARALLEL=1 will disable (most) parallel testingLoïc Hoguin
This is to make up for very slow or low resource environments, like the FreeBSD CI environment currently.
2020-04-06Experiment with a linger_timeout for HTTP/2Loïc Hoguin
This is mostly to ensure that the GOAWAY frame is properly received on Windows in some tests, but should be benefitial also in production in particular when clients are slower.
2020-04-06Increase the req_SUITE timetrap timeout on WindowsLoïc Hoguin
The local network is much slower so the tests take longer there.
2020-04-05Reduce the pipeline test body sizes to avoid filling send buffersLoïc Hoguin
This causes the test to get stuck because both the client and server end up waiting in Transport:send for the other side to read data from the socket.
2020-04-04Fix active mode and flow control during pipeliningLoïc Hoguin
We could get stuck in passive mode under certain conditions (fast and non-busy machine and perhaps other environment factors).
2020-04-02Disable ws_SUITE:unlimited_connections on WindowsLoïc Hoguin
2020-04-02Skip ws_SUITE:unlimited_connections when ulimit -n is too lowLoïc Hoguin
2020-04-02Make req_SUITE:read*_body_urlencoded_too_long tests reliableLoïc Hoguin
2020-04-02Update rebar.configLoïc Hoguin
2020-04-02Use infinity timeout for gun:await* calls in req_SUITELoïc Hoguin
2020-04-02Rework the req_SUITE:read_body_period testLoïc Hoguin
To avoid intermittent test failures. We only want to make sure the function eventually returns so we don't need to use timeouts in the test itself, or check exactly what was read.
2020-04-01Change a few flaky tests to use timetrap and infinity timeoutsLoïc Hoguin
The experiment was successful in Gun, let's see if it helps with Cowboy as well.
2020-04-01Update Cowlib to 2.9.1Loïc Hoguin
Fixes HPACK edge cases (error conditions).
2020-04-01Fix h2spec "invalid preface sequence" testLoïc Hoguin
Introduce a currently undocumented option to allow disabling cowboy_http when using a clear listener.
2020-03-30Fix the req_SUITE:parse_cookie testLoïc Hoguin
We now allow spaces in cookie names.
2020-03-30Add more headers to cowboy_req:parse_header/2,3Loïc Hoguin
2020-03-30Update Cowlib to 2.9.0Loïc Hoguin
2020-03-29Update Erlang.mkLoïc Hoguin
2020-03-29Add more router testsLoïc Hoguin
2020-03-29Increase the default max_received_frame_rateLoïc Hoguin
Allow 10000 frames every 10 seconds instead of just 1000, as the limit was too quickly reached in some deployments.
2020-03-29Add more specificationsLoïc Hoguin
2020-03-29Cowboy itself doesn't use proper; Cowlib doesLoïc Hoguin
2020-02-08Add Trace Context to the list of specsLoïc Hoguin
2020-02-08Clarify modifying/adding to the Req objectLoïc Hoguin
2020-02-07Fix HTTP/1.1 bug when a flow command is returned after finLoïc Hoguin
This resulted in a badarith error due to the current flow being set to infinity when the body has been fully read. A test case has been added reproducing the issue.
2020-02-05Add a test confirming push requests have no bodyLoïc Hoguin
2020-01-17Fix bugs related to HTTP/1.1 pipeliningLoïc Hoguin
The flow control is now only set to infinity when we are skipping the request body of the stream that is being terminated. This fixes a bug where it was set to infinity while reading a subsequent request's body, leading to a crash. The timeout is no longer reset on stream termination. Timeout handling is already done when receiving data from the socket and doing a reset on stream termination was leading to the wrong timeout being set or the right timeout being reset needlessly.
2020-01-06Fix cowboy_req:parse_header manual for unknown headersLoïc Hoguin
2020-01-06Add a skeleton performance chapter to the guideLoïc Hoguin
2020-01-06Use active,NLoïc Hoguin
This reduces the number of times we need to ask for more packets, and as a result we get a fairly large boost in performance, especially with HTTP/1.1. Unfortunately this makes Cowboy require at least Erlang/OTP 21.3+ because the ssl application did not have active,N. For simplicity the version required will be Erlang/OTP 22+. In addition this change improves hibernate handling in cowboy_websocket. Hibernate will now work for HTTP/2 transport as well, and stray or unrelated messages will no longer cancel hibernate (the process will handle the message and go back into hibernation). Thanks go to Stressgrid for benchmarking an early version of this commit: https://stressgrid.com/blog/cowboy_performance_part_2/
2020-01-02Reduce number of Transport:send/2 calls for HTTP/2Loïc Hoguin
When sending a complete response it is far more efficient to send the headers and the body in one Transport:send/2 call instead of two or more, at least for small responses. This is the HTTP/2 counterpart to what was done for HTTP/1.1 many years ago in bfab8d4b22d858e7cffa97d04210a62fae56681c. In HTTP/2's case however the implementation is a little more difficult due to flow control. On the other hand the optimization will apply not only for headers/body but also for the body of multiple separate responses, which may need to be sent all at the same time when we receive a WINDOW_UPDATE frame. When a body is sent using sendfile however a separate call is still made.
2019-12-31No longer use erlang:get_stacktrace/0Loïc Hoguin
It has been deprecated in OTP and the new way is available on all supported OTP versions.
2019-12-31Ignore malformed accept-encoding headers in cowboy_compress_hMarcos Ferreira
2019-12-31Add sponsor link to the READMELoïc Hoguin
2019-12-31Add a commented option in the MakefileLoïc Hoguin
2019-12-31Test trailers bug when there are data frames in queueTony Han
2019-12-31Add new RFCs to the listLoïc Hoguin
2019-10-10Use /long_polling for rfc7540 tests that reset the stream2.7.0Loïc Hoguin