AWS Airflow, how to write airflow DAGs efficiently? Billing included along also.

Using AWS MWAA workers we are billed by an hour.

Is my understanding correct in this use case?

Run AWS Batch Job and wait for the job to complete then proceed to next task from DAG.
In this case our task will somehow need to wait for the Batch to complete (using boto3 waiters or simple polling code)

Does this mean that we will have one worker running as long as the Batch task is running?

Potentially our Batch job lasts 24 hours, if we have 100s of Batch jobs like theese means that we will pay for a LOT of “idle” worker hours. Correct?

The “Environment Instance Pricing” includes one persistent worker by default. If you’re using that worker for the duration of your task, then you won’t accrue any additional cost. If you need an additional worker, then it will be active for the duration of the Sensor polling to see if the task has completed.

Does this looks pricey to you?

Also most probably my understanding of mwaa is not complete. I am also for that option = )

My organization has used an Airflow environment on ECS for quite some time that would fall under their medium sized bucket. We found that MWAA would be more expensive by a decent amount (though possibly cheaper than retaining a DevOps expert on Airflow).

As you mentioned, MWAA doesn’t feel like it’s feature complete yet. My organization basically has it in a “review in 12 months” state.