Unnecessary dependence between capacity_provider_strategy and volume_configurations #43046
Closed
2 tasks done
Labels
area:providers
good first issue
kind:bug
This is a clearly a bug
provider:amazon
AWS/Amazon - related issues
Apache Airflow Provider(s)
amazon
Versions of Apache Airflow Providers
apache-airflow-providers-amazon==8.29.0
Apache Airflow version
2.9.2
Operating System
Amazon Linux 2023.5.20240805
Deployment
Amazon (AWS) MWAA
Deployment details
Using a Python 3.11 environment with
botocore==1.34.106
andapache-airflow-providers-amazon==8.29.0
.This allows us to use the
volume_configurations
feature so we can deploy DAGs that use theECSRunTaskOperator
with EBS volume attachments configured at launch.What happened
Omitting
capacity_provider_strategy
fromEcsRunTaskOperator
preventsvolume_configurations
from being passed toself.client.run_task(**run_opts)
inEcsRunTaskOperator._start_task()
.So, if you aren't using
capacity_provider_strategy
(in this case we are usinglaunch_type="FARGATE"
) this prevents an EBS volume configuration from being defined which throws the following error during DAG execution:What you think should happen instead
EcsRunTaskOperator.volume_configurations
should be passed toself.client.run_task(**run_opts)
regardless of the value ofcapacity_provider_strategy
.How to reproduce
volume
andmountPoint
definitions for an EBS volume.ECSRunTaskOperator
withvolume_configurations
containing amanagedEBSVolume
defined andcapacity_provider_strategy
undefined.Anything else
EcsRunTaskOperator
(with camelCase keywords) works.Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: