kaskada icon indicating copy to clipboard operation
kaskada copied to clipboard

bug: Take advantage of FieldRef to avoid copying

Open bjchambers opened this issue 2 years ago • 1 comments

Description Recent versions of Arrow have introduced a FieldRef = Arc<Field> type. When upgrading, we continued cloning the fields and creating new Arcs around them for simplicity. However, in many places we should be able to hold a single Arc<[FieldRef]> like they do in StructArray and clone the Arc, allowing any operation on struct arrays to avoid allocating new fields for each field and the array of fields.

Filing this bug as part of the upgrade so that I can link to it in the relevant TODOs.

bjchambers avatar Jun 05 '23 19:06 bjchambers

There are a lot of places we refer to the key columns (_time, etc.) which would benefit from having a single static FieldRef we could reference in all those places.

bjchambers avatar Jun 05 '23 20:06 bjchambers