-
Notifications
You must be signed in to change notification settings - Fork 36
Conversation
This PR fixes two issues for the stats API. First, we didn't propagate multi-entity detectors' models execution exceptions for the remote invocation. This problem may impact stats' API ability to report the total failures count and thus hide an issue we should have reported during monitoring. This PR fixes the issue by collecting model host nodes' exceptions from coordinating nodes. Second, we didn't show active multi-entity detectors' models information on stats API. This PR places this information into stats API output. This PR also adds unit tests for ModelManager. Testing done: 1. added unit tests 2. manually verified the two issues are resolved.
Codecov Report
@@ Coverage Diff @@
## master #287 +/- ##
============================================
+ Coverage 70.00% 71.32% +1.31%
- Complexity 1820 1852 +32
============================================
Files 190 190
Lines 8879 8903 +24
Branches 757 760 +3
============================================
+ Hits 6216 6350 +134
+ Misses 2307 2191 -116
- Partials 356 362 +6
Flags with carried forward coverage won't be shown. Click here to find out 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.
I have a few minor comments. But, overall, it looks good. One question: does Readme need to be updated at all on KNN Stats API usage?
...in/java/com/amazon/opendistroforelasticsearch/ad/transport/AnomalyResultTransportAction.java
Outdated
Show resolved
Hide resolved
...main/java/com/amazon/opendistroforelasticsearch/ad/stats/suppliers/ModelsOnNodeSupplier.java
Show resolved
Hide resolved
Ah, I see API usage is not specified in the README. It looks like this documentation does not need to be updated. |
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!
Yes, I will make sure our docs are up dated. We have one new API and few other changes. |
Issue #, if available:
Description of changes:
This PR fixes two issues for the stats API.
First, we didn't propagate multi-entity detectors' models execution exceptions for the remote invocation. This problem may impact stats' API ability to report the total failures count and thus hide an issue we should have reported during monitoring. This PR fixes the issue by collecting model host nodes' exceptions from coordinating nodes.
Second, we didn't show active multi-entity detectors' models information on stats API. This PR places this information into stats API output.
This PR also adds unit tests for ModelManager.
Testing done:
Stats API output after my changes:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.