pruyai opened a new issue, #61705:
URL: https://github.com/apache/airflow/issues/61705

   ### Apache Airflow version
   
   Other Airflow 3 version (please specify below)
   
   ### If "Other Airflow 3 version" selected, which one?
   
   3.1.2
   
   ### What happened?
   
   Hello people , I am facing an issue in my airflow code. I am working with 
celery executer and airflow version 3.1.2. It seems like when multiple tasks 
are rendering fields in parallel, the insert conflicts and raises the error 
below. I have once observed this happening when single task tries to execute as 
well but usually seen with parallel executions.
   
   AirflowRuntimeError: API_SERVER_ERROR: {'status_code': 409, 'message': 
'Server returned error', 'detail': {'detail': {'reason': 'Unique constraint 
violation', 'statement': 'INSERT INTO rendered_task_instance_fields (dag_id, 
task_id, run_id, map_index, rendered_fields, k8s_pod_yaml) VALUES (%(dag_id)s, 
%(task_id)s, %(run_id)s, %(map_index)s, %(rendered_fields)s, 
%(k8s_pod_yaml)s)', 'orig_error': 'duplicate key value violates unique 
constraint "rendered_task_instance_fields_pkey"
   
   This issue seems to be intermittent and happens with multiple tasks, 
sometimes even 3 attempts for task resolution results into the same error 
causing entire dag failure.
   
   Is this a known issue and would be resolved sooner in next couple of 
releases? Could you please guide if there is any way to fix this up. Any 
suggestions would be highly appreciated.
   
   ### What you think should happen instead?
   
   _No response_
   
   ### How to reproduce
   
   While multiple parallel insertions working together in airflow, It fails 
with the unique constraint violation error. Airflow is unable to assign unique 
ids to every task at runtime
   
   ### Operating System
   
   It is deployed to cloud and runs as per schedule
   
   ### Versions of Apache Airflow Providers
   
   _No response_
   
   ### Deployment
   
   Official Apache Airflow Helm Chart
   
   ### Deployment details
   
   _No response_
   
   ### Anything else?
   
   Do we have any information of getting this airflow bug resolved
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to