Details
-
Bug
-
Status: Resolved
-
Resolution: Cannot Reproduce
-
None
-
None
-
None
-
Operating System: Windows
Platform: PC
-
1179
Description
Problem:
Restconf RPC operations (POST /restconf/operations/<moduleName>:<rpcName>) will not handle the errors set in the RpcResult and returns Status 204 (No Content).
I have my RPC implementation not to throw exceptions in case of failure but return the result for RPC with errors and successful flag set accordingly.
For example, my RPC returns the following.
return Futures.immediateFuture(Rpcs.<output> getRpcResult(isSuccessful, output, errors));
In case of failures, I am setting the isSuccessful to false and adding the RpcError to the errors collection with error code and cause etc. But, the restconf response for the RPC is Status 204 (No Content). It looks like restconf may not be looking at the errors in the RpcResult and just looking at the output.