-
Notifications
You must be signed in to change notification settings - Fork 202
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
Fix count aggregation exemplar data #4341
Conversation
Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com>
@@ -86,8 +87,7 @@ public AggregateActionResponse handleEvent(final Event event, final AggregateAct | |||
groupState.put(startTimeKey, Instant.now()); | |||
groupState.putAll(aggregateActionInput.getIdentificationKeys()); | |||
groupState.put(countKey, 1); | |||
exemplarList = new ArrayList<>(); |
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 remove this field and make it a local only.
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.
Actually, you can just remove the field. It should now be unused.
Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com>
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.
The changes look good. I noticed the Gradle builds were failing in the previous commit.
Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com>
Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com>
* Fix count aggregation exemplar data Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> * Addressed comments Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> * Fixed failing tests Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> * Fixed failing tests Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> --------- Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> Co-authored-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> Co-authored-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> (cherry picked from commit f7191c9)
* Fix count aggregation exemplar data Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> * Addressed comments Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> * Fixed failing tests Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> * Fixed failing tests Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> --------- Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> Signed-off-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> Co-authored-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-bd29c437.us-west-2.amazon.com> Co-authored-by: Krishna Kondaka <krishkdk@dev-dsk-krishkdk-2c-15df884d.us-west-2.amazon.com> (cherry picked from commit f7191c9) Co-authored-by: Krishna Kondaka <41027584+kkondaka@users.noreply.github.com>
Description
Count aggregation incorrectly maintains a global value for exemplars. Exemplars should be maintained per
groupState
.This change fixes it and maintains a different exemplar for different aggregate groups.
Issues Resolved
Resolves #[Issue number to be closed when this PR is merged]
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.