This PR introduces a global GRPC interceptor for error handling (instead of handling cases one by one, which can be clumsy and easy to miss cases that needs to be handled). Although now exception can only happen at user custom code (application errors) which are translated to UNKNOWN grpc error code to be retried. The error handling logic can be extended easily to handle more type of exception if needed in future.
Also note that exception in reduce and sink now will no longer cause panic and exit but return with UNKNOWN grpc error to match the behavior in python and go sdk side.
Closes #769
This PR introduces a global GRPC interceptor for error handling (instead of handling cases one by one, which can be clumsy and easy to miss cases that needs to be handled). Although now exception can only happen at user custom code (application errors) which are translated to
UNKNOWN
grpc error code to be retried. The error handling logic can be extended easily to handle more type of exception if needed in future.Also note that exception in reduce and sink now will no longer cause panic and exit but return with
UNKNOWN
grpc error to match the behavior in python and go sdk side.