[NETCONF-666] 500 response without provided rpc failure details Created: 21/Apr/20  Updated: 05/Jun/20  Resolved: 05/Jun/20

Status: Resolved
Project: netconf
Component/s: None
Affects Version/s: None
Fix Version/s: Aluminium, Magnesium SR2, Sodium SR4

Type: Bug Priority: Medium
Reporter: Jamo Luhrsen Assignee: Jamo Luhrsen
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: Text File NETCONF-666_junos_config.txt     Text File NETCONF-666_karaf_log_snippet.txt    
Issue Links:
Blocks
blocks NETCONF-695 Rpc future doesn't complete when tran... Resolved
Duplicate
is duplicated by NETCONF-645 Netconf client fails to detect error ... Resolved

 Description   

When the following rpc reply is returned from a mounted device, an IllegalArgumentException
is thrown for "Unexpected content in response of rpc".

<nc:rpc-reply xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" xmlns:junos="http://xml.juniper.net/junos/18.4R1/junos" message-id="m-11">

    <nc:rpc-error>

        <nc:error-type>protocol</nc:error-type>

        <nc:error-tag>operation-failed</nc:error-tag>

        <nc:error-severity>error</nc:error-severity>

        <source-daemon>
dcd
</source-daemon>

        <nc:error-message>
Number of member links configured, i.e [1], for interface [ae0]is lesser than the required minimum [2].
</nc:error-message>

    </nc:rpc-error>

    <nc:rpc-error>

        <nc:error-type>protocol</nc:error-type>

        <nc:error-tag>operation-failed</nc:error-tag>

        <nc:error-severity>error</nc:error-severity>

        <nc:error-message>
configuration check-out failed
</nc:error-message>

    </nc:rpc-error>

</nc:rpc-reply>

The client that issued the rpc via restconf receives the below response text with the 500
code:

{
    "errors": {
        "error": [
            {
                "error-type": "application",
                "error-tag": "operation-failed",
                "error-message": "Commit of transaction org.opendaylight.netconf.sal.connect.netconf.sal.tx.WriteCandidateTx@5f8be763 failed",
                "error-info": "RemoteDevice{junos-01}:RPC during tx returned an exceptionTask was cancelled."
            }
        ]
    }
}

Attached is a karaf.log snippet from when the rest request is sent and finally the
500 response is given.

The rpc response, seen above in the karaf.log snippet is very clear to the reason for the
failure and if delivered to the caller in the response text.



 Comments   
Comment by Andrej Mak [ 28/May/20 ]

https://jira.opendaylight.org/browse/NETCONF-645 - probably the same problem

Comment by Jamo Luhrsen [ 28/May/20 ]

agreed. I'll duplicate 645 up to 666 since there is more info on this ticket.

Generated at Wed Feb 07 20:15:35 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.