11 Commits
Author SHA1 Message Date
Johannes WeissandJohannes Weiss 8c90405f0c use NIOSingletons EventLoops/NIOThreadPool instead of spawning new (#697)
Co-authored-by: Johannes Weiss <johannes@jweiss.io>
2023-08-14 14:59:33 +01:00
David Nadoba 9195d3bcb4 Speedup tests (#639)
* Enable fast failure mode for testing

* Split-up HTTPClientTests into multiple subclasses

* Move test subclasses into separate files
2022-10-11 16:40:26 +01:00
Cory BenfieldandDavid Nadoba df87a860fd Limit max recursion depth delivering body parts (#611)
Motivation

When receiving certain patterns of response body parts, we can end up
recursing almost indefinitely to deliver them to the application. This
can lead to crashes, so we might politely describe it as "sub-optimal".

Modifications

Keep track of our stack depth and avoid creating too many stack frames.
Added some unit tests.

Result

We no longer explode when handling bodies with lots of tiny parts.

Co-authored-by: David Nadoba <d_nadoba@apple.com>
2022-08-05 17:53:21 +01:00
Fabian FettandGeorge Barnett 5844a6b4ee Crash fix: HTTP2 can handle requests are cancelled (#555)
Co-authored-by: George Barnett <gbarnett@apple.com>
2022-02-10 10:42:27 +01:00
Fabian Fett 70826d038d Add h2 stream integration tests (#502) 2021-12-01 09:27:59 +01:00
David Nadoba 9eaecbbbce SwiftFormat --ifdef no-indent (#494)
* SwiftFormat --ifdef no-indent

* update `generate_linux_tests.rb` to use new indention rule
2021-11-25 17:09:19 +01:00
David Nadoba 68f283c06d bind to loopback only (#476) 2021-11-12 10:08:53 +01:00
David Nadoba 164169a872 [HTTP2] Read Timeout Integration Test (#474) 2021-11-11 15:24:33 +01:00
David Nadoba 3e44e5154e [HTTP2] Make HTTPVersion public and set to .automatic by default (#473) 2021-11-11 14:41:11 +01:00
David Nadoba 38bbe25582 [HTTP2] More Integration Tests (#471) 2021-11-11 11:53:33 +01:00
David Nadoba cc8e7a68a2 basic http2 integration tests (#467) 2021-11-10 10:47:04 +01:00