Bird
0
0

What does the -w option specify when running Gunicorn with a Flask app?

easy📝 Conceptual Q1 of 15
Flask - Deployment
What does the -w option specify when running Gunicorn with a Flask app?
AThe number of worker processes to handle requests
BThe port number to bind the server
CThe path to the Flask application file
DThe debug mode for Flask
Step-by-Step Solution
Solution:
  1. Step 1: Understand Gunicorn options

    The -w flag in Gunicorn specifies how many worker processes will be spawned to handle incoming requests concurrently.
  2. Step 2: Differentiate from other options

    The port is set with -b, the app file is given as an argument, and debug mode is a Flask setting, not Gunicorn's.
  3. Final Answer:

    The number of worker processes to handle requests -> Option A
  4. Quick Check:

    Gunicorn -w = worker count [OK]
Quick Trick: Use -w to set workers, not port or debug [OK]
Common Mistakes:
MISTAKES
  • Confusing -w with port binding option
  • Thinking -w sets debug mode
  • Assuming -w specifies app file

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Flask Quizzes