-
Notifications
You must be signed in to change notification settings - Fork 647
Closed
Labels
feature-requestNew feature or enhancement. May require GitHub community feedback.New feature or enhancement. May require GitHub community feedback.
Description
Is your feature request related to a problem? Please describe.
When http2stream throws error with http2stream.rstCode other than NGHTTP2_NO_ERROR (0), the error thrown contains undefined. This was seen while discovering another bug with parallel streaming in https://github.com/jjtindale/aws-parallel-transcribe-repro
Error: AWS SDK error wrapper for undefined
at asSdkError (/Users/joe/Development/amazon-transcribe-error/node_modules/@aws-sdk/middleware-retry/src/StandardRetryStrategy.ts:124:10)
at StandardRetryStrategy.retry (/Users/joe/Development/amazon-transcribe-error/node_modules/@aws-sdk/middleware-retry/src/StandardRetryStrategy.ts:94:21)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at /Users/joe/Development/amazon-transcribe-error/node_modules/@aws-sdk/middleware-sdk-transcribe-streaming/src/middleware-session-id.ts:32:22
at /Users/joe/Development/amazon-transcribe-error/node_modules/@aws-sdk/middleware-logger/src/loggerMiddleware.ts:22:22 {
'$metadata': { attempts: 1, totalRetryDelay: 0 }
}Code:
aws-sdk-js-v3/packages/node-http-handler/src/node-http2-handler.ts
Lines 109 to 111 in a51c2f4
| // The HTTP/2 error code used when closing the stream can be retrieved using the | |
| // http2stream.rstCode property. If the code is any value other than NGHTTP2_NO_ERROR (0), | |
| // an 'error' event will have also been emitted. |
Describe the solution you'd like
Throw error on request close event in NodeHttp2Handler if it's value other than NGHTTP2_NO_ERROR (0).
Describe alternatives you've considered
Writing my own custom implementation of NodeHttp2Handler which throws an error
Additional context
Follow-up to #2550
Metadata
Metadata
Assignees
Labels
feature-requestNew feature or enhancement. May require GitHub community feedback.New feature or enhancement. May require GitHub community feedback.