kaxil commented on code in PR #55443: URL: https://github.com/apache/airflow/pull/55443#discussion_r2334936042
########## airflow-core/src/airflow/utils/serve_logs/core.py: ########## @@ -53,12 +53,16 @@ def serve_logs(port=None): logger.info("Starting log server on %s", serve_log_uri) - # Use uvicorn directly for ASGI applications - uvicorn.run("airflow.utils.serve_logs.log_server:app", host=host, port=port, workers=2, log_level="info") - # Note: if we want to use more than 1 workers, we **can't** use the instance of FastAPI directly - # This is way we split the instantiation of log server to a separate module - # - # https://github.com/encode/uvicorn/blob/374bb6764e8d7f34abab0746857db5e3d68ecfdd/docs/deployment/index.md?plain=1#L50-L63 + # Use uvicorn with factory pattern for lazy app creation + # This ensures proper initialization order: settings.initialize() → configure_logging() → create_app() Review Comment: You are right, fixed it -- 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: commits-unsubscr...@airflow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org