cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
313
Views
0
Helpful
3
Replies
Highlighted
Beginner

gnmi read operation on /openconfig-interfaces:interfaces/

The ydk-api generate is "/interfaces". How to append the origin yang name "/openconfig-interfaces:" to the path.

i.e., to generate path '/openconfig-interfaces:interfaces/'.

3 REPLIES 3
Highlighted
Cisco Employee

Are you referring in the RPC?  It is captured as the origin:

 

=============== Get Request Sent ================
path {
  origin: "openconfig-interfaces"
  elem {
    name: "interfaces"
  }
}
encoding: JSON_IETF


2020-02-20 19:34:47,233 - ydk - INFO - 
============= Get Response Received =============
notification {
  timestamp: 1582256075784914578
  update {
    path {
      origin: "openconfig-interfaces"
      elem {
        name: "interfaces"
      }
    }
    val {
      json_ietf_val: " // snipped "
    }
  }
}
error {
}
Highlighted

The YDK builds the path internally based on provided model API object. Therefore it is not clear from your post, what are you trying to accomplish. Could you please elaborate on your task and script.

Yan Gorelik
YDK Solutions
Highlighted

Thanks, Fixed by handling "origin" in gnmi-server.

This widget could not be displayed.