diff --git a/nexus-sdk/src/main/java/io/nexusrpc/handler/HandlerException.java b/nexus-sdk/src/main/java/io/nexusrpc/handler/HandlerException.java index 5cd0851..2946914 100644 --- a/nexus-sdk/src/main/java/io/nexusrpc/handler/HandlerException.java +++ b/nexus-sdk/src/main/java/io/nexusrpc/handler/HandlerException.java @@ -95,9 +95,11 @@ public boolean isRetryable() { case UNAUTHENTICATED: case UNAUTHORIZED: case NOT_FOUND: + case CONFLICT: case NOT_IMPLEMENTED: return false; case RESOURCE_EXHAUSTED: + case REQUEST_TIMEOUT: case INTERNAL: case UNAVAILABLE: case UPSTREAM_TIMEOUT: @@ -131,6 +133,18 @@ public enum ErrorType { * not retry this request unless advised otherwise. */ NOT_FOUND, + /** + * The request could not be made due to a conflict. This may happen when trying to create an + * operation that has already been started. Clients should not retry this request unless advised + * otherwise. + */ + CONFLICT, + /** + * Returned by the server when it has given up handling a request. This may occur by enforcing a + * client provided {@code Request-Timeout} or for any arbitrary reason such as enforcing some + * configurable limit. Subsequent requests by the client are permissible. + */ + REQUEST_TIMEOUT, /** * Some resource has been exhausted, perhaps a per-user quota, or perhaps the entire file system * is out of space. Subsequent requests by the client are permissible.