MWAA celery.worker_autoscale setup

0

Currently I am running my MWAA on small instance with:

celery.worker_autoscale = 5,5

And sometimes my tasks get SIGKILL, I assume it's because tasks are taking too many memory.

In this article : https://docs.aws.amazon.com/mwaa/latest/userguide/best-practices-tuning.html#best-practices-tuning-tasks-params

I see recommendation: mw1.small - 5,0

How does this setup works in real life scenario? My understanding is that worker is limited to run 5 tasks, once there is queued tasks autoscaling adds additional worker, which also can run 5 tasks.

But then what's the difference between 5,0 and 5,5 ?

質問済み 4ヶ月前517ビュー
1回答
0
承認された回答

Hello, The celery.worker_autoscale property takes value in the order max_concurrency,min_concurrency, and determines how many concurrent tasks can run within a worker. As such, a value of 5,5 (default for MWAA small class) means a worker will always keep 5 processes at both minimum and maximum. Whereas, a value of 5,0 means a worker will start with 0 process, but can grow up to 5 process if necessary. In other words, for more resource intensive tasks, having 5,0 can potentially allow more resource to a task when there aren't many concurrent tasks. These values need to be tuned based on the chosen worker size (small, medium or large) and nature of the task.

Ref: https://airflow.apache.org/docs/apache-airflow-providers-celery/stable/configurations-ref.html#worker-autoscale

I hope this helps.

AWS
回答済み 3ヶ月前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ