Skip to content

Feature request: Default ALBResolver Response body to empty string instead of None #4671

Closed
@TonySherman

Description

@TonySherman

Use case

There are times when I only need to return a 200 response without a body. Currently, if I return the Response class without a body while using the ALBResolver, the load balancer will return a 502, even when the lambda successfully returns a response.

Solution/User Experience

When returning Response(status_code=200) the body would default to an empty string rather than None.

I did take a look at the ALB docs and it does state:

The response from your Lambda function must include the Base64 encoding status, status code, and headers. You can omit the body.

So maybe there is another issue causing the 502 that I was seeing.

Alternative solutions

No response

Acknowledgment

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature-requestfeature requesttriagePending triage from maintainers

    Type

    No type

    Projects

    Status

    Shipped

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions