GoogleCloudPlatform / GoogleCloudPlatform/functions-framework-python

The framework default Gunicorn configs do not make sense for Gen2 environments

Đang mở
#241 7 bình luận 1 reaction 0 người được giao Xem trên GitHub
enhancement P3
Ngôn ngữ chính
Python
Star
968
Fork
128
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Hey, so we're extensively using the framework to create our GCF and Cloud Run services and it is very easy to use which is great.

But, when it comes to fine-tuning your performance things go rogue. E.g. we have a need for ~5 GB RAM in Cloud Run for some services, so effectively are 2 vCPUs already while the hard-coded gunicorn configs force only a single worker https://github.com/GoogleCloudPlatform/functions-framework-python/blob/586cc4e0833e2e9c82e685c8118be8c3187bd990/src/functions_framework/_http/gunicorn.py#L20-L27

And this is gonna be the same issue with GCF gen2 where you can use bigger instances in terms of memory but they also come with more vCPU for which you are paying but not using.

I suggest we either keep the default and let people configure/adjust Gunicorn params or implement a smart solution for picking appropriate defaults (at least based on the number of vCPU available).

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.