Yasti4 opened a new issue, #48001:
URL: https://github.com/apache/airflow/issues/48001

   ### Apache Airflow Provider(s)
   
   amazon
   
   ### Versions of Apache Airflow Providers
   
   apache-airflow-providers-amazon==9.2.0
   
   ### Apache Airflow version
   
   2.10.5
   
   ### Operating System
   
   docker image apache/airflow:2.10.5
   
   ### Deployment
   
   Other Docker-based deployment
   
   ### Deployment details
   
   _No response_
   
   ### What happened
   
   Sometimes when using fargate spot AWS fails to start a task due to lack of 
available resources (see aws reponse below).  Airflow is not retrying to launch 
the task when that is the case.
   ```
   "responseElements": {
       "failures": [
           {
               "reason": "Capacity is unavailable at this time. Please try 
again later or in a different availability zone"
           }
       ],
       "tasks": []
   }
   ```
   
   ### What you think should happen instead
   
   I would expect Airflow to retry automatically, as lack of capcity is usually 
a temporal issue and just a few seconds delay may be enough to be able to start 
the task. It is already doing it for several other erros as seen in 
[https://github.com/apache/airflow/blob/b93c3db6b1641b0840bd15ac7d05bc58ff2cccbf/airflow/providers/amazon/aws/hooks/ecs.py#L31](https://github.com/apache/airflow/blob/b93c3db6b1641b0840bd15ac7d05bc58ff2cccbf/airflow/providers/amazon/aws/hooks/ecs.py#L31)
   
   ### How to reproduce
   
   It depends on the load of the specific availability zones, so it is not 
possible to do with a 100% accuracy, but we are seeing it on a daily basis on 
our scheduled tasks in **eu-west-1**.
   
   ### Anything else
   
   We are more than happy to make or test a fix, but it is our first time 
looking under the hood of airflow, so a bit of guidance will be needed
   
   ### Are you willing to submit PR?
   
   - [x] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to