Open dyingsunlight opened 9 months ago
Thanks for raising this issue. At the moment, sam local
commands do not support response streaming and this is a known feature gap.
In the meantime, I recommend trying to test your application with sam sync
which will test in the cloud instead of using local emulation.
The issue still didn't fix? I face exactly the same problem sam sync
is not an option for me.
I'm not able to use sam sync
either is there any update on this issue ?
Description:
AWS Lambda now supports streaming responses, but it appears that the AWS SAM CLI does not. When I try to develop my application locally, it doesn't work at all.
Steps to reproduce:
Create a SAM project with the following
template.json
:Create
index.mjs
with the following content:Run the following commands:
Observed result:
After the AWS SAM CLI is ready, visiting
http://127.0.0.1:8090/hello-world
yields:Console outputs:
The lambda invocation just throws the error and does nothing.
Expected result:
If I upload the code to AWS Cloud, everything works well. I would like the AWS SAM CLI to have consistent behavior between development and production environments.