From fa97d1a575f39a6d292f4417e9b02d33fbc7f8e3 Mon Sep 17 00:00:00 2001 From: gibKim Date: Fri, 27 Nov 2026 18:04:25 +0900 Subject: [PATCH] docs(events): clarify ownership of Lambda URL response streams --- events/lambda_function_urls.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/events/lambda_function_urls.go b/events/lambda_function_urls.go index 1d5ac6ff..a44c382c 100644 --- a/events/lambda_function_urls.go +++ b/events/lambda_function_urls.go @@ -71,6 +71,10 @@ type LambdaFunctionURLResponse struct { // LambdaFunctionURLStreamingResponse models the response to a Lambda Function URL when InvokeMode is RESPONSE_STREAM. // If the InvokeMode of the Function URL is BUFFERED (default), use LambdaFunctionURLResponse instead. // +// When the handler returns this response without an error, leave Body open. +// The Lambda runtime reads Body while sending the response and closes it +// afterward if it implements [io.ReadCloser]. +// // Note: This response type requires compiling with `-tags lambda.norpc`, or choosing the `provided` or `provided.al2` runtime. type LambdaFunctionURLStreamingResponse struct { prelude *bytes.Buffer