Repository navigation
feat(runtime): support streaming with HTTP status code and headers - #19
Merged
Merged
Conversation
Define the awslambda global (streamifyResponse, HttpResponseStream.from) like the Node.js managed runtime, so asResponseStreamHandler works on Function URLs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Defines the
awslambdaglobal (streamifyResponse,HttpResponseStream.from) like the Node.js managed runtime. Streamified handlers get(event, responseStream, context)and the response POST carriesContent-Type: application/vnd.awslambda.http-integration-responsewhen a prelude is used.asResponseStreamHandlerfrom@beesolve/lambda-fetch-apinow works on Function URLs withRESPONSE_STREAM.Returned
ReadableStream/ async iterables behave as before. A throw before the first write goes to the error endpoint. A throw after streaming started aborts the request (Bun's fetch has no trailers).Verified in shared-dev: sample-app integration suite (10 tests) with a Function URL on the CMR, on the layer, and behind CloudFront with OAC. The same handler on nodejs24.x returned the same status, headers and body. Adds docs/how-to/streaming.md.
Release afterwards via workflow_dispatch with version 1.4.5 and patch 1 (4.10405.1).