configure gunicorn worker class for python2.7 google app engine Flex

519 views
Skip to first unread message

Hilal Diab

unread,
Dec 10, 2017, 11:05:38 AM12/10/17
to Google App Engine

I'm trying to configure my GAE and let it use a non-sync gunicorn worker which is the default.

I created a gunicorn.conf.py 

import multiprocessing
workers = multiprocessing.cpu_count() * 2 + 1
threads = 3
worker_class = 'eventlet'

and my app.yaml is: 

runtime: python
threadsafe: true
env: flex
entrypoint: gunicorn -b :$PORT main:app  -c config/gunicorn.conf.py

runtime_config:
  python_version: 2

requirements: 

enum-compat==0.0.2
enum34==1.1.6
eventlet
greenlet
gevent
gunicorn==19.7.1
webob==1.7.2
Flask==0.12.1

When setting the worker class to eventlet or gthread and deploy the code to the server (gcloud app deploy) 

at the very end of the deploy I get the following error:

raise RuntimeError('no suitable implementation for this system')

How can I properly change the worker class?

Jordan (Cloud Platform Support)

unread,
Dec 11, 2017, 4:55:42 PM12/11/17
to Google App Engine
As long as you are following the documentations for the recommended app.yaml entrypoint, your actual gunicorn.conf.py configuration is not Google-end and is a third-party project. As per the Gunicorn documentation, "The asynchronous workers available are based on Greenlets (via Eventlet and Gevent)". Looking at the Eventlet Git repository this exact issue has been discussed

- Note that Google Groups is for general product discussions and not for technical support. Therefore it is recommended to consult the existing issues on Eventlet for this and to comment on their Issue Tracker if you need further assistance. 
Reply all
Reply to author
Forward
0 new messages