[CONTROLLER-461] NetconfMapping.checkSuccessReply(NetconfMessage) should throw NetconfDocumentedException Created: 08/May/14 Updated: 19/Jun/14 Resolved: 19/Jun/14 |
|
| Status: | Resolved |
| Project: | controller |
| Component/s: | netconf |
| Affects Version/s: | Helium |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Devin Avery | Assignee: | Tom Pantelis |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: Mac OS |
||
| External issue ID: | 977 |
| Description |
|
This bug should modify the method to throw the proper NetconfDocumentedException (since it is required for proper downstream handling of netconf related errors). |
| Comments |
| Comment by Tom Pantelis [ 08/May/14 ] |
|
There already is an RpcError class containing the necessary info to produce appropriate restconf error output. Instead of setting an exception in the Future, I think NetconfDeviceListener.processMessage should convert the NetconfDocumentedException into an RpcError and return an RpcResult in the Future. I think this is the intention of the invoke RPC interface – an exception should only be thrown as a result of drastic internal error, ie unchecked ex (eg NPE) in code. It should make every effort to return an RpcError. |
| Comment by Tom Pantelis [ 02/Jun/14 ] |