You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "ziglerari (via GitHub)" <gi...@apache.org> on 2024/07/28 09:22:07 UTC
[I] [C++][grpc] 0-length buffers sent to grpc can cause indefinite hangs on MacOS/iOS [arrow]
ziglerari opened a new issue, #43447:
URL: https://github.com/apache/arrow/issues/43447
### Describe the bug, including details regarding any error messages, version, and platform.
A [gRPC issue](https://github.com/grpc/grpc/pull/37255) has been identified where transmitting buffers of zero length leads to a persistent hang on MacOS/iOS platforms.
Such zero-length buffers may arise, for example, in the context of using the Array structure alongside a validity bitmap, as outlined in the [Arrow Spec](https://arrow.apache.org/docs/format/Columnar.html#validity-bitmaps).
Essentially, when every element within an Array is valid (i.e., not null), it's possible to represent this state with a null validity bitmap, indicating that all elements are valid. This scenario is realized through the use of a null buffer, as demonstrated here:
https://github.com/apache/arrow/blob/187197c369058f7d1377c1b161c469a9e4542caf/cpp/src/arrow/ipc/writer.cc#L165-L179
The relevant sections of code from both transport mechanisms are provided below for reference:
https://github.com/apache/arrow/blob/187197c369058f7d1377c1b161c469a9e4542caf/cpp/src/arrow/flight/transport/grpc/serialization_internal.cc#L283-L287
https://github.com/apache/arrow/blob/187197c369058f7d1377c1b161c469a9e4542caf/cpp/src/arrow/flight/transport/ucx/ucx_internal.cc#L590-L591
Upon examining the UCX transport's approach, it's evident that a precaution is taken to avoid sending zero-length buffers. This strategy appears prudent, as it eliminates the need to forward non-transmittable buffers to the transport layer, potentially offering a solution to the issue observed with gRPC.
### Component(s)
C++, FlightRPC
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@arrow.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [C++][grpc] Sending 0-length buffers to gRPC can result in indefinite hangs on MacOS/iOS platforms [arrow]
Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm closed issue #43447: [C++][grpc] Sending 0-length buffers to gRPC can result in indefinite hangs on MacOS/iOS platforms
URL: https://github.com/apache/arrow/issues/43447
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [C++][grpc] Sending 0-length buffers to gRPC can result in indefinite hangs on MacOS/iOS platforms [arrow]
Posted by "lidavidm (via GitHub)" <gi...@apache.org>.
lidavidm commented on issue #43447:
URL: https://github.com/apache/arrow/issues/43447#issuecomment-2255056088
Issue resolved by pull request 43448
https://github.com/apache/arrow/pull/43448
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org