You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/03/10 22:58:04 UTC

[GitHub] [airflow] SamWheating opened a new pull request #22171: Don't set adoption timeout for already-started celery tasks.

SamWheating opened a new pull request #22171:
URL: https://github.com/apache/airflow/pull/22171


   Re: https://github.com/apache/airflow/issues/22160
   
   In some exceedingly rare cases, it's possible to have running tasks without a `queued_dttm`. This can cause a scheduler crashloop during task adoption as the executor tries to calculate the adoption timeout. 
   
   https://github.com/apache/airflow/blob/9e6769206e124b65d31028a3b7b9047d51fd0be5/airflow/executors/celery_executor.py#L546
   
   But this can be skipped, as if the task is running then the `adopted_task_timeouts` value is cleared almost immediately after it is set.
   https://github.com/apache/airflow/blob/9e6769206e124b65d31028a3b7b9047d51fd0be5/airflow/executors/celery_executor.py#L549
   https://github.com/apache/airflow/blob/9e6769206e124b65d31028a3b7b9047d51fd0be5/airflow/executors/celery_executor.py#L474-L476
   
   So by not setting the `adoption_task_timeout` for a running task, we can avoid ever accessing the `queued_dttm` and thus avoid the scheduler crash. 


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] SamWheating closed pull request #22171: Don't set adoption timeout for already-started celery tasks

Posted by GitBox <gi...@apache.org>.
SamWheating closed pull request #22171:
URL: https://github.com/apache/airflow/pull/22171


   


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] SamWheating commented on pull request #22171: Don't set adoption timeout for already-started celery tasks

Posted by GitBox <gi...@apache.org>.
SamWheating commented on pull request #22171:
URL: https://github.com/apache/airflow/pull/22171#issuecomment-1067176046


   Closing in favour of https://github.com/apache/airflow/pull/22259


-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org