-
Notifications
You must be signed in to change notification settings - Fork 146
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
Nexus: Well know error translation #2242
Nexus: Well know error translation #2242
Conversation
temporal-sdk/src/test/java/io/temporal/workflow/nexus/OperationFailureConversionTest.java
Outdated
Show resolved
Hide resolved
@@ -59,7 +59,6 @@ private static String getMessage(WorkflowExecution execution, String workflowTyp | |||
+ execution.getWorkflowId() | |||
+ "', runId='" | |||
+ execution.getRunId() | |||
+ (workflowType == null ? "" : "', workflowType='" + workflowType + '\'') | |||
+ '}'; | |||
+ (workflowType == null ? "" : "', workflowType='" + workflowType + '\''); |
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.
Not sure what this random }
was for
throw new OperationHandlerException( | ||
OperationHandlerException.ErrorType.INTERNAL, failure.getMessage()); | ||
} | ||
if (failure instanceof WorkflowException) { |
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.
Can you confirm that this roughly maps to WorkflowExecutionError
or QueryRejectedError
in Go?
This is fine as an initial first pass at this but I think eventually we may want a different approach. We'll see if we get any feedback on the current approach.
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.
WorkflowQueryException
and WorkflowFailedException
extend WorkflowException
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.
So they are both treated as BAD_REQUEST
Add conversion for common errors
Add conversion for common errors
Add conversion for common errors
Translate some well know errors like what we did with the Go SDK. This does not cover all possible SDK exception, just some we except users to throw in this initial release.
closes #2209