From 4963eee999aa617163db089b6200bb875e5c03fb Mon Sep 17 00:00:00 2001 From: HemangChothani <50404902+HemangChothani@users.noreply.github.com> Date: Thu, 7 Nov 2019 23:02:42 +0530 Subject: [PATCH] docs(firestore): clarify client threadsafety (#9254) * add doc for thread safety * changes in document as recommended * change in document description. --- docs/index.rst | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/index.rst b/docs/index.rst index d355d8aec..b8157df9b 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,5 +1,12 @@ .. include:: README.rst +.. note:: + + Because the firestore client uses :mod:`grpcio` library, it is safe to + share instances across threads. In multiprocessing scenarios, the best + practice is to create client instances *after* the invocation of + :func:`os.fork` by :class:`multiprocessing.Pool` or + :class:`multiprocessing.Process`. API Reference -------------