Open XBeg9 opened 4 months ago
Here is some logs from k8s celery worker:
The delivery info for this task is:
{'exchange': '', 'routing_key': 'dagster'}
Traceback (most recent call last):
File "/usr/local/lib/python3.10/site-packages/celery/worker/consumer/consumer.py", line 659, in on_task_received
strategy = strategies[type_]
KeyError: 'execute_plan'
[2024-05-22 17:14:14,422: ERROR/MainProcess] Received unregistered task of type 'execute_plan'.
The message has been ignored and discarded.```
Looks like the problem is here: https://github.com/dagster-io/dagster/blob/d307f1a5818bc25fb00fbff81d0a75669a4ab5c1/python_modules/libraries/dagster-celery/dagster_celery/executor.py#L128 while celery_k8s_job_executor
is using different routing_key https://github.com/dagster-io/dagster/blob/master/python_modules/libraries/dagster-celery-k8s/dagster_celery_k8s/executor.py#L233 .... solution, make custom CeleryK8sRunLauncher launcher?....
ok, the fix is here: https://github.com/dagster-io/dagster/blob/master/helm/dagster/templates/deployment-celery-queues.yaml#L64
change dagster_celery_k8s.app
to dagster_celery.app
This should be synchronized and we need to give the ability to change executor on the helm side.
If you're looking to use CeleryK8sRunLauncher
for Celery with Kubernetes
Then you'll want to use
from dagster_celery_k8s import celery_k8s_job_executor
Instead of
from dagster_celery import celery_executor
If you're looking to use
CeleryK8sRunLauncher
for Celery with KubernetesThen you'll want to use
from dagster_celery_k8s import celery_k8s_job_executor
Instead of
from dagster_celery import celery_executor
As I listed before, the problem is inside helm chart
Dagster version
1.7.6
What's the issue?
Using
CeleryK8sRunLauncher
as run launcher andcelery_executor
, I am getting this error on k8s cluster:What did you expect to happen?
Launching the job it should trigger the job run (kubernetes job) and that job is going to spin up celery tasks for each op. Tasks are going to be processed by celery-worker pods.
How to reproduce?
Deployment type
Dagster Helm chart
Deployment details
No response
Additional information
Message from the maintainers
Impacted by this issue? Give it a 👍! We factor engagement into prioritization.