aws / aws/aws-lambda-base-images

Support response streaming for Node.js image

Open
#200 1 comment 2 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
777
Forks
118
PR merge metrics
No merged PRs in 30d

Description

Hello,

I'm trying to debug a Node.js function that streams a response locally, but it seems the image doesn't support it.

The image I'm using is `public.ecr.aws/lambda/nodejs:20`.

This invocation doesn't work (response is "404 page not found"):
```bash
curl -v -XPOST "http://localhost:9000/2021-11-15/functions/function/response-streaming-invocations" -d '{}'
```

This invocation works:
```bash
curl -v -XPOST "http://localhost:9000/2015-03-31/functions/function/invocations" -d '{}'
```

Full cURL output:

```
* Trying 127.0.0.1:9000...
* Connected to localhost (127.0.0.1) port 9000 (#0)
> POST /2021-11-15/functions/function/response-streaming-invocations HTTP/1.1
> Host: localhost:9000
> User-Agent: curl/7.81.0
> Accept: */*
> Content-Length: 2
> Content-Type: application/x-www-form-urlencoded
>
* Mark bundle as not supporting multiuse
< HTTP/1.1 404 Not Found
< Content-Type: text/plain; charset=utf-8
< X-Content-Type-Options: nosniff
< Date: Thu, 03 Oct 2024 07:55:29 GMT
< Content-Length: 19
<
404 page not found
* Connection #0 to host localhost left intact
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.