Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

eventstream: adds middleware to close input-writer in case of error #3867

Merged
merged 10 commits into from Apr 27, 2021

Conversation

skotambkar
Copy link
Contributor

@skotambkar skotambkar commented Apr 18, 2021

Changes

  • Adds an unmarshal error middleware that will close the eventstream's inputwriter (io.writeCloser) in case server returns an error for the initial request handshake (before streaming payload).
  • Updates code generation template - so this change affects lexruntimev2 and transcribestreamingservice.
  • Added a handwritten test in transcribestreaming service pkg to test inputwriter is closed. (Uses mock http transport)
  • Minor fix for validate response handler error to include previous errors
  • Remove stale code

Copy link
Contributor

@jasdel jasdel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, only minor comments

service/transcribestreamingservice/unit_test.go Outdated Show resolved Hide resolved
service/transcribestreamingservice/unit_test.go Outdated Show resolved Hide resolved
@skotambkar skotambkar merged commit d265de1 into aws:main Apr 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants