-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-9467][SQL]Add SQLMetric to specialize accumulators to avoid boxing #7996
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
Conversation
|
cc @rxin |
|
Test build #40038 has finished for PR 7996 at commit
|
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.
nit: "Found"
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.
if i understand this correctly, this only works because the zero value of all these metrics are naturally 0 right?
(since we set zero value while we deserialize data)
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.
Right. I think we don't need a different initial value for SQL metrics. So just avoid to add an initial value to SQLMetricParam.
|
LGTM |
|
Test build #40113 has finished for PR 7996 at commit
|
|
retest this please |
|
Test build #40126 has finished for PR 7996 at commit
|
|
Test build #1400 has finished for PR 7996 at commit
|
|
Thanks - merging this in. |
…xing This PR adds SQLMetric/SQLMetricParam/SQLMetricValue to specialize accumulators to avoid boxing. All SQL metrics should use these classes rather than `Accumulator`. Author: zsxwing <[email protected]> Closes #7996 from zsxwing/sql-accu and squashes the following commits: 14a5f0a [zsxwing] Address comments 367ca23 [zsxwing] Use localValue directly to avoid changing Accumulable 42f50c3 [zsxwing] Add SQLMetric to specialize accumulators to avoid boxing (cherry picked from commit ebfd91c) Signed-off-by: Reynold Xin <[email protected]>
…xing This PR adds SQLMetric/SQLMetricParam/SQLMetricValue to specialize accumulators to avoid boxing. All SQL metrics should use these classes rather than `Accumulator`. Author: zsxwing <[email protected]> Closes apache#7996 from zsxwing/sql-accu and squashes the following commits: 14a5f0a [zsxwing] Address comments 367ca23 [zsxwing] Use localValue directly to avoid changing Accumulable 42f50c3 [zsxwing] Add SQLMetric to specialize accumulators to avoid boxing
This PR adds SQLMetric/SQLMetricParam/SQLMetricValue to specialize accumulators to avoid boxing. All SQL metrics should use these classes rather than
Accumulator.