Skip to content

Commit

Permalink
feat(cli): add "core.task_runner" and "core.enable_xcom_pickling" to…
Browse files Browse the repository at this point in the history
… unsupported config check to command "airflow config lint" (apache#45214)

* style(cli): add comments comments as deliminator

* feat(cli): add removed "core.task_runner" and "core.enable_xcom_pickling" check to command "airflow config lint"
  • Loading branch information
Lee-W authored and HariGS-DB committed Jan 16, 2025
1 parent 3bbb25c commit a6f7b21
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions airflow/cli/commands/remote_commands/config_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ def message(self) -> str:


CONFIGS_CHANGES = [
# admin
ConfigChange(
config=ConfigParameter("admin", "hide_sensitive_variable_fields"),
renamed_to=ConfigParameter("core", "hide_sensitive_var_conn_fields"),
Expand All @@ -118,6 +119,7 @@ def message(self) -> str:
config=ConfigParameter("admin", "sensitive_variable_fields"),
renamed_to=ConfigParameter("core", "sensitive_var_conn_names"),
),
# core
ConfigChange(
config=ConfigParameter("core", "check_slas"),
suggestion="The SLA feature is removed in Airflow 3.0, to be replaced with Airflow Alerts in "
Expand Down Expand Up @@ -188,6 +190,9 @@ def message(self) -> str:
config=ConfigParameter("core", "max_db_retries"),
renamed_to=ConfigParameter("database", "max_db_retries"),
),
ConfigChange(config=ConfigParameter("core", "task_runner")),
ConfigChange(config=ConfigParameter("core", "enable_xcom_pickling")),
# api
ConfigChange(
config=ConfigParameter("api", "access_control_allow_origin"),
renamed_to=ConfigParameter("api", "access_control_allow_origins"),
Expand All @@ -196,11 +201,13 @@ def message(self) -> str:
config=ConfigParameter("api", "auth_backend"),
renamed_to=ConfigParameter("api", "auth_backends"),
),
# logging
ConfigChange(
config=ConfigParameter("logging", "enable_task_context_logger"),
suggestion="Remove TaskContextLogger: Replaced by the Log table for better handling of task log "
"messages outside the execution context.",
),
# metrics
ConfigChange(
config=ConfigParameter("metrics", "metrics_use_pattern_match"),
),
Expand All @@ -218,12 +225,15 @@ def message(self) -> str:
config=ConfigParameter("metrics", "statsd_block_list"),
renamed_to=ConfigParameter("metrics", "metrics_block_list"),
),
# traces
ConfigChange(
config=ConfigParameter("traces", "otel_task_log_event"),
),
# operators
ConfigChange(
config=ConfigParameter("operators", "allow_illegal_arguments"),
),
# webserver
ConfigChange(
config=ConfigParameter("webserver", "allow_raw_html_descriptions"),
),
Expand All @@ -247,10 +257,12 @@ def message(self) -> str:
config=ConfigParameter("webserver", "force_log_out_after"),
renamed_to=ConfigParameter("webserver", "session_lifetime_minutes"),
),
# policy
ConfigChange(
config=ConfigParameter("policy", "airflow_local_settings"),
renamed_to=ConfigParameter("policy", "task_policy"),
),
# scheduler
ConfigChange(
config=ConfigParameter("scheduler", "dependency_detector"),
),
Expand Down Expand Up @@ -305,6 +317,7 @@ def message(self) -> str:
config=ConfigParameter("scheduler", "statsd_custom_client_path"),
renamed_to=ConfigParameter("metrics", "statsd_custom_client_path"),
),
# celery
ConfigChange(
config=ConfigParameter("celery", "stalled_task_timeout"),
renamed_to=ConfigParameter("scheduler", "task_queued_timeout"),
Expand All @@ -317,6 +330,7 @@ def message(self) -> str:
config=ConfigParameter("celery", "task_adoption_timeout"),
renamed_to=ConfigParameter("scheduler", "task_queued_timeout"),
),
# kubernetes_executor
ConfigChange(
config=ConfigParameter("kubernetes_executor", "worker_pods_pending_timeout"),
renamed_to=ConfigParameter("scheduler", "task_queued_timeout"),
Expand All @@ -325,6 +339,7 @@ def message(self) -> str:
config=ConfigParameter("kubernetes_executor", "worker_pods_pending_timeout_check_interval"),
renamed_to=ConfigParameter("scheduler", "task_queued_timeout_check_interval"),
),
# smtp
ConfigChange(
config=ConfigParameter("smtp", "smtp_user"),
suggestion="Please use the SMTP connection (`smtp_default`).",
Expand Down

0 comments on commit a6f7b21

Please sign in to comment.