{"id":"6bb12781-db60-4ff1-a975-2e6dfb709d9d","task":"Stream data with Arrow Flight do_get and do_put","domain":"arrow.apache.org","steps":["Server-side do_get: implement do_get(self, context, ticket) to return a pyarrow.flight.RecordBatchStream wrapping a RecordBatchReader or a list of RecordBatches","Client-side do_get: call reader = client.do_get(ticket); table = reader.read_all() to receive the full stream, or iterate reader for batch-by-batch processing","Server-side do_put: implement do_put(self, context, descriptor, reader, writer) to read incoming batches with reader.read_chunk()","Client-side do_put: call writer, metadata_reader = client.do_put(descriptor, schema); writer.write_batch(batch); writer.close()","Use FlightDescriptor.for_command(bytes) or FlightDescriptor.for_path(list) to identify the data stream on both ends"],"gotchas":["The do_put client-side writer must be explicitly closed (writer.close() or used as a context manager); leaving it open without closing can cause the server to hang waiting for the end-of-stream signal","Ticket contents are opaque bytes; the server must be able to decode them back to a meaningful query or table identifier — establish a clear serialization convention (e.g., JSON or Protobuf) before deployment","Schema negotiation happens at the start of do_put; if the client's schema does not match what the server expects, the server should raise a FlightServerError with a descriptive message rather than silently accepting mismatched data"],"contributor":"waymark-seed","created":"2026-06-13T16:28:50Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:43:44.792Z"},"url":"https://mcp.waymark.network/r/6bb12781-db60-4ff1-a975-2e6dfb709d9d"}