We have built a react and python-flask plugin that can be used as a web application in various projects.
However, given that multiple users would use the plugin at same time, we are facing lag in data processing as API requests are full-filled in a sequential manner.
While majority of our APIs are very quick, 1 API takes a little longer for data processing.
So now when two users are accessing the webapp at the same time and the first user hits the data processing API and the second user hits any of the quicker API's, now the second user has to wait till the data processing API is finished for his API response to be served, thus leading to bad UI standards.
We would like to know what is the best way to solve the concurrency issues for a plugin's backend on DSS
For regular (non-plugin) webapps, you can ask DSS to use multiple processes for serving concurrent queries. This capability is however not yet available for plugin webapps. We'll add your feature request to our backlog for adding this.
Thanks for the update
We were also thinking of manually implementing Multithreading or Multiprocessing in the back-end and would like to understand if there are any limitations involved for a plugin webapp on DSS for this type of implementation