-
Notifications
You must be signed in to change notification settings - Fork 127
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
Restrict event references in windowed select queries and add 'emit_empty_windows` setting #828
Conversation
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.
Nice improvement :) I left a few inline comments
a2980f0
to
b5888af
Compare
107dbdb
to
79da0f8
Compare
.params | ||
.get("emit_empty_windows") | ||
.and_then(Value::as_bool) | ||
.unwrap_or(WindowImpl::DEFAULT_EMIT_EMPTY_WINDOWS); |
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.
we should emit a warning here if emit_empty_windows
is set and max_groups
is not set
I love the ast walker :D that's going to be so handy over time! I left a few comments inline most just questions otherwise 👍 |
…'emit_empty_windows' Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
…be waiting longer than configured. Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
Signed-off-by: Matthias Wahl <mwahl@wayfair.com>
e99b189
to
065aaf5
Compare
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.
Woooh! Nice job :D
Pull request
Description
event
or$
in the select target expression (select --> event <-- from ...
) if this is a select query with a window, because we cannot access a single event in the select target, in that context we operate on the whole window. A freestanding event reference has always been evaluating to the last event of the window, but we haveaggr::win::last(...)
for that, and since0.10
it is possible to have windows without an event (for time based windows), where query execution would error out.emit_empty_windows
for windows, which isfalse
if not explicitly set totrue
. If set totrue
, time based tumbling windows will emit a window event on everyinterval
if they received an event or not. Some aggregations might returnnull
in this case.This fixes some unintended edge cases in the window handling changes introduced in
0.10
.Related
event
in windows and groupings #823, closed Degradation of handling signals in select statements #799Checklist
Performance