问题
While developing an infra on aws having certain questions and issues I am facing with it. I want to parallelism distributed tasks handling for API.
Scenario- I have an app that is related to banking where every minute millions of requests generate for scheduling reports. Report are of several types. Like say Account report, Transaction report, and so on. which can be further schedule daily, weekly, monthly or custom. It should be send using email and report attach to email.
Now what I require is I want build an API to handle such request and schedule the reports. Once it scheduled I want to make sure it execute the N
number of whenever it is scheduled.(parallel)
[The reason I want Parallel execution of all the reports which is scheduled at same time is because lets say if user(s) schedule report(s) at 11:00 UTC it should receive the report at the same time. I don't want user(s) end up receiving reports after 1hr or 2hr or N
number of hours. No matter how much reports are scheduled, Ever time it should execute the report at given time stamp. That's why I am looking for some solution of handling such case of parallel distributed tasks handling.]
I tried - I am not sure what AWS services would be more reliable for such kind of situation. I built API using API Gateway with SQS > Lambda which create event on cloudwatch and execute it with lambda trigger to send SES(email).
(But this approach leave me at certain issues if delaying the report delivery where N
number of users scheduled report at the same time.)
Can anyone help me here with forming some very efficient solution that can handle such cases seamlessly without any delay.
Much Thanks!
来源:https://stackoverflow.com/questions/62356552/achieve-the-parallelism-for-these-distributed-tasks-handling-with-aws