diff options
author | Feng Li <fengli@google.com> | 2018-03-23 10:05:53 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-03-23 10:05:53 -0700 |
commit | 90af9346de2e4e6f0d45b130ce0de3d08d075c3f (patch) | |
tree | 043f601d33a41aa8712f8fb1b03511e5f86d03ab | |
parent | e9bd89c8d365b9eda547b81acc41cea973d60574 (diff) | |
parent | 7b2f5775d851e5feb49db9bf2e5412f78aebb5b9 (diff) |
Merge pull request #14801 from fengli79/master
Release the GIL when calling grpc_call_start_batch.
-rw-r--r-- | src/python/grpcio/grpc/_cython/_cygrpc/call.pyx.pxi | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/call.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/call.pyx.pxi index 0892215b6d..2e02111ddd 100644 --- a/src/python/grpcio/grpc/_cython/_cygrpc/call.pyx.pxi +++ b/src/python/grpcio/grpc/_cython/_cygrpc/call.pyx.pxi @@ -30,9 +30,12 @@ cdef class Call: tag, operations, self if retain_self else None) batch_operation_tag.prepare() cpython.Py_INCREF(batch_operation_tag) - return grpc_call_start_batch( + cdef grpc_call_error error + with nogil: + error = grpc_call_start_batch( self.c_call, batch_operation_tag.c_ops, batch_operation_tag.c_nops, <cpython.PyObject *>batch_operation_tag, NULL) + return error def start_client_batch(self, operations, tag): # We don't reference this call in the operations tag because |