Flask Multi-thread (app threaded)

Options
saulleon
saulleon Registered Posts: 22 ✭✭✭✭

Hi!

Is there any way to enable multi-thread in a python flask app?

app.run(host=HOST, port=PORT, threaded=True)

This code is controlled by Dataiku, and it is injected to webapp editor.

How can I change it?

Best Answer

  • Clément_Stenac
    Clément_Stenac Dataiker, Dataiku DSS Core Designer, Registered Posts: 753 Dataiker
    Answer ✓
    Options

    Hi,

    Please go to the "Settings" tab of the webapp, and set the "number of processes" to 0 to enable threading.

    This feature was added in DSS 7, so you will need at least this version.

Answers

  • saulleon
    saulleon Registered Posts: 22 ✭✭✭✭
    Options

    Awesome! Thank you Clement!

  • rmoore
    rmoore Partner, Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Core Concepts, Neuron, Dataiku DSS Adv Designer, Registered, Neuron 2022, Frontrunner 2022 Finalist, Frontrunner 2022 Participant, Neuron 2023 Posts: 33 Neuron
    Options

    Hi @Clément_Stenac
    - how do we modify the "number of processes" in a custom webapp plugin? The backend parameters are not available by default.

Setup Info
    Tags
      Help me…