Python

Flask Installation

Guided Install

When you launch Judoscale for the first time, you'll be prompted to install an adapter library:

Screenshot: Judoscale adapter installation instructions

When you select Flask from this list, you'll see the instructions shown below. You can follow the instructions within the app, or you can follow along here.

Manual Install

Flask Web Process

Installing Judoscale for a Flask app requires only a couple of steps. First, we'll add the package dependency to our requirements.txt then run our standard pip install.

judoscale-python >= 1.0.0rc1

Finally we'll import the Judoscale middleware and wrap our app with it:

# app.py
from judoscale.flask.middleware import RequestQueueTimeMiddleware

app = Flask("MyFlaskApp")
app.wsgi_app = RequestQueueTimeMiddleware(app.wsgi_app)

Check out the judoscale-python README for additional configuration options.

Advanced Python Adapter Configuration

Need a more customized install?

Previous
Django Installation