From 410e9d292ed696eba331d68ce675b7dc1e34868f Mon Sep 17 00:00:00 2001 From: Giselle van Dongen Date: Mon, 9 Sep 2024 20:23:56 +0200 Subject: [PATCH] Fix Python serving tour (#192) --- tutorials/tour-of-restate-python/README.md | 2 +- tutorials/tour-of-restate-python/hypercorn-config.toml | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 tutorials/tour-of-restate-python/hypercorn-config.toml diff --git a/tutorials/tour-of-restate-python/README.md b/tutorials/tour-of-restate-python/README.md index 61d49220..49d33378 100644 --- a/tutorials/tour-of-restate-python/README.md +++ b/tutorials/tour-of-restate-python/README.md @@ -27,7 +27,7 @@ pip install -r requirements.txt Start the app as follows: ```shell -python3 -m hypercorn -b localhost:9080 tour/app/app:app +python -m hypercorn --config hypercorn-config.toml tour/app/app:app ``` Start the Restate Server ([other options here](https://docs.restate.dev/develop/local_dev)): diff --git a/tutorials/tour-of-restate-python/hypercorn-config.toml b/tutorials/tour-of-restate-python/hypercorn-config.toml new file mode 100644 index 00000000..39dd5b7e --- /dev/null +++ b/tutorials/tour-of-restate-python/hypercorn-config.toml @@ -0,0 +1,5 @@ +bind = "0.0.0.0:9080" +h2_max_concurrent_streams = 2147483647 +keep_alive_max_requests = 2147483647 +keep_alive_timeout = 2147483647 +workers = 8