[Contents] [Prev] [Next] [Index] [Report an Error]

Handling an Error or Warning

If the NETCONF server encounters an error condition, it emits an <rpc-error> tag element containing tag elements that describe the error:


<rpc-reply xmlns="URN "xmlns:sdx="URL”>
    <rpc-error>
        <error-severity>error-severity</error-severity>
        <error-path>error-path</error-path>
        <error-message>error-message</error-message>
        <error-info>
            <bad-element>command-or-statement</bad-element>
        </error-info>
    </rpc-error>
</rpc-reply>
]]>]]>

An error can occur while the server is performing any of the following operations, and the server can send a different combination of child tag elements in each case:

Client applications must be prepared to receive and handle an <rpc-error> tag element at any time. The information in any response tag elements already received and related to the current request might be incomplete. The client application can include logic for deciding whether to discard or retain the information.

When the <error-severity> tag element has the value error, the usual response is for the client application to discard the information and terminate. When the <error-severity> tag element has the value warning, indicating that the problem isless serious, the usual response is for the client application to log the warning or pass it to the user, but to continue parsing the server’s response.


[Contents] [Prev] [Next] [Index] [Report an Error]