ResponseErrorException is not propagated with the default exception handler
ivy-cst opened this issue · comments
The same as: #576
But by then only the doc had changed: #578
In my opinion this is not very user friendly. If I bother to throw a ResponseErrorException
, it should be propagated even if it is thrown when the method is called and not only when the CompletableFuture
is executed.
As an example, we do check some context stuff that is only available as a ThreadLocal
and not while the CompletableFuture
is executed.
There is also an open source example on eclpse-gslp that does this incorrectly. See DefaultGLSPServer
Can I confirm that the use case you are seeing is that you are getting the "wrong" ResponseError
back? Instead of getting the ResponseError
with the code, message and data that you expect you are getting an Internal error
message/code and the data is the stack trace?
Can I confirm that the use case you are seeing is that you are getting the "wrong"
ResponseError
back? Instead of getting theResponseError
with the code, message and data that you expect you are getting anInternal error
message/code and the data is the stack trace?
Yes a new ResponseError
is generated and even worse the exception is logged as SEVERE
here:
Yes a new
ResponseError
is generated [...]
Thanks for confirming. I think that the PR I provided will resolve this case. Thanks for pointing out the secondary problem of the SEVERE log message too.