Uploaded image for project: 'netconf'
  1. netconf
  2. NETCONF-23

netconf: Un-helpful error message presented when no service provider is there to handle the RPC call.

    XMLWordPrintable

Details

    • 3015

    Description

      This was uncovered during execution of the Core Functionality Tutorials, Chapter 2.

      In the tutorial, an RPC call is made to a service provider before that code has been added.

      The expected response is:

      "error-type": "rpc",
      "error-tag": "operation-not-supported",
      "error-message": "No implementation for this operation is available."

      When this call is made:

      curl -H 'Content-Type: application/json' -X POST -d '{"input" : {"toaster:toasterDoneness" : "10","toaster:toasterToastType":"wheat-bread"}}' --verbose -u admin:admin http://localhost:8181/restconf/operations/toaster:make-toast

      The response is:

      "error-type":"application",
      "error-tag":"operation-failed",
      "error-message":"The operation encountered an unexpected error while executing."

      This error message does not lead the developer to the cause of the error message.

      Also, if there's a typo in the URL as follows:

      curl -H 'Content-Type: application/json' -X POST -d '{"input" : {"toaster:toasterDoneness" : "10","toaster:toasterToastType":"wheat-bread"}}' --verbose -u admin:admin http://localhost:8181/restconf/operations/toaster:toaster

      The error message is:

      "error-type":"protocol",
      "error-tag":"malformed-message",
      "error-message":"Error parsing input: Schema node with name input wasn't found."

      "malformed-message" is technically incorrect as the message is valid JSON syntax.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            martin.ciglan Martin Ciglan
            phillip.shea@hp.com Phillip Shea
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: