Try sending/receiving a large message via Flight. See ARROW-4421: by default, gRPC won't allow us to send messages > 4MiB in size.
()
| 1378 | |
| 1379 | @pytest.mark.slow |
| 1380 | def test_flight_large_message(): |
| 1381 | """Try sending/receiving a large message via Flight. |
| 1382 | |
| 1383 | See ARROW-4421: by default, gRPC won't allow us to send messages > |
| 1384 | 4MiB in size. |
| 1385 | """ |
| 1386 | data = pa.Table.from_arrays([ |
| 1387 | pa.array(range(0, 10 * 1024 * 1024)) |
| 1388 | ], names=['a']) |
| 1389 | |
| 1390 | with EchoFlightServer(expected_schema=data.schema) as server, \ |
| 1391 | FlightClient(('localhost', server.port)) as client: |
| 1392 | writer, _ = client.do_put(flight.FlightDescriptor.for_path('test'), |
| 1393 | data.schema) |
| 1394 | # Write a single giant chunk |
| 1395 | writer.write_table(data, 10 * 1024 * 1024) |
| 1396 | writer.close() |
| 1397 | result = client.do_get(flight.Ticket(b'')).read_all() |
| 1398 | assert result.equals(data) |
| 1399 | |
| 1400 | |
| 1401 | def test_flight_generator_stream_of_batches(): |
nothing calls this directly
no test coverage detected