apache / arrow-rs

Official Rust implementation of Apache Arrow
https://arrow.apache.org/
Apache License 2.0
2.45k stars 726 forks source link

Support list_with_offset for Azure using continuation token #5653

Closed alexwilcoxson-rel closed 3 months ago

alexwilcoxson-rel commented 4 months ago

Is your feature request related to a problem or challenge? Please describe what you are trying to do. Azure object store implementation uses default list_with_offset implementation. It lists everything and does the filtering client side.

This is problematic for Delta Lake with large directories where we only really care about listing the latest files from a certain path.

Describe the solution you'd like Microsoft pointed me to the Hadoop Azure filesystem listStatus API where startFrom is supported.

Basically the starting path is embedded in the opaque continuation token provided when the list API needs to page results. On the initial request this token is created and provided to the list API to start from the path.

The downside is that this is not documented. Perhaps this could be an opt-in option if there is hesitation using an undocumented format for the token that could break.

tustvold commented 4 months ago

I think I would prefer to not implement undocumented shenanigans, that I presume would be hard to test 😅

alexwilcoxson-rel commented 3 months ago

👍 we tried to implement this and what they suggested to us is not working anyway, so we're going to pursue other options.