RestconfDocumentedException with error tag INVALID_VALUE (400) was caught and
wrapped to RestconfDocumentedException with error tag OPERATION_FAILED
(500)
Change-Id: I0ad75958e0d8e25d5bf1bdf7cbac5f855cc2b03d
Signed-off-by: Jozef Gloncak <jgloncak@cisco.com>
throw new RestconfDocumentedException(e.getMessage(), ErrorType.PROTOCOL, ErrorTag.INVALID_VALUE);
} catch (UnsupportedOperationException e) {
throw new RestconfDocumentedException(e.getMessage(), ErrorType.RPC, ErrorTag.OPERATION_NOT_SUPPORTED);
+ } catch (RestconfDocumentedException e) {
+ throw e;
} catch (Exception e) {
throw new RestconfDocumentedException("The operation encountered an unexpected error while executing.", e);
}