mirror of
https://github.com/frappe/gunicorn.git
synced 2026-07-03 03:01:31 +08:00
Add support for streaming responses when dirty app actions return generators (sync or async). This enables real-time delivery of incremental results for use cases like LLM token generation. Features: - Streaming protocol with chunk/end/error message types - Worker support for sync and async generators - Arbiter forwarding of streaming messages - Deadline-based timeout handling - Async client streaming API Protocol: - Chunk messages (type: "chunk") contain partial data - End messages (type: "end") signal stream completion - Error messages can occur mid-stream New files: - benchmarks/dirty_streaming.py: Streaming benchmark suite - tests/dirty/test_*_streaming*.py: Streaming test coverage - docs/content/dirty.md: Streaming documentation with examples
Generate Documentation
======================
Requirements
------------
Install the documentation dependencies with::
pip install -r requirements_dev.txt
This provides MkDocs with the Material theme and supporting plugins.
Build static HTML
-----------------
::
mkdocs build
The rendered site is emitted into the ``site/`` directory.
Preview locally
---------------
::
mkdocs serve
This serves the documentation at http://127.0.0.1:8000/ with live reload.