Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected Python Timeout Behaviour #3696

Open
danielgreff opened this issue May 29, 2024 · 0 comments
Open

Unexpected Python Timeout Behaviour #3696

danielgreff opened this issue May 29, 2024 · 0 comments

Comments

@danielgreff
Copy link

Hi, I am trying to understand how exactly the timeouts are handled in python based azure functions. We are running the following scenario:

  • running "func start" on a virtual machine with process count == 8 and thread count == 12 and a timeout of 10 minutes
  • running a queue based function running with python 3.8
  • messages are processed concurrently and using a shared threadlock for thread unsafe objects (all locks are used in a with context)

The issue that we are seeing is that if one thread of a process runs into a timeout that thread is killed, as expected, but all other threads of that process stay open and running until their respective timeout is also reached. They do not finish processing their messages and seem to be deadlocked or sleeping.

My question is the following, what is actually going on here? Why does the azure function worker not kill the process directly and end all threads? Why does the thread that is killed not release the lock properly?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant