-
Notifications
You must be signed in to change notification settings - Fork 647
Description
Describe the bug
NodeHttp2Handler pools its Http2Sessions per authority. An Http2Session can be closed for a variety of reasons, including those outside of the control of the client. (See the docs for the goaway event which can be triggered by the server at any time.)
Whenever a session is closed, it is invalid for further use, but NodeHttp2Handler only invalidates its cache for sessions it has closed itself. This is insufficient - if the server triggers node to close the session for any reason, the NodeHttp2Handler is invalid for that authority forever.
SDK version number
@aws-sdk/node-http-handler@1.0.0-gamma.6
Is the issue in the browser/Node.js/ReactNative?
node
Details of the browser/Node.js/ReactNative version
λ node -v
v13.9.0
To Reproduce (observed behavior)
The repro steps and context for this issue are the same as in #1524.
Expected behavior
NodeHttp2Handler should invalidate its cache on the close event for any Http2Session. Compare to another popular client:
https://github.com/hisco/http2-client/blob/12a9e6fa6701a46e92e9b7adf395ce646b2a26b4/lib/request.js#L299-L303