Skip to content
Discussion options

You must be logged in to vote

Calling one GET / makes two run_in_threadpool() calls:

  1. Calling endpoint (e.g. ping() in your example)
  2. Calling validator (here)

Explaining your first example:

  1. GET / -> run_in_threadpool(ping) -> sleep(5)
  2. GET / -> run_in_threadpool(ping) (waiting)
  3. GET / -> run_in_threadpool(ping) (waiting)
  4. (1) finish -> run_in_threadpool(field_validate) (waiting)
  5. (2) start -> sleep(5) -> finish -> run_in_threadpool(field_validate) (waiting)
  6. (3) start -> sleep(5) -> finish -> run_in_threadpool(field_validate) (waiting)
  7. (4) start -> finish -> send response
  8. (5) start -> finish -> send response
  9. (6) start -> finish -> send response

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Pitirus
Comment options

@YuriiMotov
Comment options

@methane
Comment options

Answer selected by andresbannuraschultz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question or problem
4 participants