On 19/02/2018 18:21, PeeDub wrote:
I see that (for example) AccessTokenService.logout() returns a *void* type.
Wouldn't it be helpful to return a Response type such that you could
diagnose an error if it occurs? One could tell if it was successful or not
by the Response status code. As it is, you can not possibly tell from the
client API whether the call succeeded or not.
If you are using the Syncope Client Library, when any API call (either
returning void or something else) does not succeed, the
RestClientExceptionMapper [1] will turn the reported error into a proper
Java exception.
Regards.
[1]
https://github.com/apache/syncope/blob/2_0_X/client/lib/src/main/java/org/apache/syncope/client/lib/RestClientExceptionMapper.java
--
Francesco Chicchiriccò
Tirasa - Open Source Excellence
http://www.tirasa.net/
Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/