ECS Fargate Failed Invocation with EventBridge

0

I have created an ECS Fargate Task, which I can manually run. It updates a Dynomodb and I get logs.

Now I want this to run on a schedule. I have setup a scheduled ECS task through EventBridge and through the UI in the ECS cluster. However, this does not run.

I have used the cron scheduler and I have also tried the 'Run at fixed interval' option, which also doesn't work. As far as possible I am using the same settings when I run the task manually and in EventBridge. I've tried the default capacity provider (and made sure that's set to Fargate in the cluster). I've tried using manually defined permissions and I've tried letting EventBridge make it's own permissions.

I see a 'Failed Invocation' in CloudWatch metrics, for every invocation of the task. But I am unable to find any other logs to debug. The task seems to not start: no logs are generated and the failed invocation happens at the same time as the invocation.

Are there any logs I could share that would help diagnose?

Does anyone have any suggestions for what might be causing this failure?

1 Resposta
1
Resposta aceita

Have a look in cloudtrail for "Error" events with around the time period - The event will contain a more detailed cause.

You may want to wrap this execution in a step function then you can build in more detailed logic/error response etc

AWS
ESPECIALISTA
Peter_G
respondido há 2 anos
  • Thanks - cloudtrail helped a lot!

Você não está conectado. Fazer login para postar uma resposta.

Uma boa resposta responde claramente à pergunta, dá feedback construtivo e incentiva o crescimento profissional de quem perguntou.

Diretrizes para responder a perguntas