[ 
https://issues.apache.org/jira/browse/IGNITE-19823?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17745008#comment-17745008
 ] 

Andrey N. Gura commented on IGNITE-19823:
-----------------------------------------

See changes to the original IEP here: 
https://lists.apache.org/thread/zsg9khpr6r604j96kch3bn2fdwz1m04d

*Solution:*
- Add a public exception DeploymentUnitUnavailableException to the Compute API 
which covers both cases (deployment unit is not found and deployment unit can't 
be used). The cases itself should be described with separate error codes and 
error messages. DeploymentUnitUnavailableException should be thrown instead of 
ClassNotFoundException.
- Add a public exception ComputeExecutionException to the Compute API which 
covers any errors that occur during a job execution (including class loading of 
a class representing the job). It is impossible to provide error codes for all 
possible errors so one error code will be enough. The error message can be 
something like this "An error occurred during code execution." The original 
exception have to be a cause of ComputeExecutionException.
- Complete CompletableFuture of Compute API methods with these new public 
exceptions.




> DeploymentUnitNotFoundException is internal, does not propagate to client
> -------------------------------------------------------------------------
>
>                 Key: IGNITE-19823
>                 URL: https://issues.apache.org/jira/browse/IGNITE-19823
>             Project: Ignite
>          Issue Type: Bug
>    Affects Versions: 3.0.0-beta1
>            Reporter: Pavel Tupitsyn
>            Assignee: Andrey N. Gura
>            Priority: Major
>              Labels: ignite-3
>             Fix For: 3.0.0-beta2
>
>
> * *DeploymentUnitNotFoundException* is in internal package, but it is a 
> "public" exception which is thrown when the user specifies an unknown unit 
> name/version.
> * It is remapped to *ClassNotFoundException* in 
> https://github.com/apache/ignite-3/blob/f90f949b342bd1fa864d342c4078b393f4ed23c0/modules/compute/src/main/java/org/apache/ignite/internal/compute/ClassLoaderExceptionsMapper.java#L50
> As a result, traceId and error code are not propagated to the client.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to