Scaling Problem - API Gateway and Lambda Payload limits

0

Our GraphQL service is going to get large requests now > 20MB. Currently getting <6MB requests. Our architecture is : 1. Client --> AWS API Gateway --> AWS Lambda. API Gateway has 10 MB payload limit, and Lambda has 6MB payload limit.

We are open to make changes in getting requests, changes in architecture as well. What solution we have for such problem ? What AWS recommends for such issues ?

Looking for solutions other than S3 uploads.

[Edit] : Exploring solutions other than S3 to make sure to evaluate all possible approaches to solve this problem. S3 is definitely one of the solution but exploring is there better solution available ? Example - 1>> Avoiding API Gateway and change the architecture itself 2>> Compression solutions 3>> Any streaming solutions etc.

1 Answer
0

Hello.

I would store it once in S3 to avoid API Gateway and Lambda payload limitations.
You can avoid the problem by storing it in S3 and then processing it with Lambda.
I think that a temporary workaround for this problem is to save large messages somewhere and then process them from Lambda.

Looking for solutions other than S3 uploads.

Why are you looking for a solution other than S3?
Are there any rules that prevent me from using S3?

profile picture
EXPERT
answered 2 months ago
  • I want to make sure to evaluate all possible approaches to solve this problem. S3 is definitely one of the solution but exploring is there better solution available ? Example - 1>> Avoiding API Gateway and change the architecture itself 2>> Compression solutions 3>> Any streaming solutions etc.

  • The AWS blog below is in Japanese, but it introduces a solution for uploading large files to S3 once. This method may be better if you use API Gateway and Lambda. https://aws.amazon.com/jp/blogs/news/large-size-files-transferring-by-serverless-s3presignedurl-and-clientside-javascript/

  • I think it is possible to exceed the payload limit if you use ALB, EC2, ECS, etc. instead of API Gateway. However, if you are using ALB and EC2 or ECS, it will be executed on demand, so the cost may be higher than API Gateway or Lambda.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions