Is the Python client thread safe?

Does anyone know if the Python client is thread safe? Can multiple threads make requests with the client concurrently?

I see the Java client advertises this feature, but the Python client does not, so I’d like to double check.

Thanks for the help!

Okay, these two things convinced me that it is thread safe :upside_down_face:

  1. Example of using threads
  2. The library does call PyEval_InitThreads() and kindly proclaims Makes things "thread-safe"
1 Like

Hi! As far as I know the Python client is. The GIL is grabbed for any sync call and released as soon as possible, in order to be a good citizen in a multithreaded system.

I also know that the Python client is used in production with systems like gevent.

Would be good to get any other input from users of the Python client. If anything is missing, we’ll open a feature request.

1 Like

This topic was automatically closed 84 days after the last reply. New replies are no longer allowed.