When registering a LanceDB table into a DataFusion session we currently create a new DataFusion adapter for the table.
That works, but for remote LanceDB tables we should avoid redoing table/provider setup when the same table is registered again in the same app / session scope.
We should cache the DataFusion Lance table provider by something like:
- app_id
- database cache key
- table name
- table version / tag if available
- storage prefix / uri
This should not break isolation. Server side cache should be app scoped. Client side cache should stay inside the current app / sandbox.
When registering a LanceDB table into a DataFusion session we currently create a new DataFusion adapter for the table.
That works, but for remote LanceDB tables we should avoid redoing table/provider setup when the same table is registered again in the same app / session scope.
We should cache the DataFusion Lance table provider by something like:
This should not break isolation. Server side cache should be app scoped. Client side cache should stay inside the current app / sandbox.