-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Tightening rate verification for RateTests #131114
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
|
r: @dnhatn |
|
Pinging @elastic/es-storage-engine (Team:StorageEngine) |
| case DOUBLE, COUNTER_DOUBLE -> dataRows.stream().mapToDouble(v -> (Double) v).min().orElse(0.0); | ||
| default -> throw new IllegalStateException("Unexpected value: " + fieldTypedData.type()); | ||
| }; | ||
| // If the minrate is greater than 0, we need to adjust the maxrate accordingly |
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.
Interesting.. I would've thought that counters are INTEGER or LONG, and only COUNTER_INTEGER and COUNTER_LONG can be input to rate. Also, I haven't thought about negative values - though OTLP has the notion of up/down counters:
https://opentelemetry.io/docs/specs/otel/metrics/supplementary-guidelines/#instrument-selection
Maybe we should restrict the current rate implementation to non-negative counter values and check for that? @dnhatn for thoughts.
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.
Maybe we should restrict the current rate implementation to non-negative counter values and check for that?
I think the current rate implementation does not work correctly with up/down counters.
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.
Hm there's no check for negative values, though.. Shall we add a check and error out, if a negative counter value is detected?
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.
hi team! how would these address changes to my PR? what should we address here?
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.
I don't think we need to address the issue here.
dnhatn
left a comment
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.
LGTM.
No description provided.