apache / arrow

Apache Arrow is the universal columnar format and multi-language toolbox for fast data interchange and in-memory analytics
https://arrow.apache.org/
Apache License 2.0
14.6k stars 3.55k forks source link

[C#] Unable to run FlightRPC client on http://localhost:5000 getting back exceptions #43223

Open HackPoint opened 4 months ago

HackPoint commented 4 months ago

Describe the bug, including details regarding any error messages, version, and platform.

I'm trying to test your Example: FlightClientExample when I'm running it against server getting this error:

RPC Error: Status(StatusCode="Unknown", Detail="Exception was thrown by handler. InvalidProtocolBufferException: While parsing a protocol message, the input ended unexpectedly in the middle of a field.  This could mean either that the input has been truncated or that an embedded message misreported its own length.")
Error executing query:\n Failed to execute query

Component(s)

C#

adamreeve commented 1 month ago

Hi @HackPoint, can you please provide some more details to help reproduce this problem. Are you running FlightAspServerExample as the server? And what OS are you running on?

If I run dotnet run in csharp/examples/FlightAspServerExample and then dotnet run in another terminal in csharp/examples/FlightClientExample, the client works for me:

Connecting to: http://localhost:5000
Table saved.
Wrote 2 batches to server.
Schema saved as: 
 Schema: Num fields=4, Num metadata=0
Info provided: 
 Apache.Arrow.Flight.FlightInfo
Available flights:
  Apache.Arrow.Flight.FlightInfo
Read batch from flight server: 
 RecordBatch: 4 columns by 2000 rows
Read batch from flight server: 
 RecordBatch: 4 columns by 9050 rows
Actions:
  clear: Clear the flights from the server

This was tested with the current main branch (33a4d67776) on Linux.