From a1c532eacfeddcbefaa3e565a0522e25315286c4 Mon Sep 17 00:00:00 2001 From: subkanthi Date: Mon, 22 Nov 2021 13:36:39 -0500 Subject: [PATCH 1/5] [16185] Added LocalKubernetesExecutor to breeze supported executors --- BREEZE.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/BREEZE.rst b/BREEZE.rst index a62a9734cd3c1..b6a14240ffd33 100644 --- a/BREEZE.rst +++ b/BREEZE.rst @@ -2422,6 +2422,7 @@ This is the current syntax for `./breeze <./breeze>`_: One of: KubernetesExecutor CeleryExecutor LocalExecutor CeleryKubernetesExecutor + LocalKubernetesExecutor Default: KubernetesExecutor From d16a343c1478eb068e01d7ef363d91bb704918f8 Mon Sep 17 00:00:00 2001 From: subkanthi Date: Mon, 22 Nov 2021 13:38:51 -0500 Subject: [PATCH 2/5] Revert "[16185] Added LocalKubernetesExecutor to breeze supported executors" This reverts commit a1c532eacfeddcbefaa3e565a0522e25315286c4. --- BREEZE.rst | 1 - 1 file changed, 1 deletion(-) diff --git a/BREEZE.rst b/BREEZE.rst index b6a14240ffd33..a62a9734cd3c1 100644 --- a/BREEZE.rst +++ b/BREEZE.rst @@ -2422,7 +2422,6 @@ This is the current syntax for `./breeze <./breeze>`_: One of: KubernetesExecutor CeleryExecutor LocalExecutor CeleryKubernetesExecutor - LocalKubernetesExecutor Default: KubernetesExecutor From aabf41a22e297fc6637f27c2906451eb90348ab7 Mon Sep 17 00:00:00 2001 From: Kanthi Subramanian Date: Sun, 26 Dec 2021 11:21:56 -0500 Subject: [PATCH 3/5] [20496] Removed hardcoded port 8080 and use the webserver port from conf --- airflow/cli/commands/standalone_command.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/airflow/cli/commands/standalone_command.py b/airflow/cli/commands/standalone_command.py index 37d38cb5d0204..92bbe47cf0ee2 100644 --- a/airflow/cli/commands/standalone_command.py +++ b/airflow/cli/commands/standalone_command.py @@ -81,6 +81,8 @@ def run(self): command=["triggerer"], env=env, ) + + self.web_server_port = int(conf.get('webserver', 'WEB_SERVER_PORT', fallback='8080')) # Run subcommand threads for command in self.subcommands.values(): command.start() @@ -206,7 +208,7 @@ def is_ready(self): Detects when all Airflow components are ready to serve. For now, it's simply time-based. """ - return self.port_open(8080) and self.job_running(SchedulerJob) and self.job_running(TriggererJob) + return self.port_open(self.web_server_port) and self.job_running(SchedulerJob) and self.job_running(TriggererJob) def port_open(self, port): """ From 38f6b75eae7593e697379830efd2598ab740ba61 Mon Sep 17 00:00:00 2001 From: Kanthi Subramanian Date: Sun, 26 Dec 2021 13:24:54 -0500 Subject: [PATCH 4/5] Fix flake8 errors --- airflow/cli/commands/standalone_command.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/airflow/cli/commands/standalone_command.py b/airflow/cli/commands/standalone_command.py index 92bbe47cf0ee2..d26e8e32afdfb 100644 --- a/airflow/cli/commands/standalone_command.py +++ b/airflow/cli/commands/standalone_command.py @@ -208,7 +208,11 @@ def is_ready(self): Detects when all Airflow components are ready to serve. For now, it's simply time-based. """ - return self.port_open(self.web_server_port) and self.job_running(SchedulerJob) and self.job_running(TriggererJob) + return ( + self.port_open(self.web_server_port) + and self.job_running(SchedulerJob) + and self.job_running(TriggererJob) + ) def port_open(self, port): """ From 7b2ade7bf4b4e8110e367fe67bdff0923dbdbee9 Mon Sep 17 00:00:00 2001 From: Kanthi Subramanian Date: Mon, 27 Dec 2021 16:26:12 -0500 Subject: [PATCH 5/5] Changed get WEB_SERVER_PORT --- airflow/cli/commands/standalone_command.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/airflow/cli/commands/standalone_command.py b/airflow/cli/commands/standalone_command.py index d26e8e32afdfb..82a082e853f6b 100644 --- a/airflow/cli/commands/standalone_command.py +++ b/airflow/cli/commands/standalone_command.py @@ -82,7 +82,7 @@ def run(self): env=env, ) - self.web_server_port = int(conf.get('webserver', 'WEB_SERVER_PORT', fallback='8080')) + self.web_server_port = conf.getint('webserver', 'WEB_SERVER_PORT', fallback=8080) # Run subcommand threads for command in self.subcommands.values(): command.start()