Is Using AWS Lambda for Image Processing a Smart Move for My EC2 App?

0
15
Asked By TechyTreasureHunter On

I'm developing a Node.js marketplace application for buying and selling items, and my backend is hosted on EC2. I need to manage tasks like resizing images, adding watermarks, and performing NSFW checks. Since image processing tasks can take some time and users won't mind waiting for their ads to publish, I'm considering using AWS Lambda for offloading just the image processing part. This would be triggered through S3 or SQS, while keeping the rest of my API on EC2. I'd like to know if this is a common and sensible approach, or if it's introducing unnecessary complexity when compared to using EC2 workers. Cost is a major concern for me right now, rather than speed. Additionally, I'd appreciate any advice or alternatives for setting up this kind of system.

5 Answers

Answered By LambdaOptimizer99 On

I suggest breaking each check into its own Lambda function and orchestrating them with a Step Function. That way, you'll have clear insights on cost per function, helping you track anomalies effectively.

Answered By LambdaLover92 On

Image processing is definitely one of the ideal cases for using Lambda! It can scale well with your workload and you’ll find plenty of guides online to help you set everything up.

Answered By BudgetWiseDev On

I think you'll find that using Lambda could end up being more expensive than sticking with small reserved instances or Docker containers on EC2. It’s usually more cost-effective in the long run.

Answered By CloudMaster01 On

Have you considered using Cloudflare Images? It's perfect for all the tasks you mentioned and even has a generous free plan. Running sharp on Lambda might not be the most efficient choice.

Answered By MicroservicesFan44 On

Microservices are the way to go! Just pick whatever works best for you now and be flexible for future changes. I often mix different resources depending on what fits my needs.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.