-
Notifications
You must be signed in to change notification settings - Fork 811
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(exceptions): Don't let errors in trackResult
leak out
#3843
fix(exceptions): Don't let errors in trackResult
leak out
#3843
Conversation
It's possible for trackResult metrics call to fail and we don't want that failure to leak out and fail orca tasks
@@ -58,9 +58,12 @@ default String getCredentials(Map<String, Object> context) { | |||
|
|||
// may return a list with 0, 1 or more regions (no guarantees on the ordering) | |||
default List<String> getRegions(Map<String, Object> context) { | |||
String region = (String) context.getOrDefault("region", null); | |||
Object region = context.getOrDefault("region", null); |
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.
this sometimes is a string and sometimes a list. I tried to make it handle both. but also wrapped in try/catch
in the other files
@@ -169,7 +170,7 @@ class RunTaskHandler( | |||
} else if (e is TimeoutException && stage.context["markSuccessfulOnTimeout"] == true) { | |||
queue.push(CompleteTask(message, SUCCEEDED)) | |||
} else { | |||
if (e !is TimeoutException) { | |||
if (e !is TimeoutException && e !is UserException) { |
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.
oh, this is actually from a related but separate change. but might as well go together. Basically, we shouldn't log errors for exceptiosn that are not in "our" control. E.g. bad SpEL expression and any other UserExceptions
…r#3843) It's possible for trackResult metrics call to fail and we don't want that failure to leak out and fail orca tasks Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
It's possible for trackResult metrics call to fail and we don't want that failure to leak out and fail orca tasks