jason810496 commented on code in PR #76416:
URL: https://github.com/apache/airflow/pull/76416#discussion_r4465072523


##########
airflow-core/src/airflow/api_fastapi/logging/decorators.py:
##########
@@ -222,14 +226,16 @@ def _resolve_team_name(params: dict, *, dag_id: str | 
None, session: Session) ->
         return None
     for param, (team_column, resource_column) in 
_TEAM_SCOPED_RESOURCES.items():
         if (resource_id := params.get(param)) is not None:
-            return session.scalar(select(team_column).where(resource_column == 
resource_id))
+            return await 
session.scalar(select(team_column).where(resource_column == resource_id))
     return None
 
 
 def action_logging(event: str | None = None):
     async def log_action(
         request: Request,
-        session: SessionDep,
+        # Not the route's sync ``SessionDep``: this dependency runs on the 
event loop, where a sync
+        # pool checkout blocks the requests holding the pooled connections 
from releasing them.
+        session: AsyncSessionDep,

Review Comment:
   > I haven't reproduced it yet, but it seems like the same kind of problem. 
Maybe worth a follow-up?
   
   Yes, they have the same issue but not that critical (the burst radius is not 
that large compare to this one).



-- 
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]

Reply via email to