serverless-java-container
serverless-java-container copied to clipboard
Handle AwsProxyRequest with single-valued collections only
This PR improves handling of some web requests, particularly ALB requests to Lambda endpoints.
https://github.com/awslabs/aws-serverless-java-container/issues/315
This change adds a custom Jackson Converter to populate AwsProxyRequest multi-valued collections (i.e., multiValueQueryStringParameters, multiValueHeaders) from single-valued collections (i.e., queryStringParameters, headers) if the former are not present and populated but the latter are. This is based off a real-life scenario where an ALB targets a Lambda function and lambda.multi_value_headers.enabled is not set to true on the target group.
By submitting this pull request
- [x] I confirm that my contribution is made under the terms of the Apache 2.0 license.
- [x] I confirm that I've made a best effort attempt to update all relevant documentation.
Until we finish the discussion for the fallback logic, I just added the missing properties for the next release and resolved the conflict in your branch accordingly.