You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@airflow.apache.org by "Merkel, Andreas" <An...@blue-yonder.com> on 2016/07/21 07:56:41 UTC

Airflow webserver default worker model

Hi,

the default worker model for Airflow's webserver is "sync", which according to the Gunicorn documentation is suitable only for being run behind a proxy like Nginx (http://docs.gunicorn.org/en/stable/faq.html#why-is-there-no-http-keep-alive). I've noticed that when using Airflow in connection with Google Chrome, the TCP preconnecting feature (Chrome eagerly opens up TCP connections to the webserver, https://www.igvita.com/2012/06/04/chrome-networking-dns-prefetch-and-tcp-preconnect/) can sometimes lead to all four sync workers becoming blocked on TCP connections Chrome opens up just in case it may need them in the future. The webserver becomes irresponsive for other clients then, until Chrome closes the connections (which seems to happen after ten seconds).

Would it make sense to make one of the asynchronous models the default, or to document that in order to get the webserver production ready, an asynchronous model or a proxy has to be used?

cheers,
Andreas