Skip to main content

15 docs tagged with "async"

View all tags

Advanced Event Loop

Master event loop internals including selectors, callbacks, timers, custom policies, uvloop, run_in_executor, and signal handling for production async systems.

Async Context Managers

Master async resource management with __aenter__/__aexit__, asynccontextmanager, AsyncExitStack, and production patterns for connection pools and sessions.

Async Generators and Async Iterators

Build streaming data pipelines with async for, async yield, __aiter__/__anext__, async comprehensions, and finalization protocols for production async iteration.

Async LLM Calls

Asynchronous LLM call patterns for high-throughput applications - concurrency control with semaphores, producer-consumer queues, token bucket rate limiting, circuit breakers, and async orchestration patterns.

Async Performance Patterns

asyncio internals, event loop tuning, connection pooling, backpressure, and high-throughput async patterns for production Python services.

Async Synchronization Patterns

Implement bounded concurrency, rate limiting, and circuit breakers with asyncio locks, semaphores, events, conditions, and barriers.

Asyncio and Async/Await

Master Python's async/await model - coroutines, tasks, gather, event loop, async context managers, and building high-performance I/O-bound applications.

Calling LLM APIs

Production patterns for calling LLM APIs - authentication, retry logic, rate limiting, error handling, async calls, and the Anthropic and OpenAI Python SDKs.

Custom Awaitables

Build awaitable objects with the __await__ protocol, understand how coroutines and Futures work under the hood, and create custom async primitives.

FastAPI in Depth

Dependency injection, lifespan events, background tasks, middleware, custom exception handlers, OpenAPI customisation, and production FastAPI patterns.

Production Async Architecture

Build production-grade async systems with error handling strategies, graceful shutdown, health checks, backpressure, async testing with pytest-asyncio, and structured logging.

Structured Concurrency with TaskGroup

Master asyncio.TaskGroup for safe concurrent execution, understand why gather() leaks tasks, handle ExceptionGroups, and implement the nursery pattern.