-
Notifications
You must be signed in to change notification settings - Fork 373
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SDK batching/revamp 2.2: homegrown arrow size estimation routines #2002
Conversation
b41f4ea
to
33a60ac
Compare
aece2df
to
25ca19c
Compare
c5522fe
to
f8e74e9
Compare
d0cd877
to
da160c5
Compare
estimated_bytes_size
+ Union
+ batching = disaster…ching_estimated_size_hell
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As always, Dense Unions are a major pain.
let mut idx_end = idx_start; | ||
for idx in indices { | ||
idx_end = idx; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let mut idx_end = idx_start; | |
for idx in indices { | |
idx_end = idx; | |
} | |
let idx_end = indices.last().unwrap_or_default(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah... I didn't go there because it very much looks like this is some magic 0(1)
function, which feels like I'm betraying the reader...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
This takes care of all size measurement issues (incl. batch support) and makes sure they won't bother us again, at least until the migration to
arrow1
.Don't be fooled by the line-changed numbers, it's all either tests or shuffling code around. All the relevant stuff is confined to the new
estimated_bytes_size
function insize_bytes.rs
.On top of #1983
Checks: