Skip to content

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

Open
@xSAVIKx

Description

@xSAVIKx

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

self.options = {
"bind": "%s:%s" % (host, port),
"workers": 1,
"threads": 1024,
"timeout": 0,
"loglevel": "error",
"limit_request_line": 0,
}

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).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions