Open epau opened 1 year ago
The aws-swift-sdk uses Apple's URLSession
for ios platforms and CRTEngline for linux platform. Hence the supported protocol versions (and their priorities) are dictated by these clients, and not by Smithy protocol traits.
For URLSession
, it supports HTTP/1.1, HTTP/2, and HTTP/3 protocols.
For CRTEngine
, it supports HTTP/1.1 and HTTP/2 only.
The only thing we can add/include is to validate at least one of the protocols specified in the Smithy protocol trait is also supported by the above http clients.
Clients are negotiating HTTP version with the server directly, and should throw an appropriate error when an agreement can't be made.
Describe the feature
AWS protocols define properties (
http
andeventStreamHttp
) that contain the priority ordered list of supported HTTP protocol versions, The SDK must configure the http client of the service to use the values defined by the service's protocol.Consult with smithy folks to understand if/how this should be exposed via SRA. Currently a http client just defines a single function
send(request: HTTPRequest)
. How does configuring the ALPN list and other low-level connection settings fit into this? (such as configuring ALPN and minimum TLS version etc)For example, below are the rules for the AWS restJson1 protocol:
Use Case
N/A
Proposed Solution
No response
Other Information
No response
Acknowledgements