Skip to content

Feature request: add _resolve_async() and _call_route_async() for async resolver support #8136

@leandrodamascena

Description

@leandrodamascena

Use case

With AsyncMiddlewareFrame (PR 2) and _registered_api_adapter_async (PR 3) in place, we need to wire them into the actual resolve chain. This adds the async versions of _resolve() and _call_route() as private methods - the full async pipeline without exposing it to customers yet.

Solution/User Experience

  • Add _resolve_async() - async version of _resolve(). Same route matching logic (sync, CPU-bound), but calls _call_route_async() instead of _call_route()
  • Add _call_route_async() - builds async middleware chain using AsyncMiddlewareFrame with _registered_api_adapter_async as the final frame, then awaits the chain
  • Add _build_middleware_stack_async() on Route - mirrors _build_middleware_stack() but returns an async chain
  • Integration tests with async handlers going through the full chain
  • Methods are private - not exposed to customers yet

Alternative solutions

Acknowledgment

Metadata

Metadata

Projects

Status

Triage

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions