Add "queue" support
tmaiaroto opened this issue · 1 comments
Much like cron tasks, there can also be a "task master" type facility that leverages SQS and then just a single cron/hook that gets called on a set schedule (configured by up
... maybe every 5 minutes for example or even configure that in the YAML) and handled by the Go app code.
This is a little different than cron. While a scheduled job invokes the Lambda to process the queue in SQS, it still means that a certain number of messages will be read and processed at once. So there may be a few configuration options to consider here. At any rate, it's a queue that can even support retries unlike a cron task. Though it's still very helpful.
Going to implement scheduled tasks and allow a separate package to handle a "queue" or "task master" of the sorts. It will be highly subjective I think and before Aegis gets too opinionated...It's best to leave just a scheduled task facility in place and let the end user decide if there's SQS involved, etc.
It also leaves Aegis a bit more open to potentially running on other clouds in the future. Aegis is opinionated a bit still in that it looks to AWS Lambda + API Gateway, but the local dev mode kinda proves it can run in Docker anywhere...So there's potential to broaden in an elegant way.