-
Notifications
You must be signed in to change notification settings - Fork 138
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
fixing metrics #1194
fixing metrics #1194
Conversation
Signed-off-by: Dhrubo Saha <[email protected]>
Codecov Report
@@ Coverage Diff @@
## 2.9 #1194 +/- ##
============================================
+ Coverage 78.75% 78.77% +0.02%
- Complexity 2122 2125 +3
============================================
Files 167 167
Lines 8678 8683 +5
Branches 871 871
============================================
+ Hits 6834 6840 +6
+ Misses 1448 1445 -3
- Partials 396 398 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
|
@@ -836,6 +837,7 @@ public void deployModel( | |||
|
|||
private void handleDeployModelException(String modelId, FunctionName functionName, ActionListener<String> listener, Exception e) { | |||
mlStats.createCounterStatIfAbsent(functionName, ActionName.DEPLOY, MLActionLevelStat.ML_ACTION_FAILURE_COUNT).increment(); | |||
mlStats.getStat(MLNodeLevelStat.ML_NODE_TOTAL_FAILURE_COUNT).increment(); |
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 only track the real internal server failure. For example, some exception are expected (which means that's not a code bug) like illegal input parameter. You can refer to other place
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.
Agree, addressed.
Signed-off-by: Dhrubo Saha <[email protected]>
Signed-off-by: Dhrubo Saha <[email protected]>
Signed-off-by: Dhrubo Saha <[email protected]>
@@ -689,7 +689,10 @@ private void deleteModel(String modelId) { | |||
} | |||
|
|||
private void handleException(FunctionName functionName, String taskId, Exception e) { | |||
mlStats.createCounterStatIfAbsent(functionName, REGISTER, MLActionLevelStat.ML_ACTION_FAILURE_COUNT).increment(); | |||
if (!(e instanceof MLLimitExceededException) && !(e instanceof MLResourceNotFoundException)) { |
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.
Thanks , how about also check IllegalArgumentException
which is generally user's input is wrong, we should not treat it as some internal failure.
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.
Sounds good. In that case, may be we can add same exception here also, what do you think?
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.
Sure, sounds good
Signed-off-by: Dhrubo Saha <[email protected]>
Signed-off-by: Dhrubo Saha <[email protected]>
Signed-off-by: Dhrubo Saha <[email protected]>
* fixing metrics Signed-off-by: Dhrubo Saha <[email protected]> * addressing comments Signed-off-by: Dhrubo Saha <[email protected]> * addressing comments Signed-off-by: Dhrubo Saha <[email protected]> * updating test Signed-off-by: Dhrubo Saha <[email protected]> * added IllegalArgumentException in the if statement Signed-off-by: Dhrubo Saha <[email protected]> * addressing comments Signed-off-by: Dhrubo Saha <[email protected]> * fixing spotless Signed-off-by: Dhrubo Saha <[email protected]> --------- Signed-off-by: Dhrubo Saha <[email protected]> (cherry picked from commit deb0008)
* fixing metrics Signed-off-by: Dhrubo Saha <[email protected]> * addressing comments Signed-off-by: Dhrubo Saha <[email protected]> * addressing comments Signed-off-by: Dhrubo Saha <[email protected]> * updating test Signed-off-by: Dhrubo Saha <[email protected]> * added IllegalArgumentException in the if statement Signed-off-by: Dhrubo Saha <[email protected]> * addressing comments Signed-off-by: Dhrubo Saha <[email protected]> * fixing spotless Signed-off-by: Dhrubo Saha <[email protected]> --------- Signed-off-by: Dhrubo Saha <[email protected]>
* fixing metrics * addressing comments * addressing comments * updating test * added IllegalArgumentException in the if statement * addressing comments * fixing spotless --------- Signed-off-by: Dhrubo Saha <[email protected]> Co-authored-by: Dhrubo Saha <[email protected]>
* fixing metrics * addressing comments * addressing comments * updating test * added IllegalArgumentException in the if statement * addressing comments * fixing spotless --------- Signed-off-by: Dhrubo Saha <[email protected]> Co-authored-by: Dhrubo Saha <[email protected]>
* fixing metrics * addressing comments * addressing comments * updating test * added IllegalArgumentException in the if statement * addressing comments * fixing spotless --------- Signed-off-by: Dhrubo Saha <[email protected]> Co-authored-by: Dhrubo Saha <[email protected]>
Description
[fixing metrics]
Issues Resolved
[List any issues this PR will resolve]
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.