Vamsi-klu opened a new pull request, #62660: URL: https://github.com/apache/airflow/pull/62660
## Summary - Add `ti_dag_version_id` index on `task_instance.dag_version_id` column - This column is queried by the DAG processor but had no index, causing full table scans on large tables (27M+ rows reported in #61894) - Include Alembic migration `0061_3_0_0_add_dag_version_id_index_to_ti.py` ## Test plan - [ ] Verify Alembic migration applies cleanly: `airflow db migrate` - [ ] Verify Alembic migration downgrades cleanly: `airflow db downgrade` - [ ] Verify index exists after migration: `SELECT * FROM pg_indexes WHERE indexname = 'ti_dag_version_id'` - [ ] Monitor scheduler performance improvement on large deployments Closes: #61894 **Note:** On large `task_instance` tables, the index creation may take several minutes during migration. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- 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]
