Running aiohttp web apps on Kubernetes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
Henning Jacobs 4c11649afa use pytest-kind 10 months ago
tests/e2e use pytest-kind 10 months ago
.flake8 Dockerfile 11 months ago
.gitignore Dockerfile 11 months ago
Dockerfile app code 11 months ago
Makefile use pytest-kind 10 months ago
README.md test different approaches 10 months ago
poetry.lock use pytest-kind 10 months ago
pyproject.toml use pytest-kind 10 months ago
web.py add sleep to request handler 10 months ago

README.md

aiohttp on Kubernetes

This repository shows how to configure aiohttp on Kubernetes to allow rolling updates without failing requests.

There are a number of approaches which do not work:

  • default web.run_app will handle SIGTERM and leads to failing requests during rolling pod updates
  • using aiohttp’s on_shutdown signal to sleep 20 seconds will not work as aiohttp will already close the server before trigering on_shutdown