0

This is a system architecture design question, so I'm not sure if it fits here. Excuse me if it doesn't and feel free to suggest the appropriate community.

I have an ExpressJs server and a Python script that runs a CPU intensive task, typically it can take from 30 minutes to 2 hours. I want to allow users to make requests to run that task. After the user makes their request, they should get back a response saying the task is successfully requested and they have to wait for a specific amount of time before making the next request.

My question is, how should I go about invoking that Python script and what do I need to consider, e.g. request timeout, child processes, etc.? What would be considered "best practice" in this situation?

Apologise in advance if this question sounds vague. If you need any more information please comment down below.

Mike Pham
  • 437
  • 6
  • 17
  • Is the script / ExpressJs server currently accessible to users who need to run it? – Adrian K Sep 06 '21 at 03:31
  • @AdrianK I'm not sure what you mean by "accessible". Could you please elaborate? – Mike Pham Sep 06 '21 at 04:38
  • Can the users who need to run the script already browse to the ExpressJs server, or do you need to set-up networking, DMZ, etc? Like, how much of the infrastructure is already in-place, and if it's not, is that part of the question? – Adrian K Sep 06 '21 at 22:25

0 Answers0