GitHub user nathanielc closed a discussion: Using Flight RPC Calls as a table

I would like to consume the results of a Flight RPC call as a table within a 
datafusion context. So far I have not found a built-in way to do this. Is there 
an example out there of consuming a Flight RPC stream as a TableProvider?


Looking through the available types I am expecting I would need to do the 
following:

1. Implement TableProvider trait that builds an ExecutionPlan when scan is 
called.
2. Implement the ExecutionPlan in terms of the 
[StreamingTableExec](https://docs.rs/datafusion/latest/datafusion/physical_plan/streaming/struct.StreamingTableExec.html)
 type by implementing the 
[PartitionStream](https://docs.rs/datafusion/latest/datafusion/physical_plan/streaming/trait.PartitionStream.html)
 trait on the returned stream from the Flight RPC call.

Does this sound like what is expected? Or is there a more direct path to 
exposing a stream of RecordBatches from Flight RPC as a table in datafusion? 
Thanks in advance.

GitHub link: https://github.com/apache/datafusion/discussions/11772

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to