-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Docs: try and clarify what PartitionEvaluator
functions are called
#6869
Conversation
/// |[`uses_window_frame`]|[`supports_bounded_execution`]|[`include_rank`]|function_to_implement| | ||
/// |---|---|----|----| | ||
/// |false (default) |false (default) |false (default) | [`evaluate_all`] | | ||
/// |false |true |false | [`evaluate`] | | ||
/// |false |true/false |true | [`evaluate_all_with_rank`] | | ||
/// |true |true/false |true/false | [`evaluate`] | |
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.
❤️
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.
Thanks @alamb for this PR.
Regarding
If we ignore
In this table, if However, it is a bit confusing.I will try to simplify it. |
For anyone following along, the simplifying PR is 👨🍳 👌 #6966 |
Which issue does this PR close?
N/A
Rationale for this change
@mhilton noticed that the docs were backwards when he started looking at the uses_window_frame docs
I spent some time researching / verifying what actually happens, and it turns out that
evaluate_all
will be used when the function doesn’t use the window frame and I wanted to encode this learning into documentationHere is the actual code that dispatches to the different evaluation functions
https://github.com/apache/arrow-datafusion/blob/a1281aa79ea104efdf3d07dd1948f2ae0b374634/datafusion/physical-expr/src/window/built_in.rs#L96-L128
What changes are included in this PR?
Update the documentation for
PartitionEvaluator
to make what is called when (hopefully) clearer.I still don't understand enough of what makes a
PartitionEvaluator
"stateful" to document what functions need to be implemented under what circumstances. Maybe @mustafasrepo could help clarify thisAre these changes tested?
N/A
Are there any user-facing changes?
only doc changes