uplsh580 opened a new pull request, #60645: URL: https://github.com/apache/airflow/pull/60645
# Overview Related Issue: https://github.com/apache/airflow/issues/60630 Improve `dag_bundle_config_list` Configuration in Airflow Helm Chart This PR improves the `dag_bundle_config_list` configuration in the Airflow Helm Chart by allowing users to define DAG bundle configurations in a structured YAML format instead of requiring a JSON string directly in the values file. # Changes - Added a new `dag_bundles` section in `values.yaml` that allows users to define DAG bundles in a structured YAML format - Created a Helm template helper function `dag_bundles` that automatically converts the YAML structure to the required JSON string format - Set default value for `dag_bundles` with a local DAG bundle configuration - Updated `config.dag_processor.dag_bundle_config_list` to use the helper function # Benefits 1. **Better Readability**: Long JSON strings in YAML files are difficult to read and maintain. The new structured format is much more readable. 2. **Less Error-Prone**: Manual JSON string construction is prone to syntax errors. The YAML format reduces the chance of errors. 3. **Better IDE Support**: IDEs can provide proper syntax highlighting, validation, and autocomplete for YAML structures. 4. **Easier Maintenance**: Adding, removing, or modifying bundle configurations is now straightforward. # Usage Users can now define DAG bundles like this: ```yaml dag_bundles: - name: dags-folder classpath: "airflow.dag_processing.bundles.local.LocalDagBundle" kwargs: {} - name: bundle1 classpath: "airflow.providers.git.bundles.git.GitDagBundle" kwargs: git_conn_id: "GITHUB__repo1" subdir: "dags" tracking_ref: "main" refresh_interval: 60 - name: bundle2 classpath: "airflow.providers.git.bundles.git.GitDagBundle" kwargs: git_conn_id: "GITHUB__repo2" subdir: "dags" tracking_ref: "develop" refresh_interval: 120 ``` --- ##### Was generative AI tooling used to co-author this PR? <!-- If generative AI tooling has been used in the process of authoring this PR, please change below checkbox to `[X]` followed by the name of the tool, uncomment the "Generated-by". --> - [X] Yes (Cursor) <!-- Generated-by: [Tool Name] following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions) --> --- * Read the **[Pull Request Guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#pull-request-guidelines)** for more information. Note: commit author/co-author name and email in commits become permanently public when merged. * For fundamental code changes, an Airflow Improvement Proposal ([AIP](https://cwiki.apache.org/confluence/display/AIRFLOW/Airflow+Improvement+Proposals)) is needed. * When adding dependency, check compliance with the [ASF 3rd Party License Policy](https://www.apache.org/legal/resolved.html#category-x). * For significant user-facing changes create newsfragment: `{pr_number}.significant.rst` or `{issue_number}.significant.rst`, in [airflow-core/newsfragments](https://github.com/apache/airflow/tree/main/airflow-core/newsfragments). -- 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]
